Commit dd690925 authored by Thibaut Deheunynck's avatar Thibaut Deheunynck

add a new date format with an Y

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@21520 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 0c337f16
......@@ -1071,7 +1071,7 @@ class ManageCSS:
str(scaling_factor1 *float(properties_field['position_x'])) + 'px'
if properties_field['input_order'] in \
['day/month/year', 'dmy', 'month/day/year', 'mdy']:
['day/month/year', 'dmy', 'dmY', 'month/day/year', 'mdy', 'mdY']:
# specified input order. must be dd/mm/yyyy or mm/dd/yyyy (year is
# the last field).
......@@ -2076,11 +2076,11 @@ class ScribusParser:
# getting special properties for DateTimeField objects
if object_dict['erp_type'] == 'DateTimeField':
# recovering ERP equivalent for user's input_order
if properties_field['input_order'] in ['day/month/year','dmy']:
if properties_field['input_order'] in ['day/month/year', 'dmy', 'dmY']:
object_dict['attributes']['input_order'] = 'dmy'
elif properties_field['input_order'] in ['month/day/year','mdy']:
elif properties_field['input_order'] in ['month/day/year','mdy', 'mdY']:
object_dict['attributes']['input_order'] = 'mdy'
elif properties_field['input_order'] in ['year/month/day','ymd']:
elif properties_field['input_order'] in ['year/month/day','ymd', 'Ymd']:
object_dict['attributes']['input_order'] = 'ymd'
else:
LOG('ScribusParser', INFO,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment