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: validate permission on tag creation #22753

Merged
merged 2 commits into from
Oct 16, 2023

Conversation

ruthra-kumar
Copy link
Member

Prevent users from adding tags to doctype they lack access to.

@ruthra-kumar ruthra-kumar requested review from a team and ankush and removed request for a team October 16, 2023 11:24
@github-actions github-actions bot added the add-test-cases Add test case to validate fix or enhancement label Oct 16, 2023
@codecov
Copy link

codecov bot commented Oct 16, 2023

Codecov Report

Merging #22753 (ee92afc) into develop (7474397) will decrease coverage by 0.29%.
Report is 63 commits behind head on develop.
The diff coverage is 50.00%.

❗ Current head ee92afc differs from pull request most recent head b056204. Consider uploading reports for the commit b056204 to get more accurate results

@@             Coverage Diff             @@
##           develop   #22753      +/-   ##
===========================================
- Coverage    62.31%   62.02%   -0.29%     
===========================================
  Files          768      768              
  Lines        73560    75019    +1459     
  Branches      6342     6342              
===========================================
+ Hits         45837    46533     +696     
- Misses       24131    24894     +763     
  Partials      3592     3592              
Flag Coverage Δ
server 66.50% <50.00%> (+0.08%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

@ruthra-kumar ruthra-kumar force-pushed the permission_for_adding_tags branch 3 times, most recently from cacbd67 to 2447a09 Compare October 16, 2023 12:19
Add/remove both are controlled by update
@ankush ankush enabled auto-merge (squash) October 16, 2023 12:34
@ankush ankush added backport version-13-hotfix backport version-14-hotfix backport to version 14 and removed add-test-cases Add test case to validate fix or enhancement labels Oct 16, 2023
@ankush ankush merged commit d06a580 into frappe:develop Oct 16, 2023
21 of 22 checks passed
mergify bot pushed a commit that referenced this pull request Oct 16, 2023
* fix: validation permission on `tag` creation

* refactor: apply checks on all operations

Add/remove both are controlled by update

---------

Co-authored-by: Ankush Menat <ankush@frappe.io>
(cherry picked from commit d06a580)

# Conflicts:
#	frappe/desk/doctype/tag/tag.py
mergify bot pushed a commit that referenced this pull request Oct 16, 2023
* fix: validation permission on `tag` creation

* refactor: apply checks on all operations

Add/remove both are controlled by update

---------

Co-authored-by: Ankush Menat <ankush@frappe.io>
(cherry picked from commit d06a580)
ankush pushed a commit that referenced this pull request Oct 16, 2023
* fix: validation permission on `tag` creation

* refactor: apply checks on all operations

Add/remove both are controlled by update

---------

Co-authored-by: Ankush Menat <ankush@frappe.io>
(cherry picked from commit d06a580)

Co-authored-by: ruthra kumar <ruthra@erpnext.com>
ankush pushed a commit that referenced this pull request Oct 16, 2023
* fix: validation permission on `tag` creation

* refactor: apply checks on all operations

Add/remove both are controlled by update

---------

Co-authored-by: Ankush Menat <ankush@frappe.io>
(cherry picked from commit d06a580)
ankush pushed a commit that referenced this pull request Oct 16, 2023
* fix: validation permission on `tag` creation

* refactor: apply checks on all operations

Add/remove both are controlled by update

---------

Co-authored-by: Ankush Menat <ankush@frappe.io>
(cherry picked from commit d06a580)

Co-authored-by: ruthra kumar <ruthra@erpnext.com>
@ruthra-kumar ruthra-kumar changed the title fix: validation permission on tag creation fix: validate permission on tag creation Oct 16, 2023
frappe-pr-bot pushed a commit that referenced this pull request Oct 17, 2023
## [13.58.13](v13.58.12...v13.58.13) (2023-10-17)

### Bug Fixes

* Apply address all perm only if owner ([f6105df](f6105df))
* avoid double translation (backport [#22578](#22578)) ([2c267ea](2c267ea))
* improved validation for address and contact (backport [#22574](#22574)) ([45c5756](45c5756))
* strip html and show text ([#22656](#22656)) ([#22676](#22676)) ([d371d59](d371d59))
* validation permission on `tag` creation ([#22753](#22753)) ([#22754](#22754)) ([6247aa0](6247aa0))
frappe-pr-bot pushed a commit that referenced this pull request Oct 17, 2023
## [14.52.1](v14.52.0...v14.52.1) (2023-10-17)

### Bug Fixes

* Don't mutate `df` object in frappe.format ([589e26d](589e26d))
* duplicate column in report conflict ([219b18e](219b18e))
* email from 'Table Multiselect' field  ([#22733](#22733)) ([#22740](#22740)) ([b30826d](b30826d))
* enable server script while testing ([313cf7a](313cf7a))
* fixed the conflict between fieldname in General Ledger Report ([9c87707](9c87707))
* sync doctype layout on update standard field ([#22699](#22699)) ([#22742](#22742)) ([fa2a88e](fa2a88e))
* Use same filter in report view and list view ([196a71e](196a71e))
* **UX:** Add 'Due Date' to Quick Entry Form, default to Today. ([d973f83](d973f83))
* validation permission on `tag` creation ([#22753](#22753)) ([#22755](#22755)) ([cdc16ab](cdc16ab))
* work-around to fix issue with syncing Google Contacts ([#22649](#22649)) ([#22743](#22743)) ([4430798](4430798)), closes [#22648](#22648)
* works for multiple rows now after saving ([be31d56](be31d56))
* workspace don't strip filter info on save. ([c2c2db8](c2c2db8))
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 31, 2023
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
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants