|
|
@@ -28,7 +28,7 @@ class OrderCreateController
|
|
|
v::key('table_id', v::intType()->positive())
|
|
|
->key('user_name', v::stringType()->notEmpty()->alnum('_'))
|
|
|
->key('company_id', v::intType()->positive())
|
|
|
- ->key('order_name', v::stringType()->notEmpty()->alnum(' '))
|
|
|
+ ->key('order_name', v::stringType()->notEmpty()->regex('/^[\p{L}\p{N}\s\-\'\"]+$/u'))
|
|
|
->key('order_phone', v::optional(v::stringType()->notEmpty()->length(8, 20)), false)
|
|
|
->key('status_status', v::stringType()->notEmpty()->in(['Aberta', 'Finalizada', 'Cancelada']))
|
|
|
->assert($body);
|