Ignore:
Timestamp:
10 Jan 2007, 00:24:40 (18 years ago)
Author:
joachim
Message:

increaselevels

File:
1 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/trunk/skins/waeup_student/getAccommodationInfo.py

    r1249 r1255  
    5858                    )
    5959s_brain = res[0]
     60info['error'] = None
    6061info['matric_no']=s_brain.matric_no
    6162info['jamb_reg_no']=s_brain.jamb_reg_no
     
    100101        #from Products.zdb import set_trace; set_trace()
    101102        certificate = c_brain.getObject().getContent()
    102         if int(s_brain.level) +100 == int(certificate.end_level):
     103        try:
     104            certlevel = int(certificate.end_level)
     105        except:
     106            info["error"] = '"no end_level for","%s"' % c_brain.getId
     107            return info
     108        try:
     109            studentlevel = int(s_brain.level) + 100
     110        except:
     111            info["error"] = '"no level for","%s"' % s_brain.getId
     112            return info
     113        if studentlevel >= certlevel:
    103114            bt = "fi"
    104115d['sex'] = 'male'
Note: See TracChangeset for help on using the changeset viewer.