Browse Source

fix: date column missing placeholde

pull/6323/head
DarkPhoenix2704 1 year ago
parent
commit
69343270a5
  1. 2
      packages/nc-gui/components/cell/DatePicker.vue
  2. 2
      packages/nc-gui/components/cell/DateTimePicker.vue
  3. 2
      packages/nc-gui/components/cell/TimePicker.vue
  4. 4
      packages/nc-gui/components/cell/YearPicker.vue

2
packages/nc-gui/components/cell/DatePicker.vue

@ -83,7 +83,7 @@ watch(
) )
const placeholder = computed(() => { const placeholder = computed(() => {
if (isEditColumn.value && modelValue === null) { if (isEditColumn.value && ( modelValue === '' || modelValue === null )) {
return '(Optional)' return '(Optional)'
} else if (modelValue === null && showNull.value) { } else if (modelValue === null && showNull.value) {
return 'NULL' return 'NULL'

2
packages/nc-gui/components/cell/DateTimePicker.vue

@ -136,7 +136,7 @@ watch(
) )
const placeholder = computed(() => { const placeholder = computed(() => {
if (isEditColumn.value && modelValue === null) { if (isEditColumn.value && ( modelValue === '' || modelValue === null )) {
return '(Optional)' return '(Optional)'
} else if (modelValue === null && showNull.value) { } else if (modelValue === null && showNull.value) {
return 'NULL' return 'NULL'

2
packages/nc-gui/components/cell/TimePicker.vue

@ -88,7 +88,7 @@ watch(
) )
const placeholder = computed(() => { const placeholder = computed(() => {
if (isEditColumn.value && modelValue === null) { if (isEditColumn.value && ( modelValue === '' || modelValue === null )) {
return '(Optional)' return '(Optional)'
} else if (modelValue === null && showNull.value) { } else if (modelValue === null && showNull.value) {
return 'NULL' return 'NULL'

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

@ -75,8 +75,8 @@ watch(
) )
const placeholder = computed(() => { const placeholder = computed(() => {
if (isEditColumn.value && modelValue === null) { if (isEditColumn.value && ( modelValue === '' || modelValue === null )) {
return 'Select default year (Optional)' return '(Optional)'
} else if (modelValue === null && showNull.value) { } else if (modelValue === null && showNull.value) {
return 'NULL' return 'NULL'
} else if (isYearInvalid.value) { } else if (isYearInvalid.value) {

Loading…
Cancel
Save