brexis / laravel-workflow

Use the Symfony Workflow component in Laravel
MIT License
281 stars 105 forks source link

emitting symfony-style events to allow for cleaner multiple workflows #4

Closed zerodahero closed 7 years ago

zerodahero commented 7 years ago

When multiple workflows are used, every listener has to duplicate a check on whether or not it is relevant to this listener and model. By dispatching events similar to symfony, we can listen only to specific events workflow.flowname.guard--thus greatly cleaning up the slew of listeners for multiple workflows.