Ignore:
Timestamp:
11 Dec 2019, 12:58:38 (5 years ago)
Author:
Henrik Bettermann
Message:

KOFA should only display class of degree only when the student registration state = graduated else shows only CGPA.

File:
1 edited

Legend:

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

    r15880 r15881  
    3535from zope.i18n import translate
    3636from waeup.kofa.interfaces import (
    37     IExtFileStore, IKofaUtils, RETURNING, PAID, CLEARED,
     37    IExtFileStore, IKofaUtils, RETURNING, PAID, CLEARED, GRADUATED,
    3838    academic_sessions_vocab, IFileStoreNameChooser)
    3939from waeup.kofa.interfaces import MessageFactory as _
     
    10031003        format_float = getUtility(IKofaUtils).format_float
    10041004        cgpa = format_float(transcript_data[1], 3)
    1005         f_text = formatted_text('%s (%s)' % (
    1006             cgpa, self.getClassFromCGPA(transcript_data[1], student)[1]))
     1005        if student.state == GRADUATED:
     1006            f_text = formatted_text('%s (%s)' % (
     1007                cgpa, self.getClassFromCGPA(transcript_data[1], student)[1]))
     1008        else:
     1009            f_text = formatted_text('%s' % cgpa)
    10071010        f_text = Paragraph(f_text, ENTRY1_STYLE)
    10081011        contextdata.append([f_label,f_text])
Note: See TracChangeset for help on using the changeset viewer.