Changeset 17930


Ignore:
Timestamp:
26 Sep 2024, 19:52:39 (3 months ago)
Author:
Henrik Bettermann
Message:

2024 school fees

Location:
main/waeup.uniben/trunk/src/waeup/uniben/students
Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.uniben/trunk/src/waeup/uniben/students/utils.py

    r17915 r17930  
    3434
    3535SCHOOLFEES = dict()
     36
     37schoolfees_path = os.path.join(
     38    os.path.dirname(__file__), 'schoolfees_24.csv')
     39reader = csv.DictReader(open(schoolfees_path, 'rb'))
     40SCHOOLFEES[24] = {line['code']: {item[0]:item[1] for item in line.items()}
     41    for line in reader}
    3642
    3743schoolfees_path = os.path.join(
     
    502508                elif student.entry_session < 2023:
    503509                    schoolfees_dict = SCHOOLFEES[22][p_item]
     510                elif student.entry_session < 2024:
     511                    schoolfees_dict = SCHOOLFEES[23][p_item]
    504512                else:
    505                     schoolfees_dict = SCHOOLFEES[23][p_item]
     513                    schoolfees_dict = SCHOOLFEES[24][p_item]
    506514            except KeyError:
    507515                return _('School fee not yet fixed: p_item = %s' % p_item), None
Note: See TracChangeset for help on using the changeset viewer.