| | |
| | | :referConfig="item.referConfig || {}" |
| | | :value="form[item.referConfig.field] || item.value" |
| | | :text="form[item.referConfig.showField]" |
| | | :disabled="item.disabled" |
| | | :display="item.display" |
| | | @setReferValue="setReferValue" |
| | | ></vciWebRefer> |
| | | </template> |
| | |
| | | collapse: true, |
| | | column: [], |
| | | }); |
| | | return |
| | | } |
| | | if ( |
| | | formItem.type === "combox" && |
| | |
| | | maxlength: formItem.maxlength, |
| | | filterable: true, |
| | | referConfig:formItem.type=='refer'?{ |
| | | title:formItem.text, |
| | | title:formItem.text , |
| | | showField:formItem.showField || formItem.field, |
| | | field: formItem.field, |
| | | placeholder: formItem.inputTip, |
| | |
| | | this.$set(this.option, "column", column); |
| | | this.$set(this.option, "group", group); |
| | | this.formIndex++; |
| | | if (this.type === 'add') { |
| | | if (this.type === 'add' || this.type === 'preview') { |
| | | this.loading = false; |
| | | } |
| | | this.geDictData(dictKeys); |
| | |
| | | if (type === "truefalse") { |
| | | return [ |
| | | { |
| | | key: false, |
| | | key: 'false', |
| | | value: "否", |
| | | }, |
| | | { |
| | | key: true, |
| | | key: 'true', |
| | | value: "是", |
| | | }, |
| | | ]; |
| | |
| | | }, |
| | | // 获取表单详情数据 |
| | | getFormDetail() { |
| | | if (this.type === 'add') return |
| | | if (this.type === 'add' || this.type === 'preview') return |
| | | getFormDetail({ templateOid: this.templateOid, oid: this.rowOid }).then( |
| | | (res) => { |
| | | this.form = Object.assign(this.form, res.data.data[0]) |
| | |
| | | if(data.field){ |
| | | this.form[data.field]=data.value || ''; |
| | | this.form[data.showField]=data.text || ''; |
| | | this.$emit("getFormData", this.form); |
| | | this.$emit("referConfigDataUpdate", data); |
| | | } |
| | | } |
| | | }, |