Changeset 3247


Ignore:
Timestamp:
28 Feb 2008, 06:48:14 (17 years ago)
Author:
Henrik Bettermann
Message:

fix and resolve ticket #491

File:
1 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/base/Widgets.py

    r3246 r3247  
    15441544                    datastructure['reg_no'] = ref
    15451545                    res = self.applicants_catalog(reg_no = ref)
    1546                     if res.screening_type != screening_type_request\
    1547                           and screening_type_request != 'manage':
    1548                         err = "You are using the wrong access form!"
    1549                         s_logger.info('%s tried to use %s application form but has applied for %s' % (ref,screening_type_request,applicant.screening_type))
    1550                         break                   
    1551                     if not res:
     1546                    if res:
     1547                        if getattr(res[0],'screening_type',None) != screening_type_request\
     1548                              and screening_type_request != 'manage':
     1549                            err = "You are using the wrong access form!"
     1550                            s_logger.info('%s tried to use %s application form but has applied for %s' % (ref,screening_type_request,getattr(res[0],'screening_type',None)))
     1551                            break
     1552                        s_logger.info('%s/%s repeatedly entered application record with PIN %s' % (member_id,ref,pin_str))
     1553                    else:
    15521554                        s_logger.info('%s successfully used PIN %s' % (ref,pin_str))
    15531555                        d = {}
     
    15591561                                                  pin_record.serial)
    15601562                        self.applicants_catalog.addRecord(**d)
    1561                     else:
    1562                         s_logger.info('%s/%s repeatedly entered application record with PIN %s' % (member_id,ref,pin_str))
     1563                       
    15631564            break
    15641565        if err:
Note: See TracChangeset for help on using the changeset viewer.