Share Pastebin
Guest
Public paste!

pigeonflight

By: a guest | Mar 18th, 2010 | Syntax: HTML | Size: 12.96 KB | Hits: 34 | Expires: Never
Copy text to clipboard
  1. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
  2.      lang="en"
  3.      metal:use-macro="here/main_template/macros/master"
  4.      i18n:domain="plone">
  5. <body>
  6.  
  7. <div metal:fill-slot="main" tal:define="view context/@@summary;
  8.                                        country_name view/country_name;
  9.                                        full_location view/full_location;
  10.                                        meeting_url context/absolute_url;
  11.                                        backtotop string:$meeting_url#meeting_top;
  12.                                       " >
  13.  <h2><span tal:content="structure context/Title"></span>
  14.      - <span tal:content="full_location" /></h2>
  15.  
  16. <!-- meeting details (dates etc...) -->
  17. <!-- meeting dates -->
  18.        <h3 id="meeting_date"  tal:condition="context/startDate|nothing">
  19.                    <tal:block define="
  20.                                      meetingstart python:context.toLocalizedTime(DateTime.Date(context.startDate),long_format=0);
  21.                                      meetingend python:context.toLocalizedTime(DateTime.Date(context.endDate),long_format=0);
  22.                                      spandays python:meetingstart != meetingend">
  23.                         <tal:spandays tal:condition="spandays"
  24.                                     tal:define="ampm python:site_properties.getProperty('localLongTimeFormat').find('%p') >= 0">
  25.                             <span tal:replace="meetingstart">Start Date Time</span>
  26.                             <span i18n:translate="event_to">to</span>
  27.                             <span tal:replace="meetingend" />
  28.                         </tal:spandays>
  29.                         <tal:sameday tal:condition="not:spandays"
  30.                                     tal:define="ampm python:site_properties.getProperty('localLongTimeFormat').find('%p') >= 0">
  31.                             <span tal:replace="meetingstart">Start Date Time</span>
  32.                             <!--<span tal:replace="python:context.startDate()" />-->
  33.                         </tal:sameday>
  34.                   </tal:block>
  35.        </h3>
  36.        <tal:nodate tal:condition="not: context/start|nothing">
  37.         <h3 class="discreet">dates not finalized</h3>
  38.        </tal:nodate>
  39.  <!-- meeting description -->
  40.  <p class="documentDescription" tal:content="context/Description" />
  41.  
  42. <!-- meeting announcement -->
  43.  <h3 class="heading" tal:condition="context/getText|nothing">Announcements</h3><a name="announcements"></a>
  44.  <p tal:content="structure context/getText" />
  45.  
  46.  
  47. <metal:block tal:define="
  48.                          can_edit python:checkPermission('Modify portal content', context);
  49.                          travel_info context/getTravel_visa|nothing;
  50.                          travel_info_there python:len(travel_info) > 20;
  51.                           accomodation_info context/getTravel_hotel|nothing;
  52.                           accomodation_info_there python:len(accomodation_info) > 20;
  53.                           registration_info context/getRegistration |nothing;
  54.                           list_of_documents_info context/getList_of_documents|nothing;
  55.                           collections python:view.meeting_contents(type='MeetingDocumentCollection');">
  56. <h3 class="heading"
  57. tal:condition="python:registration_info or accommodation_info_there or travel_info_there"
  58. >Participant Information</h3><a name="announcements"></a>
  59. <!-- meeting registration -->
  60. <metal:noreg tal:condition="not:registration_info">
  61.  
  62.  <div tal:condition="can_edit" class="portalMessage">
  63.  <h3>no registration information</h3>
  64.  <a tal:condition="can_edit" href="base_edit?fieldset=Registration"><img src="add_icon.gif"  />add registration information</a>
  65.  </div>
  66. </metal:noreg>
  67. <metal:registration tal:condition="registration_info">
  68.  <h3><a name="registration_information"></a>Registration Information
  69. <a class="anchor-link"
  70. tal:attributes="href backtotop;"
  71. href="#meeting_top">[top]</a>
  72. </h3>
  73. <metal:doclist tal:repeat="document registration_info">
  74. <tal:definitions tal:define="
  75.                             icon document/getIcon |nothing;
  76.                             url document/absolute_url|nothing;
  77.                             title document/Title|nothing;"
  78. >
  79.  
  80.  <a tal:condition="can_edit" href="base_edit?fieldset=Registration"><img src="edit.gif"  />[edit]</a>
  81. <p class="discreet">details for registering for this event</p>
  82.  <a href="" tal:attributes="href url">
  83.  <img src="download_icon.gif" /><img src="" tal:attributes="src icon"/><p tal:omit-tag="" tal:content="title" />
  84. </a> &nbsp;
  85.  <a tal:condition="can_edit" href="" tal:attributes="title string:edit ${title};href string:${url}/edit"><img src="edit.gif"  />[edit]</a>
  86. </tal:definitions>
  87. </metal:doclist>
  88. </metal:registration>
  89. <!-- meeting travel accomodation -->
  90. <metal:notravel_hotel tal:condition="not:accomodation_info_there">
  91.  
  92.  <div tal:condition="can_edit" class="portalMessage">
  93.  <h3>no accomodation information</h3>
  94.  <a tal:condition="can_edit" href="base_edit?fieldset=Travel%20and%20Accomodation#travel_hotel_help"><img src="add_icon.gif"  />add accomodation information</a>
  95.  </div>
  96. </metal:notravel_hotel>
  97. <metal:travel_hotel tal:condition="accomodation_info_there">
  98.  <h3><a name="accomodation_information"></a>Accomodation Information
  99. <a class="anchor-link"
  100. tal:attributes="href backtotop;"
  101. href="#meeting_top">[top]</a>
  102. </h3>
  103.  
  104.  <a tal:condition="can_edit" href="base_edit?fieldset=Travel%20and%20Accomodation#travel_hotel_help"><img src="edit.gif"  />[edit]</a>
  105.  <p tal:content="structure context/getTravel_hotel" />
  106. </metal:travel_hotel>
  107. <!-- meeting travel visa -->
  108. <metal:novisa tal:condition="not:travel_info_there">
  109.  
  110.  <div tal:condition="can_edit" class="portalMessage">
  111.  <h3>no visa information</h3>
  112.  <a tal:condition="can_edit" href="base_edit?fieldset=Travel%20and%20Accomodation#travel_hotel_help"><img src="add_icon.gif"  />add visa information</a>
  113.  </div>
  114. </metal:novisa>
  115. <metal:visa tal:condition="travel_info_there">
  116.  <h3><a name="travel_information"></a>Travel Information
  117. <a class="anchor-link"
  118. tal:attributes="href backtotop;"
  119. href="#meeting_top">[top]</a>
  120. </h3>
  121.  
  122.  <a tal:condition="can_edit" href="base_edit?fieldset=Travel%20and%20Accomodation#travel_visa_help"><img src="edit.gif"  />[edit]</a>
  123.  <p tal:content="structure context/getTravel_visa" />
  124. </metal:visa>
  125. <metal:not-collections tal:condition="not: collections">
  126. <div class="no-meeting-documents portalMessage" tal:condition="can_edit">   <h3> no meeting documents </h3>
  127. <a href="createObject?type_name=MeetingDocumentCollection"><img src="add_icon.gif" />add a meeting document collection</a>
  128. </div>
  129. </metal:not-collections>
  130. <metal:collections tal:condition="collections">
  131.  <h3 class="heading"><a name="meeting_documents"></a>Meeting Documents
  132.   <a class="anchor-link"
  133. tal:attributes="href backtotop;"
  134. href="#meeting_top">[top]</a>
  135. </h3>
  136. <!-- meeting list of documents -->
  137. <metal:nolist_of_documents tal:condition="not:list_of_documents_info">
  138.  
  139.  <div tal:condition="can_edit" class="portalMessage">
  140.  <h3>no list_of_documents information</h3>
  141.  <a tal:condition="can_edit" href="base_edit?fieldset=List%20of%20documents"><img src="add_icon.gif"  />add list of documents information</a>
  142.  </div>
  143. </metal:nolist_of_documents>
  144. <metal:list_of_documents tal:condition="list_of_documents_info">
  145.  <h4><a name="list_of_document_information"></a>List of Meeting Documents</h4>
  146.  
  147.  <a tal:condition="can_edit" href="base_edit?fieldset=List%20of%20documents"><img src="edit.gif"  />[edit]</a>
  148. <p class="discreet">list of documents for meeting</p>
  149. <metal:doclist tal:repeat="document list_of_documents_info">
  150. <tal:definitions tal:define="icon document/getIcon|nothing;
  151.                             url document/absolute_url|nothing;
  152.                             title document/Title|nothing;"
  153. >
  154.  <a href="" tal:attributes="href url">
  155.  <img src="download_icon.gif" /><img src="" tal:attributes="src icon"/><p tal:omit-tag="" tal:content="title" />
  156. </a>
  157. &nbsp;
  158.  <a tal:condition="can_edit" href="" tal:attributes="title string:edit ${title};href string:${url}/edit"><img src="edit.gif"  />[edit]</a>
  159.  <a tal:condition="nothing" tal:attributes="href string:${url}/delete_confirmation"><img src="delete_icon.gif"  />[delete]</a>
  160. </tal:definitions>
  161. <br />
  162. </metal:doclist>
  163. </metal:list_of_documents>
  164.   <div tal:repeat="collection collections">
  165.     <metal:define tal:define="collection_title collection/Title;
  166.                              collection_url collection/getId;
  167.                              meeting_docs collection/getDocuments;
  168.                              " >
  169.         <a name="" tal:attributes="name python:collection_title.replace(' ','-')"></a>
  170. <metal:edit tal:condition="can_edit">
  171.                   <div class="portalMessage no-meeting-docs" tal:condition="not: meeting_docs">
  172.                    
  173.                   <span tal:omit-tag="" tal:content="collection_title"></span>
  174.                   has no documents
  175.         <a tal:condition="can_edit" href="" tal:attributes="href string:$collection_url/edit" ><img src="add_icon.gif" />
  176.                  add documents</a> </div>
  177. </metal:edit>
  178.                  
  179.         <dl class="collapsible xcollapsedBlockCollapsible"
  180.                  tal:condition="meeting_docs">
  181.          <dt class="collapsibleHeader" tal:attributes="class string:$collection_title $collection_url collapsibleHeader">
  182.         <span tal:omit-tag="" tal:content="collection_title"></span> <a class="toplink"
  183. tal:attributes="href backtotop;"
  184. href="#meeting_top">[top]</a>
  185.         <a tal:condition="can_edit" href="" tal:attributes="href string:$collection_url/edit" ><img src="add_icon.gif" />[add/remove]</a>
  186.         </dt>
  187.         <dd class="collapsibleContent meeting-docs">
  188.         <table>
  189.                 <metal:tr tal:repeat="document meeting_docs">
  190.                  <metal:document
  191.                       tal:define="doc_code_title document/document;
  192.                                   doc_code_split python:context.splitonpipe(doc_code_title);
  193.                                   doc_code doc_code_split/code;
  194.                                   doc_title doc_code_split/title;
  195.                                   "
  196.                           >
  197.                   <tr>
  198.                   <td class="doc_code" tal:content="doc_code"></td><td class="doc_title" colspan="3" tal:content="doc_title">this will be the title of the document</td>
  199.                   </tr>
  200.                   <tr>
  201.                   <td></td>
  202.                     <td>
  203.                     <metal:block
  204.                        tal:repeat="key python:[language for language in document.keys() if language != 'document']"
  205.                                 >
  206.                    <tal:definitions tal:define="docid python:document[key];
  207.                                          query python:{'UID':docid,};
  208.                                          doc_brain python:context.portal_catalog.searchResults(query);
  209.                                          "
  210.                                >
  211.                   <span class="doc-cell">
  212.                        <tal:doclink    tal:condition="python:len(doc_brain) > 0">
  213.                        <tal:definitions define="doc_brain python:doc_brain[0];
  214.                                                url doc_brain/getURL;
  215.                                                edit_url string:$url/edit#title;
  216.                                                icon doc_brain/getIcon;
  217.                                                size doc_brain/getObjSize;
  218.                                                description doc_brain/Description;
  219.                                                title doc_brain/Title;
  220.                                                title_snip python:title[:14] + '...';
  221.                                                doc_lang python:{'english':'[English]','spanish':'[Espanol]','french':'[Francais]'}[key];">
  222.  
  223.                        <a class="meeting-doc-link" href=""
  224.                        tal:attributes="href url"><img src="" tal:attributes="src icon" /><span tal:omit-tag="" tal:content="string:$doc_lang">[English]</span></a>
  225.                           <span class="discreet doc-size" tal:content="size"></span>
  226.                           <span class="discreet doc-title" tal:attributes="title string:$title - $description" tal:content="title_snip"></span>
  227.                           <a class="can_edit" tal:condition="can_edit" tal:attributes="href edit_url;title string:edit this document"><img src="edit.gif" />- edit</a>
  228.                       </tal:definitions>
  229.                        </tal:doclink>
  230.                   </span>
  231.                   </tal:definitions>
  232.                    </metal:block>
  233.                    </td>
  234.                   </tr>
  235.                 </metal:document>
  236.                 </metal:tr>
  237.          </table>    
  238.         </dd>
  239.        </dl>
  240.  
  241.     </metal:define>
  242.  </div>
  243. </metal:collections>
  244.         <div id="contact">
  245.         <h3 class="heading">Contact</h3>
  246.         <a name="contact" class="anchor-link"
  247. tal:attributes="href backtotop;"
  248. href="#meeting_top">[top]</a>