Annotation of cdli/zpt/basketObject_index_html.zpt, revision 1.1
1.1 ! dwinter 1: <html metal:use-macro="here/main_template/macros/page">
! 2: <tal:block metal:fill-slot="body" tal:define="results here/contents;
! 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:
! 11: <h2>CDLI File Storage</h2>
! 12: <p>Basket: <span tal:replace="here/getId"/> contains <span tal:replace="here/numberOfItems"/> items</p>
! 13: <p><a tal:attributes="href python:here.getId()+'/downloadObjectsAsOneFile'"> download basket (combined in one file)</a>
! 14: <p>
! 15: <a tal:condition="previous"
! 16: tal:attributes="href string:${request/URL0}?start:int=${previous/first}"
! 17: href="previous_url">previous <span tal:replace="previous/length">20</span> results</a>
! 18: <a tal:condition="next"
! 19: tal:attributes="href string:${request/URL0}?start:int=${next/first}"
! 20: href="next_url">next <span tal:replace="next/length">20</span> results</a>
! 21: </p>
! 22: <form action="basket/deleteObjects">
! 23: <table width="100%" border=0 cellspacing=1 cellpadding=2>
! 24: <tr>
! 25: <th align=left bgcolor="#88ff88">
! 26: <a href="?sortField=title"> File</a>
! 27: </th>
! 28: <th align=left bgcolor="#00">
! 29: <a>Rev.</a>
! 30: </th>
! 31: <th align=left bgcolor="#cccccc">
! 32: <a href="?sortField=date">Date</a>
! 33: </th>
! 34: <th align=left bgcolor="#cccccc">
! 35: <a href="?sortField=author">Author</a>
! 36: </th>
! 37: <th align=left bgcolor="#cccccc">
! 38: <a >Last log entry</a>
! 39: </th>
! 40: <th align=left bgcolor="#cccccc" width="80">
! 41: <a href="?sortField=comment">Comment</a>
! 42: </th>
! 43: <th align=left bgcolor="#cccccc">
! 44: <a>Download<br><font size="-1"><a tal:attributes="href python:here.absolute_url()+'/helpDownload'" target="help">(help)</a></font></a>
! 45: </th>
! 46: <th align=left bgcolor="#cccccc">
! 47: <a>Downl. and lock</a>
! 48: </th>
! 49: <th align=left bgcolor="#cccccc">
! 50: <a>Upload</a>
! 51: </th>
! 52: </tr>
! 53:
! 54: <tal:x repeat="result batch">
! 55: <tr tal:define="version result;lastVersion python:version.getLastVersion()">
! 56: <td><input type="checkbox" tal:attributes="value version/getId" name="ids">
! 57: <a tal:content="python:version.title" tal:attributes="href python:lastVersion.absolute_url()+'/view'"/></td>
! 58: <td>
! 59: <span tal:replace="lastVersion/getVersionNumber"/>
! 60: <font size="-1"><a tal:attributes="href python:here.REQUEST['URL1']+'/'+version.title+'/history'">(history)</a></font>
! 61: </td>
! 62: <td tal:content="lastVersion/getTime"/>
! 63: <td tal:content="lastVersion/lastEditor"/>
! 64: <td tal:content="lastVersion/getVersionComment"/>
! 65: <td><a tal:attributes="href python:lastVersion.absolute_url()+'/manageVCommentForm'"><small tal:content="python:lastVersion.getVComment()"/></a></td>
! 66: <!--<td><a tal:attributes="href python:version.absolute_url()+'/manageCommentForm'"><small tal:content="python:version.getComment()"/></a></td>-->
! 67: <td><a tal:attributes="href python:lastVersion.absolute_url()">download</a></td>
! 68:
! 69: <td tal:condition="python:lastVersion.lockedBy==''"><a tal:attributes="href python:here.REQUEST['URL1']+'/'+version.title+'/downloadLocked'">download and lock</a></td>
! 70: <td tal:condition="not:python:lastVersion.lockedBy==''"><a>locked</a></td>
! 71:
! 72: <td tal:condition="python:lastVersion.lockedBy==''"><a tal:attributes="href python:here.REQUEST['URL1']+'/'+version.title+'/addVersionedFileObjectForm'">Upload New Version</a></td>
! 73: <td tal:condition="not:python:lastVersion.lockedBy==''">
! 74: <b tal:attributes="href python:here.REQUEST['URL1']+'/'+version.title+'/addVersionedFileObjectForm'">Locked by: <span tal:replace="lastVersion/lockedBy"/></b> <a tal:attributes="href python:here.REQUEST['URL1']+'/'+version.title+'/unlock'">unlock</a>
! 75: </td>
! 76: </tr>
! 77:
! 78: </tal:x>
! 79:
! 80: </table>
! 81: <p>
! 82: <a tal:condition="previous"
! 83: tal:attributes="href string:${request/URL0}?start:int=${previous/first}"
! 84: href="previous_url">previous <span tal:replace="previous/length">20</span> results</a>
! 85: <a tal:condition="next"
! 86: tal:attributes="href string:${request/URL0}?start:int=${next/first}"
! 87: href="next_url">next <span tal:replace="next/length">20</span> results</a>
! 88: </p>
! 89: <input type="submit" value="delete from basket">
! 90: </tal:block>
! 91: </html>
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>