[Update] Fix date picker component
This commit is contained in:
parent
9ccc26455e
commit
28a8c1e63d
@ -105,7 +105,14 @@ const tempStartDate = ref('')
|
|||||||
const tempEndDate = ref('')
|
const tempEndDate = ref('')
|
||||||
const errorMessage = ref('')
|
const errorMessage = ref('')
|
||||||
|
|
||||||
const maxDate = computed(() => new Date().toISOString().split('T')[0])
|
const maxDate = computed(() => {
|
||||||
|
const today = new Date()
|
||||||
|
const year = today.getFullYear()
|
||||||
|
const month = String(today.getMonth() + 1).padStart(2, '0')
|
||||||
|
const day = String(today.getDate()).padStart(2, '0')
|
||||||
|
return `${year}-${month}-${day}`
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
const displayText = computed(() => {
|
const displayText = computed(() => {
|
||||||
if (props.modelValue.start && props.modelValue.end) {
|
if (props.modelValue.start && props.modelValue.end) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user