king
2021-05-20 5d48f8215284ca8de312f1c85f78e07215a0faf1
src/templates/zshare/formconfig.jsx
@@ -1927,10 +1927,118 @@
    roleList = []
  }
  
  let _openType = []
  let _openType = [{
    value: 'text',
    text: Formdict['model.form.text']
  }, {
    value: 'number',
    text: Formdict['model.form.number']
  }, {
    value: 'select',
    text: Formdict['model.form.select']
  }, {
    value: 'multiselect',
    text: Formdict['model.form.multiselect']
  }, {
    value: 'link',
    text: Formdict['model.form.link']
  }, {
    value: 'switch',
    text: '开关'
  }, {
    value: 'checkbox',
    text: '多选框'
  }, {
    value: 'radio',
    text: '单选框'
  }, {
    value: 'checkcard',
    text: '选项卡'
  }, {
    value: 'fileupload',
    text: Formdict['header.form.fileupload']
  }, {
    value: 'date',
    text: Formdict['model.form.dateday']
  }, {
    value: 'datemonth',
    text: Formdict['model.form.datemonth']
  }, {
    value: 'datetime',
    text: Formdict['model.form.datetime']
  }, {
    value: 'textarea',
    text: Formdict['model.form.textarea']
  }, {
    value: 'color',
    text: Formdict['model.form.color']
  }, {
    value: 'brafteditor',
    text: '富文本'
  }, {
    value: 'funcvar',
    text: Formdict['header.form.funcvar']
  }, {
    value: 'hint',
    text: '提示'
  }, {
    value: 'split',
    text: '分隔线'
  }]
  let _fieldlength = 50
  if (subtable) {
  if (appType === 'mob') {
    _openType = [{
      value: 'text',
      text: Formdict['model.form.text']
    }, {
      value: 'number',
      text: Formdict['model.form.number']
    }, {
      value: 'select',
      text: '选择器'
    }, {
      value: 'link',
      text: Formdict['model.form.link']
    }, {
      value: 'switch',
      text: '开关'
    }, {
      value: 'checkbox',
      text: '多选框'
    }, {
      value: 'radio',
      text: '单选框'
    }, {
      value: 'checkcard',
      text: '选项卡'
    }, {
      value: 'fileupload',
      text: Formdict['header.form.fileupload']
    }, {
      value: 'date',
      text: Formdict['model.form.dateday']
    }, {
      value: 'datemonth',
      text: Formdict['model.form.datemonth']
    }, {
      value: 'datetime',
      text: Formdict['model.form.datetime']
    }, {
      value: 'textarea',
      text: Formdict['model.form.textarea']
    }, {
      value: 'funcvar',
      text: Formdict['header.form.funcvar']
    }, {
      value: 'hint',
      text: '提示'
    }, {
      value: 'split',
      text: '分隔线'
    }]
  } else if (subtable) {
    _openType.push({
      value: 'linkMain',
      text: Formdict['header.form.linkMain']
@@ -1966,65 +2074,7 @@
      label: Formdict['model.form.type'],
      initVal: card.type,
      required: true,
      options: [{
        value: 'text',
        text: Formdict['model.form.text']
      }, {
        value: 'number',
        text: Formdict['model.form.number']
      }, {
        value: 'select',
        text: Formdict['model.form.select']
      }, {
        value: 'multiselect',
        text: Formdict['model.form.multiselect']
      }, {
        value: 'link',
        text: Formdict['model.form.link']
      }, {
        value: 'switch',
        text: '开关'
      }, {
        value: 'checkbox',
        text: '多选框'
      }, {
        value: 'radio',
        text: '单选框'
      }, {
        value: 'checkcard',
        text: '选项卡'
      }, {
        value: 'fileupload',
        text: Formdict['header.form.fileupload']
      }, {
        value: 'date',
        text: Formdict['model.form.dateday']
      }, {
        value: 'datemonth',
        text: Formdict['model.form.datemonth']
      }, {
        value: 'datetime',
        text: Formdict['model.form.datetime']
      }, {
        value: 'textarea',
        text: Formdict['model.form.textarea']
      }, {
        value: 'color',
        text: Formdict['model.form.color']
      }, {
        value: 'brafteditor',
        text: '富文本'
      }, {
        value: 'funcvar',
        text: Formdict['header.form.funcvar']
      }, {
        value: 'hint',
        text: '提示'
      }, {
        value: 'split',
        text: '分隔线'
      },
      ..._openType]
      options: _openType
    },
    {
      type: 'text',
@@ -2061,14 +2111,16 @@
      key: 'openText',
      label: '开启提示',
      initVal: card.openText || '',
      required: false
      required: false,
      forbid: appType === 'mob'
    },
    {
      type: 'text',
      key: 'closeText',
      label: '关闭提示',
      initVal: card.closeText || '',
      required: false
      required: false,
      forbid: appType === 'mob'
    },
    {
      type: 'radio',
@@ -2399,6 +2451,19 @@
    },
    {
      type: 'radio',
      key: 'cursor',
      label: '光标',
      initVal: card.cursor || 'right',
      options: [{
        value: 'right',
        text: '右对齐'
      }, {
        value: 'left',
        text: '左对齐'
      }]
    },
    {
      type: 'radio',
      key: 'readin',
      label: Formdict['header.form.readin'],
      tooltip: Formdict['header.form.readin.tooltip'],
@@ -2448,7 +2513,8 @@
      label: '表单宽度',
      initVal: card.span || (['textarea', 'hint', 'checkcard', 'brafteditor'].includes(card.type) ? 24 : 12),
      tooltip: '栅格布局整行24等分。',
      required: true
      required: true,
      forbid: appType === 'mob'
    },
    {
      type: 'number',