Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0042270
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminorhave not tried2019-11-13 18:282019-12-12 23:01
ReportercaristuView Statuspublic 
Assigned Tocaristu 
PriorityhighResolutionfixedFixed in Version3.0PR20Q1
StatusclosedFix in branchFixed in SCM revision0a493e062362
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toalostale
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0042270: Grid not properly initialized due to missing window personalization information

DescriptionThe grids of an standard window can not be initialized properly having view personalizations: if the default view personalization is not provided by the WindowSettingsActionHandler and there exists one or more view personalizations then the following JS error is thrown when trying to save a record:

Class.js:1796 Uncaught TypeError: Cannot read property 'length' of undefined
    at cons.addToCacheData (b695962a877b1a59ae4c48580e07e5f7.js:47135)
    at cons.callback [as _userCallback] (b695962a877b1a59ae4c48580e07e5f7.js:42783)
    at cons.fireCallback (Class.js:1789)
    at cons.fireCallback (Class.js:3488)
    at cons.formSavedComplete (ActionMethods.js:1132)
    at cons._saveDataReply (ActionMethods.js:1102)
    at cons.eval (eval at isc__makeFunction (Object.js:129), <anonymous>:1:18)
    at cons.fireCallback (Class.js:1789)
    at cons.fireCallback (Class.js:3488)
    at cons.fireResponseCallbacks (DataSource.js:13641)
Steps To Reproduce1) Go to the [Purchase Order] window and create a new saved view. Set it as default.
2) Go to the database and perform a manual delete of the window personalization created in step 1: delete from obuiapp_uipersonalization where obuiapp_uipersonalization_id =<uuid>. This lead us to an state where the default save view is still defined in the application (through the "Default View Setting" preference) but the window personalization definition is not present.
3) Log out/log in
4) Go to the [Purchase Order] window and create a new saved view. Do NOT set it as default.
5) Log out/log in
6) Go to the [Purchase Order] and try to create a new record. The JS error is thrown which avoids to save the record.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 00282423.0PR15Q1 closedAugustoMauch First request to load the window data is not done under some circumnstances 

-  Notes
(0115591)
hgbot (developer)
2019-11-13 19:30

Repository: erp/devel/pi
Changeset: 0a493e062362c9d16b14311e5c0ede6228f95308
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Wed Nov 13 19:14:34 2019 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/0a493e062362c9d16b14311e5c0ede6228f95308 [^]

fixes bug 42270: window can be not initialized if default saved view is missing

  Having a window with several saved view personalizations, if the default saved view is not provided by the WindowSettingsActionHandler then the header's grid was not properly initialized, leaving it in an inconsistent state which did not allow to save records.

  Note that it already exists a mechanism that tries to avoid this scenario by deleting the configuration used to mark a personalization as default in case it does not exists (WindowPersonalizationEventHandler). But this inconsistent state can be also reached in case the window personalization is manually deleted through the database (i.e., by deleting the corresponding obuiapp_uipersonalization record).

  To fix this problem now we are forcing the grid initialization in case the default view is not found.

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/main/ob-standard-window.js
---
(0115618)
alostale (developer)
2019-11-15 09:21

reviewed + tested
(0116283)
hudsonbot (developer)
2019-12-12 23:01

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/954d2b7a66fb [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2019-11-13 18:28 caristu New Issue
2019-11-13 18:28 caristu Assigned To => platform
2019-11-13 18:28 caristu Modules => Core
2019-11-13 18:28 caristu Triggers an Emergency Pack => No
2019-11-13 18:28 caristu Relationship added related to 0028242
2019-11-13 18:34 caristu Assigned To platform => caristu
2019-11-13 18:36 caristu Review Assigned To => alostale
2019-11-13 19:30 hgbot Checkin
2019-11-13 19:30 hgbot Note Added: 0115591
2019-11-13 19:30 hgbot Status new => resolved
2019-11-13 19:30 hgbot Resolution open => fixed
2019-11-13 19:30 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/0a493e062362c9d16b14311e5c0ede6228f95308 [^]
2019-11-13 19:31 caristu Summary Window generated in inconsistent state due to missing window personalization information => Window grids not properly initialized due to missing window personalization information
2019-11-13 19:31 caristu Description Updated View Revisions
2019-11-13 19:31 caristu Summary Window grids not properly initialized due to missing window personalization information => grid not properly initialized due to missing window personalization information
2019-11-13 19:32 caristu Summary grid not properly initialized due to missing window personalization information => Grid not properly initialized due to missing window personalization information
2019-11-13 19:32 caristu Description Updated View Revisions
2019-11-14 08:36 rafaroda Issue Monitored: rafaroda
2019-11-15 09:21 alostale Status resolved => closed
2019-11-15 09:21 alostale Fixed in Version => 3.0PR20Q1
2019-11-15 09:21 alostale Note Added: 0115618
2019-12-12 23:01 hudsonbot Checkin
2019-12-12 23:01 hudsonbot Note Added: 0116283


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker