inveniosoftware / invenio-rdm-records

DataCite-based data model for InvenioRDM flavour.
https://invenio-rdm-records.readthedocs.io
MIT License
15 stars 87 forks source link

permissions: records always in community feature #1719

Open Samk13 opened 5 months ago

Samk13 commented 5 months ago

:heart: Thank you for your contribution!

Description

Closes inveniosoftware/product-rdm#183

This PR adds an option to prevent deleting all communities in a record except for the last one, as our org requires at least one community per record. This feature is off by default and can be activated in your instance by adding:

RDM_ENSURE_RECORD_COMMUNITY_EXISTS = True

Then you will still be able to remove communities, but not the last one. modal-err-msg-fix

This PR is connected to this package we create, it prevents submitting any record without selecting a community from the API level. and prevents users from creating communities unless they have certain privileges that we set for the theme programmatically. Future plans are to implement this as well with the master branch.

Checklist

Ticks in all boxes and 🟢 on all GitHub actions status checks are required to merge:

Third-party code

If you've added third-party code (copy/pasted or new dependencies), please reach out to an architect.

Reminder

By using GitHub, you have already agreed to the GitHub’s Terms of Service including that:

  1. You license your contribution under the same terms as the current repository’s license.
  2. You agree that you have the right to license your contribution under the current repository’s license.
Samk13 commented 5 months ago

Opened this PR as a continuation of the previously closed PR #1283

github-actions[bot] commented 3 months ago

This PR was automatically marked as stale.

github-actions[bot] commented 1 month ago

This PR was automatically marked as stale.