Browse Source

fix: year field

pull/6323/head
DarkPhoenix2704 1 year ago
parent
commit
0ecf4b9f02
  1. 14
      packages/nc-gui/components/cell/YearPicker.vue

14
packages/nc-gui/components/cell/YearPicker.vue

@ -1,6 +1,16 @@
<script setup lang="ts"> <script setup lang="ts">
import dayjs from 'dayjs' import dayjs from 'dayjs'
import { ActiveCellInj, ReadonlyInj, computed, inject, onClickOutside, ref, useSelectedCellKeyupListener, watch } from '#imports' import {
ActiveCellInj,
EditColumnInj,
ReadonlyInj,
computed,
inject,
onClickOutside,
ref,
useSelectedCellKeyupListener,
watch,
} from '#imports'
interface Props { interface Props {
modelValue?: number | string | null modelValue?: number | string | null
@ -69,7 +79,7 @@ const placeholder = computed(() => {
return '(Optional) Select default year' return '(Optional) Select default year'
} else if (modelValue === null && showNull.value) { } else if (modelValue === null && showNull.value) {
return 'NULL' return 'NULL'
} else if (isTimeInvalid.value) { } else if (isYearInvalid.value) {
return 'Invalid year' return 'Invalid year'
} else { } else {
return '' return ''

Loading…
Cancel
Save