Hi,
When I use a DateItem with setUseTextField(Boolean.TRUE) the date encoding in JSON isn't used and the data is send as displayed instead of the JSON date encoding preference. The same works correctly if you don't use the setUseTextField.
You can easily reproduce with that and then look at the Developer console to see that the date isn't send in the default JSON date format.
The same removing the useTextField works correctly.
Can I submit this as a bug?
Browser: Ie8 but it's not browser dependent
SmartGWT 2.3 current trunk version
When I use a DateItem with setUseTextField(Boolean.TRUE) the date encoding in JSON isn't used and the data is send as displayed instead of the JSON date encoding preference. The same works correctly if you don't use the setUseTextField.
You can easily reproduce with that and then look at the Developer console to see that the date isn't send in the default JSON date format.
Code:
public void onModuleLoad() { RestDataSource rds=new RestDataSource(); rds.setDataFormat(DSDataFormat.JSON); DataSourceDateField dfield=new DataSourceDateField("date"); rds.setFields(dfield); final DynamicForm dm=new DynamicForm(); dm.setDataSource(rds); DateItem date=new DateItem("date","Date"); date.setUseTextField(Boolean.TRUE); ButtonItem send=new ButtonItem("send"); send.addClickHandler(new ClickHandler() { public void onClick(ClickEvent event) { dm.saveData(); } }); dm.setFields(date,send); dm.setHeight100(); dm.setWidth100(); RootPanel.get().add(dm);
Can I submit this as a bug?
Browser: Ie8 but it's not browser dependent
SmartGWT 2.3 current trunk version
Comment