You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CodeMeister edited this page Feb 28, 2023
·
10 revisions
Step 1:
include StateGate within the model class.
Step 2:
create the state-gate on the required attribute, defining the individual states and allowed transactions.
Simple Example
This example creates a minimal state-gate on the :status attribute of the Post class,
allowing any state to transition to any other state without restriction.