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

UISER-153: Support edit for publication patterns #114

Merged
merged 9 commits into from
Oct 17, 2024
Merged

Conversation

Jack-Golding
Copy link
Contributor

Purpose:
To support an edit option for publication patterns that have not yet been used to generate predicted pieces. If there are any predicted piece sets linked to a publication pattern it will not be possible to edit the pattern (although an active pattern can be deprecated by making a new active pattern as currently)

Added ruleset edit endpoint
Added predicted piece set delete endpoint to module descriptor, along with associated permissions
Updated Todos and changes after futher discussion
Added replaceAndDelete and replaceAndDeprecate endpoints and placeholder methods
Added replaceAndDelete and replaceAndDeprecate functions to the serial ruleset controller class
Added new permissions to endpoints following the standard used by the ruleset set status endpoints
@Jack-Golding Jack-Golding marked this pull request as ready for review October 14, 2024 08:54
@folio-org folio-org deleted a comment from github-actions bot Oct 14, 2024
@Jack-Golding
Copy link
Contributor Author

Jack-Golding commented Oct 16, 2024

Notes from call:

  • Dont allow setting ruleset to draft once its been used

  • Move this code block to a generalised private method

if(ruleset?.rulesetStatus?.value == 'active'){
        String activeRulesetId = serialRulesetService.findActive(ruleset?.owner?.id)
        if(activeRulesetId){
          serialRulesetService.updateRulesetStatus(activeRulesetId, 'deprecated')
        }
      }

Moved logic for checking active ruleset to private method within controller
@Jack-Golding Jack-Golding merged commit e28100a into master Oct 17, 2024
5 checks passed
@Jack-Golding Jack-Golding deleted the feat/uiser-153 branch October 17, 2024 22:13
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