Changeset 16242 for main/waeup.kofa/trunk/src/waeup/kofa/applicants
- Timestamp:
- 23 Sep 2020, 19:27:06 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/applicants/utils.py
r16134 r16242 20 20 21 21 from time import time 22 from datetime import datetime 22 23 import grok 23 24 from zope.component import getUtility … … 61 62 """ 62 63 timestamp = ("%d" % int(time()*10000))[1:] 63 session = str(container.year) 64 try: 65 session_config = grok.getSite()['configuration'][session] 66 except KeyError: 67 return _(u'Session configuration object is not available.') 64 if container.year: 65 session = str(container.year) 66 try: 67 session_config = grok.getSite()['configuration'][session] 68 except KeyError: 69 return _(u'Session configuration object is not available.') 68 70 payment.p_id = "p%s" % timestamp 69 71 payment.p_item = container.title 70 payment.p_session = container.year 72 if container.year: 73 payment.p_session = container.year 74 else: 75 payment.p_session = datetime.now().year 71 76 payment.amount_auth = 0.0 72 77 if applicant.special:
Note: See TracChangeset for help on using the changeset viewer.