From af3ff155b9e82a4b21697b8cd0560bb169147573 Mon Sep 17 00:00:00 2001
From: WXL <1785969728@qq.com>
Date: 星期三, 02 七月 2025 14:47:11 +0800
Subject: [PATCH] 测试完成
---
src/views/followvisit/satisfaction/index.vue | 362 +++++++++++++++++++++++++---------------
src/views/followvisit/discharge/index.vue | 95 +++++++---
src/views/patient/propaganda/QuestionnaireTask.vue | 28 --
3 files changed, 291 insertions(+), 194 deletions(-)
diff --git a/src/views/followvisit/discharge/index.vue b/src/views/followvisit/discharge/index.vue
index 296305f..001e5a1 100644
--- a/src/views/followvisit/discharge/index.vue
+++ b/src/views/followvisit/discharge/index.vue
@@ -260,12 +260,22 @@
<el-col :span="1.5">
<div class="documentf">
<div class="document">
- <el-button
- :disabled="multiple"
- style="background: #983680; color: azure"
- @click="scoreDialogVisible = true"
- >婊℃剰搴﹁皟鏌�</el-button
+ <el-tooltip
+ content="璇峰厛閫変腑鏈嶅姟"
+ placement="top"
+ :disabled="!multiple"
>
+ <div class="tooltip-wrapper">
+ <el-button
+ type="primary"
+ :disabled="multiple"
+ class="purple-button"
+ @click="scoreDialogVisible = true"
+ >
+ 婊℃剰搴﹁皟鏌�
+ </el-button>
+ </div>
+ </el-tooltip>
</div>
</div>
</el-col>
@@ -617,7 +627,7 @@
</el-row>
<!-- 婊℃剰搴﹀脊妗� -->
<el-dialog
- title="闅忚璇勫垎"
+ title="闅忚婊℃剰搴﹁瘎鍒�"
:visible.sync="scoreDialogVisible"
width="80%"
:close-on-click-modal="false"
@@ -631,7 +641,7 @@
/>
<el-table-column
label="浠诲姟鍚嶇О"
- width="150"
+ width="180"
align="center"
prop="taskName"
/>
@@ -641,8 +651,7 @@
align="center"
key="authenticity"
prop="authenticity"
- sortable
- width="120"
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -659,8 +668,7 @@
align="center"
key="weekFinish"
prop="weekFinish"
- sortable
- width="120"
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -677,7 +685,7 @@
align="center"
key="standard"
prop="standard"
- sortable
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -694,8 +702,7 @@
align="center"
key="timeliness"
prop="timeliness"
- sortable
- width="120"
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -712,8 +719,7 @@
align="center"
key="library"
prop="library"
- sortable
- width="120"
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -730,8 +736,7 @@
align="center"
key="environment"
prop="environment"
- sortable
- width="120"
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -748,8 +753,7 @@
align="center"
key="doctorSatisfaction"
prop="doctorSatisfaction"
- width="120"
- sortable
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -766,8 +770,7 @@
align="center"
key="nurseSatisfaction"
prop="nurseSatisfaction"
- width="120"
- sortable
+ width="150"
>
<template slot-scope="scope">
<el-input-number
@@ -784,7 +787,7 @@
align="center"
key="total"
prop="total"
- sortable
+ fixed="right"
>
<template slot-scope="scope">
<span>{{ calculateTotal(scope.row) }}</span>
@@ -1017,6 +1020,7 @@
buidegetTasklist,
addserviceSubtask,
query360PatInfo,
+ addsatisfaction,
} from "@/api/AiCentre/index";
import { alterpatient, particularpatient } from "@/api/patient/homepage";
import Treeselect from "@riophae/vue-treeselect";
@@ -1570,6 +1574,8 @@
});
if (this.selectedRows.length > 0) {
+ this.multiple = false;
+ } else {
this.multiple = true;
}
},
@@ -1590,15 +1596,21 @@
// 淇濆瓨璇勫垎
saveScores() {
- // 杩欓噷鍙互娣诲姞淇濆瓨閫昏緫锛屽璋冪敤API淇濆瓨璇勫垎
- this.$message.success("璇勫垎淇濆瓨鎴愬姛");
- this.scoreDialogVisible = false;
-
- // 鏇存柊涓昏〃鏍兼暟鎹�
- this.userList = this.userList.map((user) => {
- const updatedUser = this.selectedRows.find((row) => row.id === user.id);
- return updatedUser ? updatedUser : user;
+ this.selectedRows.forEach((item) => {
+ item.createBy = null;
+ item.patName = item.sendname;
+ item.hospitaldistrictname = item.leavehospitaldistrictname;
});
+ addsatisfaction(this.selectedRows).then((res) => {
+ if (res.code == 200) {
+ this.$message.success("璇勫垎淇濆瓨鎴愬姛");
+ this.scoreDialogVisible = false;
+ } else {
+ this.$modal.msgWarning("璇勫垎淇濆瓨澶辫触");
+ this.scoreDialogVisible = false;
+ }
+ });
+ // 杩欓噷鍙互娣诲姞淇濆瓨閫昏緫锛屽璋冪敤API淇濆瓨璇勫垎
},
//鍒犻櫎閫夐」
handleClose(tag) {
@@ -2032,7 +2044,28 @@
font-size: 24px;
}
}
+.purple-button {
+ background-color: #7e22ce;
+ border-color: #7e22ce;
+ color: #fff;
+}
+.purple-button:hover,
+.purple-button:focus {
+ background-color: #9333ea;
+ border-color: #9333ea;
+}
+
+.purple-button:active {
+ background-color: #6b21a8;
+ border-color: #6b21a8;
+}
+
+.purple-button.is-disabled {
+ background-color: #d8b4fe;
+ border-color: #d8b4fe;
+ opacity: 1; /* 淇濇寔绂佺敤鐘舵�侀�忔槑搴� */
+}
// 閫夐」瀛椾綋鏀惧ぇ
// ::v-deep.el-checkbox-group {
// span {
diff --git a/src/views/followvisit/satisfaction/index.vue b/src/views/followvisit/satisfaction/index.vue
index e405d10..1de1266 100644
--- a/src/views/followvisit/satisfaction/index.vue
+++ b/src/views/followvisit/satisfaction/index.vue
@@ -11,44 +11,14 @@
v-show="showSearch"
label-width="98px"
>
- <el-form-item label="浠诲姟鍚嶇О">
- <el-input v-model="topqueryParams.name"></el-input>
+ <el-form-item label="鐥呭尯鍚嶇О">
+ <el-input placeholder="璇疯緭鍏ユ偅鑰呯梾鍖�" v-model="topqueryParams.hospitaldistrictname"></el-input>
</el-form-item>
- <el-form-item label="鍙戣捣浜�">
- <el-input v-model="topqueryParams.name"></el-input>
+ <el-form-item label="绉戝鍚嶇О">
+ <el-input placeholder="璇疯緭鍏ユ偅鑰呯瀹�" v-model="topqueryParams.deptname"></el-input>
</el-form-item>
- <el-form-item label="鍙戣捣鏃堕棿">
- <el-date-picker
- v-model="dateRange"
- style="width: 240px"
- value-format="yyyy-MM-dd"
- type="daterange"
- range-separator="-"
- start-placeholder="寮�濮嬫棩鏈�"
- end-placeholder="缁撴潫鏃ユ湡"
- ></el-date-picker>
- </el-form-item>
- <el-form-item label="璋冩煡绫诲瀷" prop="status">
- <el-select v-model="topqueryParams.topic" placeholder="璇烽�夋嫨">
- <el-option
- v-for="item in topicoptions"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- >
- </el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="璋冩煡鐘舵��" prop="status">
- <el-select v-model="topqueryParams.topic" placeholder="璇烽�夋嫨">
- <el-option
- v-for="item in topicoptions"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- >
- </el-option>
- </el-select>
+ <el-form-item label="鎮h�呭悕绉�">
+ <el-input placeholder="璇疯緭鍏ユ偅鑰呭鍚�" v-model="topqueryParams.patName"></el-input>
</el-form-item>
<el-form-item>
<el-button
@@ -116,26 +86,20 @@
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="50" align="center" />
- <el-table-column
- label="搴忓彿"
- align="center"
- key="id"
- prop="id"
- />
+ <el-table-column label="缂栧彿" align="center" key="id" prop="id" />
<el-table-column
label="鐥呭尯"
align="center"
- sortable
+ width="120"
key="hospitaldistrictname"
prop="hospitaldistrictname"
:show-overflow-tooltip="true"
/>
<el-table-column
label="绉戝"
- width="100"
+ width="120"
align="center"
- sortable
key="deptname"
prop="deptname"
:show-overflow-tooltip="true"
@@ -143,8 +107,8 @@
<el-table-column
label="濮撳悕"
align="center"
- key="age"
- prop="age"
+ key="patName"
+ prop="patName"
width="120"
/>
<el-table-column
@@ -152,6 +116,8 @@
align="center"
key="phone"
prop="phone"
+ width="150"
+ show-overflow-tooltip
/>
<el-table-column
label="鐪熷疄鎬�(20)"
@@ -160,72 +126,207 @@
prop="authenticity"
sortable
width="120"
- />
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.authenticity"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.authenticity }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="涓�鍛ㄥ唴瀹屾垚(20)"
align="center"
key="weekFinish"
prop="weekFinish"
sortable
- width="120"
- />
+ width="150"
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.weekFinish"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.weekFinish }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="瑙勮寖鎬�(10)"
align="center"
key="standard"
prop="standard"
+ width="120"
sortable
- />
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.standard"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.standard }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="鍙婃椂鎬�(10)"
align="center"
key="timeliness"
prop="timeliness"
sortable
- width="120"
- />
+ width="150"
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.timeliness"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.timeliness }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="瀹f暀鎯呭喌(10)"
align="center"
key="library"
prop="library"
sortable
- width="120"
- />
+ width="150"
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.library"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.library }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="鐜婊℃剰搴�(10)"
align="center"
key="environment"
prop="environment"
sortable
- width="120"
- />
+ width="150"
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.environment"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.environment }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="鍖荤敓婊℃剰搴�(10)"
align="center"
key="doctorSatisfaction"
prop="doctorSatisfaction"
- width="120"
+ width="150"
sortable
-
- />
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.doctorSatisfaction"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.doctorSatisfaction }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="鎶ゅ+婊℃剰搴�(10)"
align="center"
key="nurseSatisfaction"
prop="nurseSatisfaction"
- width="120"
+ width="150"
sortable
-
- />
+ >
+ <template slot-scope="scope">
+ <el-input-number
+ v-if="scope.row.editing"
+ v-model="scope.row.nurseSatisfaction"
+ :min="0"
+ :max="20"
+ size="small"
+ controls-position="right"
+ />
+ <span v-else>{{ scope.row.nurseSatisfaction }}</span>
+ </template>
+ </el-table-column>
<el-table-column
label="鎬诲垎"
+ fixed="right"
align="center"
key="total"
prop="total"
sortable
- />
+ >
+ </el-table-column>
+ <el-table-column
+ label="鎿嶄綔"
+ align="center"
+ fixed="right"
+ width="200"
+ class-name="small-padding fixed-width"
+ >
+ <template slot-scope="scope">
+ <el-button
+ v-if="!scope.row.editing"
+ size="medium"
+ type="text"
+ @click="handleDelete(scope.row)"
+ ><span class="button-zx"
+ ><i class="el-icon-delete"></i>鍒犻櫎</span
+ ></el-button
+ >
+ <el-button
+ size="medium"
+ type="text"
+ @click="toggleEdit(scope.row, scope.$index)"
+ >
+ <span class="button-textxga">
+ <i
+ :class="scope.row.editing ? 'el-icon-check' : 'el-icon-edit'"
+ ></i>
+ {{ scope.row.editing ? "淇濆瓨" : "缂栬緫" }}
+ </span>
+ </el-button>
+ <el-button
+ v-if="scope.row.editing"
+ size="medium"
+ type="text"
+ @click="handleCancel(scope.row, scope.$index)"
+ >鍙栨秷</el-button
+ >
+ </template>
+ </el-table-column>
</el-table>
<pagination
@@ -236,60 +337,6 @@
@pagination="getList"
/>
</el-row>
- <!-- 娣诲姞鎴栦慨鏀瑰奖鍍忛殢璁垮璇濇 -->
- <el-dialog
- :title="title"
- :visible.sync="addalteropen"
- width="700px"
- append-to-body
- >
- <el-form ref="form" :model="form" label-width="100px">
- <el-row :gutter="20">
- <el-col :span="12"
- ><el-form-item label="浠诲姟鍚嶇О">
- <el-input v-model="form.name"></el-input> </el-form-item
- ></el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="24"
- ><el-form-item label="鎵�灞炵瀹�">
- <el-select v-model="form.region" placeholder="璇烽�夋嫨绉戝">
- <el-option label="鍖哄煙涓�" value="shanghai"></el-option>
- <el-option label="鍖哄煙浜�" value="beijing"></el-option>
- </el-select> </el-form-item></el-col
- ></el-row>
- <el-row :gutter="20">
- <el-col :span="24"
- ><el-form-item label="闅忚绫诲瀷">
- <el-select v-model="form.region" placeholder="璇烽�夋嫨闅忚绫诲瀷">
- <el-option label="鍖哄煙涓�" value="shanghai"></el-option>
- <el-option label="鍖哄煙浜�" value="beijing"></el-option>
- </el-select> </el-form-item
- ></el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="24">
- <el-form-item label="鏈嶅姟妯″潡">
- <el-select v-model="form.region" placeholder="璇烽�夋嫨妯″潡">
- <el-option label="鍖哄煙涓�" value="shanghai"></el-option>
- <el-option label="鍖哄煙浜�" value="beijing"></el-option>
- </el-select>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="24">
- <el-form-item label="褰卞儚闅忚瑕佹眰">
- <el-input type="textarea" v-model="form.desc"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- <div slot="footer" class="dialog-footer">
- <el-button type="primary" @click="submitForm">鎻� 浜�</el-button>
- <el-button @click="cancel">杩� 鍥�</el-button>
- </div>
- </el-dialog>
</div>
</template>
@@ -368,8 +415,7 @@
value: [],
list: [],
loading: false,
- states: [
- ],
+ states: [],
pickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now();
@@ -502,13 +548,11 @@
/** 鏌ヨ褰卞儚闅忚鍒楄〃 */
getList() {
this.loading = true;
- listsatisfaction(this.topqueryParams).then(
- (response) => {
- this.userList = response.rows;
- this.total = response.total;
- this.loading = false;
- }
- );
+ listsatisfaction(this.topqueryParams).then((response) => {
+ this.userList = response.rows;
+ this.total = response.total;
+ this.loading = false;
+ });
},
// 鏌ョ湅褰卞儚闅忚璇︽儏
Referencequestion(row) {
@@ -598,13 +642,46 @@
path: "/Intelligentcenter/satisfaction/particulars",
query: { type: this.tasktopic },
});
-
},
/** 淇敼鎸夐挳鎿嶄綔 */
- handleUpdate(row) {
- this.reset();
- const userId = row.userId || this.ids;
+ toggleEdit(row, index) {
+ if (row.editing) {
+ // 淇濆瓨閫昏緫
+ updatesatisfaction(row).then((response) => {
+ this.$modal.msgSuccess("淇敼鎴愬姛");
+ this.$set(this.userList, index, {
+ ...row,
+ editing: false,
+ // 璁$畻鎬诲垎
+ total: this.calculateTotal(row),
+ });
+ });
+ // 杩欓噷鍙互娣诲姞API璋冪敤淇濆瓨鏁版嵁
+ } else {
+ // 杩涘叆缂栬緫妯″紡
+ this.$set(this.userList, index, {
+ ...row,
+ editing: true,
+ // 淇濆瓨鍘熷鏁版嵁鐢ㄤ簬鍙兘鐨勫彇娑堟搷浣�
+ originalData: { ...row },
+ });
+ }
+ },
+ handleCancel(row, index) {
+ this.$set(this.userList, index, row.originalData);
+ },
+ calculateTotal(row) {
+ return (
+ (row.authenticity || 0) +
+ (row.weekFinish || 0) +
+ (row.standard || 0) +
+ (row.timeliness || 0) +
+ (row.library || 0) +
+ (row.environment || 0) +
+ (row.doctorSatisfaction || 0) +
+ (row.nurseSatisfaction || 0)
+ );
},
/** 鎻愪氦鎸夐挳 */
@@ -623,9 +700,9 @@
},
/** 鍒犻櫎鎸夐挳鎿嶄綔 */
handleDelete(row) {
- const userIds = row.userId || this.ids;
+ const userIds = row.id || this.ids;
this.$modal
- .confirm('鏄惁纭鍒犻櫎鐢ㄦ埛缂栧彿涓�"' + userIds + '"鐨勬暟鎹」锛�')
+ .confirm('鏄惁纭鍒犻櫎鐢ㄦ埛缂栧彿涓�"' + row.patName + '"鐨勬暟鎹」锛�')
.then(function () {
return delsatisfaction(userIds);
})
@@ -750,11 +827,22 @@
font-weight: 500;
color: #dd302a;
}
+// .button-zx {
+// background: #e94f4f;
+// padding: 5px;
+// border-radius: 1px;
+// color: #ffffff;
+// }
+.el-table .cell .el-input-number {
+ width: 100%;
+}
+
+/* 鎸夐挳鏍峰紡 */
.button-zx {
- background: #4fabe9;
- padding: 5px;
- border-radius: 1px;
- color: #ffffff;
+ color: #f56c6c;
+}
+.button-textxga {
+ color: #409eff;
}
::v-deep.el-radio-group {
diff --git a/src/views/patient/propaganda/QuestionnaireTask.vue b/src/views/patient/propaganda/QuestionnaireTask.vue
index 651b294..e24eaa0 100644
--- a/src/views/patient/propaganda/QuestionnaireTask.vue
+++ b/src/views/patient/propaganda/QuestionnaireTask.vue
@@ -1026,7 +1026,6 @@
patientqueryParams: {
pageNum: 1, //
pageSize: 10,
- topica: 1, //0鍏ㄩ儴1绉戝2鐥呭尯
leavehospitaldistrictcodes: [],
leaveldeptcodes: [],
},
@@ -1688,9 +1687,7 @@
this.allpids.push(item.patid);
});
if (
- this.patientqueryParams.allhosp == 1 ||
- (this.patientqueryParams.allhosp == 1 &&
- this.patientqueryParams.cry == 1)
+ this.patientqueryParams.allhosp == 4
) {
this.tableLabelhz = [
// { label: "鍏ラ櫌鏃ユ湡", width: "170", prop: "starttime" },
@@ -1706,7 +1703,7 @@
{ label: "绉戝", width: "180", prop: "dept" },
{ label: "鐥呭尯", width: "150", prop: "leavehospitaldistrictname" },
];
- } else if (this.patientqueryParams.allhosp == 4) {
+ } else if (this.patientqueryParams.allhosp == 1) {
this.tableLabelhz = [
{ label: "鍏ラ櫌鏃ユ湡", width: "150", prop: "starttime" },
{ label: "鎮h��", width: "", prop: "name" },
@@ -1725,13 +1722,6 @@
this.patientqueryParams.pids = this.allpids;
} else {
this.patientqueryParams.pids = null;
- }
- // 绫诲瀷鍒ゆ柇
- if (this.patientqueryParams.allhosp == 1) {
- this.patientqueryParams.cry = 1;
- } else if (this.patientqueryParams.allhosp == 4) {
- this.patientqueryParams.cry = 0;
- this.patientqueryParams.allhosp = "1";
}
// 鏉ユ簮鍒ゆ柇
@@ -1836,7 +1826,6 @@
getList() {},
handleQuery() {
// 鑾峰彇澶栭儴鎮h��
- console.log(this.patientqueryParams.allhosp, "aaalll");
if (this.patientqueryParams.allhosp == 6) {
this.Externallist();
@@ -1844,19 +1833,6 @@
return;
}
- if (this.patientqueryParams.topica == 0) {
- this.patientqueryParams.leavehospitaldistrictcodes =
- store.getters.leavehospitaldistrictcodes;
- this.patientqueryParams.leaveldeptcodes = store.getters.leaveldeptcodes;
- } else if (this.patientqueryParams.topica == 1) {
- this.patientqueryParams.leavehospitaldistrictcodes = null;
- this.patientqueryParams.leaveldeptcodes = store.getters.leaveldeptcodes;
- } else if (this.patientqueryParams.topica == 2) {
- this.patientqueryParams.leavehospitaldistrictcodes =
- store.getters.leavehospitaldistrictcodes;
- this.patientqueryParams.leaveldeptcodes = null;
- }
-
if (
!this.patientqueryParams.leavehospitaldistrictcodes ||
!this.patientqueryParams.leavehospitaldistrictcodes[0]
--
Gitblit v1.9.3