Ignore:
Timestamp:
11 Jan 2023, 07:16:59 (2 years ago)
Author:
Henrik Bettermann
Message:

Adjust customized method according to changes in base package.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/kofacustom.edopoly/trunk/src/kofacustom/edopoly/students/utils.py

    r17102 r17265  
    206206            amount = academic_session.clearance_fee
    207207        elif category == 'bed_allocation':
    208             p_item = self.getAccommodationDetails(student)['bt']
     208            acco_details = self.getAccommodationDetails(student)
     209            p_session = acco_details['booking_session']
     210            p_item = acco_details['bt']
    209211            amount = academic_session.booking_fee
    210212        elif category == 'hostel_maintenance':
    211213            amount = 0.0
    212             bedticket = student['accommodation'].get(
    213                 str(student.current_session), None)
     214            booking_session = grok.getSite()['hostels'].accommodation_session
     215            bedticket = student['accommodation'].get(str(booking_session), None)
    214216            if bedticket is not None and bedticket.bed is not None:
     217                p_session = booking_session
    215218                p_item = bedticket.bed_coordinates
    216219                if bedticket.bed.__parent__.maint_fee > 0:
Note: See TracChangeset for help on using the changeset viewer.