Skip to content

[FC-0049] feat: Update permissions to remove object tags - #188

Merged
bradenmacdonald merged 3 commits into
openedx:mainfrom
open-craft:chris/FAL-3720-permissions-to-remove-object-tag
May 8, 2024
Merged

[FC-0049] feat: Update permissions to remove object tags#188
bradenmacdonald merged 3 commits into
openedx:mainfrom
open-craft:chris/FAL-3720-permissions-to-remove-object-tag

Conversation

@ChrisChV

@ChrisChV ChrisChV commented May 7, 2024

Copy link
Copy Markdown
Contributor

Description

This updates rules to add can_remove_object_tag_objectid to Objet tag views

Supporting information

Testing instructions

@openedx-webhooks

Copy link
Copy Markdown

Thanks for the pull request, @ChrisChV! Please note that it may take us up to several weeks or months to complete a review and merge your PR.

Feel free to add as much of the following information to the ticket as you can:

  • supporting documentation
  • Open edX discussion forum threads
  • timeline information ("this must be merged by XX date", and why that is)
  • partner information ("this is a course on edx.org")
  • any other information that can help Product understand the context for the PR

All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here.

Please let us know once your PR is ready for our review and all tests are green.

@openedx-webhooks openedx-webhooks added the open-source-contribution PR author is not from Axim or 2U label May 7, 2024
@ChrisChV ChrisChV changed the title feat: Update permissions to remove object tags [FC-0049] feat: Update permissions to remove object tags May 7, 2024
* chore: Bump version

* fix: Issue with remove object tag permission
Comment thread openedx_tagging/core/tagging/rules.py Outdated

This rule could be defined in other apps for proper permission checking.
"""
return True

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can you move this down below can_change_object_tag_objectid ? Also the default value shouldn't be True - the default value should be the same as can_change_object_tag_objectid, so just call that function and return the same value.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@bradenmacdonald Updated here bf49f69

expected_perm = True
object_id, sort_test_applied_result = self.prepare_for_sort_test(expected_perm)
expoected_remove_perm = False
object_id, sort_test_applied_result = self.prepare_for_sort_test(expoected_remove_perm)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Minor typo: expoected_remove_perm

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Fixed: 0df63a1

@bradenmacdonald
bradenmacdonald merged commit 0f8cf60 into openedx:main May 8, 2024
@openedx-webhooks

Copy link
Copy Markdown

@ChrisChV 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future.

@bradenmacdonald
bradenmacdonald deleted the chris/FAL-3720-permissions-to-remove-object-tag branch May 8, 2024 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

open-source-contribution PR author is not from Axim or 2U

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants