File:  [Repository] / cdli / zpt / BasketVersionMain.zpt
Revision 1.4: download - view: text, annotated - select for diffs - revision graph
Tue Feb 28 15:17:52 2006 UTC (18 years, 4 months ago) by dwinter
Branches: MAIN
CVS tags: HEAD
changes in baskets

    1: <html metal:use-macro="here/main_template/macros/page">
    2:  <tal:block metal:fill-slot="body" tal:define="results  here/getContent;
    3:                     start request/start|python:0;
    4:                     batch python:modules['ZTUtils'].Batch(results, 
    5:                                                           size=20, 
    6:                                                           start=start);
    7:                     previous python:batch.previous;
    8:                     next python:batch.next">
    9: 
   10:   <h2>Basket: <span tal:replace="python:here.aq_parent.title"/></h2>
   11:   <p>contains <span tal:replace="here/numberOfItems"/> items
   12:   <a tal:attributes="href python:here.aq_parent.absolute_url()+'/history'">View history</a>
   13:   </p>
   14:   <p><a tal:attributes="href python:here.getId()+'/downloadObjectsAsOneFile'"> download basket (combined in one file)</a>
   15:  <p><a tal:attributes="href python:here.getId()+'/downloadObjectsAsOneFile?lock=yes'"> download basket and lock all files(combined in one file)</a>
   16:  
   17:   <p>
   18:     <a tal:condition="previous"
   19:        tal:attributes="href string:${request/URL0}?start:int=${previous/first}"
   20:        href="previous_url">previous <span tal:replace="previous/length">20</span> results</a>
   21:     <a tal:condition="next"
   22:        tal:attributes="href string:${request/URL0}?start:int=${next/first}"
   23:        href="next_url">next <span tal:replace="next/length">20</span> results</a>
   24:   </p>
   25:  <form action="basket/deleteObjects">
   26:  <table  width="100%" border=0 cellspacing=1 cellpadding=2>
   27:     <tr>
   28:       <th align=left bgcolor="#88ff88">
   29:       <a href="?sortField=title"> File</a>
   30:       </th>
   31:       <th align=left bgcolor="#00">
   32: 	<a>Rev.</a>
   33:       </th>
   34:       <th align=left bgcolor="#cccccc">
   35: 	<a href="?sortField=date">Date</a>
   36:       </th>
   37:       <th align=left bgcolor="#cccccc">
   38: 	<a href="?sortField=author">Author</a>
   39:       </th>
   40:       <th align=left bgcolor="#cccccc">
   41: 	<a >Last log entry</a>
   42:       </th>
   43:       <th align=left bgcolor="#cccccc" width="80">
   44: 	<a href="?sortField=comment">Comment</a>
   45:       </th>
   46:       <th align=left bgcolor="#cccccc">
   47: 	<a>Download<br><font size="-1"><a tal:attributes="href python:here.absolute_url()+'/helpDownload'" target="help">(help)</a></font></a>
   48:       </th>
   49:       <th align=left bgcolor="#cccccc">
   50: 	<a>Downl. and lock</a>
   51:       </th>
   52:       <th align=left bgcolor="#cccccc">
   53: 	<a>Upload</a>
   54:       </th>
   55:       <th>
   56:       C
   57:       </th>
   58:     </tr>
   59:        
   60:   <tal:x repeat="result batch">
   61:    <tal:x tal:define="version python:here.getFile(result);lastVersion python:here.getFileLastVersion(result)">
   62:     <tr tal:attributes="class python:test(here.isActual(result),'actual','old')">
   63: 	<td><input type="checkbox" tal:attributes="value version/getId" name="ids">
   64: 		   <a tal:content="python:version.getTitle()" tal:attributes="href python:here.getObjUrl(result)+
   65: 		   '/'+lastVersion.getId()+'/view'"/></td>
   66: 	<td>
   67: 	<span tal:replace="lastVersion/getVersionNumber"/>
   68: 	<font size="-1"><a tal:attributes="href python:here.getObjUrl(result)+'/history'">(history)</a></font>
   69: 	</td>
   70: 	<td tal:content="lastVersion/getTime"/>
   71: 	<td tal:content="lastVersion/lastEditor"/>
   72: 	<td tal:content="lastVersion/getVersionComment"/>
   73:         <td><a tal:attributes="href python:here.getObjUrl(result)+'/manageVCommentForm'"><small tal:content="python:lastVersion.getVComment()"/></a></td>
   74:         <!--<td><a tal:attributes="href python:version.absolute_url()+'/manageCommentForm'"><small tal:content="python:version.getComment()"/></a></td>-->
   75: 	<td><a tal:attributes="href python:here.getObjUrl(result)">download</a></td>
   76: 	
   77: 	<td tal:condition="python:version.lockedBy==''"><a tal:attributes="href python:here.getObjUrl(result)+'/downloadLocked'">download and lock</a></td>
   78: 	<td tal:condition="not:python:version.lockedBy==''"><a>locked</a></td>
   79: 	
   80: 	<td tal:condition="python:version.lockedBy==''"><a tal:attributes="href python:here.getObjUrl(result)+'/'+version.title+'/addCDLIFileObjectForm'">Upload New Version</a></td>
   81: 	<td tal:condition="not:python:version.lockedBy==''">
   82: 	  <b tal:attributes="href python:here.getObjUrl(result)+'/addCDLIFileObjectForm'">Locked by: <span tal:replace="version/lockedBy"/></b>&nbsp;
   83: 	  <a tal:attributes="href python:here.getObjUrl(result)+'/unlock'">unlock</a>
   84: 	</td>
   85: 	<td>
   86: 	 <a tal:repeat="collection python:version.isContainedInBaskets(context=here)" tal:content="collection/title"
   87: 	 tal:attributes="href python:collection.getLastVersion().absolute_url()"/>	</td>
   88:    </tr>
   89:     </tal:x>
   90:   </tal:x>
   91: 
   92:   </table>
   93:   <p>
   94:     <a tal:condition="previous"
   95:        tal:attributes="href string:${request/URL0}?start:int=${previous/first}"
   96:        href="previous_url">previous <span tal:replace="previous/length">20</span> results</a>
   97:     <a tal:condition="next"
   98:        tal:attributes="href string:${request/URL0}?start:int=${next/first}"
   99:        href="next_url">next <span tal:replace="next/length">20</span> results</a>
  100:   </p>
  101: <input type="submit" value="delete from basket">
  102: </tal:block>
  103: </html>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>