Changeset 7272 for main/waeup.sirp/trunk


Ignore:
Timestamp:
4 Dec 2011, 18:04:39 (13 years ago)
Author:
Henrik Bettermann
Message:

Start registration only if applicant visits the display view for the first time.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/applicants/browser.py

    r7270 r7272  
    445445        self.passport_url = self.url(self.context, 'passport.jpg')
    446446        # Mark application as started if applicant logs in for the first time
    447         if IWorkflowState(self.context).getState() == INITIALIZED:
     447        usertype = getattr(self.request.principal, 'user_type', None)
     448        if usertype == 'applicant' and \
     449            IWorkflowState(self.context).getState() == INITIALIZED:
    448450            IWorkflowInfo(self.context).fireTransition('start')
    449451        return
Note: See TracChangeset for help on using the changeset viewer.