- Timestamp:
- 7 Mar 2008, 23:17:25 (17 years ago)
- Location:
- WAeUP_SRP
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/base/skins/waeup_upload/uploads_form.pt
r3283 r3285 19 19 <form action="" method="post" enctype="multipart/form-data" class="group"> 20 20 <span tal:replace="structure rendered" /> 21 <input type="submit" name="upload" value="upload" 21 <br /> 22 <input type="submit" name="upload" value="Upload" 22 23 class="destructive" /> 23 24 </form> … … 30 31 <th></th> 31 32 <th>Filename</th> 32 <th> Schema</th>33 <th> Uploaded by</th>34 <th> UploadDate</th>33 <th>Data Layout</th> 34 <th>By</th> 35 <th>Date</th> 35 36 <th>Message</th> 36 <th> Invalid Keys</th>37 <th>Conform Headline</th> 37 38 </tr> 38 39 <tr tal:repeat="row rows" … … 60 61 <td tal:content="row/msg" ></td> 61 62 <td> 62 < spantal:repeat="key row/invalid_keys">63 <span tal:replace="key" /> 63 <div tal:repeat="key row/invalid_keys"> 64 <span tal:replace="key" /><br /> 64 65 <select tal:attributes="name string:${row/id}|${key}.valid_key:record"> 65 66 <option tal:repeat="new row/valid_keys" … … 67 68 tal:content="new" /> 68 69 </select> 69 </ span>70 </div> 70 71 </td> 71 72 <td tal:condition="python:0"> … … 79 80 </tr> 80 81 </table> 81 <table width="100%" cellspacing="0" cellpadding="2" 82 summary="contents of the folder" 83 class="folderButtons"> 84 <tr> 85 <td align="left" valign="top" rowspan="3"></td> 86 <td align="left" valign="top"> 87 <input tal:condition="nothing" type="button" value="button_select_all" class="context" 88 onclick="someJavaScriptFunctionThatWillBeReplaced" 89 i18n:attributes="value" 90 tal:attributes="onclick python:'toggleSelect(this, \'%s\', \'%s\')' 91 % (cpsmcat('button_select_all'), cpsmcat('button_deselect_all'))" 92 /> 93 <input type="submit" name="edit" value="edit" 94 class="destructive" i18n:attributes="value" 95 /> 96 <input type="submit" name="folder_delete:method" value="button_delete" 97 class="destructive" i18n:attributes="value" 98 tal:attributes="onclick python:'return window.confirm(\'%s\')' % 99 (cpsmcat('description_confirm_delete'), )" 100 /> 101 </td> 102 </tr> 103 </table> 82 83 <br /> 84 85 <input tal:condition="nothing" type="button" value="button_select_all" class="context" 86 onclick="someJavaScriptFunctionThatWillBeReplaced" 87 i18n:attributes="value" 88 tal:attributes="onclick python:'toggleSelect(this, \'%s\', \'%s\')' 89 % (cpsmcat('button_select_all'), cpsmcat('button_deselect_all'))" 90 /> 91 <input type="submit" name="edit" value="Edit" 92 class="destructive" i18n:attributes="value" 93 /> 94 <input type="submit" name="folder_delete:method" value="button_delete" 95 class="destructive" i18n:attributes="value" 96 tal:attributes="onclick python:'return window.confirm(\'%s\')' % 97 (cpsmcat('description_confirm_delete'), )" 98 /> 99 104 100 </form> 105 101 </metal:main> -
WAeUP_SRP/base/skins/waeup_upload/uploads_index.py
r3283 r3285 50 50 if new_keys: 51 51 doc.editHeadline(new_keys) 52 request.RESPONSE.redirect(context.absolute_url()) 53 52 request.RESPONSE.redirect(context.absolute_url()) 53 54 54 for id,upload in context.objectItems(): 55 55 row = {} … … 61 61 row['url'] = upload.absolute_url() 62 62 row['msg'], row['invalid_keys'] = doc['checkKeys']() 63 row['filename'] = doc.filename 63 row['filename'] = doc.filename 64 64 row['import_layout'] = doc.import_layout 65 65 row['upload_date'] = doc.upload_date.strftime("%d/%m/%y %H:%M:%S") … … 92 92 if filename not in context.objectIds(): 93 93 break 94 psm = "Upload file exists"94 psm = "Upload object exists!" 95 95 return context.uploads_form(rendered = res, 96 96 psm = psm, … … 103 103 upload = getattr(context,filename) 104 104 d = {} 105 d['filename'] = d['id'] = filename 105 d['filename'] = d['id'] = filename 106 106 d['upload_date'] = DateTime.DateTime() 107 107 d['import_layout'] = ds.get('import_layout','') … … 110 110 upload.getContent().edit(mapping=d) 111 111 112 request.RESPONSE.redirect(context.absolute_url()) 112 request.RESPONSE.redirect(context.absolute_url()) 113 113 -
WAeUP_SRP/uniben/profiles/default/layouts/upload.xml
r3277 r3285 7 7 <property name="flexible_widgets"/> 8 8 <property name="validate_values_expr"></property> 9 <widget name="upload_file" meta_type="Disc File Widget"> 10 <property name="title">Upload File</property> 11 <property name="fields"> 12 <element value="filename"/> 13 </property> 14 <property name="is_required">True</property> 15 <property name="label">Upload File</property> 16 <property name="label_edit">Upload File</property> 17 <property name="readonly_layout_modes"/> 18 <property name="hidden_layout_modes"> 19 <element value="create"/> 20 </property> 21 <property name="hidden_readonly_layout_modes"/> 22 <property name="size_max">0</property> 23 <property name="display_external_editor">False</property> 24 </widget> 9 10 <widget name="upload_file" meta_type="Disc File Widget"> 11 <property name="title">Upload File</property> 12 <property name="fields"> 13 <element value="filename"/> 14 </property> 15 <property name="is_required">True</property> 16 <property name="label">Upload File</property> 17 <property name="label_edit">Upload File</property> 18 <property name="readonly_layout_modes"/> 19 <property name="hidden_layout_modes"> 20 <element value="create"/> 21 </property> 22 <property name="hidden_readonly_layout_modes"/> 23 <property name="size_max">0</property> 24 <property name="display_external_editor">False</property> 25 </widget> 26 25 27 <widget name="import_layout" meta_type="Select Widget"> 26 <property name="title"> ImportLayout</property>28 <property name="title">Data Layout</property> 27 29 <property name="fields"> 28 30 <element value="import_layout"/> 29 31 </property> 30 32 <property name="is_required">False</property> 31 <property name="label"> ImportLayout</property>32 <property name="label_edit"> ImportLayout</property>33 <property name="label">Data Layout</property> 34 <property name="label_edit">Data Layout</property> 33 35 <property name="readonly_layout_modes"/> 34 36 <property name="hidden_layout_modes"/> … … 36 38 <property name="vocabulary">import_names</property> 37 39 </widget> 40 41 <widget name="uploaded_by" meta_type="String Widget"> 42 <property name="title">Uploaded By</property> 43 <property name="fields"> 44 <element value="uploaded_by"/> 45 </property> 46 <property name="label">Uploaded By</property> 47 <property name="label_edit">Uploaded By</property> 48 <property name="description"></property> 49 <property name="help"></property> 50 <property name="is_i18n">False</property> 51 <property name="widget_mode_expr"></property> 52 <property name="readonly_layout_modes"> 53 </property> 54 <property name="hidden_layout_modes"> 55 </property> 56 <property name="hidden_readonly_layout_modes"/> 57 <property name="css_class_expr">string:row</property> 58 </widget> 59 60 61 <widget name="upload_date" meta_type="DateTime Widget"> 62 <property name="title">Upload Date</property> 63 <property name="fields"> 64 <element value="upload_date"/> 65 </property> 66 <property name="label">Upload Date</property> 67 <property name="label_edit">Upload Date</property> 68 <property name="description"></property> 69 <property name="help"></property> 70 <property name="is_i18n">False</property> 71 <property name="widget_mode_expr"></property> 72 <property name="readonly_layout_modes"/> 73 <property name="hidden_layout_modes"> 74 </property> 75 <property name="hidden_readonly_layout_modes"/> 76 <property name="view_format">%d/%m/%Y</property> 77 <property name="time_setting">False</property> 78 <property name="css_class_expr">string:row</property> 79 </widget> 80 81 <widget name="import_date" meta_type="DateTime Widget"> 82 <property name="title">Import Date</property> 83 <property name="fields"> 84 <element value="import_date"/> 85 </property> 86 <property name="label">Import Date</property> 87 <property name="label_edit">Import Date</property> 88 <property name="description"></property> 89 <property name="help"></property> 90 <property name="is_i18n">False</property> 91 <property name="widget_mode_expr"></property> 92 <property name="readonly_layout_modes"/> 93 <property name="hidden_layout_modes"> 94 </property> 95 <property name="hidden_readonly_layout_modes"/> 96 <property name="view_format">%d/%m/%Y</property> 97 <property name="time_setting">False</property> 98 <property name="css_class_expr">string:row</property> 99 </widget> 100 101 102 38 103 <table> 39 104 <row> … … 43 108 <cell name="import_layout" /> 44 109 </row> 110 <row> 111 <cell name="uploaded_by" /> 112 </row> 113 <row> 114 <cell name="upload_date" /> 115 </row> 116 <row> 117 <cell name="import_date" /> 118 </row> 45 119 </table> 46 120 </object> -
WAeUP_SRP/uniben/profiles/default/schemas/upload.xml
r3278 r3285 6 6 <field name="filename" meta_type="CPS String Field"/> 7 7 <field name="uploaded_by" meta_type="CPS String Field"/> 8 <field name="import ed_at" meta_type="CPS DateTime Field"/>8 <field name="import_date" meta_type="CPS DateTime Field"/> 9 9 </object>
Note: See TracChangeset for help on using the changeset viewer.