Comments

adriancid created an issue. See original summary.

neslee canil pinto’s picture

@adriancid, we need to have configuration form for this?
In which we have to have a checkbox , on click of it we will disable "Manage" for non-admin roles.

adriancid’s picture

@Neslee Canil Pinto I think the idea here is to have new permission, I don't remember the issue where we talked about this and I see now I forgot to link it. I will see if I can find it.

adriancid’s picture

neslee canil pinto’s picture

Is this as been already fixed?

rokzabukovec’s picture

Status: Active » Needs review
StatusFileSize
new3.64 KB

I created the patch that adds a 'Use Admin Toolbar manage' permission and hides the 'Manage' menu tab based on that permission. I also added some tests that check the presence of that menu element.
My patch does not prevent the user to go to the URLs from the menu, because the issue does not state that this is necessary. It just hides the menu navigation. If any modifications are required let me know.
Best regards

Status: Needs review » Needs work

The last submitted patch, 6: 3117860-6.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

rokzabukovec’s picture

Status: Needs work » Needs review
StatusFileSize
new6.16 KB
new7.7 KB

I fixed the test errors and some coding standards. See the interdiff for changes.
@adriancid can you review it?
Best regards

romainj’s picture

I think that as the Manage menu item is defined by the core Toolbar module this issue should not be related to the Admin Toolbar module.

romainj’s picture

Project: Admin Toolbar » Drupal core
Version: 8.x-2.x-dev » 8.9.x-dev
Component: User interface » toolbar.module
tripurari’s picture

Reviewing and will update the status shortly.

tripurari’s picture

I agree with @romainj, permission is already added for toolbar to handle for non-admin-user. It shows Manage if allowed permission to non-admin-user.I think if we allow only toolbar permission to a user, in that case Manage menu should be hidden. In case of adding more permission to non-admin-user like add manage some admin level menu, manage should be visible.

vikashsoni’s picture

StatusFileSize
new76.78 KB
new76.01 KB

#8, #6 Patch is not working sharing screenshot

manojithape’s picture

Assigned: Unassigned » manojithape
manojithape’s picture

Assigned: manojithape » Unassigned
chetanbharambe’s picture

Status: Needs review » Needs work
StatusFileSize
new605.44 KB

Verified and tested patch #8 but it's not applied successfully.
Not working as expected.

Please check the attached screenshot.
Moving to Needs Work.

richa_porwal’s picture

Assigned: Unassigned » richa_porwal
richa_porwal’s picture

StatusFileSize
new993 bytes

Hi Team,

I have created patch for the above problem motivation. Need review.

richa_porwal’s picture

richa_porwal’s picture

StatusFileSize
new965 bytes

Hi Team,

Please use the latest created patch. Need Review

richa_porwal’s picture

Assigned: richa_porwal » Unassigned
Status: Needs work » Needs review
manojithape’s picture

Assigned: Unassigned » manojithape
manojithape’s picture

Assigned: manojithape » Unassigned

Not able to reproduce this issue.

ambuj_gupta’s picture

Assigned: Unassigned » ambuj_gupta
ambuj_gupta’s picture

StatusFileSize
new34.97 KB
new37.28 KB

Testing Steps:
1. Install Drupal 8.9.x
2. log in as an admin.
3. Go to "/admin/people/permissions"
4. And Enable toolbar for Non-Admin Roles.
5. Now create an account with a non-admin role
6. And login with that user.
7. And verify the toolbar.
8. Manage option is coming in the toolbar for non-admin users.(issue Replicate)
9. Now apply patch #20.
10. Verify the toolbar (Issue fixed)

Testing Results:
After applying the patch successfully. The Manage option is hidden from the toolbar for the non-admin user

Note:
When the patch is applied successfully, new permission(Use toolbar manage tab) is added into the toolbar option at "/admin/people/permissions". Using which admin is able to show/hide the manage tab for non-admin users.

ambuj_gupta’s picture

Assigned: ambuj_gupta » Unassigned
Status: Needs review » Reviewed & tested by the community
quietone’s picture

Status: Reviewed & tested by the community » Needs work
Issue tags: +Needs issue summary update

This needs an issue summary update, see Write an issue summary for an existing issue for guidance.

chetanbharambe’s picture

Issue summary: View changes
chetanbharambe’s picture

Issue summary: View changes
Status: Needs work » Needs review
StatusFileSize
new303.68 KB
new158.15 KB
new151.86 KB

Verified and tested patch #20.
Patch applied successfully and looks good to me.

Testing Steps:
# log in as an admin.
# Goto:- /admin/people/permissions
# And Enable toolbar for Non-Admin Roles.
# Now create an account with a non-admin role
# And login with that user.
# And verify the toolbar.
# Manage option is coming in the toolbar for non-admin users.
# Verify the toolbar

Expected Results:
# Menu item ‘Manage’ should be removed for non-admin roles.

Actual Results:
# Currently Menu item 'Manage' is visible for non-admin roles.

Looks good to me.
Can be a move to +1RTBC.

gauravvvv’s picture

StatusFileSize
new981 bytes
new768 bytes

Fixed MARKED SNIFF VIOLATIONS, for patch #20, Attached interdiff for same.
please review.

avpaderno’s picture

Version: 8.9.x-dev » 9.2.x-dev

Drupal 8.9.x is now open only to security issues.

Version: 9.2.x-dev » 9.3.x-dev

Drupal 9.1.10 (June 4, 2021) and Drupal 9.2.10 (November 24, 2021) were the last bugfix releases of those minor version series. Drupal 9 bug reports should be targeted for the 9.3.x-dev branch from now on, and new development or disruptive changes should be targeted for the 9.4.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

dww’s picture

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.15 was released on June 1st, 2022 and is the final full bugfix release for the Drupal 9.3.x series. Drupal 9.3.x will not receive any further development aside from security fixes. Drupal 9 bug reports should be targeted for the 9.4.x-dev branch from now on, and new development or disruptive changes should be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

igork96’s picture

Status: Needs review » Reviewed & tested by the community

I tested this and can confirm that patch from #30 is working with the Drupal 9.4.x version

catch’s picture

Status: Reviewed & tested by the community » Needs work

#30 doesn't pass tests and we still need an answer to #33.

igork96’s picture

@catch I checked the issue, and yes I think it is a duplicate. There the best suggestion is to add a new permission for this to access administration pages, with an update function that grants that permission to all roles that are allowed to use the toolbar but don't have the administration pages permission. Maybe we should close this ticket and move further work there ?

akram khan’s picture

StatusFileSize
new957 bytes

updating patch against 9.4.x

akram khan’s picture

StatusFileSize
new950 bytes

Fixing Custom Command failed

prem suthar’s picture

#39 Working Fine For me I tested the patch it updated the Permission Form "Use the toolbar "To "Use toolbar manage tab" in toolbar manage.
As mentioned in #37 Please Add new permission for this to access administration pages.

prem suthar’s picture

StatusFileSize
new31.9 KB
new26.45 KB

Add the screenshot For Refernace.

quietone’s picture

@Akram Khan, @Prem Suthar, thank you for your interest in improving Drupal. The comment in #37 suggests that this is a duplicate. That means the next task here is to read this issue and the other one (See #33) to confirm that. Adding patches or screenshots after that comment aren't helping to resolve the issue. You can use the contributor tasks on Drupal.org that provide the steps for making useful additions to an issue. Credit has been removed per How is credit granted for Drupal core issues.

Version: 9.4.x-dev » 9.5.x-dev

Drupal 9.4.9 was released on December 7, 2022 and is the final full bugfix release for the Drupal 9.4.x series. Drupal 9.4.x will not receive any further development aside from security fixes. Drupal 9 bug reports should be targeted for the 9.5.x-dev branch from now on, and new development or disruptive changes should be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.5.x-dev » 11.x-dev

Drupal core is moving towards using a “main” branch. As an interim step, a new 11.x branch has been opened, as Drupal.org infrastructure cannot currently fully support a branch named main. New developments and disruptive changes should now be targeted for the 11.x branch. For more information, see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.

quietone’s picture

Status: Needs work » Postponed

The Toolbar Module was approved for removal in #3476882: [Policy] Move Toolbar module to contrib.

This is Postponed. The status is set according to two policies. The Remove a core extension and move it to a contributed project and the Extensions approved for removal policies.

The deprecation work is in #3484850: [meta] Tasks to deprecate Toolbar module and the removal work in #3488828: [meta] Tasks to remove Toolbar module.

Toolbar will be moved to a contributed project before Drupal 12.0.0 is released.