Sylius / AdminOrderCreationPlugin

Create orders in Sylius as an Administrator
MIT License
55 stars 50 forks source link

move payments constraint from xml to NewOrderType #108

Open wadjeroudi opened 5 years ago

wadjeroudi commented 5 years ago

See https://github.com/Sylius/AdminOrderCreationPlugin/pull/77#issuecomment-449978349

In some use cases, you don't need to validate payments outside of the plugin. (skip payment transition for example...etc)

bartoszpietrzak1994 commented 5 years ago

That seems to be a welcome change. However, since all constraints in Sylius are placed in xml files, I would go for changing the validation group name in src/Resources/config/validation.xml file - that would keep the configuration consistent.

wadjeroudi commented 5 years ago

@bartoszpietrzak1994 It was on purpose, I deleted the validation file that already existed in my PR to disable the validation globaly. If we need to keep the xml validation, the only solution is to create an other validation group.

Leobaillard commented 5 years ago

Could this be merged?

lchrusciel commented 4 years ago

This validation should stay in xml file (according to current Sylius usage) and we may introduce a new validation group for this case (the similar thing is done for order complete)