Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0023068Openbravo ERPA. Platformpublic2013-02-13 12:312013-03-06 19:42
caristu 
AugustoMauch 
immediatemajoralways
closedfixed 
5
pi 
3.0MP213.0MP21 
shankarb
Core
No
0023068: Sorting by computed column is lost after saving a record with errors
When we have a window sorted by a computed column, and we save a record in grid view with errors, and after that we correct it, the sorting is lost. If we scroll down the records are not sorted.
1) Create the computed column defined here http://wiki.openbravo.com/wiki/How_to_create_a_Computed_Column [^] in the sales order window
2) Sort the window using that computed column
3) Edit a record in grid view and save it with an error
4) Correct it and save. Check that the sort icon has disappeared from the computed column and if you scroll down the window is not sorted anymore.

Note: in some environments step 4) is not necessary
No tags attached.
related to defect 0023154 closed AugustoMauch Read only logic not working as expected. 
related to defect 00232203.0MP21 closed AugustoMauch When calculating the display logic null values are not converted to '' 
diff issue23068.diff (2,595) 2013-02-15 12:06
https://issues.openbravo.com/file_download.php?file_id=5984&type=bug
Issue History
2013-02-13 12:31caristuNew Issue
2013-02-13 12:31caristuAssigned To => AugustoMauch
2013-02-13 12:31caristuModules => Core
2013-02-13 12:31caristuTriggers an Emergency Pack => No
2013-02-13 12:31caristuIssue Monitored: networkb
2013-02-13 12:33caristuversion => pi
2013-02-13 12:39caristuDescription Updatedbug_revision_view_page.php?rev_id=4409#r4409
2013-02-14 14:26AugustoMauchSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=4413#r4413
2013-02-15 11:56AugustoMauchIssue Monitored: shankarb
2013-02-15 11:56AugustoMauchReview Assigned To => shankarb
2013-02-15 12:06AugustoMauchFile Added: issue23068.diff
2013-02-15 12:08hgbotCheckin
2013-02-15 12:08hgbotNote Added: 0056488
2013-02-15 12:08hgbotStatusnew => resolved
2013-02-15 12:08hgbotResolutionopen => fixed
2013-02-15 12:08hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/57378b7ff2bd78d52d69b051cd7683e540e47f87 [^]
2013-02-20 04:50hudsonbotCheckin
2013-02-20 04:50hudsonbotNote Added: 0056608
2013-02-21 08:03shankarbNote Added: 0056664
2013-02-21 08:03shankarbStatusresolved => closed
2013-02-21 08:03shankarbFixed in Version => 3.0MP21
2013-02-25 10:55AugustoMauchRelationship addedrelated to 0023154
2013-02-25 11:08hgbotCheckin
2013-02-25 11:08hgbotNote Added: 0056741
2013-02-28 16:39hudsonbotCheckin
2013-02-28 16:39hudsonbotNote Added: 0056850
2013-03-05 10:22AugustoMauchRelationship addedrelated to 0023220
2013-03-05 10:25hgbotCheckin
2013-03-05 10:25hgbotNote Added: 0057033
2013-03-06 19:42hudsonbotCheckin
2013-03-06 19:42hudsonbotNote Added: 0057110

Notes
(0056488)
hgbot   
2013-02-15 12:08   
Repository: erp/devel/pi
Changeset: 57378b7ff2bd78d52d69b051cd7683e540e47f87
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Fri Feb 15 12:04:59 2013 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/57378b7ff2bd78d52d69b051cd7683e540e47f87 [^]

Fixes issue 23068: Sorting is not reset after saving a record with errors

This problem was caused because the value of the computed column changed from null to an empty string. This caused the sorting of the grid to be cleared, due to [1]. The change from null to an empty string is done in the fixNull250 function. This functions is needed for evaluating properly the display logic of the field, but it should not be called using the record itself, but with a clone of the record, so that the record itself is not changed.


[1] https://code.openbravo.com/erp/mods/org.openbravo.userinterface.smartclient.dev/file/8c2bc26694da/web/org.openbravo.userinterface.smartclient/isomorphic/client/widgets/ListGrid.js#l28665 [^]

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/main/ob-standard-view.js
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-action-button.js
---
(0056608)
hudsonbot   
2013-02-20 04:50   
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/d828167a9e83 [^]

Maturity status: Test
(0056664)
shankarb   
2013-02-21 08:03   
Code reviewed and tested in pi changeset 9f692840db92
(0056741)
hgbot   
2013-02-25 11:08   
Repository: erp/devel/pi
Changeset: 51672575b04f50fb9798ac3dc7a01397d40f7d26
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Mon Feb 25 11:05:03 2013 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/51672575b04f50fb9798ac3dc7a01397d40f7d26 [^]

Fixes issue 23154: Read only logic is working as expected.

In the fix of issue 23068 a change was made so that the current values of the form were not changed to '' if they were originally null. The problem is that the read only logic depended on this to work. This has been fixed by fixing the values inside the onFieldChanged function, the same way it was fixed for the display logc in the issue 23068.

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/templates/ob-view-form.js.ftl
---
(0056850)
hudsonbot   
2013-02-28 16:39   
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/8c5cb16254f4 [^]

Maturity status: Test
(0057033)
hgbot   
2013-03-05 10:25   
Repository: erp/devel/pi
Changeset: 9fa4494e366cb04c8fcee0c6e31ba2186cd0bb6c
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Tue Mar 05 10:24:55 2013 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/9fa4494e366cb04c8fcee0c6e31ba2186cd0bb6c [^]

Fixes issue 23220: Display logic works as expected

In the fix of issue 23068 a change was done to prevent all properties of the form being changed from null to ''. This change had to be done on a clone of the record, not on the record itself.

The problem is that at one point the record itself was being used, being taken for granted that its null values would be replaced with an empty string. This has been fixed by replacing the record by the clone that already has had its null values replaced by ''.

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-action-button.js
---
(0057110)
hudsonbot   
2013-03-06 19:42   
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/95e36a1b246f [^]

Maturity status: Test