Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0021533 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] A. Platform | major | have not tried | 2012-09-03 13:08 | 2012-09-26 17:18 | |||
Reporter | mtaal | View Status | public | |||||
Assigned To | AugustoMauch | |||||||
Priority | normal | Resolution | fixed | Fixed in Version | 3.0MP16 | |||
Status | closed | Fix in branch | Fixed in SCM revision | 6b2ba000fb7a | ||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Merge Request Status | ||||||||
Review Assigned To | mtaal | |||||||
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 | 0021533: ShowIf computation incorrect for showIf values which are a boolean | |||||||
Description | In the ob-main-view.js the showIf property is replaced with a function, see this line: fld.showIf = function (item, value, form, values) { then the original value of showIf is stored in the originalShowIf property. And it is then called in the function above: originalShowIfValue = this.originalShowIf(item, value, form, currentValues, context); But this fails if the original show If value is not a function but a string (for example: "false"). For fields initially not displayed in the grid the showIf has the value "false", see this snippet in the view field ftl: <#if !field.showInitiallyInGrid> , showIf: '${field.showInitiallyInGrid?string}' </#if> and this is not a function, so treating it as a function call in the ob-view-main.js is wrong. The function definition in ob-view-main.js should be changed to take into account string values. | |||||||
Steps To Reproduce | See for example the net list price in the sales order line tab. | |||||||
Tags | No tags attached. | |||||||
Attached Files | ||||||||
![]() |
||||||||
|
![]() |
|
(0051932) hgbot (developer) 2012-09-07 13:59 |
Repository: erp/devel/pi Changeset: 6b2ba000fb7a772d810be7fb7ace8d17a64fff18 Author: Augusto Mauch <augusto.mauch <at> openbravo.com> Date: Fri Sep 07 13:57:57 2012 +0200 URL: http://code.openbravo.com/erp/devel/pi/rev/6b2ba000fb7a772d810be7fb7ace8d17a64fff18 [^] Fixes issue 21533: Showif computation now supports boolean values Now, before trying to execute the originalShowIf property, it is checked if it is set to 'true' or 'false'. In that case, it is assigned to originalShowIfValue the corresponding boolean. If not, it is executed as a function as usual. --- M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/main/ob-standard-view.js --- |
(0051942) hgbot (developer) 2012-09-07 14:41 |
Repository: erp/devel/pi Changeset: c60e1cf42d3b190810fdddfe4dfc2c2d2d53def4 Author: Augusto Mauch <augusto.mauch <at> openbravo.com> Date: Fri Sep 07 14:40:32 2012 +0200 URL: http://code.openbravo.com/erp/devel/pi/rev/c60e1cf42d3b190810fdddfe4dfc2c2d2d53def4 [^] Related to issue 21533: Fix refactored to detect if input is a function The code has been refactored, so that if the input is a function is executes it, while if it is not a function, it tries to decode using isc.JSON.decode. --- M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/main/ob-standard-view.js --- |
(0052123) mtaal (viewer) 2012-09-14 11:39 |
Reviewed |
(0052713) hudsonbot (viewer) 2012-09-26 17:18 |
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/b780e90c6452 [^] Maturity status: Test |
(0052717) hudsonbot (viewer) 2012-09-26 17:18 |
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/b780e90c6452 [^] Maturity status: Test |
![]() |
|||
Date Modified | Username | Field | Change |
2012-09-03 13:08 | mtaal | New Issue | |
2012-09-03 13:08 | mtaal | Assigned To | => marvintm |
2012-09-03 13:08 | mtaal | Modules | => Core |
2012-09-03 13:08 | mtaal | OBNetwork customer | => No |
2012-09-03 13:10 | mtaal | Relationship added | related to 0021530 |
2012-09-05 17:22 | AugustoMauch | Assigned To | marvintm => AugustoMauch |
2012-09-07 13:58 | AugustoMauch | Closed by | => mtaal |
2012-09-07 13:59 | hgbot | Checkin | |
2012-09-07 13:59 | hgbot | Note Added: 0051932 | |
2012-09-07 13:59 | hgbot | Status | new => resolved |
2012-09-07 13:59 | hgbot | Resolution | open => fixed |
2012-09-07 13:59 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/6b2ba000fb7a772d810be7fb7ace8d17a64fff18 [^] |
2012-09-07 14:41 | hgbot | Checkin | |
2012-09-07 14:41 | hgbot | Note Added: 0051942 | |
2012-09-14 11:39 | mtaal | Note Added: 0052123 | |
2012-09-14 11:39 | mtaal | Status | resolved => closed |
2012-09-14 11:39 | mtaal | Fixed in Version | => 3.0MP16 |
2012-09-26 17:18 | hudsonbot | Checkin | |
2012-09-26 17:18 | hudsonbot | Note Added: 0052713 | |
2012-09-26 17:18 | hudsonbot | Checkin | |
2012-09-26 17:18 | hudsonbot | Note Added: 0052717 |
Copyright © 2000 - 2009 MantisBT Group |