Rails - multiple "workflows" on the same model

I am using a workflow gem on some of my models to implement a state machine. is it possible to have multiple "workflows" on the same model?

+3


source to share


1 answer


Using some ruby ​​meta-programming (see Saving Worker Processes (Machine States) to DB. What's the best way? ) This should be easy to accomplish. I am developing a solution in this vein to use for myself and hopefully for a possible doc pull if I can work it out.



However, if you have a finite number of workflows with predefined steps, you can simply follow the example from the readme at https://github.com/geekq/workflow/#individual-workflows-for-objects

0


source







All Articles