raoul2000 / yii2-workflow

A simple workflow engine for Yii2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

force model to be a given status

cornernote opened this issue · comments

I have a use case where I need to bypass the workflow and directly set the status. I can't seem to find a method to do this. Is there any existing way to achieve this?

commented

You mean assigning directly a status to the status attribute of your model ? If that's the case you should try to call initStatus() after status attribute assignment (not tested). Please note that this will not fire any event ...

Let me know

ciao