Reports not editable by regular users based on "Line Items" Report Module #2453

Closed
opened 2026-02-20 15:24:07 -05:00 by deekerman · 2 comments
Owner

Originally created by @artjomsmorscakovs on GitHub (Nov 6, 2017).

Issue

Two users: Admin, Regular User
No Roles or Security Groups created
Case #1 Admin creates Report with Report Module equal to "Line Items"
Case #2 Regular User created Report with Report Module equal to "Line Items"

Expected Behavior

Both cases can create and view and edit

Actual Behavior

Case #1 Report created and viewable by Admin, Regular User not able to view it (It sees the record but link doesn`t show, If you try to go to a detailed view using url and Id, then you get error:
"You do not have access to this area. Contact your site administrator to obtain access.

Redirect to Home in 3 seconds

Case #2 After pushing save button you get message "You do not have access to this area. Contact your site administrator to obtain access.

Redirect to Home in 3 seconds

Possible Fix

I was able to fix this by creating records for "Line Items" module in acl_actions table

INSERT INTO acl_actions (id, date_entered, date_modified, modified_user_id, created_by, name, category, acltype, aclaccess, deleted) VALUES ('3b51b254-5b6c-b2db-abc2-582e8ac2f265', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'access', 'AOS_Products_Quotes', 'module', '89', '0'), ('3d6a812a-41b2-c9a5-abc7-582e8a5c8f34', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'delete', 'AOS_Products_Quotes', 'module', '90', '0'), ('3ce4825f-da3e-d3d7-abcf-582e8a4057a6', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'edit', 'AOS_Products_Quotes', 'module', '90', '0'), ('3e76e190-8ca9-f4fe-abc6-582e8ac8c2ec', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'export', 'AOS_Products_Quotes', 'module', '90', '0'), ('3dedb06c-23f1-a963-abc3-582e8a48db52', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'import', 'AOS_Products_Quotes', 'module', '90', '0'), ('3c648899-74c9-673a-abc3-582e8af5b317', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'list', 'AOS_Products_Quotes', 'module', '90', '0'), ('3f002d14-060b-28f0-6bd5-abce8ab1ec1f', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'massupdate', 'AOS_Products_Quotes', 'module', '90', '0'), ('3be1b70f-2f88-a396-030d-abce8a2de8b7', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'view', 'AOS_Products_Quotes', 'module', '90', '0');

Steps to Reproduce

  1. Go To Reports module
  2. Create Report
  3. set Report Module = "Line Items"
  4. Save
  5. Get Access Error

Context

Reports not visible for Reqular Users

Your Environment

  • SuiteCRM Version used: Version 7.9.7
  • Browser name and version (e.g. Chrome Version 51.0.2704.63 (64-bit)): Version 62.0.3202.75 (Official Build) (64-bit)
  • Environment name and version (e.g. MySQL, PHP 7): MySQL: 5.5.56-2.el7, php: 5.4.16-42.el7
  • Operating System and version (e.g Ubuntu 16.04): ‪CentOS Linux 7.4.1708 (Core)‬
  • Reproducable on https://demo.suiteondemand.com
Originally created by @artjomsmorscakovs on GitHub (Nov 6, 2017). #### Issue Two users: Admin, Regular User No Roles or Security Groups created Case #1 Admin creates Report with Report Module equal to "Line Items" Case #2 Regular User created Report with Report Module equal to "Line Items" #### Expected Behavior Both cases can create and view and edit #### Actual Behavior Case #1 Report created and viewable by Admin, Regular User not able to view it (It sees the record but link doesn`t show, If you try to go to a detailed view using url and Id, then you get error: "You do not have access to this area. Contact your site administrator to obtain access. Redirect to Home in 3 seconds Case #2 After pushing save button you get message "You do not have access to this area. Contact your site administrator to obtain access. Redirect to Home in 3 seconds #### Possible Fix I was able to fix this by creating records for "Line Items" module in acl_actions table INSERT INTO `acl_actions` (`id`, `date_entered`, `date_modified`, `modified_user_id`, `created_by`, `name`, `category`, `acltype`, `aclaccess`, `deleted`) VALUES ('3b51b254-5b6c-b2db-abc2-582e8ac2f265', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'access', 'AOS_Products_Quotes', 'module', '89', '0'), ('3d6a812a-41b2-c9a5-abc7-582e8a5c8f34', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'delete', 'AOS_Products_Quotes', 'module', '90', '0'), ('3ce4825f-da3e-d3d7-abcf-582e8a4057a6', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'edit', 'AOS_Products_Quotes', 'module', '90', '0'), ('3e76e190-8ca9-f4fe-abc6-582e8ac8c2ec', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'export', 'AOS_Products_Quotes', 'module', '90', '0'), ('3dedb06c-23f1-a963-abc3-582e8a48db52', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'import', 'AOS_Products_Quotes', 'module', '90', '0'), ('3c648899-74c9-673a-abc3-582e8af5b317', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'list', 'AOS_Products_Quotes', 'module', '90', '0'), ('3f002d14-060b-28f0-6bd5-abce8ab1ec1f', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'massupdate', 'AOS_Products_Quotes', 'module', '90', '0'), ('3be1b70f-2f88-a396-030d-abce8a2de8b7', '2016-11-18 05:00:25', '2016-11-18 05:00:25', '1', '', 'view', 'AOS_Products_Quotes', 'module', '90', '0'); #### Steps to Reproduce 1. Go To Reports module 2. Create Report 3. set Report Module = "Line Items" 4. Save 5. Get Access Error #### Context Reports not visible for Reqular Users #### Your Environment <!--- Include as many relevant details about the environment you experienced the bug in --> * SuiteCRM Version used: Version 7.9.7 * Browser name and version (e.g. Chrome Version 51.0.2704.63 (64-bit)): Version 62.0.3202.75 (Official Build) (64-bit) * Environment name and version (e.g. MySQL, PHP 7): MySQL: 5.5.56-2.el7, php: 5.4.16-42.el7 * Operating System and version (e.g Ubuntu 16.04): ‪CentOS Linux 7.4.1708 (Core)‬ * Reproducable on https://demo.suiteondemand.com
Author
Owner

@iteschke commented on GitHub (Dec 29, 2017):

I have a problem in reporting module which is very similar:

Issue

Regular user cannot create a report with a condition which bases on a line item which is linked from another module. Corresponding reports which were created by an admin cannot be executed by a regular user.

Expected Behavior

Regular user can select fields from line items as a condition.

Actual Behavior

The field of line items will not appear for selection when defining a condition.

Steps to Reproduce

  1. Logon as a regular user
  2. Create Report
  3. set Report Module = "Quotes"
  4. Define Conditions
  5. Selection line_items (LBL_AOS_PRODUCT_QUOTES)
  6. Selection line items
  7. No fields of line items are offered for selection.

Environment

  • SuiteCRM Version used: Version 7.8.8
  • Browser Name and Version: Firefox ESR 52.5.3
  • Language package: German

Thanks,
Ingo

@iteschke commented on GitHub (Dec 29, 2017): I have a problem in reporting module which is very similar: **Issue** Regular user cannot create a report with a condition which bases on a line item which is linked from another module. Corresponding reports which were created by an admin cannot be executed by a regular user. **Expected Behavior** Regular user can select fields from line items as a condition. **Actual Behavior** The field of line items will not appear for selection when defining a condition. **Steps to Reproduce** 1. Logon as a regular user 2. Create Report 3. set Report Module = "Quotes" 4. Define Conditions 5. Selection line_items (LBL_AOS_PRODUCT_QUOTES) 6. Selection line items 7. No fields of line items are offered for selection. **Environment** - SuiteCRM Version used: Version 7.8.8 - Browser Name and Version: Firefox ESR 52.5.3 - Language package: German Thanks, Ingo
Author
Owner

@PedroErnst commented on GitHub (Feb 7, 2018):

Thanks @artjomsmorscakovs and @iteschke

I've been looking into this and I think the underlying problem is that there is no permissions for line items per se, in this case the system should look at the permission for Quotes for the user, and if the user has access to Quotes he should be able to see Line Items Reports.

@PedroErnst commented on GitHub (Feb 7, 2018): Thanks @artjomsmorscakovs and @iteschke I've been looking into this and I think the underlying problem is that there is no permissions for line items per se, in this case the system should look at the permission for Quotes for the user, and if the user has access to Quotes he should be able to see Line Items Reports.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/SuiteCRM-SuiteCRM#2453
No description provided.