Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0025012Openbravo ERP00. Application dictionarypublic2013-10-24 17:232015-11-30 09:49
gorkaion 
caristu 
highmajoralways
closedfixed 
20Gentoo
 
3.0PR16Q1 
alostale
Core
No
0025012: Process definition parameters of type text does not work as expected when lenght is 1000 or more
Having a Process Definition of Standard UI Definition with a Parameter with reference "Text" and a length of 1000 or more.
If this process is added to a tab's button field the window is not open and the console shows a javascript error.

The group separator should be defined as comma (",")
1 Create a Process Definition with UI Pattern Standard.
2 Add a Parameter with Reference "Text" and length "2000"
3 Assign the Process Definition to button type column.
4 Try to open a window containing a tab with that button.

Window does not open and the following error appear in the logs:

433955 [http-8080-7] ERROR org.openbravo.client.kernel.ComponentGenerator - Error parsing component View
>>>>>>> Issues found in javascript <<<<<<<<<
Warehouse Picking List.View:1732:20: Unexpected '000'. >> offending code: length: 2,000,
Warehouse Picking List.View:1732:20: Expected ':' and instead saw ','. >> offending code: length: 2,000,
Warehouse Picking List.View:1733:13: Expected '}' to match '{' from line 1722 and instead saw ':'. >> offending code: required: false
Warehouse Picking List.View:1733:15: Expected ']' to match '[' from line 1721 and instead saw 'false'. >> offending code: required: false
Properly format to javascript number the length of text parameters.
No tags attached.
Issue History
2013-10-24 17:23gorkaionNew Issue
2013-10-24 17:23gorkaionAssigned To => AugustoMauch
2013-10-24 17:23gorkaionModules => Core
2013-10-24 17:23gorkaionTriggers an Emergency Pack => No
2015-02-24 17:06alostalePrioritynormal => urgent
2015-02-24 17:06alostaleStatusnew => acknowledged
2015-03-11 13:53alostalePriorityurgent => high
2015-03-17 14:37alostaleAssigned ToAugustoMauch => platform
2015-11-17 19:27caristuAssigned Toplatform => caristu
2015-11-17 19:27caristuStatusacknowledged => scheduled
2015-11-18 10:22hgbotCheckin
2015-11-18 10:22hgbotNote Added: 0081940
2015-11-18 10:22hgbotStatusscheduled => resolved
2015-11-18 10:22hgbotResolutionopen => fixed
2015-11-18 10:22hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/0e332eb591027f96a6c4030257f2f66740fb4e42 [^]
2015-11-18 10:22caristuReview Assigned To => alostale
2015-11-18 10:22caristuIssue Monitored: alostale
2015-11-23 21:17hudsonbotCheckin
2015-11-23 21:17hudsonbotNote Added: 0082250
2015-11-30 09:49alostaleNote Added: 0082458
2015-11-30 09:49alostaleStatusresolved => closed
2015-11-30 09:49alostaleFixed in Version => 3.0PR16Q1

Notes
(0081940)
hgbot   
2015-11-18 10:22   
Repository: erp/devel/pi
Changeset: 0e332eb591027f96a6c4030257f2f66740fb4e42
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Tue Nov 17 19:37:00 2015 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/0e332eb591027f96a6c4030257f2f66740fb4e42 [^]

fixes issue 25012: Process definition params not work if lenght is 1000 or more

The length value was using directly as a float value to generate the js component. This caused the error parsing the component view as for example a length of 2000 result in a value of '2,000'. That comma was causing the error in the parser.

To solve the problem the float value is now converted using the 'c' built-in in the freemarker template. This built-in converts a number to string for a 'computer language', using dot as decimal separator. Also it never uses grouping separators which is the key to solve this problem.

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/templates/ob-param-window-parameter.ftl
---
(0082250)
hudsonbot   
2015-11-23 21:17   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/7b56bebaaa88 [^]
Maturity status: Test
(0082458)
alostale   
2015-11-30 09:49   
code reviewed + verified