@@ -30,24 +30,6 @@
|
||||
</template>
|
||||
</TextField>
|
||||
</div>
|
||||
<div class="term-form__cell term-form__cell--third">
|
||||
<DatePickerField
|
||||
v-model="form.startsAt"
|
||||
name="startsAt"
|
||||
label="تاریخ شروع"
|
||||
:min="todayIso"
|
||||
:error="errors.startsAt"
|
||||
/>
|
||||
</div>
|
||||
<div class="term-form__cell term-form__cell--third">
|
||||
<DatePickerField
|
||||
v-model="form.endsAt"
|
||||
name="endsAt"
|
||||
label="تاریخ پایان"
|
||||
:min="todayIso"
|
||||
:error="errors.endsAt"
|
||||
/>
|
||||
</div>
|
||||
<div class="term-form__cell term-form__cell--third">
|
||||
<TextField
|
||||
v-model="form.minimumScore"
|
||||
@@ -136,7 +118,6 @@ import ImageCropper from '@/components/form/ImageCropper.vue'
|
||||
import { objectToFormData } from '@/utils/object-to-formdata'
|
||||
import { useUploadMediaMutation } from '@/services/query/auth'
|
||||
import TextareaField from '@/components/form/TextareaField.vue'
|
||||
import DatePickerField from '@/components/form/DatePickerField.vue'
|
||||
import BoxedIconTitleBlock from '@/components/blocks/BoxedIconTitleBlock.vue'
|
||||
import {
|
||||
adminTermsKeys,
|
||||
@@ -152,14 +133,10 @@ const queryClient = useQueryClient()
|
||||
const termId = computed(() => (route.params.id ? Number(route.params.id) : null))
|
||||
const isEditMode = computed(() => !!termId.value)
|
||||
|
||||
const todayIso = new Date().toISOString()
|
||||
|
||||
const form = ref({
|
||||
title: '',
|
||||
description: '',
|
||||
isActive: true,
|
||||
startsAt: '',
|
||||
endsAt: '',
|
||||
minimumScore: '',
|
||||
score: '',
|
||||
coverMediaId: null,
|
||||
@@ -181,8 +158,6 @@ watch(
|
||||
title: term.title || '',
|
||||
description: term.description || '',
|
||||
isActive: term.isActive ?? true,
|
||||
startsAt: term.startsAt || '',
|
||||
endsAt: term.endsAt || '',
|
||||
minimumScore: term.minimumScore ?? '',
|
||||
score: term.score ?? '',
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user