Changeset 3986 for WAeUP_SRP


Ignore:
Timestamp:
27 Feb 2009, 20:24:33 (16 years ago)
Author:
Henrik Bettermann
Message:

Widgets.py: boolean widget allows True and False

File:
1 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/trunk/Widgets.py

    r3982 r3986  
    10221022            self.render_format = 'select'
    10231023
    1024         female = value in ('F','f','Female','female',"True",True)
    1025         male = value in ('M','m','Male','male','False',False)
     1024        female = value in ('F','f','Female','female','True','true',True)
     1025        male = value in ('M','m','Male','male','False','false',False)
    10261026        if not female and not male:
    10271027            datastructure.setError(self.getWidgetId(),
     
    10521052        if self.render_format not in self.render_formats:
    10531053            self.render_format = 'select'
    1054         true = value.upper() in ('T','1','TRUE','WAHR',True)
    1055         false = value.upper() in ('F','0','FALSE','FALSCH',False)
     1054        true = value.upper() in ('T','1','TRUE','True','true','WAHR',True)
     1055        false = value.upper() in ('F','0','FALSE','False','false','FALSCH',False)
    10561056        if not true and not false:
    10571057            datastructure.setError(self.getWidgetId(),
Note: See TracChangeset for help on using the changeset viewer.