Jump to content

Enhanced List View


Marcher Technologies
 Share

Recommended Posts

%7Boption%7D


File Name: Enhanced List View

File Submitter: Marcher Technologies

File Submitted: 06 Jun 2012

File Category: User and Social Engagement

This Hook Will add an Advanced Gracefully-Degrading Ajaxed Paginated and filterable List View to IP.Calendar showing All Calendar Events to the Calendar with enhanced sorting/filtering options with ACP-Defined defaults per Calendar with an enhanced display for the Currently Viewed Calendar respecting event permissions and personal status.
Filters Include: All Events, Upcoming events, Past Events, Recurring Events, RSVP Requested Events, Month, Year, and My Submissions*.
Sorting Options include Event Submission, Event Last Update, Event Start, Event End, and Event Rating in Ascending and Descending order.
Has the ability to remember the user's Selections for all of the above options per Calendar using cookies.
*For members only, not definable as a default from ACP, not visible to guests.
Pagination per-page count is ACP-defined for each Calendar, and max is 50.
Birthdays are NOT included in this Listing.
This Hook will Also Allow you as the admin to choose the default view type for any given calendar.
Prefer a different view type than month as default? This mod does that. :smile:

here to download this file

Link to comment
Share on other sites

  • 4 weeks later...

Summary listing (to the right side) has dates and times incorrect.


Calendar posts are correct - but these summary dates are off by time setting offset (8 hours in my case).



post-25055-0-09408500-1341509387_thumb.p

forward or back?
I'Il double-check the code removing the offset before is sent to parse date again... >.> could swear I triple-checked that mess.
Need to know whether its off forward or back though.... parse date re-adds the user time offset, so i remove it in the code when gathering data so it is not added twice...
Link to comment
Share on other sites


forward or back?


I'Il double-check the code removing the offset before is sent to parse date again... >.> could swear I triple-checked that mess.


Need to know whether its off forward or back though.... parse date re-adds the user time offset, so i remove it in the code when gathering data so it is not added twice...



>.> and am unable to reproduce locally... is there a certain time or time zone triggering it?
As far as i can see in further testing, it matches the calendars dates/times to a tee... :unsure:
Link to comment
Share on other sites

Did you see the image I provided?
For example... the first event is July 11th - 7:00 pm to 8:30 pm
and the summary at the right says July 12th - 3:00 am to 4:30 am

Live link http://www.wffna.org/index.php?app=calendar&module=calendar&section=view&do=list&cal_id=1

I have only test in PDT.

Link to comment
Share on other sites


Thank you.


Sorry, but I do not see how being 1 hour off is "more correct".


Start time and end are the same whether there is DST or not.



no they are not.... sure, they are stored in the db the same, but the time is different(in fact, your tz would have to be exact GMT to see the 'real' date as it were not relative).
Calendar displays the time relative to the users offset, it does not take into account the DST as it is supposed to, hence the bug report confirmed.... im not gonna hack up my code again to remove the valid working DST offset should be working in calendar in the first place.
Link to comment
Share on other sites

  • 1 month later...

Just purchased and installed. got this error message after clicking on the calendar page, and yes, I did configure the calendar settings via calendar management:

Fatal error: Method calendarListView does not exist in mt_cal_listing_button in /var/www/vhosts/domain.com/httpdocs/forums/admin/sources/classes/output/publicOutput.php on line 3731

thanks

Brian

Link to comment
Share on other sites

yeah, that took care of it. thanks for the quick response. as an aside, I observe that if there are no events that are upcoming, and the calendar is set to display only upcoming events, the calendar view defaults to the month view. that's neither good nor bad, I guess. Just an observation.

also, I plan to add global sidebars to the existing calendar layout, causing a major squish. Do you anticipate any big problems? Or, would you be willing to speculate?

Thanks,

Brian

follow up comment: because we have 13 calendars, and some of them do have upcoming events and some don't, I need see a behavior where if I start with a calendar with upcoming events, and click on list view, and then go to another calendar without an upcoming event, and I get the monthly view (if that is the correct behavior), then when I click back to the first calendar, with upcoming events, I am now reverted to monthly view again, and I have to click list view again.

is there a way to set all calendars for list view by default and to revert?

Link to comment
Share on other sites

was just checking the display of the list view and yes, we have a similar issue as described by Loren above.

If you click on the event itself, it says quite plainly that the event is "
Taking place 19 Oct 2012 through 21 Oct 2012 (Ranged Event)"


and yet in the list view, it shows this:

Event Start: 18 Oct 2012
Event End: 20 Oct 2012
Type of Event: (Ranged Event)
Comments: 0 %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >
Request RSVP?: No

Notes of use to you:
our board is set for Paris - +1 GMT

me, as the creator of the event and as the logged in person viewing the event, albeit as the superadmin, the time at the very bottom of the user profile shows this: Time Now: 24 Aug 2012 1340 (that is LA time) ...

Link to comment
Share on other sites

umm, will look further, and am very freaking likely going to forego parse date and it's formatting options and just show the split nums right from the sql(STILL don't fathom the use of a dang DATETIME field here, a uni is a constant set, date-time changes in storage by sql server afaik corrupting it, I cannot truly even say calendar has it right(DST wth!!!), which makes this doubly painful).

Link to comment
Share on other sites

Fixed, it matches the calendar to the nth degree, if something is off in regards to times/dates, they would be off in calendar as well(same code for formatting/parsing/handling offsets as in the event view).
Also got around to fixing something that bugged me for ages, double-clicking the box an event appears in will take you to that event, rather than the day it occurs on.

Link to comment
Share on other sites

thanks and darn it! I know you are bashing your head against a wall on this app.

alas, don't have good news. well, the list view does remain without any calendar events upcoming so that's good but ...

now the ranged event on one of our calendars is listed as such:

Taking place: 19 Oct 2012
Type of Event: (Single Day Event)
Comments: 0 %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >
Request RSVP?: No

and yet ... the calendar event when you click on it confirms it is indeed a ranged event:

Taking place 19 Oct 2012 through 21 Oct 2012 (Ranged Event)

Link to comment
Share on other sites


thanks and darn it! I know you are bashing your head against a wall on this app.



alas, don't have good news. well, the list view does remain without any calendar events upcoming so that's good but ...



now the ranged event on one of our calendars is listed as such:



Taking place: 19 Oct 2012


Type of Event: (Single Day Event)


Comments: 0 %7Boption%7D

' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D

' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D

' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D

' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D

' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >


Request RSVP?: No



and yet ... the calendar event when you click on it confirms it is indeed a ranged event:



Taking place 19 Oct 2012 through 21 Oct 2012 (Ranged Event)



:unsure: how...... need access... this makes no sense unless the Calendar data itself is being pulled from a stale cache whereas I am pulling it fresh from DB..... ranged events are appearing correctly locally.
Link to comment
Share on other sites

did you make a strategic choice in the template to forego the start and end date in a ranged event. here is the latest output (maybe be a different event but ranged all the same):

Taking place: 27 Oct 2012
Type of Event: (Ranged Event)
Comments: 0 %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' > %7Boption%7D' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >' alt='' class='ipsImage' >
Request RSVP?: No


just feedback ... would much prefer this format:

Event Start: 18 Oct 2012
Event End: 20 Oct 2012
Type of Event: (Ranged Event)

but with correct dates, of course!

Link to comment
Share on other sites

oh, sorry, hopefully last relay of bad news ...

just checked all 13 calendars and they all have settings as list view as the default

so I logged out of my super admin account, logged in on one of my personal accounts, and saw month view again on some of the calendars. thought it might be a previous visit thing so logged out again, and this time, logged in as a very unused member account and again found default view of calendars was month ... is this a cookie thing on my laptop?

Link to comment
Share on other sites


oh, sorry, hopefully last relay of bad news ...



just checked all 13 calendars and they all have settings as list view as the default



so I logged out of my super admin account, logged in on one of my personal accounts, and saw month view again on some of the calendars. thought it might be a previous visit thing so logged out again, and this time, logged in as a very unused member account and again found default view of calendars was month ... is this a cookie thing on my laptop?



It *does* remember user preference for filters, but for the default view, no, it should honor your ACP config, moreover it should enforce the selected default view, and has nothing to do with cookies.
http://www.marcherte...board/calendar/ confused, just after seeing this after importing the hook to my live for this last template twitch changed my default....
Are you switching calendars via the top drop-down? it sends the month parameter... seems I need to strip that with another hook as if the month/week/day is defined in the request I have to give said view sway... not a quick fix but am working on it.... no apparent hook points factually viable for this..... probably going to have to skin overload it and swap in a custom template in whole....


<if test="gotcalendars:|:is_array( $calendars ) && count( $calendars ) > 1">

<span class='desc calendar_jump clearfix'>{$this->lang->words['cal_in']} <a href='#calendar_chooser_menucontent' title='{$this->lang->words['switch_calendar']}' class='calendar_dropdown ipsButton_secondary' id='calendar_chooser'><strong>{$calendar['cal_title']}</strong> <img src='{$this->settings['img_url']}/dropdown.png' /></a></span>

<ul class='ipbmenu_content' style='display: none' id='calendar_chooser_menucontent'>

  <foreach loop="calendars:$calendars as $cid => $cal">

   <li class='clearfix'>

    <a href='{parse url="app=calendar&amp;module=calendar&amp;section=view&amp;cal_id={$cid}&amp;m={$chosen_date['month']}&amp;y={$chosen_date['year']}" base="public" seotitle="{$cal['cal_title_seo']}" template="cal_month"}' title="{$this->lang->words['view_this_calendar']}">{$cal['cal_title']}</a>

   </li>

  </foreach>

</ul>

<script type='text/javascript'>

  new ipb.Menu( $('calendar_chooser'), $('calendar_chooser_menucontent') );

</script>

<else />

<span class='desc calendar_jump blend_links'>{$this->lang->words['cal_in']} <strong><a href='{parse url="app=calendar&amp;module=calendar&amp;section=view&amp;cal_id={$calendar['cal_id']}&amp;m={$chosen_date['month']}&amp;y={$chosen_date['year']}" base="public" seotitle="{$calendar['cal_title_seo']}" template="cal_month"}' title="{$this->lang->words['view_this_calendar']}" class='rounded'>{$calendar['cal_title']}</a></strong></span>

</if>


see the $chosen_date vars in the url? those are over-riding the default view.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...