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

feat(import) : Filter destinations based on a user's permissions #3211

Open
wants to merge 1 commit into
base: feat/import
Choose a base branch
from

Conversation

jacquesfize
Copy link
Contributor

This PR propose to alter the /destinations/ route by taking in a account a user's permissions.

  • a method filter_by_permissions was added to the Destination class
  • the latter is called in list_destinations()

@jacquesfize jacquesfize requested review from bouttier and Pierre-Narcisi and removed request for bouttier October 1, 2024 15:12
@jacquesfize jacquesfize self-assigned this Oct 1, 2024
@jacquesfize jacquesfize added this to the 2.15 milestone Oct 1, 2024
@jacquesfize jacquesfize changed the title feat(import) : Filter Destination based on a user's permissions feat(import) : Filter destinations based on a user's permissions Oct 1, 2024
Copy link

codecov bot commented Oct 1, 2024

Codecov Report

Attention: Patch coverage is 55.55556% with 4 lines in your changes missing coverage. Please review.

Project coverage is 83.49%. Comparing base (523f48d) to head (e70453d).

Files with missing lines Patch % Lines
backend/geonature/core/imports/models.py 57.14% 3 Missing ⚠️
backend/geonature/core/imports/routes/__init__.py 50.00% 1 Missing ⚠️
Additional details and impacted files
@@               Coverage Diff               @@
##           feat/import    #3211      +/-   ##
===============================================
- Coverage        83.51%   83.49%   -0.02%     
===============================================
  Files              121      121              
  Lines             9543     9551       +8     
===============================================
+ Hits              7970     7975       +5     
- Misses            1573     1576       +3     
Flag Coverage Δ
pytest 83.49% <55.55%> (-0.02%) ⬇️

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant