- Timestamp:
- 19 Aug 2019, 10:27:05 (5 years ago)
- Location:
- main/waeup.kofa/trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/CHANGES.txt
r15546 r15548 4 4 1.6.1.dev0 (unreleased) 5 5 ======================= 6 7 * Allow to add applicants containers with a number instead of entrance year 8 in container code. 6 9 7 10 * Add semester filter to Fix `CourseTicketExporter`. -
main/waeup.kofa/trunk/src/waeup/kofa/applicants/browser.py
r15502 r15548 225 225 def addApplicantsContainer(self, **data): 226 226 year = data['year'] 227 code = u'%s%s' % (data['prefix'], year) 227 if not data['container_number']: 228 code = u'%s%s' % (data['prefix'], year) 229 else: 230 code = u'%s%s' % (data['prefix'], data['container_number']) 228 231 apptypes_dict = getUtility(IApplicantsUtils).APP_TYPES_DICT 229 232 title = apptypes_dict[data['prefix']][0] -
main/waeup.kofa/trunk/src/waeup/kofa/applicants/interfaces.py
r15502 r15548 325 325 ) 326 326 327 container_number = schema.Choice( 328 title = _(u'Container Number'), 329 values = (1,2,3,4,5,6,7,8,9), 330 description = _(u'If set, this number will be added to the container ' 331 'prefix (e.g. app3). If not set, the year of entrance will be ' 332 'used (e.g. app2019).'), 333 required = False, 334 readonly = False, 335 ) 336 327 337 IApplicantsContainerAdd[ 328 338 'prefix'].order = IApplicantsContainer['prefix'].order 329 339 IApplicantsContainerAdd[ 330 340 'year'].order = IApplicantsContainer['year'].order 341 IApplicantsContainerAdd[ 342 'container_number'].order = IApplicantsContainer['year'].order 331 343 332 344 class IApplicantBaseData(IKofaObject): -
main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_browser.py
r15287 r15548 365 365 self.assertTrue('exists already in the database' 366 366 in self.browser.contents) 367 # Managers can add containers with prefix+number code instead of 368 # prefix+year code. 369 self.browser.open(self.add_container_path) 370 self.browser.getControl(name="form.prefix").value = ['app'] 371 self.browser.getControl(name="form.year").value = [str(session_2)] 372 self.browser.getControl(name="form.container_number").value = ['8'] 373 self.browser.getControl(name="form.mode").value = ['create'] 374 self.browser.getControl( 375 name="form.application_category").value = ['basic'] 376 self.browser.getControl("Add applicants container").click() 377 self.assertTrue('Added: "app8"' in self.browser.contents) 378 self.browser.getLink(container_name_1).click() 379 self.assertTrue('Manage applicants container' 380 in self.browser.contents) 367 381 self.browser.open(self.manage_root_path) 368 382 ctrl = self.browser.getControl(name='val_id')
Note: See TracChangeset for help on using the changeset viewer.