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

Added code to hide publish button for user without tagmanager_use_custom_templates capability #785

Merged
merged 10 commits into from May 8, 2024

Conversation

AltamashShaikh
Copy link
Contributor

Description:

Added code to hide publish button for user without tagmanager_use_custom_templates capability
Fixes: #PG-3450, #784

Review

Copy link
Contributor

@snake14 snake14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. I confirmed that the ability to publish new versions was hidden and displayed based on the user permissions as expected 👍

@snake14
Copy link
Contributor

snake14 commented May 1, 2024

@araichyk If this PR looks alright to you, I can go ahead and merge it.

Copy link

@araichyk araichyk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't seem to reproduce the original issue for whatever reason. This change is hiding/unhiding the Publish button for me based on access level though.

Do we also want to remove the Publish link from this alert on TagEdit, TriggerEdit, and VariableEdit?
image

@AltamashShaikh
Copy link
Contributor Author

Can't seem to reproduce the original issue for whatever reason. This change is hiding/unhiding the Publish button for me based on access level though.

Do we also want to remove the Publish link from this alert on TagEdit, TriggerEdit, and VariableEdit? image

@araichyk Good point, will remove the link too 👍

API.php Show resolved Hide resolved
@snake14
Copy link
Contributor

snake14 commented May 6, 2024

Aside from the broken UI test cases, the changes look good to me 👍

@AltamashShaikh
Copy link
Contributor Author

Aside from the broken UI test cases, the changes look good to me 👍

@snake14 UI tests fixed

Copy link
Contributor

@snake14 snake14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Confirmed that the publish link is no longer part of the success message after creating/updating items.

Copy link

@araichyk araichyk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Publish and Versions links are now hidden for my user with the Write access level, but they're still there for Admin or higher access levels. Looks good 👍. Thanks for making those changes!

@AltamashShaikh AltamashShaikh merged commit 2ecc3c2 into 5.x-dev May 8, 2024
4 checks passed
@AltamashShaikh AltamashShaikh deleted the PG-3450-hide-publish branch May 8, 2024 02:27
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

3 participants