Changeset 3036 for WAeUP_SRP/base
- Timestamp:
- 23 Jan 2008, 10:02:33 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/base/WAeUPTool.py
r3033 r3036 1936 1936 if matric_no and student_record.matric_no and\ 1937 1937 matric_no != student_record.matric_no: 1938 logger.info("%s, old matric_no %s overwritten with %s" % (student_record.id,student_record.matric_no,matric_no)) 1938 return '', 'student %s matric_no %s does not match %s' % (student_record.id, 1939 student_record.matric_no, 1940 matric_no) 1939 1941 elif matric_no: 1940 1942 res = self.students_catalog(matric_no = matric_no) … … 1946 1948 student_id = student_record.id 1947 1949 student_review_state = student_record.review_state 1948 if student_review_state not in ('courses_validated', ):1950 if student_review_state not in ('courses_validated','returning'): 1949 1951 return '',"student %s in wrong review_state %s" % (student_id, student_review_state) 1950 1952 student_obj = getattr(students_folder,student_id) … … 1965 1967 current_level, 1966 1968 student_record.level) 1967 s ub_obj = getattr(student_obj,'study_course',None)1968 if s ub_obj is None:1969 study_course_obj = getattr(student_obj,'study_course',None) 1970 if study_course_obj is None: 1969 1971 return '','student_id %s: no study_course-object' % student_id 1970 level_obj = getattr(s ub_obj,current_level,None)1972 level_obj = getattr(study_course_obj,current_level,None) 1971 1973 if level_obj is None: 1972 1974 return '','student_id %s: no study_level-object for level %s' % (student_id, 1973 1975 current_level) 1974 verdict = d['verdict'] = mapping.get('current_verdict','')1976 verdict = d['verdict'] = d['current_verdict'] = mapping.get('current_verdict','') 1975 1977 if verdict == student_record.verdict: 1976 1978 return '','student_id %s: verdict already set to %s' % (student_id, … … 1982 1984 current_level) 1983 1985 1986 study_course_obj.getContent().edit(mapping = d) 1984 1987 level_obj.getContent().edit(mapping = d) 1988 if student_review_state != "returning": 1989 wftool.doActionFor(student_obj,'return') 1985 1990 try: 1986 1991 wftool.doActionFor(level_obj,'close')
Note: See TracChangeset for help on using the changeset viewer.