yokai-php / sonata-workflow

Integrate Symfony workflow component in Sonata Admin
MIT License
22 stars 12 forks source link

How can i specify flash message for specific transition? #22

Open gansky-alexander opened 4 years ago

yann-eugone commented 4 years ago

Hi @gansky-alexander

Sadly, the current code provide no way to customize flash messages.

We are re-using a generic sonata admin flash : https://github.com/yokai-php/sonata-workflow/blob/0.x/src/Controller/WorkflowControllerTrait.php#L115

Using a dedicated flash message for applying transition can be a thing. But per transition flash message is something else (harder).

Maybe using sonata label strategies... But this would assume that ALL admins in ALL projects are using the appropriate strategy.

gansky-alexander commented 4 years ago

Okay, thank you for the response.