Ignore:
Timestamp:
17 Aug 2016, 04:09:07 (8 years ago)
Author:
Henrik Bettermann
Message:

Extend category_mapping. Distinguish part-time and full-time students.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.aaue/trunk/src/waeup/aaue/etranzact/browser.py

    r13799 r14083  
    9696            'SCHOOL-FEE-BALANCE': ('schoolfee','schoolfee_incl',
    9797                                   'schoolfee_1','schoolfee_2'),
     98            'SCHOOL-FEE-PT-NEW': ('schoolfee',),
     99            'SCHOOL-FEE-PT-RETURNING': ('schoolfee',),
     100            'SCHOOL-FEE-PT-PLUS-NEW': ('schoolfee_incl',),
     101            'SCHOOL-FEE-PT-PLUS-RETURNING': ('schoolfee_incl',),
     102            'SCHOOL-FEE-PT-PG-NEW': ('schoolfee',),
     103            'SCHOOL-FEE-PT-PG-RETURNING': ('schoolfee',),
     104            'SCHOOL-FEE-PT-FIRST-INSTALMENT-PLUS': ('schoolfee_1',),
     105            'SCHOOL-FEE-PT-SECOND-INSTALMENT': ('schoolfee_2',),
     106            'SCHOOL-FEE-PT-BALANCE': ('schoolfee','schoolfee_incl',
     107                                      'schoolfee_1','schoolfee_2'),
     108
    98109            'ACCEPTANCE-FEE': ('clearance',),
    99110            'ACCEPTANCE-FEE-PLUS': ('clearance_incl',),
     
    161172            and results[0].p_item != 'Balance':
    162173            self.output = ERROR_PART1 + 'Postgrad student' + ERROR_PART2
     174            return
     175        if student and '-PT' in PAYMENT_TYPE \
     176            and not student.current_mode.endswith('_pt'):
     177            self.output = ERROR_PART1 + 'Not a part-time student' + ERROR_PART2
     178            return
     179        if student and '-PT' not in PAYMENT_TYPE \
     180            and student.current_mode.endswith('_pt'):
     181            self.output = ERROR_PART1 + 'Part-time student' + ERROR_PART2
    163182            return
    164183        if '-BALANCE' in PAYMENT_TYPE and results[0].p_item != 'Balance':
Note: See TracChangeset for help on using the changeset viewer.