Ignore:
Timestamp:
29 Nov 2006, 14:26:31 (18 years ago)
Author:
joachim
Message:

created new catalog pumeresults for pumeresult checking
modified pume_anon_view and pume_anon_slip to use it.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/trunk/Widgets.py

    r952 r966  
    288288    letters = 2
    289289    letters_str = "L"*letters
    290 
    291290    def validate(self, datastructure, **kw):
    292291        """Validate datastructure and update datamodel."""
     
    294293        valid = CPSStringWidget.validate(self, datastructure, **kw)
    295294        #import pdb;pdb.set_trace()
     295        pumeresults = self.portal_pumeresults
    296296        if not valid:
    297297            return 0
     
    303303                err = 'Invalid number, the expected format is: %s%s with N = Number, L = Letter' % (self.digits_str,self.letters_str)
    304304            else:
    305                 s = getStudentByRegNo(self,value)
    306                 if s is None:
     305                #s = getStudentByRegNo(self,value)
     306                pume = pumeresults(jamb_reg_no = value)
     307                if pume is None:
    307308                    err = 'No Student with JAMB-Reg-No %s' % (value)
    308309                else:
    309                     s_id = s.getId()
    310                     datastructure['s_id'] = s_id
     310                    datastructure['pume'] = pume[0]
    311311            if err:
    312312                datastructure.setError(widget_id, err)
Note: See TracChangeset for help on using the changeset viewer.