Hi Team,I have a date editor control in my site. If i select a date . It is saving the previous date of selected date.I have set the DataMode as 'Date' and enableUTCDates as 'false' . If am selecting the date it is posting correctly .If i have default value for the date picker control and not changing the default date . It is posting the previous date of the default date. Please suggest me to overcome this issue.$("#Field_Name").igDatePicker({ value: DefaultValue, dataMode: 'date' enableUTCDates:false, });
Hello Ramesh,
Thank you for posting in our community!
I have tried and could not reproduce the described behavior.
1)What is the DefaultValue you try to set? Is it a valid dateObject? Please notice, when dataMode option is set to date, the Date object is used. When that mode is set the value send to the server on submit is string value converter from the javascript Date object using "toISOString" method.
2)Where is DefaultValue defined and is it available prior to the igDatePicker initialization?
3) Could you please add some more details including the actual code in use or preferably an isolated sample with the steps to reproduce the issue?
4)Can you specify what is the exact version of Ignite UI 2016 Vol. 2 you are using?
PS: Please notice enableUTCDates:false is the default setting for the widget and it should work the same without setting this option at all.
What is more, there are braking changes in progress regarding what enableUTCDates does and how it is used, so it is to be considered in case you are using the latest source or plan to update the version you are using. If interested, please take a look at the following Pull request https://github.com/IgniteUI/ignite-ui/pull/540 , as well as the issue logged itself.