- Timestamp:
- 22 Feb 2014, 15:46:03 (11 years ago)
- Location:
- main/waeup.kofa/trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk
- Property svn:mergeinfo changed
-
main/waeup.kofa/trunk/src/waeup/kofa
-
Property
svn:mergeinfo
set to
(toggle deleted branches)
/main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa merged eligible /main/waeup.kofa/branches/uli-autoinclude-less/src/waeup/kofa 8871-8888 /main/waeup.sirp/branches/uli-studentpw/src/waeup/kofa 6703-6755 /main/waeup.sirp/branches/ulif-extimgstore/src/waeup/kofa 7001-7062 /main/waeup.sirp/branches/ulif-schoolgrades/src/waeup/kofa 7761-7794
-
Property
svn:mergeinfo
set to
(toggle deleted branches)
-
main/waeup.kofa/trunk/src/waeup/kofa/students/viewlets.py
r10816 r11254 825 825 size = file_size(upload) 826 826 if size > max_size: 827 view.flash(_('Uploaded file is too big.') )827 view.flash(_('Uploaded file is too big.'), type="danger") 828 828 return False 829 829 upload.seek(0) # file pointer moved when determining size … … 831 831 upload.seek(0) # same here 832 832 if file_format is None: 833 view.flash(_('Could not determine file type.') )833 view.flash(_('Could not determine file type.'), type="danger") 834 834 return False 835 835 basename, expected_ext = os.path.splitext(download_name) … … 837 837 if '.' + file_format != expected_ext: 838 838 view.flash(_('${a} file extension expected.', 839 mapping = {'a':expected_ext[1:]}) )839 mapping = {'a':expected_ext[1:]}), type="danger") 840 840 return False 841 841 else: … … 843 843 view.flash( 844 844 _('Only the following extensions are allowed: ${a}', 845 mapping = {'a':', '.join(ALLOWED_FILE_EXTENSIONS)})) 845 mapping = {'a':', '.join(ALLOWED_FILE_EXTENSIONS)}), 846 type="danger") 846 847 return False 847 848 download_name += '.' + file_format … … 891 892 template = default_fileupload_template 892 893 grok.require('waeup.uploadStudentFile') 893 tab_redirect = ' ?tab2'894 tab_redirect = '#tab2-top' 894 895 mus = 1024 * 150 895 896 upload_button =_('Upload new file') … … 931 932 self.context, self.view.__name__) + self.tab_redirect) 932 933 else: 933 self.view.flash(_('No local file selected.') )934 self.view.flash(_('No local file selected.'), type="danger") 934 935 self.view.redirect( 935 936 self.view.url( … … 959 960 mus = 1024 * 50 960 961 download_name = u'passport.jpg' 961 tab_redirect = ' ?tab2'962 tab_redirect = '#tab2' 962 963 963 964 class PassportUploadEdit(PassportUploadManage): … … 986 987 mus = 1024 * 150 987 988 download_name = u'birth_certificate' 988 tab_redirect = ' ?tab2'989 tab_redirect = '#tab2-top' 989 990 990 991 class Image(grok.View):
Note: See TracChangeset for help on using the changeset viewer.