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: apply perms on letter head selection #26563

Merged
merged 2 commits into from
May 27, 2024

Conversation

barredterra
Copy link
Collaborator

@barredterra barredterra commented May 24, 2024

By default, all desk users have read access on all Letter Heads. However, this can be further restricted by custom Role- and User Permissions. The print settings dialog and the Letter Head list in frappe.boot.letter_heads didn't respect these permissions.

Fixes:

  • Use a "Link" field for the selection of Letter Head -> the standard way, which respects user permissions.
  • Use get_list for constructing frappe.boot.letter_heads.

@github-actions github-actions bot added the add-test-cases Add test case to validate fix or enhancement label May 24, 2024
@barredterra barredterra changed the title letter head link fix: select letter head when printing report May 24, 2024
@barredterra barredterra added backport version-14-hotfix backport to version 14 backport version-15-hotfix Backport the PR to v15 and removed add-test-cases Add test case to validate fix or enhancement labels May 24, 2024
@barredterra barredterra changed the title fix: select letter head when printing report fix: apply perms on letter head selection May 24, 2024
@barredterra barredterra merged commit d5f3bb5 into frappe:develop May 27, 2024
25 checks passed
@barredterra barredterra deleted the letter-head-link branch May 27, 2024 15:23
ankush pushed a commit that referenced this pull request Jun 4, 2024
* fix: use link field for letter head

(cherry picked from commit 223ad14)

* fix: apply user permissions on letter head

(cherry picked from commit bb7e1eb)

---------

Co-authored-by: barredterra <14891507+barredterra@users.noreply.github.com>
ankush pushed a commit that referenced this pull request Jun 5, 2024
* fix: use link field for letter head

(cherry picked from commit 223ad14)

* fix: apply user permissions on letter head

(cherry picked from commit bb7e1eb)

---------

Co-authored-by: barredterra <14891507+barredterra@users.noreply.github.com>
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport version-14-hotfix backport to version 14 backport version-15-hotfix Backport the PR to v15
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant