summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorNick Palmer <nick@sluggardy.net>2007-04-05 18:33:12 +0000
committerNick Palmer <nick@sluggardy.net>2007-04-05 18:33:12 +0000
commit16f093924f550889173b5cfaeb0e7aee50ea12d1 (patch)
tree1e110463f08b279ad8f7443c4990fbcbbb859455 /templates
parenta4ba68fca33a1532c95b30eafa5883d21edb96a1 (diff)
downloadcalendar-16f093924f550889173b5cfaeb0e7aee50ea12d1.tar.gz
calendar-16f093924f550889173b5cfaeb0e7aee50ea12d1.tar.bz2
calendar-16f093924f550889173b5cfaeb0e7aee50ea12d1.zip
Added better integration with events at the expense of queries. Will ajaxify sometime soon to reduce the cost. Added p_calendar_view_changes which needs to be on for users to use the calendar the old way.
Diffstat (limited to 'templates')
-rw-r--r--templates/calendar.tpl11
-rw-r--r--templates/calendar_box.tpl9
-rw-r--r--templates/calendar_nav_inc.tpl4
3 files changed, 18 insertions, 6 deletions
diff --git a/templates/calendar.tpl b/templates/calendar.tpl
index 6cd3e4b..314f1e7 100644
--- a/templates/calendar.tpl
+++ b/templates/calendar.tpl
@@ -1,4 +1,4 @@
-{* $Header: /cvsroot/bitweaver/_bit_calendar/templates/calendar.tpl,v 1.43 2006/09/03 20:05:42 squareing Exp $ *}
+{* $Header: /cvsroot/bitweaver/_bit_calendar/templates/calendar.tpl,v 1.44 2007/04/05 18:33:12 nickpalmer Exp $ *}
{strip}
{if !$gBitSystem->isFeatureActive( 'site_help_popup' )}
{popup_init src="`$smarty.const.UTIL_PKG_URL`javascript/libs/overlib.js"}
@@ -115,10 +115,11 @@
{/if}
</table>
{/jstab}
-
- {jstab title="Display Options"}
- {include file="bitpackage:calendar/calendar_options_inc.tpl"}
- {/jstab}
+ {if $gBitUser->hasPermission('p_calendar_view_changes')}
+ {jstab title="Display Options"}
+ {include file="bitpackage:calendar/calendar_options_inc.tpl"}
+ {/jstab}
+ {/if}
{/jstabs}
</div><!-- end .body -->
</div><!-- end .calendar -->
diff --git a/templates/calendar_box.tpl b/templates/calendar_box.tpl
index f699604..e434f8a 100644
--- a/templates/calendar_box.tpl
+++ b/templates/calendar_box.tpl
@@ -1,5 +1,12 @@
+{strip}
<div class="calendar popup box">
<h3>{$cellHash.title|escape}</h3>
+ {if $cellHash.content_type_guid == 'bitevents' && $gBitSystem->isPackageActive('events')}
+ <div class="center">
+ {include file="bitpackage:events/render_header_inc.tpl" contentHash=$cellHash}
+ </div>
+ {/if}
+ {if $gBitUser->hasPermission('p_calendar_view_changes')}
<div class="boxcontent">
{tr}Content Type{/tr}: {$cellHash.content_description}
<br />
@@ -7,4 +14,6 @@
<br />
<strong>{tr}Last modified{/tr}</strong>: {displayname login=$cellHash.modifier_user real_name=$cellHash.modifier_real_name}<br />{$cellHash.last_modified|cal_date_format:"%Y-%m-%d - %H:%M %Z"}
</div>
+ {/if}
</div>
+{/strip}
diff --git a/templates/calendar_nav_inc.tpl b/templates/calendar_nav_inc.tpl
index 206d669..80e2f36 100644
--- a/templates/calendar_nav_inc.tpl
+++ b/templates/calendar_nav_inc.tpl
@@ -6,9 +6,11 @@
{else}
<li>{smartlink ititle="Only my items" user_id=$gBitUser->mUserId sort_mode=$smarty.request.sort_mode}</li>
{/if}
+ {if $gBitUser->hasPermission('p_calendar_view_changes')}
<li>{smartlink ititle="Creation date" isort="created"}</li>
<li>{smartlink ititle="Modification date" isort="last_modified"}</li>
<li>{smartlink ititle="Event time" idefault=1 isort="event_time"}</li>
+ {/if}
</ul>
</div>
@@ -34,7 +36,7 @@
{rdelim}
/* ]]> */</script>
- {jscalendar inputField=todate time=$navigation.focus_date onUpdate=gotocal displayArea=datrigger}
+ {jscalendar inputField=todate time=$navigation.focus_date onUpdate=gotocal displayArea=datrigger daFormat=$gBitSystem->getConfig('site_long_date_format')}
</td>
<td style="white-space:nowrap; width:140px; text-align:right;">
<a href="{$smarty.const.CALENDAR_PKG_URL}index.php?view_mode=day&amp;{$url_string}" class="{if $smarty.session.calendar.view_mode eq 'day'}highlight{/if}">{biticon ipackage=calendar iname=day iexplain=Day}</a>