|
@ -1,5 +1,5 @@ |
|
|
<template> |
|
|
<template> |
|
|
<el-form :model="formModel" :rules="createRules" ref="createForm"> |
|
|
<el-form :model="formModel" :rules="createRules" ref="editForm"> |
|
|
<el-form-item prop="customerId" label="客户" label-width="100px"> |
|
|
<el-form-item prop="customerId" label="客户" label-width="100px"> |
|
|
<el-select v-model="formModel.customerId" @change="onCustomerChanged" :disabled="customerIdFixed"> |
|
|
<el-select v-model="formModel.customerId" @change="onCustomerChanged" :disabled="customerIdFixed"> |
|
|
<el-option |
|
|
<el-option |
|
@ -80,6 +80,7 @@ export default { |
|
|
return { |
|
|
return { |
|
|
// 表单内容 |
|
|
// 表单内容 |
|
|
formModel: { |
|
|
formModel: { |
|
|
|
|
|
id: null, |
|
|
customerId: null, |
|
|
customerId: null, |
|
|
formId: null, |
|
|
formId: null, |
|
|
itemGroupId: null, |
|
|
itemGroupId: null, |
|
@ -202,7 +203,6 @@ export default { |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
this.formModel = result.data |
|
|
this.formModel = result.data |
|
|
debugger |
|
|
|
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -300,16 +300,16 @@ export default { |
|
|
* 提交 |
|
|
* 提交 |
|
|
*/ |
|
|
*/ |
|
|
onSubmitBtnClick() { |
|
|
onSubmitBtnClick() { |
|
|
this.$refs['createForm'].validate(rst => { |
|
|
this.$refs['editForm'].validate(rst => { |
|
|
if (!rst) { |
|
|
if (!rst) { |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
this.$http.post(`/oper/customize/icform/config/createItem`, this.formModel).then(({status:httpStatus, data: httpData}) => { |
|
|
this.$http.post(`/oper/customize/icform/config/updateItem`, this.formModel).then(({status:httpStatus, data: httpData}) => { |
|
|
if (httpData.code === 0) { |
|
|
if (httpData.code === 0) { |
|
|
this.$message({ |
|
|
this.$message({ |
|
|
type: 'success', |
|
|
type: 'success', |
|
|
message:"新增成功" |
|
|
message:"提交成功" |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
this.resetForm() |
|
|
this.resetForm() |
|
@ -334,7 +334,7 @@ export default { |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
resetForm() { |
|
|
resetForm() { |
|
|
this.$refs['createForm'].resetFields(); |
|
|
this.$refs['editForm'].resetFields(); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|