-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[5.2] Delete user access level - check for levels in use #43223
Conversation
I have tested this item ✅ successfully on e449b22 Just one tiny correction, the message after Patch is correct unlike the photo: (photo) View Access Levels removed ---> (site) No View Access Levels removed. This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
In this case I wanted to delete 3 levels. One of them was deleted. Two of them could not be deleted, they are still in use. This is a bit confusing on the screen |
Ah ok. In my case, I tried to delete just 1 level. |
Co-authored-by: Brian Teeman <[email protected]>
Co-authored-by: Brian Teeman <[email protected]>
I have tested this item ✅ successfully on 615eb4e This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. I created 3 access levels, assigned 3 different articles (one to each) and then tried deleting the 3 levels. The message was the same for all three levels. |
I have tested this item ✅ successfully on 615eb4e This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
I have tested this item ✅ successfully on 615eb4e This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
rtc This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
This pull request has been automatically rebased to 5.2-dev. |
Thanks for this PR @chmst |
I have tested this item ✅ successfully on f8ee84c This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
3 similar comments
I have tested this item ✅ successfully on f8ee84c This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
I have tested this item ✅ successfully on f8ee84c This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
I have tested this item ✅ successfully on f8ee84c This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43223. |
Thanks @chmst ! |
joomla/joomla-cms#43232 + joomla/joomla-cms#43378 + joomla/joomla-cms#43216 + joomla/joomla-cms#43260 + joomla/joomla-cms#43386 + joomla/joomla-cms#43575 + joomla/joomla-cms#43491 + joomla/joomla-cms#43760 - (upmerge, внесено в 5.1х) joomla/joomla-cms#43247 + joomla/joomla-cms#43579 + joomla/joomla-cms#43690 + joomla/joomla-cms#43829 + joomla/joomla-cms#43840 + joomla/joomla-cms#43841 + joomla/joomla-cms#43885 - (upmerge, только для др. пакетов) joomla/joomla-cms#43223 + joomla/joomla-cms#43810 - (только для en-GB) joomla/joomla-cms#43898 + joomla/joomla-cms#43432 + joomla/joomla-cms#43870 + joomla/joomla-cms#42850 + joomla/joomla-cms#43937 - (upmerge, только для др. пакетов) joomla/joomla-cms#43862 + joomla/joomla-cms#43975 + joomla/joomla-cms#43910 + joomla/joomla-cms#43965 + joomla/joomla-cms#43738 + joomla/joomla-cms#43814 + joomla/joomla-cms#44000 + joomla/joomla-cms#44050 + (upmerge, с 4.4.9) joomla/joomla-cms#43966 + joomla/joomla-cms#44065 +
Pull Request replacing #39654
Summary of Changes
An access level can only be deleted if there is no content which uses this level. But there is no information given, which tabels are concerned.
This PR adds the list of tables to the error message. It adds the delete method to the model and makes a check for all leves on all tables.
Testing Instructions
Add one or more access levels.
Set this access level for some items in your content, an article, a contact, a module .. whatever.
Then try to delete this access level.
Actual result BEFORE applying this Pull Request
You get a message
"You can't delete the view access level '%d:%s' because it is being used by content."
Expected result AFTER applying this Pull Request
Information is diplayed for all levels, where they are used.
This enables the experienced user to find the components and filter there for these levels.
Only leves are deleted (in my test above it was one (1) which are not in use.
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