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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0053866
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 07. Sales managementmajoralways2023-11-06 15:502023-12-20 15:36
ReporterDaria_ShView Statuspublic 
Assigned ToTriage Platform Base 
PriorityimmediateResolutionfixedFixed in VersionPR24Q1
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Web browser
ModulesCore
Regression levelAutomated tests
Regression date2023-10-17
Regression introduced in releasepi
Regression introduced by commithttps://gitlab.com/openbravo/product/openbravo/-/commit/22b446ee1caf09bee0f4d8ca3ad6eb97f4164df5 [^]
Triggers an Emergency PackNo
Summary

0053866: 'No items to show' is shown when adding the 'Price List Version' to the new product

DescriptionThe 'Price List Version' dropdown list does not display any rows when creating a new product in Backoffice.
Issue reproducible in livebuilds "pi" but not reproducible in livebuilds 23Q3.1
Steps To Reproduce1.Go to Backoffice (login: Openbravo/password: openbravo)
2.Proceed to Product window
3.Fulfill the necessary fields to create new product → Click Ctrl+S to save the changes
4.Navigate to 'Price' tab
5.Right click to create new record → Click the arrow to expand 'Price List Version' drop down list

Actual result: 'No items to show' is displaying
Expected result: The list with available 'Price Lists'(exists in Price List window) is displaying
TagsNo tags attached.
Attached Filespng file icon Screenshot_6.png [^] (97,674 bytes) 2023-11-06 15:50

- Relationships Relation Graph ] Dependency Graph ]
caused by defect 0053408 closedablasco Do not persist access for automatic roles 

-  Notes
(0157146)
AugustoMauch (administrator)
2023-11-14 17:36

These are the afected validation rules:


<!--800022--> <CODE><![CDATA[AD_CLIENT.ISACTIVE = 'Y' AND EXISTS (SELECT 1 FROM AD_ROLE_ORGACCESS WHERE AD_ROLE_ORGACCESS.AD_CLIENT_ID = AD_CLIENT.AD_CLIENT_ID AND AD_ROLE_ORGACCESS.AD_ROLE_ID = @Default_AD_Role_ID@ AND AD_ROLE_ORGACCESS.ISACTIVE = 'Y')]]></CODE>

 name | name | tablevel | name | sqllogic
------+------+----------+----------------+----------
 User | User | 0 | Default Client |


<!--800023--> <CODE><![CDATA[EXISTS (SELECT 1 FROM AD_ROLE_ORGACCESS A_R_O, ad_role r
        WHERE A_R_O.AD_ORG_ID = AD_ORG.AD_Org_ID
        AND A_R_O.ISACTIVE = 'Y'
        AND A_R_O.AD_ROLE_ID = R.AD_ROLE_ID
        and r.ad_role_id = @Default_AD_Role_ID@
        AND R.ISACTIVE = 'Y'
        AND (LPAD(TO_CHAR(R.USERLEVEL), 1, '1')='S' OR AD_ORG.AD_ORG_ID <> '0')
        AND A_R_O.AD_ROLE_ID = @Default_AD_Role_ID@)]]></CODE>

db_pos2_modules=> select w.name, t.name, t.tablevel, f.name, c.sqllogic from ad_window w, ad_tab t, ad_field f, ad_column c where w.ad_window_id = t.ad_window_id and t.ad_tab_id = f.ad_tab_id and f.ad_column_id = c.ad_column_id and c.ad_column_id in (select ad_column_id from ad_column where ad_val_rule_id = '800023') order by 1, 2, 3;
 name | name | tablevel | name | sqllogic
------+------+----------+----------------------+----------
 User | User | 0 | Default Organization |
(1 row)


<!--994D5D0FB26D44988D04CE19D66B0A2C--> <CODE><![CDATA[EXISTS (SELECT 1
        FROM AD_ROLE_ORGACCESS A_R_O
        INNER JOIN ad_role r ON (A_R_O.AD_ROLE_ID = r.AD_ROLE_ID)
        WHERE A_R_O.ISACTIVE = 'Y'
        AND r.ISACTIVE = 'Y'
        and r.ad_role_id = @#AD_Role_ID@
        AND (A_R_O.AD_ORG_ID = td0.AD_Org_ID
             OR (SUBSTR(TO_CHAR(r.USERLEVEL), 2, 1) = 'C' AND td0.AD_ORG_ID = '0')
             )
        )]]></CODE>

db_pos2_modules=> select w.name, t.name, t.tablevel, f.name, c.sqllogic from ad_window w, ad_tab t, ad_field f, ad_column c where w.ad_window_id = t.ad_window_id and t.ad_tab_id = f.ad_tab_id and f.ad_column_id = c.ad_column_id and c.ad_column_id in (select ad_column_id from ad_column where ad_val_rule_id = '994D5D0FB26D44988D04CE19D66B0A2C') order by 1, 2, 3;
               name | name | tablevel | name | sqllogic
----------------------------------+-------------------------------+----------+--------------------+----------
 Commercial Operations by Product | Commercial Operations | 0 | Product Price |
 Commercial Operations by Product | Commercial Operations | 0 | Price List Version |
 Expense Type | Price | 2 | Price List Version |
 Price List | Product Price | 2 | Price List Version |
 Price List | Product Price with Exceptions | 3 | Product Price |
 Product | Price | 1 | Price List Version |
 Product | Product Price with Exceptions | 2 | Product Price |
 Resource | Price | 2 | Price List Version |


 <!--D9463AFD77E44F619D396C19BF9E6A15--> <CODE><![CDATA[EXISTS (SELECT 1 FROM AD_ROLE_ORGACCESS A_R_O, ad_role r
        WHERE A_R_O.AD_ORG_ID = AD_ORG.AD_Org_ID
        AND A_R_O.ISACTIVE = 'Y'
        AND A_R_O.AD_ROLE_ID = R.AD_ROLE_ID
        and r.ad_role_id = @#AD_Role_ID@
        AND R.ISACTIVE = 'Y'
        AND (LPAD(TO_CHAR(R.USERLEVEL), 1, '1')='S' OR AD_ORG.AD_ORG_ID <> '0')
        AND A_R_O.AD_ROLE_ID = @#AD_Role_ID@)]]></CODE>

db_pos2_modules=> select w.name, t.name, t.tablevel, f.name, c.sqllogic from ad_window w, ad_tab t, ad_field f, ad_column c where w.ad_window_id = t.ad_window_id and t.ad_tab_id = f.ad_tab_id and f.ad_column_id = c.ad_column_id and c.ad_column_id in (select ad_column_id from ad_column where ad_val_rule_id = 'D9463AFD77E44F619D396C19BF9E6A15') order by 1, 2, 3;
 name | name | tablevel | name | sqllogic
------+------+----------+------+----------
(0 rows)
(0157934)
hgbot (developer)
2023-12-04 10:18

Merge Request created: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/1064 [^]
(0158415)
hgbot (developer)
2023-12-20 15:36

Merge request merged: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/1064 [^]
(0158416)
hgbot (developer)
2023-12-20 15:36

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: 24a0faec07cb9eb6ed1493a13cd670897f48e8cd
Author: meriem azaf <meriem.azaf@openbravo.com>
Date: 20-12-2023 14:36:52
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/24a0faec07cb9eb6ed1493a13cd670897f48e8cd [^]

Fixes ISSUE-53866: 'No items to show' is shown when adding the 'Price List Version' to the new product

The 'Price List Version' dropdown list does not display any rows when creating a new product in Backoffice.

The problem was in 4 validation rules that use role_orgAccess table, so it is a regression related with recently merged automatic roles project.

That project removed all the role_orgaccess entries, as automatic roles now by default have access to all orgs of the client with their corresponding user-level.

To fix this, we added an extra query "EXISTS" before the old one to be executed where the role is automatic so the second will be executed when the role is manual.

---
M src-db/database/sourcedata/AD_VAL_RULE.xml
---

- Issue History
Date Modified Username Field Change
2023-11-06 15:50 Daria_Sh New Issue
2023-11-06 15:50 Daria_Sh Assigned To => Triage Omni OMS
2023-11-06 15:50 Daria_Sh Modules => Core
2023-11-06 15:50 Daria_Sh Triggers an Emergency Pack => No
2023-11-06 15:50 Daria_Sh File Added: Screenshot_6.png
2023-11-14 15:07 lorenzofidalgo Regression level => Automated tests
2023-11-14 15:07 lorenzofidalgo Regression introduced in release => pi
2023-11-14 15:07 lorenzofidalgo Priority normal => immediate
2023-11-14 15:07 lorenzofidalgo Severity minor => major
2023-11-14 15:07 lorenzofidalgo Reproducibility have not tried => always
2023-11-14 15:07 lorenzofidalgo Description Updated View Revisions
2023-11-14 16:54 lorenzofidalgo Relationship added caused by 0053408
2023-11-14 17:00 lorenzofidalgo Regression date => 2023-10-17
2023-11-14 17:00 lorenzofidalgo Regression introduced by commit => https://gitlab.com/openbravo/product/openbravo/-/commit/22b446ee1caf09bee0f4d8ca3ad6eb97f4164df5 [^]
2023-11-14 17:03 aferraz Assigned To Triage Omni OMS => Triage Platform Base
2023-11-14 17:36 AugustoMauch Note Added: 0157146
2023-12-04 10:18 hgbot Note Added: 0157934
2023-12-20 15:36 hgbot Resolution open => fixed
2023-12-20 15:36 hgbot Status new => closed
2023-12-20 15:36 hgbot Note Added: 0158415
2023-12-20 15:36 hgbot Fixed in Version => PR24Q1
2023-12-20 15:36 hgbot Note Added: 0158416


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker