Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0004683 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] F. Localization | major | always | 2008-08-22 14:39 | 2009-04-21 11:06 | |||
Reporter | gorka_gil | View Status | public | |||||
Assigned To | Dowid | |||||||
Priority | normal | Resolution | fixed | Fixed in Version | ||||
Status | closed | Fix in branch | pi | Fixed in SCM revision | 10878 | |||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | pi | SCM revision | 6502 | |||||
Merge Request Status | ||||||||
Review Assigned To | ||||||||
OBNetwork customer | No | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Support ticket | ||||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0004683: In some jasper reports date format is hardcoded | |||||||
Description | In some jasper reports date format is hardcoded: <textField...pattern="dd/MM/yyyy"...> The files are: ad_reports/ReportAnnualCertification.jrxml ad_reports/ReportGuaranteeDateJR.jrxml ad_reports/ReportInvoiceCustomerJR.jrxml ad_reports/ReportInvoicesEditJR.jrxml ad_reports/ReportOrderNotInvoiceJR.jrxml ad_reports/ReportPurchaseOrder.jrxml ad_reports/ReportSalesOrderJR.jrxml ad_reports/ReportShipmentEdition.jrxml ad_reports/ReportTaxInvoicePurchase.jrxml ad_reports/ReportTaxInvoicePurchaseForeign.jrxml ad_reports/ReportTaxInvoiceSale.jrxml ad_reports/ReportTaxInvoiceSaleForeign.jrxml erpReports/C_OrderJR.jrxml erpReports/ReportRegisterByVatJR.jrxml erpReports/ReportRegisterLineJR.jrxml erpReports/RptC_Invoice.jrxml erpReports/RptC_OrderPO.jrxml erpReports/RptC_Remittance.jrxml erpReports/RptC_Remittance_Lines.jrxml erpReports/RptM_Requisition.jrxml | |||||||
Proposed Solution | Now, this reports has some parameters defined as date type, and in the jrxml is hardcoded the pattern that defines the format of the date. A solution can be change the type of the parameters to string, and apply the date format in java and send the parameter as string to jasper. | |||||||
Tags | No tags attached. | |||||||
Attached Files | ||||||||
![]() |
||||||||||||||||||||||
|
![]() |
|
(0010282) gorka_gil (administrator) 2008-11-14 13:56 |
In some reports is enough to remove the pattern attribute, because the specified date format in "dateFormat.java" variable in Openbravo.properties is applied . For example in ReportSalesOrderJR.jrxml in line 425 only removing: pattern="dd-MM-yyy" is enough. |
(0010885) Dowid (viewer) 2008-12-02 13:27 |
It's sufficient enough to remove pattern="dd-MM-yyy" in all reports, except for ReportAnnualCertification.jrxml For report ReportAnnualCertification.jrxml I propose to convert the java.util.Date into java.lang.String using the following code: <parameter name="DateFormatter" class="java.text.DateFormat" isForPrompting="false"> <defaultValueExpression>$P{REPORT_FORMAT_FACTORY}.createDateFormat("", $P{REPORT_LOCALE}, $P{REPORT_TIME_ZONE})</defaultValueExpression> </parameter> <textFieldExpression class="java.lang.String"><![CDATA[$P{DATEFORMATTER}.format(new Date())]]></textFieldExpression> This code can be used in jasper reports to convert Date into String without "hardcoding" the date format. |
(0010910) svnbot (viewer) 2008-12-02 17:06 |
Repository: openbravo Revision: 10878 Author: dowid Date: 2008-12-02 17:06:07 +0100 (Tue, 02 Dec 2008) Bug fixed 0004683: In some jasper reports date format is hardcoded --- U trunk/src/org/openbravo/erpCommon/ad_reports/ReportAnnualCertification.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportGuaranteeDateJR.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportInvoiceCustomerJR.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportInvoicesEditJR.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportOrderNotInvoiceJR.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportPurchaseOrder.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportSalesOrderJR.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportShipmentEdition.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportTaxInvoicePurchase.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportTaxInvoicePurchaseForeign.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportTaxInvoiceSale.jrxml U trunk/src/org/openbravo/erpCommon/ad_reports/ReportTaxInvoiceSaleForeign.jrxml U trunk/src/org/openbravo/erpReports/C_OrderJR.jrxml U trunk/src/org/openbravo/erpReports/RptC_Invoice.jrxml U trunk/src/org/openbravo/erpReports/RptC_OrderPO.jrxml U trunk/src/org/openbravo/erpReports/RptC_Remittance.jrxml U trunk/src/org/openbravo/erpReports/RptC_Remittance_Lines.jrxml U trunk/src/org/openbravo/erpReports/RptM_Requisition.jrxml --- https://dev.openbravo.com/websvn/openbravo/?rev=10878&sc=1 [^] |
![]() |
|||
Date Modified | Username | Field | Change |
2008-08-22 14:39 | gorka_gil | New Issue | |
2008-08-22 14:39 | gorka_gil | Assigned To | => cromero |
2008-08-22 14:39 | gorka_gil | sf_bug_id | 0 => 2067410 |
2008-08-22 14:39 | gorka_gil | OBNetwork customer | => No |
2008-08-22 14:39 | gorka_gil | Regression testing | => No |
2008-08-25 16:34 | gorka_gil | Relationship added | related to 0004668 |
2008-09-01 11:55 | psarobe | Status | new => scheduled |
2008-09-01 11:55 | psarobe | fix_in_branch | => trunk |
2008-09-01 12:36 | gorka_gil | fix_in_branch | trunk => |
2008-09-01 12:36 | gorka_gil | Steps to Reproduce Updated | |
2008-09-04 10:02 | cromero | Status | scheduled => feedback |
2008-09-04 10:02 | cromero | Assigned To | cromero => gorka_gil |
2008-09-04 10:02 | cromero | Severity | minor => major |
2008-09-04 10:03 | cromero | Status | feedback => scheduled |
2008-09-04 10:03 | cromero | fix_in_branch | => trunk |
2008-09-05 17:30 | cromero | Status | scheduled => feedback |
2008-09-05 17:31 | cromero | Status | feedback => scheduled |
2008-09-10 09:57 | cromero | Status | scheduled => feedback |
2008-09-10 09:57 | cromero | Status | feedback => scheduled |
2008-09-29 12:31 | psarobe | Relationship added | has duplicate 0005130 |
2008-11-13 22:53 | rafaroda | Assigned To | gorka_gil => Hennadzi |
2008-11-14 13:56 | gorka_gil | Note Added: 0010282 | |
2008-11-26 10:26 | PavelPonomarev | Assigned To | Hennadzi => Dowid |
2008-12-02 13:27 | Dowid | Note Added: 0010885 | |
2008-12-02 17:06 | svnbot | Checkin | |
2008-12-02 17:06 | svnbot | Note Added: 0010910 | |
2008-12-02 17:06 | svnbot | Status | scheduled => resolved |
2008-12-02 17:06 | svnbot | Resolution | open => fixed |
2008-12-02 17:06 | svnbot | svn_revision | => 10878 |
2009-04-21 11:06 | psarobe | Status | resolved => closed |
Copyright © 2000 - 2009 MantisBT Group |