Changeset 4525


Ignore:
Timestamp:
31 Aug 2009, 08:55:31 (15 years ago)
Author:
Henrik Bettermann
Message:

provide link for download import file

Location:
WAeUP_SRP/trunk
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/trunk/Upload.py

    r4392 r4525  
    122122        data = open(importer.pending_path).read()
    123123        return importer.pending_fn,data
     124       
     125    security.declareProtected(ModifyPortalContent,"getData") ###(
     126    def getData(self):
     127        """return data"""
     128        data_path = "%s/import/%s" % (i_home,self.filename)
     129        data = open(data_path).read()
     130        return self.filename,data       
    124131
    125     security.declareProtected(ModifyPortalContent,"getPending") ###(
     132    security.declareProtected(ModifyPortalContent,"getErrors") ###(
    126133    def getErrors(self):
    127134        """return import_errors"""
  • WAeUP_SRP/trunk/skins/waeup_upload/uploads_form.pt

    r4120 r4525  
    4747                         />
    4848                </td>
    49                 <td tal:condition="nothing"> <a href="view" tal:attributes="href string:${row/url}"> <span tal:content="row/id" /></a>  </td>
    50                 <td tal:content="string:${row/id}.csv" ></td>
     49               
     50                <td> <a href="view" tal:attributes="href string:${row/url}/download_data"> <span tal:content="string:${row/id}.csv" /> </a></td>
    5151                <td>
    5252                  <select name="import_layout:record" tal:attributes="name string:${row/id}.import_layout:record">
     
    151151                       />
    152152              </td>
    153               <td tal:condition="nothing"> <a href="view" tal:attributes="href string:${row/url}"> <span tal:content="row/id" /></a>  </td>
    154               <td tal:content="string:${row/id}.csv" ></td>
     153              <td> <a href="view" tal:attributes="href string:${row/url}/download_data"> <span tal:content="string:${row/id}.csv" /> </a></td>
    155154              <td tal:content="row/import_layout"></td>
    156155              <td tal:content="row/uploaded_by" ></td>
    157156              <td tal:content="row/upload_date" ></td>
    158               <td tal:content="row/msg" ></td>
    159157            </tr>
    160158          </table>
Note: See TracChangeset for help on using the changeset viewer.