Ignore:
Timestamp:
15 Nov 2012, 14:25:56 (12 years ago)
Author:
Henrik Bettermann
Message:

Add viewlets for reports.py

Add permission to roles.

Set label attribbute of views.

Location:
main/waeup.kofa/trunk/src/waeup/kofa/students
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py

    r9571 r9637  
    21112111                self.flash(_('You are not the owner of this access code.'))
    21122112                return
    2113         if self.context.student.state == CLEARED:
    2114             IWorkflowInfo(self.context.student).fireTransition(
    2115                 'pay_first_school_fee')
    2116         elif self.context.student.state == RETURNING:
    2117             IWorkflowInfo(self.context.student).fireTransition(
    2118                 'pay_school_fee')
    2119         elif self.context.student.state == PAID:
    2120             IWorkflowInfo(self.context.student).fireTransition(
    2121                 'pay_pg_fee')
     2113        try:
     2114            if self.context.student.state == CLEARED:
     2115                IWorkflowInfo(self.context.student).fireTransition(
     2116                    'pay_first_school_fee')
     2117            elif self.context.student.state == RETURNING:
     2118                IWorkflowInfo(self.context.student).fireTransition(
     2119                    'pay_school_fee')
     2120            elif self.context.student.state == PAID:
     2121                IWorkflowInfo(self.context.student).fireTransition(
     2122                    'pay_pg_fee')
     2123        except ConstraintNotSatisfied:
     2124            self.flash(_('An error occurred, please contact the system administrator.'))
     2125            return
    21222126        self.flash(_('Session started.'))
    21232127        self.redirect(self.url(self.context))
  • main/waeup.kofa/trunk/src/waeup/kofa/students/reports.py

    r9633 r9637  
    173173    grok.require('waeup.manageReports')
    174174
     175    label = _('Create students report')
     176
    175177    @property
    176178    def generator_name(self):
Note: See TracChangeset for help on using the changeset viewer.