Changeset 2507 for WAeUP_SRP/base
- Timestamp:
- 2 Nov 2007, 20:42:32 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/base/skins/waeup_utilities/moveCourseResults.py
r2502 r2507 27 27 logger = logging.getLogger('Skins.moveCourseResults') 28 28 from Products.AdvancedQuery import Eq, Between, Le,In 29 #aq_results = context.course_results.evalAdvancedQuery29 aq_results = context.course_results.evalAdvancedQuery 30 30 aq_students = context.students_catalog.evalAdvancedQuery 31 31 students = context.portal_url.getPortalObject().campus.students … … 53 53 logger.info("Committing %s transactions, total %s" % (commit_after,count)) 54 54 cocount += 1 55 if cocount > 3: 56 break 55 #if cocount > 3: 56 # break 57 already_moved = aq_results(Eq('student_id',brain.id)) 58 if len(already_moved) > 0: 59 continue 57 60 try: 58 61 study_level = getattr(getattr(getattr(students,brain.id), … … 64 67 continue 65 68 if not results: 66 rwrite('no courses%s/study_course/%s' % (brain.id,brain.level))69 rwrite('no result objects in %s/study_course/%s' % (brain.id,brain.level)) 67 70 else: 68 71 logger.info("moving results of student %s" % (brain.id)) … … 73 76 logger.info(msg) 74 77 rwrite(msg) 78
Note: See TracChangeset for help on using the changeset viewer.