Changeset 1971
- Timestamp:
- 27 Jun 2007, 10:03:44 (17 years ago)
- Location:
- WAeUP_SRP/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/WAeUPTables.py
r1967 r1971 556 556 if event_type not in ("sys_add_object","sys_del_object"): 557 557 return 558 #import pdb;pdb.set_trace()559 558 course_id = object.getId() 560 559 if course_id.endswith('_co'): … … 566 565 student_rec = res[0] 567 566 registered_courses = getattr(student_rec,'registered_courses',[]) 567 #import pdb;pdb.set_trace() 568 568 try: 569 569 x = course_id in registered_courses 570 570 except TypeError: 571 571 registered_courses = [] 572 if event_type == "sys_add_object" and course_id not in registered_courses: 573 registered_courses.append(course_id) 572 if event_type == "sys_add_object": 573 if course_id not in registered_courses: 574 registered_courses.append(course_id) 575 else: 576 return 574 577 elif event_type == "sys_del_object": 575 578 while course_id in registered_courses: … … 578 581 data['registered_courses'] = registered_courses 579 582 self.modifyRecord(**data) 583 return 580 584 if pt not in self.affected_types.keys(): 581 585 return … … 596 600 InitializeClass(StudentsCatalog) 597 601 602 ###) 603 604 class StatisticsCatalog(StudentsCatalog): ###( 605 security = ClassSecurityInfo() 606 meta_type = 'WAeUP Statistics Catalog' 607 name = "statistics" 608 affected_types = { ###( 609 'StudentApplication': 610 {'id': 'application', 611 'fields': 612 ('jamb_reg_no', 613 'entry_mode', 614 #'entry_level', 615 'entry_session', 616 ) 617 }, 618 'StudentClearance': 619 {'id': 'clearance', 620 'fields': 621 ('matric_no', 622 ) 623 }, 624 'StudentPersonal': 625 {'id': 'personal', 626 'fields': 627 ('name', 628 'sex', 629 'email', 630 'phone', 631 ) 632 }, 633 'StudentStudyCourse': 634 {'id': 'study_course', 635 'fields': 636 ('course', 637 'faculty', 638 'department', 639 'level', 640 'mode', 641 'session', 642 'verdict', 643 ) 644 }, 645 } 646 ###) 647 648 649 InitializeClass(StudentsCatalog) 598 650 ###) 599 651 -
WAeUP_SRP/trunk/skins/waeup_student/add_course_result.py
r1896 r1971 37 37 args = {} 38 38 err = '' 39 d['core_or_elective'] = True 39 40 while True: 40 41 if not course_id: … … 64 65 65 66 cr_id = context.invokeFactory('StudentCourseResult',course_id) 66 #set_trace()67 67 cr = getattr(context,cr_id) 68 68 context.portal_workflow.doActionFor(cr,'open')
Note: See TracChangeset for help on using the changeset viewer.