remove exit station
This commit is contained in:
@@ -26,7 +26,7 @@ class UpdateRequest extends FormRequest
|
||||
public function rules(): array
|
||||
{
|
||||
return [
|
||||
'enter_station' => 'required|date',
|
||||
'enter_time' => 'required|date',
|
||||
];
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ class UpdateRequest extends FormRequest
|
||||
{
|
||||
return [
|
||||
function (Validator $validator) {
|
||||
if (strtotime($this->violation->exit_station) < strtotime($this->enter_station)) {
|
||||
if (strtotime($this->violation->exit_time) < strtotime($this->enter_time)) {
|
||||
$validator->errors()->add(
|
||||
'time',
|
||||
'زمان پایان ماموریت باید بعد از زمان شروع ماموریت باشد.'
|
||||
|
||||
Reference in New Issue
Block a user