details: https://code.openbravo.com/erp/devel/pi/rev/111e6fc5762c
changeset: 13295:111e6fc5762c
user: Antonio Moreno <antonio.moreno <at> openbravo.com>
date: Wed Jul 27 10:45:34 2011 +0200
summary: Fixed issue 18060. DateTime columns will be correctly exported to CSV
diffstat:
modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/DataSourceServlet.java
| 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diffs (13 lines):
diff -r 7a0507ddc412 -r 111e6fc5762c
modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/DataSourceServlet.java
---
a/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/DataSourceServlet.java
Wed Jul 27 10:37:43 2011 +0200
+++
b/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/DataSourceServlet.java
Wed Jul 27 10:45:34 2011 +0200
@@ -484,7 +484,8 @@
keyValue = dateFormat.format(date);
} else if (dateTimeCols.contains(key) && keyValue != null
&& !keyValue.toString().equals("null")) {
- Date date =
JsonUtils.createDateTimeFormat().parse(keyValue.toString());
+ final String repairedString =
JsonUtils.convertFromXSDToJavaFormat(keyValue.toString());
+ Date date = JsonUtils.createDateTimeFormat().parse(repairedString);
String pattern =
RequestContext.get().getSessionAttribute("#AD_JAVADATETIMEFORMAT")
.toString();
SimpleDateFormat dateFormat = new SimpleDateFormat(pattern);
------------------------------------------------------------------------------
Got Input? Slashdot Needs You.
Take our quick survey online. Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits