Anonymous | Login
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformmajoralways2017-02-23 10:002017-03-15 20:20
ReporterJONHMView Statuspublic 
Assigned Toalostale 
PriorityhighResolutionfixedFixed in Version3.0PR17Q2
StatusclosedFix in branchFixed in SCM revision0d4102902eea
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tocaristu
Web browser
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo

0035346: can't save grid record after opening form if there's a selector with multi field pick list

DescriptionThe problem happens when saving a record in form mode on a tab which contains a selector with multiple fields in the pick list (ie. 'Product Complete' selector), and then return to grid view and create and save more records in that view. Also, some of the toolbar buttons does not respond anymore unless you close the window and reopen again.

The problem is setPickListWidth is invoked for this kind of selectors because space needs to be recalculated, in this situation it is invoked on an already closed pick list which does not contain grid field, so it fails trying to access elements of an undefined object.
Steps To ReproduceFirst, we need the 'Product Complete' selector to be shown in a tab, so as System Administrator:
1) Open [Windows, tabs and fields] > 'Sales Order' window > 'Lines' tab > 'Product' field, and open its related column
2) With a module in development, change its 'Reference search key' and select 'Product Complete' selector

Then, as F&B International Group Admin role:
3) Open [Sales Order] window and create a record
4) Switch to 'Lines' tab and create a record (selecting the product) and save it in FORM view, then return to grid view
5) Create more records in Grid View, also selecting products
--> The toolbar icons does not respond anymore
    check js error:

    at cons.setPickListWidth (c619db9….js:54772)
    at cons.setUpPickList (c619db9….js:54668)
    at cons.setValueMap (ComboBoxItem.js:1717)
    at cons.setEntries (c619db9….js:54650)
    at cons.addValueMapEntry (c619db9….js:54611)
    at cons.transformResponse (c619db9….js:23922)
    at cons._completeResponseProcessing (DataSource.js:13531)
    at cons._handleJSONReply (DataSource.js:11651)
    at cons._handleJSONTextReply (DataSource.js:11744)
    at cons.fireCallback (Class.js:1789)

*** Watch the attached video for a demonstration of how to reproduce ***
TagsNo tags attached.
Attached Files? file icon gridViewError.mp4 [^] (4,625,784 bytes) 2017-02-23 10:00

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
hgbot (developer)
2017-02-24 13:27

Repository: erp/devel/pi
Changeset: 0d4102902eea3c2a36ee9ab9d443cb03f0d05a7b
Author: Asier Lostalé <asier.lostale <at>>
Date: Fri Feb 24 13:07:53 2017 +0100
URL: [^]

fixed bug 35346: can't save grid record with multi field pick list selector

  Records in tabs with a column having a selector with multiple fields in pick
  list couldn't be saved in grid after opening form view.

  The problem was casued becasue this kind of selectors require to calculate the
  size for the picking list, but when saving it is already closed so it failed
  assuming it has a grid.

  Fixed by checking if grid is present which indirectly checks if it is visible.

M modules/org.openbravo.userinterface.selector/web/org.openbravo.userinterface.selector/js/ob-selector-item.js
caristu (developer)
2017-02-27 12:28

Code review + testing OK in pi@1f961fdb2035.
hudsonbot (developer)
2017-03-15 20:20

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2017-02-23 10:00 JONHM New Issue
2017-02-23 10:00 JONHM Assigned To => platform
2017-02-23 10:00 JONHM File Added: gridViewError.mp4
2017-02-23 10:00 JONHM Modules => Core
2017-02-23 10:00 JONHM Triggers an Emergency Pack => No
2017-02-23 10:09 Practics Issue Monitored: Practics
2017-02-24 12:55 alostale Summary Cannot save multiple records if a tab contains a 'Product Complete' selector => can't save grid record after opening form if there's a selector with multi field pick list
2017-02-24 12:55 alostale Description Updated View Revisions
2017-02-24 12:55 alostale Steps to Reproduce Updated View Revisions
2017-02-24 13:01 alostale Status new => scheduled
2017-02-24 13:01 alostale Assigned To platform => alostale
2017-02-24 13:01 alostale Review Assigned To => caristu
2017-02-24 13:27 hgbot Checkin
2017-02-24 13:27 hgbot Note Added: 0094611
2017-02-24 13:27 hgbot Status scheduled => resolved
2017-02-24 13:27 hgbot Resolution open => fixed
2017-02-24 13:27 hgbot Fixed in SCM revision => [^]
2017-02-27 12:28 caristu Note Added: 0094635
2017-02-27 12:28 caristu Status resolved => closed
2017-02-27 12:28 caristu Fixed in Version => 3.0PR17Q2
2017-03-15 20:20 hudsonbot Checkin
2017-03-15 20:20 hudsonbot Note Added: 0095232

Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker