magento / inventory

Magento Inventory Project (a.k.a MSI)
Open Software License 3.0
336 stars 248 forks source link

User Role with Limited Resource Permissions Cannot Access Shipping Methods Config Section #3298

Open mam08ixo opened 3 years ago

mam08ixo commented 3 years ago

Preconditions

Any M2 version with magento/module-inventory-in-store-pickup-shipping-admin-ui installed

Steps to Reproduce

  1. In admin panel, create a new user role.
  2. Set Resource Access: Custom.
  3. Grant the Stores → Settings → Configuration → Shipping Methods Section permission.
  4. Create a new user, assign to the new role.
  5. Log in with the new user, navigate to store configuration.

Expected Result

The user with the Shipping Methods Section permission can access the Shipping Methods configuration.

Actual Result

The user with the Shipping Methods Section permission cannot access the Shipping Methods configuration.

Cause

The Magento_InventoryInStorePickupShippingAdminUi module changes the config section's resource, label, and properties.

https://github.com/magento/inventory/blob/e59e2f48b0176514cbb566ae647df0ec609331b6/InventoryInStorePickupShippingAdminUi/etc/adminhtml/system.xml#L10-L12

A module must not change the properties of a config section introduced by another (core) module, in this case Magento_Shipping.

Workaround

Grant the Stores → Inventory → In-Store Pickup permission or uninstall MSI.

m2-assistant[bot] commented 3 years ago

Hi @mam08ixo. Thank you for your report. To help us process this issue please make sure that you provided sufficient information.

Please, add a comment to assign the issue: @magento I am working on this


alexiscl02 commented 3 years ago

@mam08ixo

Thank you for the workaround!