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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0024637
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminorhave not tried2013-08-30 14:282013-09-27 14:15
ReportercaristuView Statuspublic 
Assigned Toshankarb 
PriorityhighResolutionfixedFixed in Version3.0MP28
StatusclosedFix in branchpiFixed in SCM revision06606d1fa59d
ProjectionnoneETAnoneTarget Version3.0MP28
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned ToAugustoMauch
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0024637: Display Logic does not work in tabs located in windows that have several tabs referencing the same entity

DescriptionDisplay logic is not working in those windows where the referenced table in the header is also referenced in another tab in the same window.
Steps To ReproduceAs system administrator:

1) Go to [Windows, tabs and fields] and look for the Business Partner window (In this window, the c_bpartner table is referenced in the header and also in other tabs: Customer, Vendor and Employee)

2) Add a display logic for the Location/Address tab, for example: @Name2@='AA'

Log-out and Log-in as group admin role

3) Go to the BusinessPartner window and notice that the display logic doesn't work
Proposed SolutionIn the KernelUtils.java class the entities referenced in tabs are stored inside the tabOfEntity hashMap, which stores the entity-tab relationship.

When we have more than one entity referenced in the same window, the header reference is overwritten in the hash-map with the tab referencing the same entity. (Line 406: tabOfEntity.put(entity, aTab);)

Attached is a patch that solves this problem, avoiding this override. But it must be checked if it is valid in all possible scenarios.
TagsNo tags attached.
Attached Filesdiff file icon tabIssue.diff [^] (713 bytes) 2013-08-30 14:28 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]
has duplicate defect 00247633.0MP29 closedAugustoMauch Display logic for tabs not working properly for tabs that reference the same entity of the header 
related to defect 00246383.0MP28 closedshankarb An error appears when using a field in the tab display logic which is present in the header and also in the tab 

-  Notes
(0060880)
shankarb (developer)
2013-09-03 07:07

Issue fixed. Will be pushed in MP28.
(0060924)
hgbot (developer)
2013-09-05 06:34

Repository: erp/devel/pi
Changeset: d208b0b6ef089881027acb04b58392058a9bfe98
Author: Shankar Balachandran <shankar.balachandran <at> openbravo.com>
Date: Mon Sep 02 09:48:15 2013 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/d208b0b6ef089881027acb04b58392058a9bfe98 [^]

Fixes Issue 0024637: Display Logic does not work in tabs located in windows that have several tabs referencing the same entity

When we have more than one entity referenced in the same window, the header reference is overwritten in the hash-map with the tab referencing the same entity.
Overriding is prevented and only if entity is not found in the hash map, it is added.

---
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/KernelUtils.java
---
(0061132)
AugustoMauch (developer)
2013-09-13 10:28

The code that was modified belongs to the getParentTab method of the KernelUtils class. Given a tab, this method returns its parent tab. Suppose this tab structure:

[Tab1 | Entity1]
|
| - [Tab2 | Entity1]
| |
| | - [Tab3 | Entity2]
|
| - [Tab4 | Entity1]
| |
| | - [Tab5 | Entity3]
|
| - [Tab6 | Entity4]

In this case, KernelUtils.getParentTab(tab3) would return tab1, because that is the class associated with the entity1, which is the referenced entity by the tab3 link to parent column.

This issue can be closed when the getParentTab returns the following:
getParentTab(tab1) => null
getParentTab(tab2) => tab1
getParentTab(tab3) => tab2
getParentTab(tab4) => tab1
getParentTab(tab5) => tab4
getParentTab(tab6) => tab1

One way to achieve this would be to store in the tabOfEntity hash an array of tabs for each entity, and then adding some logic to, given an entity, selecting the proper parent tab, probably taking into account the tab level and the tab sequence number.
(0061218)
hudsonbot (developer)
2013-09-17 19:02

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/1c53d622fc50 [^]

Maturity status: Test
(0061292)
shankarb (developer)
2013-09-19 11:28

Issue fixed in the changeset http://code.openbravo.com/erp/devel/pi/rev/06606d1fa59dc0e973c2033683e7e041672227f7 [^] . The other issue 24638 has been reopened becuase the fix does not solve the issue completely.
(0061447)
AugustoMauch (developer)
2013-09-27 14:14

Code reviewed and verified in pi@34a6241c3e04

- Issue History
Date Modified Username Field Change
2013-08-30 14:28 caristu New Issue
2013-08-30 14:28 caristu Assigned To => AugustoMauch
2013-08-30 14:28 caristu File Added: tabIssue.diff
2013-08-30 14:28 caristu Modules => Core
2013-08-30 14:28 caristu Triggers an Emergency Pack => No
2013-08-30 14:28 caristu Issue Monitored: networkb
2013-08-30 14:29 caristu Proposed Solution updated
2013-08-30 14:31 caristu Target Version => 3.0MP28
2013-08-30 14:41 caristu Relationship added related to 0024638
2013-08-30 14:42 caristu Priority normal => high
2013-09-01 07:37 shankarb Assigned To AugustoMauch => shankarb
2013-09-03 07:07 shankarb Status new => scheduled
2013-09-03 07:07 shankarb Note Added: 0060880
2013-09-03 07:07 shankarb fix_in_branch => pi
2013-09-05 06:32 shankarb Review Assigned To => AugustoMauch
2013-09-05 06:32 shankarb fix_in_branch pi =>
2013-09-05 06:32 shankarb Issue Monitored: AugustoMauch
2013-09-05 06:34 hgbot Checkin
2013-09-05 06:34 hgbot Note Added: 0060924
2013-09-05 06:34 hgbot Status scheduled => resolved
2013-09-05 06:34 hgbot Resolution open => fixed
2013-09-05 06:34 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/d208b0b6ef089881027acb04b58392058a9bfe98 [^]
2013-09-13 10:14 caristu Relationship added related to 0024763
2013-09-13 10:28 AugustoMauch Note Added: 0061132
2013-09-13 10:28 AugustoMauch Status resolved => new
2013-09-13 10:28 AugustoMauch Resolution fixed => open
2013-09-17 19:02 hudsonbot Checkin
2013-09-17 19:02 hudsonbot Note Added: 0061218
2013-09-19 11:27 shankarb Status new => scheduled
2013-09-19 11:27 shankarb fix_in_branch => pi
2013-09-19 11:28 shankarb Note Added: 0061292
2013-09-19 11:28 shankarb Status scheduled => resolved
2013-09-19 11:28 shankarb Fixed in Version => pi
2013-09-19 11:28 shankarb Fixed in SCM revision http://code.openbravo.com/erp/devel/pi/rev/d208b0b6ef089881027acb04b58392058a9bfe98 [^] => http://code.openbravo.com/erp/devel/pi/rev/06606d1fa59dc0e973c2033683e7e041672227f7 [^]
2013-09-19 11:28 shankarb Resolution open => fixed
2013-09-27 14:14 AugustoMauch Note Added: 0061447
2013-09-27 14:14 AugustoMauch Status resolved => closed
2013-09-27 14:15 AugustoMauch Fixed in Version pi => 3.0MP28
2013-09-30 14:55 AugustoMauch Relationship replaced has duplicate 0024763


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker