This commit is contained in:
2025-08-08 17:36:23 +08:00
parent 613ed5173c
commit 181a98c157
4 changed files with 195 additions and 58 deletions

View File

@@ -26,36 +26,102 @@
ref="commonMedicalDetail"
></medicalDetail>
<view class="footer_box">
<view style="color: #5188e5;padding-left: 10rpx;margin-bottom: 24rpx;">请您结合医案内容给出评价 : </view>
<view class="footer_box" v-if="options.taimedId == 0">
<view style="color: #5188e5; padding-left: 10rpx; margin-bottom: 24rpx"
>请您结合医案内容给出评价 :
</view>
<view style="display: flex; flex-direction: row">
<view class="footer_item" @click="handleSubmit('A')">
<view class="footer_item" @click="showModal('A')">
<image src="/static/icon/a.png"></image>
<view class="button savebutton" style="background-color:#2bc66912;
color: #2bc669;"
<view
class="button savebutton"
style="background-color: #2bc66912; color: #2bc669"
>A
</view> <view class="button_text" style="color: #2bc669;">特别具有吴门意义</view>
</view>
<view class="button_text" style="color: #2bc669"
>特别具有吴门意义</view
>
</view>
<view class="footer_item" @click="handleSubmit('B')"
> <image src="/static/icon/b.png"></image><view class="button" style="background-color: #0099ff0f;
color: #0099ff;"
<view class="footer_item" @click="showModal('B')">
<image src="/static/icon/b.png"></image
><view
class="button"
style="background-color: #0099ff0f; color: #0099ff"
>B </view
><view class="button_text" style="color: #0099ff;">不太具有吴门意义</view></view
><view class="button_text" style="color: #0099ff"
>不太具有吴门意义</view
></view
>
<view class="footer_item" @click="handleSubmit('C')"
> <image src="/static/icon/c.png"></image><view class="button" style="background-color: #f2f1f6;
color: #333333cf;"
<view class="footer_item" @click="showModal('C')">
<image src="/static/icon/c.png"></image
><view
class="button"
style="background-color: #f2f1f6; color: #333333cf"
>C</view
><view class="button_text" style="color: #333333cf">医案内容不够精准</view></view
><view class="button_text" style="color: #333333cf"
>医案内容不够精准</view
></view
>
</view>
</view>
<view class="footer_box" v-if="options.taimedId == 1" style="height: 170rpx;">
<view style="color: #5188e5; padding-left: 10rpx; margin-bottom: 0rpx"
>您给出的评价是 :
</view>
<view style="display: flex; flex-direction: row">
<view class="footer_item" ></view>
<view class="footer_item" v-if="currentSelect=='A'">
<image src="/static/icon/a.png"></image>
<view
class="button savebutton"
style="background-color: #2bc66912; color: #2bc669"
>A
</view>
<view class="button_text" style="color: #2bc669"
>特别具有吴门意义</view
>
</view>
<view class="footer_item" v-if="currentSelect=='B'">
<image src="/static/icon/b.png"></image
><view
class="button"
style="background-color: #0099ff0f; color: #0099ff"
>B </view
><view class="button_text" style="color: #0099ff"
>不太具有吴门意义</view
></view
>
<view class="footer_item" v-if="currentSelect=='C'">
<image src="/static/icon/c.png"></image
><view
class="button"
style="background-color: #f2f1f6; color: #333333cf"
>C</view
><view class="button_text" style="color: #333333cf"
>医案内容不够精准</view
></view
>
<view class="footer_item" ></view>
</view>
</view>
</view>
<!-- <z-navigation></z-navigation> -->
<u-modal
:show="show"
@confirm="confirm"
@cancel="cancel"
ref="uModal"
:asyncClose="true"
:showCancelButton="true"
title="提示"
>
<view class="slot-content">
<rich-text :nodes="content"></rich-text>
</view>
</u-modal>
</view>
</template>
@@ -64,12 +130,16 @@ import $http from "@/config/requestConfig.js";
import { mapState, mapMutations } from "vuex";
import medicalDetail from "./medicalDetail.vue";
import qs from "qs";
import color from "uview-ui/libs/config/color";
export default {
components: {
medicalDetail,
},
data() {
return {
selectType: "",
content: "",
show: false,
options: {},
fileList1: [],
@@ -120,6 +190,7 @@ export default {
freeStatus: null,
flag: null,
scrollIntoView: "",
currentSelect: "",
recordData: {},
editableMap: {},
isRefreshing: false, //刷新状态
@@ -129,6 +200,8 @@ export default {
...mapState(["userInfo"]),
},
async onLoad(options) {
this.selectType = "";
this.show = false;
this.options = options;
this.medicalId = options.id;
if (this.options.type == "add") {
@@ -150,6 +223,10 @@ export default {
url: image, // 文件 URL
}));
}
if(this.medicalForm.stateInfo){
this.currentSelect = JSON.parse(this.medicalForm.stateInfo)[this.userInfo.id];
console.log('this.currentSelect at line 223:', this.currentSelect)
}
});
// this.tishi=true
@@ -209,6 +286,36 @@ export default {
}, 800);
},
methods: {
showModal(type) {
this.selectType = type;
var color = "";
var content = "";
switch (type) {
case "A":
color = "#2bc669";
content = "特别具有吴门意义";
break;
case "B":
color = "#0099ff";
content = "不太具有吴门意义";
break;
case "C":
color = "#333333cf";
content = "医案内容不够精准";
break;
}
this.content = `您确定选择 <span style="color:${color};font-size:20px;font-weight:bold;margin:0 4px">${type} </span> 吗?`;
this.show = true;
},
confirm() {
this.handleSubmit(this.selectType);
},
cancel() {
this.show = false;
},
//更新子组件内容
updateEditableMap(val) {
this.editableMap = val;
@@ -225,14 +332,13 @@ export default {
},
handleSubmit(type) {
this.$http
.request({
url: "common/medicalRecords/medicalRecordsCheck",
method: "POST",
data: {
"id":this.options.id,
"state":type
id: this.options.id,
state: type,
},
header: {
"Content-Type": "application/json",
@@ -241,16 +347,27 @@ export default {
.then((res) => {
if (res.code == 0) {
console.log("res.code at line 434:", res.code);
uni.redirectTo({
url: "/pages/medicalRecords/PendingApprovalIndex",
});
setTimeout(() => {
// 3秒后自动关闭
this.show = false;
}, 500);
uni.redirectTo({
url: "/pages/medicalRecords/PendingApprovalIndex",
});
} else {
setTimeout(() => {
// 3秒后自动关闭
this.show = false;
}, 500);
this.$commonJS.showToast(res.msg);
}
})
.catch((err) => {});
.catch((err) => {
setTimeout(() => {
// 3秒后自动关闭
this.show = false;
}, 500);
});
},
// 判断内容是否为空或无效
@@ -1605,23 +1722,22 @@ h3 {
flex: 1;
// display: flex;
// align-items: center;
image{
width: 80rpx;
height: 80rpx;
margin-right: -60rpx;
margin-left: 60rpx;
float: left;
image {
width: 80rpx;
height: 80rpx;
margin-right: -60rpx;
margin-left: 60rpx;
float: left;
}
.button_text{
.button_text {
position: relative;
font-size: 24rpx;
color: #666;
margin-top: 10rpx;
padding-left: 30rpx;
width: 100%;
display: inline-block;
text-align: center;
width: 100%;
display: inline-block;
text-align: center;
}
.button {
float: left;
@@ -1629,7 +1745,7 @@ float: left;
background-color: #f0f0f0;
// margin: auto auto;
margin-top: 10rpx;
padding-left:40rpx;
padding-left: 40rpx;
border-radius: 50px;
line-height: 36px;
height: 36px;