Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better validation handling for FlowBundle #241

Closed
zachbadgett opened this issue Aug 5, 2013 · 2 comments
Closed

Better validation handling for FlowBundle #241

zachbadgett opened this issue Aug 5, 2013 · 2 comments

Comments

@zachbadgett
Copy link
Contributor

Currently the 'Coordinator' in FlowBundle will throw a NotFoundHttpException if a Scenario is not valid. This limits flexibility and can be handled more effectively.

I'm willing to take care of it if we have an agreed solution. The best way I can think of is to have a ProcessValidator class available for extending or constructing that can be passed to the builder. If we want to keep the simplicity of the closure as well, we can transform it to the default validator. If a Scenario is invalid we can return a response using a selected or default error template; we can also redirect with a set flash message. Thoughts?

@pjedrzejewski
Copy link
Member

I love this idea... I believe your idea with ProcessValidator is best what we can do now. Can you provide a PoC?

@pjedrzejewski
Copy link
Member

Implemented by Zach.

pamil pushed a commit to pamil/Sylius that referenced this issue Mar 21, 2016
Minor - updating version number
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants