Changeset 5030
- Timestamp:
- 22 Feb 2010, 11:18:29 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/patches/PatchExtendedWidgetsCPSDateTimeWidget.py
r5027 r5030 13 13 if self.view_format == 'import': 14 14 #import pdb;pdb.set_trace() 15 if datastructure[widget_id] == 'None': 16 datastructure[widget_id] == '' 17 try: 18 dt = datastructure[widget_id].strip() 19 date,time,dummy = dt.split() 20 y,m,d = date.split('/') 21 hour,minute,second = time.split(':') 22 except: 23 datastructure.setError(widget_id, 'cpsschemas_err_date') 24 return 0 15 if datastructure[widget_id] == 'None' or datastructure[widget_id] == '': 16 date = None 17 else: 18 try: 19 dt = datastructure[widget_id].strip() 20 date,time,dummy = dt.split() 21 y,m,d = date.split('/') 22 hour,minute,second = time.split(':') 23 except: 24 datastructure.setError(widget_id, 'cpsschemas_err_date') 25 return 0 25 26 if not (date): 26 27 if self.is_required:
Note: See TracChangeset for help on using the changeset viewer.