Merge pull request #4789 from rahulshukla-webkul/development
Issue #2715 fixed
This commit is contained in:
commit
a2b9099b60
|
|
@ -63,7 +63,8 @@ return [
|
|||
'day' => 'يوم',
|
||||
'status' => 'الحالة',
|
||||
'open' => 'افتح',
|
||||
'close' => 'غلق'
|
||||
'close' => 'غلق',
|
||||
'time-error' => 'The to time must be greater than the from time.'
|
||||
]
|
||||
]
|
||||
],
|
||||
|
|
|
|||
|
|
@ -63,7 +63,8 @@ return [
|
|||
'day' => 'Day',
|
||||
'status' => 'Status',
|
||||
'open' => 'Open',
|
||||
'close' => 'Close'
|
||||
'close' => 'Close',
|
||||
'time-error' => 'The to time must be greater than the from time.'
|
||||
]
|
||||
]
|
||||
],
|
||||
|
|
|
|||
|
|
@ -63,7 +63,8 @@ return [
|
|||
'day' => 'Día',
|
||||
'status' => 'Estado',
|
||||
'open' => 'Abierto',
|
||||
'close' => 'Cerrado'
|
||||
'close' => 'Cerrado',
|
||||
'time-error' => 'The to time must be greater than the from time.'
|
||||
]
|
||||
]
|
||||
],
|
||||
|
|
|
|||
|
|
@ -63,7 +63,8 @@ return [
|
|||
'day' => 'روز',
|
||||
'status' => 'وضعیت',
|
||||
'open' => 'باز کن',
|
||||
'close' => 'بستن'
|
||||
'close' => 'بستن',
|
||||
'time-error' => 'The to time must be greater than the from time.'
|
||||
]
|
||||
]
|
||||
],
|
||||
|
|
|
|||
|
|
@ -63,7 +63,8 @@ return [
|
|||
'day' => 'Giorno',
|
||||
'status' => 'Stato',
|
||||
'open' => 'Aperto',
|
||||
'close' => 'Chiuso'
|
||||
'close' => 'Chiuso',
|
||||
'time-error' => 'The to time must be greater than the from time.'
|
||||
]
|
||||
]
|
||||
],
|
||||
|
|
|
|||
|
|
@ -63,7 +63,8 @@ return [
|
|||
'day' => 'Dag',
|
||||
'status' => 'Toestand',
|
||||
'open' => 'Open',
|
||||
'close' => 'Dichtbij'
|
||||
'close' => 'Dichtbij',
|
||||
'time-error' => 'The to time must be greater than the from time.'
|
||||
]
|
||||
]
|
||||
],
|
||||
|
|
|
|||
|
|
@ -63,7 +63,8 @@ return [
|
|||
'day' => 'Dia',
|
||||
'status' => 'Status',
|
||||
'open' => 'Aberto',
|
||||
'close' => 'Fechar'
|
||||
'close' => 'Fechar',
|
||||
'time-error' => 'The to time must be greater than the from time.'
|
||||
]
|
||||
]
|
||||
],
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@
|
|||
</div>
|
||||
|
||||
<div class="slot-list table" v-else>
|
||||
<accordian
|
||||
<accordian
|
||||
v-for="(day, dayIndex) in week_days"
|
||||
:key="dayIndex"
|
||||
:title="day"
|
||||
|
|
@ -47,7 +47,7 @@
|
|||
<th class="actions"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
|
||||
<tbody v-if="slots['different_for_week'][dayIndex] && slots['different_for_week'][dayIndex].length">
|
||||
<slot-item
|
||||
v-for="(slot, slotIndex) in slots['different_for_week'][dayIndex]"
|
||||
|
|
@ -85,7 +85,7 @@
|
|||
<td>
|
||||
<div class="control-group date" :class="[errors.has(controlName + '[to]') ? 'has-error' : '']">
|
||||
<time-component>
|
||||
<input type="text" v-validate="'required'" :name="controlName + '[to]'" v-model="slotItem.to" class="control" data-vv-as=""{{ __('bookingproduct::app.admin.catalog.products.to') }}"">
|
||||
<input type="text" v-validate="{required: true, time_min: slotItem.from }" :name="controlName + '[to]'" v-model="slotItem.to" class="control" data-vv-as=""{{ __('bookingproduct::app.admin.catalog.products.to') }}"">
|
||||
</time-component>
|
||||
|
||||
<span class="control-error" v-if="errors.has(controlName + '[to]')">
|
||||
|
|
@ -192,4 +192,20 @@
|
|||
},
|
||||
}
|
||||
});
|
||||
|
||||
const time_validator = {
|
||||
getMessage: (field) => {
|
||||
return "{{ __('bookingproduct::app.admin.catalog.products.time-error') }}"
|
||||
},
|
||||
|
||||
validate: (value, min) => {
|
||||
if (Array.isArray(value) || value === null || value === undefined || value === '') {
|
||||
return false;
|
||||
}
|
||||
|
||||
return value > min;
|
||||
}
|
||||
};
|
||||
|
||||
VeeValidate.Validator.extend('time_min', time_validator);
|
||||
</script>
|
||||
Loading…
Reference in New Issue