Annotation of cdli/zpt/CDLIFileFolderMain.zpt, revision 1.3
1.1 dwinter 1: <html metal:use-macro="here/main_template/macros/page">
2: <tal:block metal:fill-slot="body">
3: <h2>CDLI File Storage - <span tal:content="here/title"/></h2>
4: <span tal:replace="structure here/header_html"/>
5: <a tal:condition="here/hasParent"
6: tal:attributes="href python:here.aq_parent.absolute_url()"
7: tal:content="python:'back (%s)'%here.aq_parent.title">back</a>
8: <hr>
9: <tal:block tal:define="folders python:here.getFolders()" tal:condition="python:len(folders)>0">
10: <h3>Subfolder</h3>
11: <table>
12: <tr tal:repeat="folder folders">
13: <td><a tal:content="python:folder[0].title" tal:attributes="href python:folder[0].absolute_url()"/></td>
14: <td tal:content="python:'( folder: %s)'% folder[1]"/>
15: <td tal:content="python:'( files: %s)'% folder[2]"/>
16: </tr>
17: </table>
18: <hr>
19: </tal:block>
20: <form>
21: <script type="text/javascript">
22: <!--
23:
24:
25: isSelected=false
26:
27: function toggleSelect() {
28: addBasket=document.getElementById('addBasket')
29: selectButton=document.getElementById('selectButton')
30:
31:
32: if (isSelected == false) {
33:
34: for (i = 0; i < addBasket.length-1; i++)
35:
36: addBasket.elements[i].checked = true ;
37:
38:
39: isSelected = true;
40:
41: selectButton.value = "Deselect All";
42: return isSelected;
43: }
44: else {
45:
46: for (i = 0; i < addBasket.length+1; i++)
47: addBasket.elements[i].checked = false ;
48: isSelected = false;
49: selectButton.value = "Select All";
50: return isSelected;
51: }
52: }
53:
54: //-->
55: </script>
56: <input class="space_right" type="submit" id="selectButton" value="Select All" onClick="toggleSelect(); return false">
57: </form>
58: <tal:block tal:define="sortField python:here.REQUEST.get('sortField','title');
59: versions python:here.getVersionedFiles(sortField=sortField)">
60:
1.2 dwinter 61: <form id="addBasket" tal:condition="python:len(versions)>0" action="basketContainer/storeInBasket">
62: <input name="submit" type="submit" value="store in active basket">
63: <input name="submit" type="submit" value="store in new basket"><input name="newBasketName">
1.1 dwinter 64: <table width="100%" border=0 cellspacing=1 cellpadding=2>
65: <tr>
66: <th align=left bgcolor="#88ff88">
67: <a href="?sortField=title"> File</a>
68: </th>
69: <th align=left bgcolor="#00">
70: <a>Rev.</a>
71: </th>
72: <th align=left bgcolor="#cccccc">
73: <a href="?sortField=date">Date</a>
74: </th>
75: <th align=left bgcolor="#cccccc">
76: <a href="?sortField=author">Author</a>
77: </th>
78: <th align=left bgcolor="#cccccc">
79: <a >Last log entry</a>
80: </th>
81: <th align=left bgcolor="#cccccc" width="80">
82: <a href="?sortField=comment">Comment</a>
83: </th>
84: <th align=left bgcolor="#cccccc">
85: <a>Download<br><font size="-1"><a tal:attributes="href python:here.absolute_url()+'/helpDownload'" target="help">(help)</a></font></a>
86: </th>
87: <th align=left bgcolor="#cccccc">
88: <a>Downl. and lock</a>
89: </th>
90: <th align=left bgcolor="#cccccc">
91: <a>Upload</a>
92: </th>
93: </tr>
94: <span tal:omit-tag="" tal:define="sortField python:here.REQUEST.get('sortField','title')" tal:repeat="version versions">
95: <tr tal:define="lastVersion python:version[1].getLastVersion()">
96: <td><input type="checkbox" tal:attributes="value python:version[1].getId()" name="ids"><a tal:content="python:version[1].title" tal:attributes="href python:lastVersion.absolute_url()+'/view'"/></td>
97: <td>
98: <span tal:replace="lastVersion/versionNumber"/>
99: <font size="-1"><a tal:attributes="href python:here.REQUEST['URL1']+'/'+version[0]+'/history'">(history)</a></font>
100: </td>
101: <td tal:content="lastVersion/getTime"/>
102: <td tal:content="lastVersion/lastEditor"/>
103: <td tal:content="lastVersion/versionComment"/>
104: <td><a tal:attributes="href python:lastVersion.absolute_url()+'/manageVCommentForm'"><small tal:content="python:lastVersion.getVComment()"/></a></td>
105: <!--<td><a tal:attributes="href python:version[1].absolute_url()+'/manageCommentForm'"><small tal:content="python:version[1].getComment()"/></a></td>-->
106: <td><a tal:attributes="href python:lastVersion.absolute_url()">download</a></td>
107:
108: <td tal:condition="python:lastVersion.lockedBy==''"><a tal:attributes="href python:here.REQUEST['URL1']+'/'+version[0]+'/downloadLocked'">download and lock</a></td>
109: <td tal:condition="not:python:lastVersion.lockedBy==''"><a>locked</a></td>
110:
1.3 ! dwinter 111: <td tal:condition="python:lastVersion.lockedBy==''"><a tal:attributes="href python:here.REQUEST['URL1']+'/'+version[0]+'/addCDLIFileObjectForm'">Upload New Version</a></td>
1.1 dwinter 112: <td tal:condition="not:python:lastVersion.lockedBy==''">
1.3 ! dwinter 113: <b tal:attributes="href python:here.REQUEST['URL1']+'/'+version[0]+'/addCDLIFileObjectForm'">Locked by: <span tal:replace="lastVersion/lockedBy"/></b> <a tal:attributes="href python:here.REQUEST['URL1']+'/'+version[0]+'/unlock'">unlock</a>
1.1 dwinter 114: </td>
1.3 ! dwinter 115: <td>
! 116: <a tal:repeat="collection python:version[1].isContainedInBaskets()" tal:content="collection/title"
! 117: tal:attributes="href python:collection.getLastVersion().absolute_url()"/> </td>
1.1 dwinter 118: </tr>
119: </span>
120: </table>
121: </form>
122: </tal:block>
123: </tal:block>
124: </html>
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>