Changeset 1382 for WAeUP_SRP


Ignore:
Timestamp:
1 Feb 2007, 08:59:07 (18 years ago)
Author:
Henrik Bettermann
Message:

fixed

File:
1 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/trunk/skins/waeup_utilities/deleteStudentByMatricNo.py

    r1350 r1382  
    3636res_deleted = []
    3737output = []
    38 resi = ret_imp(matric_no=matric_no)
    39 if len(res) != 1:
    40     msg = "Student with matric_no %s not found in students_import" % matric_no
     38res_ret = ret_imp(matric_no=matric_no)
     39if len(res_ret) != 1:
     40    msg = "Student with matric_no %s not found in returning_import" % matric_no
    4141    logger.info(msg)
    4242else:
    43     msg = "Student with matric_no %s removed from students_import" % matric_no
     43    ret_imp.deleteRecord(matric_no)
     44    msg = "Student with matric_no %s removed from returning_import" % matric_no
    4445logger.info(msg)
    4546output.append(msg)
    46 results = res_imp(matric_no=matric_no)
    47 if len(results) > 0:
    48     for r in results:
     47res_res = res_imp(matric_no=matric_no)
     48if len(res_res) > 0:
     49    for r in res_res:
    4950        res_imp.deleteRecord(r.key)
    5051        res_deleted.append(r.key)
    51     msg = "%s results deleted" % (',\n'.join(res_deleted))
     52    msg = "%s results deleted from results_import" % (',\n'.join(res_deleted))
    5253else:
    53     msg = "No results to delete for %s" % matric_no
     54    msg = "No results to delete for %s from results_import" % matric_no
    5455output.append(msg)
    5556logger.info(msg)
Note: See TracChangeset for help on using the changeset viewer.