root/trunk/calendar3/webclient/war/docs/header.jsp

Revision 81 (checked in by johnsa, 7 years ago)

updated ical download in public stylsheet to work with new export action
modified ical and vcal skins to use new export data

Line 
1 <!DOCTYPE ucalendar
2 [
3   <!ENTITY nbsp "&#160;">
4 ]>
5 <%@ page contentType="text/xml;charset=UTF-8" language="java" %>
6 <%@ taglib uri='struts-bean' prefix='bean' %>
7 <%@ taglib uri='struts-logic' prefix='logic' %>
8 <%@ taglib uri='struts-genurl' prefix='genurl' %>
9 <%
10 try {
11 %>
12
13 <ucalendar>
14   <now><%-- The actual date right "now" - this may not be the same as currentdate --%>
15     <date><bean:write name="calForm" property="today.dateDigits"/></date><%--
16       Value: YYYYMMDD --%>
17     <longdate><bean:write name="calForm" property="today.longDateString"/></longdate><%--
18       Value (example): February 8, 2004 - long representation of the date --%>
19     <shortdate><bean:write name="calForm" property="today.dateString"/></shortdate><%--
20       Value (example): 2/8/04 - short representation of the date --%>
21     <time><bean:write name="calForm" property="today.timeString"/></time><%--
22       Value (example): 10:15 PM --%>
23   </now>
24   <bean:define id="ctView" name="calForm" property="curTimeView"/>
25   <currentdate><%-- The current user-selected date --%>
26     <date><bean:write name="ctView" property="curDay.dateDigits"/></date><%--
27       Value: yyyymmdd - date value --%>
28     <longdate><bean:write name="ctView"
29                           property="curDay.fullDateString"/></longdate><%--
30       Value (example): Wednesday, February 11, 2004 --%>
31     <shortdate><bean:write name="ctView" property="curDay.dateString"/></shortdate><%--
32       Value (example): 2/8/04 - short representation of the date --%>
33     <monthname><bean:write name="ctView" property="curDay.monthName"/></monthname><%--
34       Value (example): January - full month name --%>
35   </currentdate>
36   <firstday><%-- The first date appearing in the currently selected time period --%>
37     <date><bean:write name="ctView" property="firstDay.dateDigits"/></date><%--
38       Value: yyyymmdd - date value --%>
39     <longdate><bean:write name="ctView"
40                           property="firstDay.fullDateString"/></longdate><%--
41       Value (example): Wednesday, February 11, 2004 --%>
42     <shortdate><bean:write name="ctView" property="firstDay.dateString"/></shortdate><%--
43       Value (example): 2/8/04 - short representation of the date --%>
44     <monthname><bean:write name="ctView" property="firstDay.monthName"/></monthname><%--
45       Value (example): January - full month name --%>
46   </firstday>
47   <lastday><%-- The last date appearing in the currently selected time period --%>
48     <date><bean:write name="ctView" property="lastDay.dateDigits"/></date><%--
49       Value: yyyymmdd - date value --%>
50     <longdate><bean:write name="ctView"
51                           property="lastDay.fullDateString"/></longdate><%--
52       Value (example): Wednesday, February 11, 2004 --%>
53     <shortdate><bean:write name="ctView" property="lastDay.dateString"/></shortdate><%--
54       Value (example): 2/8/04 - short representation of the date --%>
55     <monthname><bean:write name="ctView" property="lastDay.monthName"/></monthname><%--
56       Value (example): January - full month name --%>
57   </lastday>
58   <previousdate><bean:write name="ctView" property="prevDate"/></previousdate><%--
59     Value: YYYYMMDD - The previous "firstdate" in the selected time period  --%>
60   <nextdate><bean:write name="ctView" property="nextDate"/></nextdate><%--
61     Value: YYYYMMDD - The next "firstdate" in the selected time period --%>
62   <periodname><bean:write name="ctView" property="periodName"/></periodname><%--
63     Values: Day, Week, Month, Year - The current time period name.   --%>
64   <multiday><bean:write name="ctView" property="multiDay"/></multiday><%--
65     Values: true, false - Flag if we are viewing multiple days --%>
66   <hour24><bean:write name="calForm" property="hour24" /></hour24><%--
67     Values: true, false - Flag if we are using 24 hour time --%>
68
69   <logic:present name="calForm" property="currentView" >
70     <name><bean:write name="calForm" property="currentView.name"/></name><%--
71       Value: string - Name of selected view for display --%>
72     <viewid><bean:write name="calForm" property="currentView.id"/></viewid><%--
73       Value: string - String ID of selected view for display --%>
74   </logic:present>
75   <logic:notPresent name="calForm" property="currentView" >
76     <name>All</name>
77     <viewid>-1</viewid>
78   </logic:notPresent>
79   <search><bean:write name="calForm" property="search"/></search><%--
80     Value: string - Current search string for display --%>
81
82   <publicview><bean:write name="calForm" property="publicView" /></publicview><%--
83     Values: true, false - Flag if we are in the guest (public) view  --%>
84   <guest><bean:write name="calForm" property="guest" /></guest><%--
85     Value: true, false - Flag if we are a guest --%>
86   <logic:equal name="calForm" property="guest" value="false">
87     <userid><bean:write name="calForm" property="currentUser" /></userid><%--
88       Value: string - Userid of non-guest user --%>
89   </logic:equal>
90
91   <logic:iterate id="msg" name="calForm" property="msg.msgList">
92     <message>
93       <id><bean:write name="msg" property="msgId" /></id>
94       <logic:iterate id="param" name="msg" property="params" >
95         <param><bean:write name="param" /></param>
96       </logic:iterate>
97     </message>
98   </logic:iterate>
99
100   <logic:iterate id="errBean" name="calForm" property="err.msgList">
101     <error>
102       <id><bean:write name="errBean" property="msgId" /></id>
103       <logic:iterate id="param" name="errBean" property="params" >
104         <param><bean:write name="param" /></param>
105       </logic:iterate>
106     </error>
107   </logic:iterate>
108
109   <approot><bean:write name="calForm" property="presentationState.appRoot"/></approot><%--
110         Value: URI - the location of web resources used by the code to find the
111         XSLT files.  This element is defined prior to build in
112         ../../../../clones/democal.properties
113         as pubevents.app.root and personal.app.root. Note that references to
114         html web resources such as images are set in the xsl stylesheets. --%>
115   <urlprefix><bean:write name="calForm" property="urlPrefix"/></urlprefix><%--
116         Value: URI - this is prefix of the calendar application.
117         e.g. http://localhost:8080/cal
118         Use this value to prefix calls to the application actions in your XSLT.
119         e.g. <a href="{$urlPrefix}/eventView.do?eventId=8">View Event</a> --%>
120   <urlpattern><genurl:rewrite action="DUMMYACTION.DO" /></urlpattern>
121
122   <personaluri><bean:message key="org.bedework.personal.calendar.uri"/></personaluri>
123   <publicuri><bean:message key="org.bedework.public.calendar.uri"/></publicuri>
124   <adminuri><bean:message key="org.bedework.public.admin.uri"/></adminuri>
125   <bean:define id="personalUri"><bean:message key="org.bedework.personal.calendar.uri"/></bean:define>
126   <urlPrefixes>
127     <%-- render urls --%>
128     <initialise><genurl:rewrite forward="initialise"/></initialise>
129     <showCals><genurl:rewrite forward="showCals"/></showCals>
130     <eventMore><genurl:rewrite forward="eventMore"/></eventMore>
131     <initUpload><genurl:rewrite forward="initUpload"/></initUpload>
132
133     <%-- action urls --%>
134     <setup><genurl:rewrite action="setup.do"/></setup>
135     <selectView><genurl:rewrite action="selectView.do"/></selectView>
136     <setView><genurl:rewrite action="setView.do"/></setView>
137     <eventView><genurl:rewrite action="eventView.do"/></eventView>
138     <initEvent><genurl:rewrite action="initEvent.do"/></initEvent>
139     <addEvent><genurl:rewrite action="addEvent.do"/></addEvent>
140     <addEventUsingPage><genurl:rewrite action="addEventUsingPage.do"/></addEventUsingPage>
141     <editEvent><genurl:rewrite action="editEvent.do"/></editEvent>
142     <delEvent><genurl:rewrite action="delEvent.do"/></delEvent>
143     <mailEvent><genurl:rewrite action="mailEvent.do"/></mailEvent>
144     <showPage><genurl:rewrite action="showPage.do"/></showPage>
145     <manageLocations><genurl:rewrite action="manageLocations.do"/></manageLocations>
146     <addLocation><genurl:rewrite action="addLocation.do"/></addLocation>
147     <editLocation><genurl:rewrite action="editLoc.do"/></editLocation>
148     <delLocation><genurl:rewrite action="delLocation.do"/></delLocation>
149     <subscribe><genurl:rewrite action="subscribe.do"/></subscribe>
150     <export><genurl:rewrite action="export.do"/></export>
151
152     <initEventAlarm><genurl:rewrite action="initEventAlarm.do"/></initEventAlarm>
153     <setAlarm><genurl:rewrite action="setAlarm.do"/></setAlarm>
154     <addEventRef><genurl:rewrite action="addEventRef.do"/></addEventRef>
155     <upload><genurl:rewrite action="upload.do"/></upload>
156   </urlPrefixes><%--
157         actionUrlPrefixes are used to generate appropriately encoded urls for
158         calls into the application; these are required for use within portals --%>
159   <confirmationid><bean:write name="calForm" property="confirmationId"/></confirmationid><%--
160         Value: String - a 16 character random string used to allow users to confirm
161         additions to thier private calendar --%>
162   <logic:iterate id="appvar" name="calForm" property="appVars">
163     <appvar><%--
164         Application variables can be set arbitrarily by the stylesheet designer.
165         Use an "appvar" by adding setappvar=key(value) to the query string of
166         a URL.  This feature is useful for setting up state during a user's session.
167         e.g. <a href="{$urlPrefix}/eventView.do?eventId=8&setappvar=currentTab(event)">View Event</a>
168         To change the value of an appvar, call the same key with a different value.
169         e.g. <a href="{$urlPrefix}/setup.do?setappvar=currentTab(home)">Return Home</a>
170         If appvars exist, they will be output in the following form:  --%>
171       <key><bean:write name="appvar" property="key" /></key>
172       <value><bean:write name="appvar" property="value" /></value>
173
174       <logic:equal name="appvar" property="key" value="summaryMode"><%--
175         This is a special use of the appvar feature.  Normally, we don't return
176         all details about events except when we display a single event (to keep the
177         XML lighter).  To return all event details in an events listing, append a
178         query string with setappvar=summaryMode(details).  Turn the detailed view
179         off with setappvar=summaryMode(summary).--%>
180         <logic:equal name="appvar" property="value" value="details">
181           <bean:define id="detailView" value="true" toScope="request"/><%--
182             Send this bean to the request scope so we can test for it on the page
183             that builds the calendar tree (main.jsp) --%>
184         </logic:equal>
185       </logic:equal>
186     </appvar>
187   </logic:iterate>
188 <%
189 } catch (Throwable t) {
190   t.printStackTrace();
191 }
192 %>
193
Note: See TracBrowser for help on using the browser.