Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Admin role scopes set to custom breaks backend #9337

Closed
sydekumf opened this issue Apr 21, 2017 · 6 comments
Closed

Admin role scopes set to custom breaks backend #9337

sydekumf opened this issue Apr 21, 2017 · 6 comments
Labels
bug report Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed

Comments

@sydekumf
Copy link

sydekumf commented Apr 21, 2017

When the admin role scope is set to custom instead to all several things won't work, like saving product attributes, editing CMS content or editing admin users.

Preconditions

  1. Magento CE 2.1.4 fresh installation

Steps to reproduce

  1. Edit an admin user role and switch its role scope to custom
  2. Save the role

Expected result

  1. The role works as configured (on custom scope)

Actual result

  1. The role does not work as configured
  2. You won't see the roles nor the admin users anylonger
  3. If you open a product attribute in the backend, the save button is missing
  4. If you want to edit a cms page the following mysql error appears:
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'store.store_id' in 'where clause', query was: SELECT `main_table`.*, `page_table`.`title` AS `page_title`, `page_table`.`identifier` AS `page_identifier`, IF(clone.node_id IS NULL, 0, 1) AS `page_exists`, IF(main_table.page_id = '2', 1, 0) AS `current_page`, (SELECT GROUP_CONCAT(stor
e_id SEPARATOR ',') AS `store_id` FROM `cms_page_store` AS `store` WHERE (store.row_id = main_table.page_id)) AS `page_in_stores` FROM `magento_versionscms_hierarchy_node` AS `main_table`
 LEFT JOIN `cms_page` AS `page_table` ON main_table.page_id = page_table.page_id AND (page_table.created_in <= 1 AND page_table.updated_in > 1)
 LEFT JOIN `magento_versionscms_hierarchy_node` AS `clone` ON main_table.node_id = clone.parent_node_id AND clone.page_id = '2' WHERE (store.store_id IN (0, '1')) HAVING (main_table.page_id IS NULL OR page_in_stores IS NOT NULL) ORDER BY `main_table`.`level` ASC, `main_table`.`sort_order` ASC
@Stas94
Copy link

Stas94 commented Jun 26, 2017

@sydekumf We cannot reproduce this issue as described. Please provide the detailed steps we must follow to reproduce this issue. In addition, identify the web server you are running, the versions of PHP and MySQL, and any other information needed to reproduce your issue.

@ipascual
Copy link

I'm experiencing the same issue, check attachments. Create an admin role with Role Scope to one store only. Try to add a CMS Page.
screen shot 2017-07-10 at 8 21 18 am
screen shot 2017-07-10 at 8 20 33 am

@Stas94
Copy link

Stas94 commented Jul 10, 2017

@iainhubbard @sydekumf Thanks for reporting this issue. If this issue is actual for Enterprise Edition only, please address it to Magento Support.

@sydekumf
Copy link
Author

I do not know if this is an Enterprise bug only :-) That's why we are reporting it. You can handle it the way you want to handle bugs. I am just reporting what I see :-)

@philippsander
Copy link
Member

philippsander commented Jul 28, 2017

I there any way to set the role scopes back to "all"?

ANSWER: I manipulated the DB:

Table: authorization_role
Fields:

gws_is_all (1 is "all")
I also suggest setting "gws_websites = null" and "gws_store_groups = null" where gws_is_all = 1

@magento-engcom-team magento-engcom-team added 2.1.x bug report Progress: needs update Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed and removed G1 Passed labels Sep 5, 2017
@magento-engcom-team magento-engcom-team added Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Magento Commerce and removed Progress: needs update labels Sep 18, 2017
@magento-engcom-team
Copy link
Contributor

@sydekumf thank you for your report. Please follow these guidelines for proper tracking of your issue. You can report Commerce-related issues in one of two ways:
You can use the Support portal associated with your account
or
If you are a Partner reporting on behalf of a merchant, use the Partner portal.

GitHub is intended for Magento Open Source users to report on issues related to Open Source only. There are no account management services associated with GitHub.

magento-devops-reposync-svc pushed a commit that referenced this issue Nov 10, 2024
[Support Tier-4 aplapana] 11-05-2024 Regular delivery of bugfixes and improvements
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug report Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed
Projects
None yet
Development

No branches or pull requests

6 participants