Fixed validation rule to check the date of a new person target in the booking

create form.
This commit is contained in:
Lukas Halbritter
2018-10-16 09:35:00 +02:00
parent 4768e8d8cd
commit 16b9d3a7b3
+1
View File
@@ -34,6 +34,7 @@ class StoreBooking extends FormRequest
'personTarget.person_id' => 'empty_if:person_target_id'
. '|required_with:personTarget.date',
'personTarget.date' => 'sometimes'
. '|nullable'
. '|empty_if:person_target_id'
. '|before_or_equal:date'
];