12345678910111213141516171819202122 |
- def uploadComplete(self, ns):
- id = ns['id']
- bdata = ns['data']
- ftype = ns['ftype']
- ident = ns['ident']
- linkonly = ns['linkonly']
- filename = ns['filename']
- if id != 0:
- file_obj = model.Files.uploadFileEdit(id, filename, ftype, bdata)
- else:
- file_obj = model.Files.uploadFile(ident, filename, ftype, bdata)
- ns['filename'] = file_obj.getFilename()
- new_html = self.getEditHTML(ftype, ident, linkonly)
- new_html = new_html.replace("'", "\\'")
- ns['new_html'] = new_html
- AmiCache.expireCurrentPage()
- return render("skeletonz/plugins/upload/view/upload_complete.tmpl", ns)
|