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

[fix] check all custom perms before adding permissions from standard docperm #3280

Merged

Conversation

saurabh6790
Copy link
Member

Before

docperm


After

docperm1

@@ -330,7 +330,8 @@ def get_all_perms(role):
'''Returns valid permissions for a given role'''
perms = frappe.get_all('DocPerm', fields='*', filters=dict(role=role))
custom_perms = frappe.get_all('Custom DocPerm', fields='*', filters=dict(role=role))
doctypes_with_custom_perms = list(set(p.parent for p in custom_perms))
all_custom_perms = frappe.get_all('Custom DocPerm', fields='parent')
Copy link
Member

@rmehta rmehta May 12, 2017

Choose a reason for hiding this comment

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

why not select distinct parent from `tabCustom DocPerm ?

@saurabh6790 saurabh6790 force-pushed the role_permission_manager_display_fix branch from f6df8ea to 0c6bb1c Compare May 12, 2017 10:02
@saurabh6790
Copy link
Member Author

saurabh6790 commented May 12, 2017

@rmehta Fixed!!

@rmehta rmehta merged commit eb9551f into frappe:develop May 12, 2017
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 18, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants