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

[4.4] Set permission for add-module-to-dashboard button #42467

Merged
merged 8 commits into from
Jun 27, 2024

Conversation

chmst
Copy link
Contributor

@chmst chmst commented Dec 5, 2023

Pull Request for Issue #41624 .

PR #37268 set wrong permission for the "Add module to dahboard" Button on cpanel.
This was caused because a user had a special use case - descibed in #37267

Summary of Changes

This PR sets the permission back to core.manage on com_modules.

Therefore the issue #37267 is unresolved again.
This special use case needs an other solution. Maybe an override of cpanel.

Testing Instructions

You need a user in usergroup manager. Login as manager - you see the button "Add Module to the dashboard".
Activate.
An Error message is displayed.

Apply the patch - no button for usergroup "manager".

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

@brianteeman
Copy link
Contributor

Could you explain what the problem is as it is not clear from your post

@chmst
Copy link
Contributor Author

chmst commented Dec 5, 2023

Users in group "manager"" are not allowed to work on com_modules. log in as manager and the Menu (content) is:
grafik

If the user now activates the button and has not the permission, it gives an error.
grafik

grafik

@chmst
Copy link
Contributor Author

chmst commented Apr 9, 2024

Therefore the issue #37267 is unresolved again.

resolved now also for this case.

@carlitorweb
Copy link
Member

I have tested this item ✅ successfully on 2eef018


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42467.

@carlitorweb
Copy link
Member

In the case of #37267 will still work fine and no need any change after apply this PR

@carlitorweb
Copy link
Member

@chmst delete from summary at least this part: "This PR sets the permission back to core.manage on com_modules."

@HLeithner HLeithner added the bug label Apr 24, 2024
@Sieger66
Copy link
Contributor

Sieger66 commented May 1, 2024

I have tested this item 🔴 unsuccessfully on 2eef018

With this PR at this point all users in the usergroup "Administrator"
see not the "Add Module to the dashboard" button.

No button for usergroup "Administrator" only for "Super Users".

Alternative i have test it with:
<?php if (($user->authorise('core.admin', 'com_modules')) and ($user->authorise('core.create', 'com_modules'))) : ?>
This works for me as aspected.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42467.

@Sieger66
Copy link
Contributor

Sieger66 commented May 12, 2024

I have tested this item ✅ successfully on 39a1c85

Works as aspected.

@chmst delete from summary at least this part: "This PR sets the permission back to core.manage on com_modules."

or alternatively change it to: This PR sets the permission back to core.manage on com_modules.

@carlitorweb : Now we need a second test.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42467.

@viocassel
Copy link
Contributor

I have tested this item ✅ successfully on 39a1c85


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42467.

@richard67
Copy link
Member

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42467.

@joomla-cms-bot joomla-cms-bot added the RTC This Pull Request is Ready To Commit label May 26, 2024
@pe7er pe7er assigned pe7er and unassigned pe7er May 26, 2024
@MacJoom MacJoom self-assigned this Jun 26, 2024
@MacJoom MacJoom added this to the Joomla! 4.4.6 milestone Jun 27, 2024
@MacJoom MacJoom merged commit 2b458a3 into joomla:4.4-dev Jun 27, 2024
3 of 4 checks passed
@MacJoom
Copy link
Contributor

MacJoom commented Jun 27, 2024

Thank you!

@joomla-cms-bot joomla-cms-bot removed the RTC This Pull Request is Ready To Commit label Jun 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet