|
|
|
@ -66,8 +66,8 @@
|
|
|
|
|
placeholder="请输入店铺简称">
|
|
|
|
|
</i-input>
|
|
|
|
|
</FormItem>
|
|
|
|
|
<FormItem label="所属客户" prop="parentId">
|
|
|
|
|
<Select filterable clearable v-model="formValidate.parentId"
|
|
|
|
|
<FormItem label="所属客户" prop="customerId">
|
|
|
|
|
<Select filterable clearable v-model="formValidate.customerId"
|
|
|
|
|
placeholder="选择客户">
|
|
|
|
|
<Option v-for="item in customerList" :value="item.id" :key="item.id">{{ item.name }}</Option>
|
|
|
|
|
</Select>
|
|
|
|
@ -158,7 +158,7 @@
|
|
|
|
|
name: '',
|
|
|
|
|
code: '',
|
|
|
|
|
abbreviation: '',
|
|
|
|
|
parentId: 0
|
|
|
|
|
customerId: 0
|
|
|
|
|
},
|
|
|
|
|
ruleValidate: {
|
|
|
|
|
name: [
|
|
|
|
@ -170,7 +170,7 @@
|
|
|
|
|
detailName: [
|
|
|
|
|
{required: true, message: '店铺简称不能为空', trigger: 'blur'}
|
|
|
|
|
],
|
|
|
|
|
parentId: [
|
|
|
|
|
customerId: [
|
|
|
|
|
{ required: true, type: 'number', message: '请选择客户', trigger: 'change' }
|
|
|
|
|
]
|
|
|
|
|
},
|
|
|
|
@ -204,7 +204,7 @@
|
|
|
|
|
name: "",
|
|
|
|
|
code: '',
|
|
|
|
|
abbreviation: '',
|
|
|
|
|
parentId: 0
|
|
|
|
|
customerId: 0
|
|
|
|
|
}
|
|
|
|
|
}else{
|
|
|
|
|
this.formValidate = {
|
|
|
|
@ -212,7 +212,8 @@
|
|
|
|
|
name: item.name,
|
|
|
|
|
code: item.code,
|
|
|
|
|
abbreviation: item.abbreviation,
|
|
|
|
|
parentId: item.customerId
|
|
|
|
|
customerId: item.customerId
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
@ -224,7 +225,7 @@
|
|
|
|
|
},
|
|
|
|
|
handleSubmit(value) {
|
|
|
|
|
if (value) {
|
|
|
|
|
if(!value.parentId){
|
|
|
|
|
if(!value.customerId){
|
|
|
|
|
this.$Message.info('请输入表单内容');
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
@ -316,7 +317,7 @@
|
|
|
|
|
name: val.name,
|
|
|
|
|
code: val.code,
|
|
|
|
|
abbreviation: val.abbreviation,
|
|
|
|
|
customerId: val.parentId
|
|
|
|
|
customerId: val.customerId
|
|
|
|
|
};
|
|
|
|
|
that.btnLoading = true;
|
|
|
|
|
service.postOrganizationStoreAdd(request, function (res) {
|
|
|
|
@ -343,7 +344,7 @@
|
|
|
|
|
name: val.name,
|
|
|
|
|
code: val.code,
|
|
|
|
|
abbreviation: val.abbreviation,
|
|
|
|
|
customerId: val.parentId
|
|
|
|
|
customerId: val.customerId
|
|
|
|
|
};
|
|
|
|
|
service.postOrganizationStoreModify(request, function (res) {
|
|
|
|
|
that.btnLoading = false;
|
|
|
|
|