- Timestamp:
- 13 Jun 2007, 12:42:38 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/Widgets.py
r1836 r1891 127 127 c_ids = [c.id for c in self.portal_catalog({'meta_type': "Course"})] 128 128 if hasattr(self.aq_parent,value): 129 err = 'Course %s already exists' % (value)129 err = 'Course already exists' 130 130 elif value not in c_ids: 131 err = 'Course %s does not exist' % (value)131 err = 'Course does not exist' 132 132 if err: 133 133 datastructure.setError(widget_id, err) … … 159 159 res = self.portal_catalog(meta_type= "Course",id = value) 160 160 if len(res) > 0: 161 err = 'Course %s already exists' % (value)161 err = 'Course already exists' 162 162 if err: 163 163 datastructure.setError(widget_id, err) … … 592 592 pume = jamb_nr_catalog(jamb_reg_no = value) 593 593 if len(pume) < 1: 594 err = 'No student record with registration number %s in %s.' % (value,jamb_nr_catalog.id)594 err = 'No student record with this registration number.' 595 595 else: 596 596 datastructure['pume'] = pume[0] … … 727 727 value = datastructure[widget_id] 728 728 if not valid or not value: 729 err = 'Invalid string %s' % value729 err = 'Invalid string' 730 730 logger.info('Invalid matric_no string %s' % value) 731 731 else: … … 736 736 if len(res) < 1: 737 737 logger.info('matric_no %s not found' % value) 738 err = 'No student with matriculation number %s in %s' % (value, returning.id)738 err = 'No student with this matriculation number.' 739 739 break 740 740 datastructure['student'] = res[0] … … 742 742 res = results(matric_no = value) 743 743 if len(res) < 1: 744 err = 'No results for matriculation number %s' % (value)744 err = 'No results for this matriculation number' 745 745 continue 746 746 datastructure['results'] = res … … 771 771 value = datastructure[widget_id] 772 772 if not valid or not value: 773 err = 'Invalid Id string %s' % value773 err = 'Invalid Id string' 774 774 logger.info('Invalid id string %s' % value) 775 775 datastructure['student'] = None … … 779 779 if not res: 780 780 logger.info('Student id %s not found' % value) 781 err = 'No student with Id %s' % (value)781 err = 'No student with this Id' 782 782 datastructure['student'] = None 783 783 else: … … 916 916 while 1: 917 917 if not s and g: 918 err = "No subject grade for subject %s " % s918 err = "No subject grade for subject" 919 919 break 920 920 i = 0 … … 1057 1057 elif len(n) != 10: 1058 1058 do = 0 1059 err = 'Invalid PIN length %d' % len(n)1059 err = 'Invalid PIN length' 1060 1060 s_logger.info('%s entered invalid PIN with length %d' % (s_id,len(n))) 1061 1061 elif self.reference == "": … … 1114 1114 s_logger.info('%s/%s (non-member) repeatedly checked admission with PIN %s' % (s_id,ref,pin_str)) 1115 1115 else: 1116 err = "Unknown error" % s_id1116 err = "Unknown error" 1117 1117 s_logger.info('%s/%s repeatedly activated service with PIN %s' % (s_id,ref,pin_str)) 1118 1118 break
Note: See TracChangeset for help on using the changeset viewer.