Changeset 8099 for main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
- Timestamp:
- 11 Apr 2012, 07:42:13 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
r8082 r8099 27 27 from zope.catalog.interfaces import ICatalog 28 28 from zope.component import queryUtility, getUtility, createObject 29 from zope.schema.interfaces import ConstraintNotSatisfied 29 30 from zope.formlib.textwidgets import BytesDisplayWidget 30 31 from hurry.workflow.interfaces import IWorkflowInfo, IWorkflowState … … 407 408 408 409 @property 410 def separators(self): 411 return getUtility(IStudentsUtils).SEPARATORS_DICT 412 413 @property 409 414 def form_fields(self): 410 415 cm = getattr(self.context,'current_mode', None) … … 469 474 label = _('Manage clearance data') 470 475 pnav = 4 476 477 @property 478 def separators(self): 479 return getUtility(IStudentsUtils).SEPARATORS_DICT 471 480 472 481 @property … … 634 643 @action(_('Save'), style='primary') 635 644 def save(self, **data): 636 msave(self, **data) 645 try: 646 msave(self, **data) 647 except ConstraintNotSatisfied: 648 # The selected level might not exist in certificate 649 self.flash(_('Current level not available for certificate.')) 650 return 637 651 notify(grok.ObjectModifiedEvent(self.context.__parent__)) 638 652 return
Note: See TracChangeset for help on using the changeset viewer.