|
@@ -92,6 +92,17 @@
|
|
|
<el-table-column prop="cardType" label="证型" width="120" align="center"></el-table-column>
|
|
<el-table-column prop="cardType" label="证型" width="120" align="center"></el-table-column>
|
|
|
<el-table-column prop="westernDisease" label="西医病名" width="120" align="center"></el-table-column>
|
|
<el-table-column prop="westernDisease" label="西医病名" width="120" align="center"></el-table-column>
|
|
|
<el-table-column prop="expert" label="专家" width="100" align="center"></el-table-column>
|
|
<el-table-column prop="expert" label="专家" width="100" align="center"></el-table-column>
|
|
|
|
|
+ <el-table-column prop="status" label="应用" width="90" align="center">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <el-switch
|
|
|
|
|
+ :value="scope.row.status === 0"
|
|
|
|
|
+ :disabled="scope.row.createUser != currentUserId"
|
|
|
|
|
+ active-color="#5386f6"
|
|
|
|
|
+ inactive-color="#dcdfe6"
|
|
|
|
|
+ @change="handleStatusChange(scope.row, $event)"
|
|
|
|
|
+ ></el-switch>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
<el-table-column label="操作" width="180" align="center">
|
|
<el-table-column label="操作" width="180" align="center">
|
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
|
<div class="flex-center">
|
|
<div class="flex-center">
|
|
@@ -401,7 +412,7 @@ import {
|
|
|
getSymptomListMethod as getSymptomListMethodApi,
|
|
getSymptomListMethod as getSymptomListMethodApi,
|
|
|
getTherapyListMethod as getTherapyListMethodApi,
|
|
getTherapyListMethod as getTherapyListMethodApi,
|
|
|
} from "@/request/api";
|
|
} from "@/request/api";
|
|
|
-import { getLocalSuitableTechList, deleteLocalSuitableTech, saveLocalSuitableTech, getLocalSuitableTechInfo, getMappedNondrugItemList } from "@/api/technology.js";
|
|
|
|
|
|
|
+import { getLocalSuitableTechList, deleteLocalSuitableTech, saveLocalSuitableTech, getLocalSuitableTechInfo, getMappedNondrugItemList, changeLocalExpertTechStatus } from "@/api/technology.js";
|
|
|
import { getXDiseaseName } from "@/api/knowledge.js";
|
|
import { getXDiseaseName } from "@/api/knowledge.js";
|
|
|
import SuitableTechDetail from "./components/SuitableTechDetail.vue";
|
|
import SuitableTechDetail from "./components/SuitableTechDetail.vue";
|
|
|
|
|
|
|
@@ -466,6 +477,12 @@ export default {
|
|
|
viewData: {},
|
|
viewData: {},
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
|
|
+ computed: {
|
|
|
|
|
+ currentUserId() {
|
|
|
|
|
+ const userInfo = this.$store.state.user.userInfo || {};
|
|
|
|
|
+ return userInfo.pid;
|
|
|
|
|
+ },
|
|
|
|
|
+ },
|
|
|
created() {
|
|
created() {
|
|
|
this.getList()
|
|
this.getList()
|
|
|
},
|
|
},
|
|
@@ -723,6 +740,18 @@ export default {
|
|
|
handleExpandChange(row, expandedRows) {
|
|
handleExpandChange(row, expandedRows) {
|
|
|
this.expandRows = expandedRows.map(item => item.pid)
|
|
this.expandRows = expandedRows.map(item => item.pid)
|
|
|
},
|
|
},
|
|
|
|
|
+ async handleStatusChange(row, val) {
|
|
|
|
|
+ const status = val ? 0 : 1;
|
|
|
|
|
+ try {
|
|
|
|
|
+ const res = await changeLocalExpertTechStatus({ pid: row.pid, status });
|
|
|
|
|
+ if (res.ResultCode === 0) {
|
|
|
|
|
+ this.$message.success(status === 0 ? '已启用' : '已禁用');
|
|
|
|
|
+ row.status = status;
|
|
|
|
|
+ }
|
|
|
|
|
+ } catch (e) {
|
|
|
|
|
+ this.$message.error('操作失败');
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
formatDetailList(row) {
|
|
formatDetailList(row) {
|
|
|
const parts = []
|
|
const parts = []
|
|
|
const extractNames = (arr) => {
|
|
const extractNames = (arr) => {
|