flagsmith icon indicating copy to clipboard operation
flagsmith copied to clipboard

feat: edit versioned change request

Open kyle-ssg opened this issue 2 weeks ago • 2 comments

Thanks for submitting a PR! Please check the boxes below:

  • [ ] I have added information to docs/ if required so people know about the feature!
  • [x] I have filled in the "Changes" section below?
  • [x] I have filled in the "How did you test this code" section below?
  • [x] I have used a Conventional Commit title for this Pull Request

Changes

Allows editing a versioned change request

  • Opens up the edit feature modal with the changesets applied
  • Corresponding changes are then converted back to changesets and updated with the change request

How did you test

https://github.com/user-attachments/assets/cbbda60a-903c-49bf-80a9-c00a23309377

this code?

Edit a change request in a versioned environment

kyle-ssg avatar Dec 03 '25 19:12 kyle-ssg

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
flagsmith-frontend-preview Ready Ready Preview, Comment Dec 16, 2025 1:34pm
flagsmith-frontend-staging Ready Ready Preview, Comment Dec 16, 2025 1:34pm
1 Skipped Deployment
Project Deployment Review Updated (UTC)
docs Ignored Ignored Preview Dec 16, 2025 1:34pm

vercel[bot] avatar Dec 03 '25 19:12 vercel[bot]

Docker builds report

Image Build Status Security report
ghcr.io/flagsmith/flagsmith-api-test:pr-6368 Finished :white_check_mark: Skipped
ghcr.io/flagsmith/flagsmith-e2e:pr-6368 Finished :white_check_mark: Skipped
ghcr.io/flagsmith/flagsmith-api:pr-6368 Finished :white_check_mark: Results :white_check_mark:
ghcr.io/flagsmith/flagsmith:pr-6368 Finished :white_check_mark: Results :white_check_mark:
ghcr.io/flagsmith/flagsmith-private-cloud:pr-6368 Finished :white_check_mark: Results :white_check_mark:
ghcr.io/flagsmith/flagsmith-frontend:pr-6368 Finished :white_check_mark: Results :white_check_mark:

github-actions[bot] avatar Dec 03 '25 19:12 github-actions[bot]

My understanding of the requirements, written in test scenarios. @kyle-ssg is this your understanding of the behaviour? Anything else that we should be testing?

Non-scheduled CRs

  1. User can edit unpublished CRs they created
  2. User cannot edit unpublished CRs created by another user
  3. User cannot edit published CRs

Scheduled CRs

  1. User can edit unpublished scheduled CRs that they created
  2. User cannot edit unpublished scheduled CRs created by another user
  3. User cannot edit published scheduled CRs

matthewelwell avatar Dec 15 '25 11:12 matthewelwell

My understanding of the requirements, written in test scenarios. @kyle-ssg is this your understanding of the behaviour? Anything else that we should be testing?

@matthewelwell The exception to that at the moment is anyone can edit a change request if they have the ability to create one. I can see a use case for this tbh, if someone is away we should let someone with appropriate permissions to do this.

kyle-ssg avatar Dec 16 '25 08:12 kyle-ssg

@matthewelwell The exception to that at the moment is anyone can edit a change request if they have the ability to create one. I can see a use case for this tbh, if someone is away we should let someone with appropriate permissions to do this.

My concern with that is that we don't have any indication when a change request has been edited. If we're not going to add that (which is probably the correct approach for now), I would rather restrict it to the author, or environment admins for now.

At the moment, it's only the author that can delete a change request for example - I think we should add environment admins to this list, but I don't think anyone should be able to edit or delete a CR.

matthewelwell avatar Dec 16 '25 09:12 matthewelwell

I've aligned the BE with my expectations in a PR here.

matthewelwell avatar Dec 16 '25 09:12 matthewelwell

I've aligned the BE with my expectations in a PR here.

Ok yep, I've updated the FE to do this too.

Testing scenarios look valid

kyle-ssg avatar Dec 16 '25 10:12 kyle-ssg