river-admin icon indicating copy to clipboard operation
river-admin copied to clipboard

Support deleting transitions on workflows

Open javrasya opened this issue 5 years ago • 2 comments

Description: Once a transition is created there is no way back

**Acceptance Criteria: **

  • Provide a component to delete created transitions on workflow edit page

javrasya avatar Nov 29 '19 17:11 javrasya

Hello , is there any updates on this? I wish to contribute however im pretty new to programming. So far i have tried to convert the on_delete = PROTECT to on_delete = models.CASCADE for the transitionmeta model and converting the transitionmeta field within transition from on_delete = PROTECT to on_delete= models.SET_NULL , it seems to be working but i am not sure if there is any repercussions in doing so

noobmaster19 avatar May 27 '20 12:05 noobmaster19

Hi @neowenshun , this has nothing to do with delete permissions between models. If you use river-admin, you would notice that it doesn't have the capability of deleting transitions. So this is about it. Even though this support were to be added to riveradmin, it would still not be possible to delete a transition meta when there are transitions that belong to it.

Making transition metas protected when there are transitions belong to it is a desired feature. One can simply delete all the transitions first before deleting the transition meta if it is really wanted to delete it. This is a choice by design, so that one can't delete the entire history just by deleting a transition meta accidentally. These operations require more attention.

javrasya avatar Jul 26 '20 21:07 javrasya