|
|
@ -75,19 +75,19 @@
|
|
|
|
<el-row :gutter="20" class="el-row" type="flex">
|
|
|
|
<el-row :gutter="20" class="el-row" type="flex">
|
|
|
|
<el-col :span="15" class="el-col" type="flex">
|
|
|
|
<el-col :span="15" class="el-col" type="flex">
|
|
|
|
<div class="text item">
|
|
|
|
<div class="text item">
|
|
|
|
<el-form-item label="医院客户名称" prop="corpName">
|
|
|
|
<el-form-item label="医院客户名称" prop="unitId">
|
|
|
|
<el-select
|
|
|
|
<el-select
|
|
|
|
v-model="editLogin.corpName"
|
|
|
|
v-model="editLogin.unitId"
|
|
|
|
style="width: 65%"
|
|
|
|
style="width: 65%"
|
|
|
|
:disabled="editDialogVisible"
|
|
|
|
:disabled="editDialogVisible"
|
|
|
|
@change="intentPlatform"
|
|
|
|
@change="unitChange"
|
|
|
|
placeholder="请选择医院客户"
|
|
|
|
placeholder="请选择医院客户"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<el-option
|
|
|
|
<el-option
|
|
|
|
v-for="item in corpNamesList"
|
|
|
|
v-for="item in corpNamesList"
|
|
|
|
:key="item.id"
|
|
|
|
:key="item.unitId"
|
|
|
|
:label="item.name"
|
|
|
|
:label="item.name"
|
|
|
|
:value="item.id"
|
|
|
|
:value="item.unitId"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
</el-option>
|
|
|
|
</el-option>
|
|
|
|
</el-select>
|
|
|
|
</el-select>
|
|
|
@ -107,7 +107,7 @@
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<el-option
|
|
|
|
<el-option
|
|
|
|
v-for="item in platformList"
|
|
|
|
v-for="item in platformList"
|
|
|
|
:key="item.platformId"
|
|
|
|
:key="item.id"
|
|
|
|
:label="item.name"
|
|
|
|
:label="item.name"
|
|
|
|
:value="item.id"
|
|
|
|
:value="item.id"
|
|
|
|
>
|
|
|
|
>
|
|
|
@ -287,6 +287,7 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
editLogin: {
|
|
|
|
editLogin: {
|
|
|
|
id: null,
|
|
|
|
id: null,
|
|
|
|
|
|
|
|
unitId: null,
|
|
|
|
corpName: null,
|
|
|
|
corpName: null,
|
|
|
|
platformId: null,
|
|
|
|
platformId: null,
|
|
|
|
platformUsername: null,
|
|
|
|
platformUsername: null,
|
|
|
@ -298,9 +299,10 @@ export default {
|
|
|
|
targetAction: null,
|
|
|
|
targetAction: null,
|
|
|
|
invCode: "",
|
|
|
|
invCode: "",
|
|
|
|
invSubCode: "",
|
|
|
|
invSubCode: "",
|
|
|
|
|
|
|
|
customerId: this.$store.getters.customerId
|
|
|
|
},
|
|
|
|
},
|
|
|
|
editPlatfromQuery: {
|
|
|
|
editPlatfromQuery: {
|
|
|
|
id: null,
|
|
|
|
unitId: null,
|
|
|
|
name: null,
|
|
|
|
name: null,
|
|
|
|
host: null
|
|
|
|
host: null
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -439,6 +441,7 @@ export default {
|
|
|
|
//清空表单数据
|
|
|
|
//清空表单数据
|
|
|
|
this.editLogin = {
|
|
|
|
this.editLogin = {
|
|
|
|
id: null,
|
|
|
|
id: null,
|
|
|
|
|
|
|
|
unitId: null,
|
|
|
|
corpName: null,
|
|
|
|
corpName: null,
|
|
|
|
platformId: null,
|
|
|
|
platformId: null,
|
|
|
|
platformUsername: null,
|
|
|
|
platformUsername: null,
|
|
|
@ -450,13 +453,12 @@ export default {
|
|
|
|
targetAction: null,
|
|
|
|
targetAction: null,
|
|
|
|
invCode: "",
|
|
|
|
invCode: "",
|
|
|
|
invSubCode: "",
|
|
|
|
invSubCode: "",
|
|
|
|
|
|
|
|
customerId: this.$store.getters.customerId
|
|
|
|
};
|
|
|
|
};
|
|
|
|
this.getLocalBussinessType();
|
|
|
|
this.getLocalBussinessType();
|
|
|
|
this.getUnitMaintain();
|
|
|
|
this.getUnitMaintain();
|
|
|
|
this.getPlatformList();
|
|
|
|
this.getPlatformList();
|
|
|
|
},
|
|
|
|
},
|
|
|
|
change() {
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
getUnitMaintain() {
|
|
|
|
getUnitMaintain() {
|
|
|
|
let unitQuery = {
|
|
|
|
let unitQuery = {
|
|
|
|
customerId: this.$store.getters.customerId,
|
|
|
|
customerId: this.$store.getters.customerId,
|
|
|
@ -483,14 +485,17 @@ export default {
|
|
|
|
this.platformList = [];
|
|
|
|
this.platformList = [];
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
unitChange(value) {
|
|
|
|
|
|
|
|
this.editLogin.unitId = value;
|
|
|
|
|
|
|
|
},
|
|
|
|
intentPlatform(value) {
|
|
|
|
intentPlatform(value) {
|
|
|
|
this.editPlatfromQuery.id = value;
|
|
|
|
this.editPlatfromQuery.id = value;
|
|
|
|
this.curPlatformId = value;
|
|
|
|
this.curPlatformId = value;
|
|
|
|
|
|
|
|
this.targetPlatformEdit = true;
|
|
|
|
//拉取对应平台的单据类型
|
|
|
|
//拉取对应平台的单据类型
|
|
|
|
this.getTargetInv(value);
|
|
|
|
this.getTargetInv(value);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
getTargetActions() {
|
|
|
|
getTargetActions() {
|
|
|
|
this.targetActions = [];
|
|
|
|
this.targetActions = [];
|
|
|
|
let query = {
|
|
|
|
let query = {
|
|
|
@ -586,7 +591,7 @@ export default {
|
|
|
|
}).then(() => {
|
|
|
|
}).then(() => {
|
|
|
|
this.loading = true;
|
|
|
|
this.loading = true;
|
|
|
|
let query = {
|
|
|
|
let query = {
|
|
|
|
corpId: row.id
|
|
|
|
id: row.id
|
|
|
|
};
|
|
|
|
};
|
|
|
|
unbindPlatform(query).then((res) => {
|
|
|
|
unbindPlatform(query).then((res) => {
|
|
|
|
this.loading = false;
|
|
|
|
this.loading = false;
|
|
|
@ -600,46 +605,12 @@ export default {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
linkSubmit() {
|
|
|
|
linkSubmit() {
|
|
|
|
//判断此用户是否已经添加过
|
|
|
|
if (this.targetPlatformEdit) {
|
|
|
|
let corpId = this.editLogin.corpName;
|
|
|
|
this.$message.error("请验证账号!");
|
|
|
|
if (!this.editDialogVisible) {
|
|
|
|
return;
|
|
|
|
let corpNameTemp = null;
|
|
|
|
|
|
|
|
this.corpNamesList.forEach(item => {
|
|
|
|
|
|
|
|
if (item.id == this.editLogin.corpName) {
|
|
|
|
|
|
|
|
corpNameTemp = item.name;
|
|
|
|
|
|
|
|
corpId = item.id;
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
let flag = false;
|
|
|
|
|
|
|
|
//此时为添加
|
|
|
|
|
|
|
|
this.list.forEach(item => {
|
|
|
|
|
|
|
|
if (item.corpName == corpNameTemp) {
|
|
|
|
|
|
|
|
flag = true;
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (flag) {
|
|
|
|
|
|
|
|
this.$message.error('“' + corpNameTemp + '”' + " 已经关联");
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
let corpNameTemp = null;
|
|
|
|
|
|
|
|
this.corpNamesList.forEach(item => {
|
|
|
|
|
|
|
|
if (item.name == this.editLogin.corpName) {
|
|
|
|
|
|
|
|
corpNameTemp = item.name;
|
|
|
|
|
|
|
|
corpId = item.id;
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
this.$refs["editLogin"].validate((valid) => {
|
|
|
|
this.$refs["editLogin"].validate((valid) => {
|
|
|
|
if (valid) {
|
|
|
|
if (valid) {
|
|
|
|
this.editLogin.id = corpId;
|
|
|
|
|
|
|
|
linkPlatform(this.editLogin)
|
|
|
|
linkPlatform(this.editLogin)
|
|
|
|
.then((response) => {
|
|
|
|
.then((response) => {
|
|
|
|
if (response.code == 20000) {
|
|
|
|
if (response.code == 20000) {
|
|
|
|