king
2023-05-09 7b0dbecd1d6155d26ec67be0a47a16264c738c85
src/tabviews/zshare/mutilform/index.jsx
@@ -19,6 +19,7 @@
const MKCheckCard = asyncComponent(() => import('./mkCheckCard'))
const MKSwitch = asyncComponent(() => import('./mkSwitch'))
const MKCheck = asyncComponent(() => import('./mkCheck'))
const MKCheckbox = asyncComponent(() => import('./mkCheckbox'))
const MKRadio = asyncComponent(() => import('./mkRadio'))
const MKDatePicker = asyncComponent(() => import('./mkDatePicker'))
@@ -124,11 +125,13 @@
        item.precision = 'second'
      }
      if (!item.field || !['text', 'number', 'switch', 'rate', 'select', 'link', 'cascader', 'linkMain', 'funcvar', 'date', 'datemonth', 'radio', 'checkbox', 'checkcard', 'fileupload', 'textarea', 'multiselect', 'brafteditor', 'color', 'vercode'].includes(item.type)) return false
      if (!item.field || !['text', 'number', 'switch', 'check', 'rate', 'select', 'link', 'cascader', 'linkMain', 'funcvar', 'date', 'datemonth', 'radio', 'checkbox', 'checkcard', 'fileupload', 'textarea', 'multiselect', 'brafteditor', 'color', 'vercode'].includes(item.type)) return false
      if (/^\s+$/.test(item.label)) {
        item.style = item.style || {}
        item.style.color = 'transparent'
        item.style.opacity = 0
        item.style.width = 1
        item.style.display = 'inline-block'
      }
      // 数据自动填充
@@ -218,7 +221,7 @@
        if (newval === '$empty' && item.initval) {
          newval = moment().subtract(item.initval, 'month').format('YYYY-MM')
        }
      } else if (item.type === 'switch') { // 开关只接收固定值
      } else if (item.type === 'switch' || item.type === 'check') { // 开关勾选框只接收固定值
        if (newval !== '$empty' && (newval === item.closeVal || newval === item.openVal)) {
        } else if (item.initval === true) {
@@ -995,6 +998,8 @@
          content = (<MKCheckCard config={item} onChange={(val, other) => this.recordChange({[item.field]: val, ...other}, item)}/>)
        } else if (item.type === 'switch') {
          content = (<MKSwitch config={item} onChange={(val) => this.recordChange({[item.field]: val}, item)}/>)
        } else if (item.type === 'check') {
          content = (<MKCheck config={item} onChange={(val) => this.recordChange({[item.field]: val}, item)}/>)
        } else if (item.type === 'checkbox') {
          content = (<MKCheckbox config={item} onChange={(val) => this.recordChange({[item.field]: val})}/>)
        } else if (item.type === 'radio') {