瀏覽代碼

优化质控记录列表

gaohaiyong 9 月之前
父節點
當前提交
3a591d376d
共有 2 個文件被更改,包括 340 次插入90 次删除
  1. 89 2
      src/views/allcase/caseControl.vue
  2. 251 88
      src/views/allcase/components/CaseQualityBox2.vue

+ 89 - 2
src/views/allcase/caseControl.vue

@@ -12,7 +12,88 @@ import CaseQualityBox from './components/CaseQualityBox2.vue';
     },
     data() {
       return {
-        data: {}
+        data: {
+        "score": 79,
+        "is_case": 1, // 质控状态,1质控中,2已质控
+        "quality_time": "2023-01-01 02:13:43",// 质控结果更新时间
+        "data": [{
+          "id": 9081016,
+          "BLBH": 0,
+          "rule_id": 109,
+          "notice": "有抗菌药,24小时内无病程记录",
+          "created_at": "2024-07-08 04:49:46",
+          "code": "kjy",
+          "error_field": "病程记录",
+          "JZHM": "756595",
+          "BRBH": "",
+          "basis": [
+            [
+              "抗菌药名称【头孢唑林钠】",
+              "开嘱时间【2022-10-28 09:10:16】",
+              "病程记录时间【无】"
+            ],
+            [
+              "抗菌药名称【克林霉素】",
+              "开嘱时间【2022-10-28 14:07:54】",
+              "病程记录时间【无】"
+            ]
+          ],
+          "is_ai": 1,
+          "ZKR": null,
+          "ZKKS": null,
+          "JSR": null,
+          "JSKS": null,
+          "ZGJB": null,
+          "ZGQX": null,
+          "updated_at": "2024-07-08 04:49:46",
+          "score": 1,
+          "category": "病程类",
+          "appeal_status": 1,// 1通过,2驳回
+          "reject_content": "拒绝理由" // 驳回原因
+        },
+        {
+          "id": 9081032,
+          "BLBH": 0,
+          "rule_id": 100,
+          "notice": "时间未精确到分钟",
+          "created_at": "2024-07-08 04:49:46",
+          "code": "rule_100",
+          "error_field": "整体",
+          "JZHM": "756595",
+          "BRBH": "",
+          "basis": [
+            [
+              "出院记录入院时间【2022-10-28】"
+            ],
+            [
+              "出院记录出院时间【2023-02-02】"
+            ]
+          ],
+          "is_ai": 1,
+          "ZKR": null,
+          "ZKKS": null,
+          "JSR": null,
+          "JSKS": null,
+          "ZGJB": null,
+          "ZGQX": null,
+          "updated_at": "2024-07-08 04:49:46",
+          "score": 0.5,
+          "category": "整体"
+        }
+        ],
+        "total": 14,
+        "summary": [
+          {
+            "category": "病程类",
+            "nums": 13
+          },
+          {
+            "category": "整体",
+            "nums": 1
+          }
+        ],
+        "run_score": 0
+      },
       }
     },
     created() {
@@ -27,7 +108,10 @@ import CaseQualityBox from './components/CaseQualityBox2.vue';
           id: Number(this.$route.query.id),
         };
         this.$axios2.post('/get_case_quality_v2', params).then(res => {
-          this.data = res.data;
+          this.$nextTick(() =>{
+            this.data = res.data;
+          })
+         
         });
       }
     }
@@ -35,4 +119,7 @@ import CaseQualityBox from './components/CaseQualityBox2.vue';
 </script>
 
 <style lang="scss" scoped>
+  .app-main{
+    height: 100% !important;
+  }
 </style>

+ 251 - 88
src/views/allcase/components/CaseQualityBox2.vue

@@ -9,78 +9,72 @@
     </div>
 
     <div class="card-box">
-      <el-row :gutter="20" style="margin-bottom: 16px;">
-        <el-col :span="12">
-          <div class="title">病历问题:<span class="error">{{ data.total }}</span></div>
-        </el-col>
-      </el-row>
-      <el-row :gutter="20">
-        <el-col :span="12" v-for="(item, index) of data.summary" :key="index">
-          <div class="title2" @click="onScroll(index)">{{ item.category }}:<span style="float: right;">({{ item.nums }})</span></div>
-        </el-col>
-      </el-row>
+      <div class="title">
+        <span class="font-size12">智能结果更新时间:</span>
+        <span class="font-size12">{{ data.quality_time }}</span>
+      </div>
+      <el-tag type="danger" v-if="data.is_case == 1" class="font-size12">质控中</el-tag>
+      <el-tag v-if="data.is_case == 2" class="font-size12">已质控</el-tag>
+      
     </div>   
+
+
     <el-scrollbar ref="scrollRef" class="scrollBox" :style="{'height': scrollHeight}">
-      <el-table
-        :data="tableData"
-        default-expand-all
-        :show-header="false"
-        style="width: 100%">
-        <el-table-column type="expand">
-          <template slot-scope="props">
-            <el-card v-for="(item, index) of props.row.children" :key="index" class="box-card" shadow="hover">
-              <el-image
-                class="typeImg"
-                v-if="item.is_ai"
-                :src="require('../../../assets/images/jiqiren.png')"
-                fit="contain">
+      <template v-for="(item, index) in tableData">
+        <div class="list-box box-card" :key="index" v-if="is_show">
+          <div class="list-score-tips-box">
+            <div class="list-left-score" :class=" item.level == 1 ? 'hover-1' : 'hover-2' ">
+              <div> {{ item.level == 1? '必改':'建议' }} </div>
+              <div>-{{ item.score }}</div>
+            </div>
+            <div class="list-right-tips">
+              <div><span class="font-size12 title-color">字段:</span><span class="font-size12">{{ item.category }}</span></div>
+              <div class="notice-box"><span class="font-size12 title-color">提示:</span><span class="font-size12">{{ item.notice }}</span></div>
+            </div>
+          </div>
+          <div class="list-basis-box">
+            <div class="list-basis-title" @click="clickListItem(index)">
+              <span>质控依据</span>
+              <span> >> </span>
+              <el-image class="typeImg" v-if="item.is_ai" :src="require('../../../assets/images/jiqiren.png')" fit="contain">
               </el-image>
-              <el-image
-                v-else
-                class="typeImg"
-                :src="require('../../../assets/images/kefu.png')"
-                fit="contain">
+              <el-image v-else class="typeImg" :src="require('../../../assets/images/kefu.png')" fit="contain">
               </el-image>
-              <el-row>
-                <el-col :span="24">
-                  <el-descriptions title="" :column="1" direction="vertical">
-                    <el-descriptions-item label="质控项目">
-                      <el-tag class="category">{{ item.error_field }}</el-tag>
-                      <el-tag type="danger" class="koufen">-{{ item.score }}分</el-tag>
-                    </el-descriptions-item>
-                    <el-descriptions-item label="错误描述">{{ item.notice }}</el-descriptions-item>
-                    <el-descriptions-item label="质控依据">
-                      <div v-for="(yItem, yIndex) of item.basis" :key="yIndex" style="margin-bottom: 10px;">
-                        <div v-if="item.rule_id !== 6">
-                          <span class="span-index">{{ yIndex+1 }}</span>
-                          <span v-if="item.category=='入院记录'">
-                            <span v-for="(cItem, cIndex) of yItem" :key="cIndex" @click="hightRight(cItem,292,item.JZHM)">{{ cItem }}</span>
-                          </span>
-                          <span v-else>
-                            <span v-for="(cItem, cIndex) of yItem" :key="cIndex">{{ cItem }}</span>
-                          </span>
-                        </div>
-                        <div v-else>
-                          <span class="span-index">1</span>
-                          <span>{{ yItem[0] }}</span>
-                        </div>
-                      </div>
-                    </el-descriptions-item>
-                  </el-descriptions>
-                  
-                </el-col>
-              </el-row>
-            </el-card>
-          </template>
-        </el-table-column>
-        <el-table-column
-          label=""
-          prop="">
-          <template slot-scope="scope">
-            <div :class="`category${scope.$index}`">{{ scope.row.category }}</div>
-          </template>
-        </el-table-column>
-      </el-table>
+            </div>
+            <div class="list-basis-text" :class="item.show?'show':''">
+              <div v-for="(yItem, yIndex) of item.basis" :key="yIndex" style="margin-bottom: 10px;">
+                <div v-if="item.rule_id !== 6">
+                  <span class="span-index">{{ yIndex+1 }}</span>
+                  <span v-if="item.category=='入院记录'">
+                    <span v-for="(cItem, cIndex) of yItem" :key="cIndex" @click="hightRight(cItem,292,item.JZHM)">{{ cItem }}</span>
+                  </span>
+                  <span v-else>
+                    <span v-for="(cItem, cIndex) of yItem" :key="cIndex">{{ cItem }}</span>
+                  </span>
+                </div>
+                <div v-else>
+                  <span class="span-index">1</span>
+                  <span style="font-size: 13px;">{{ yItem[0] }}</span>
+                </div>
+              </div>
+              <div class="list-basis-bottom-box">
+                <div class="list-basis-bottom-tips">
+                  <el-tooltip class="appeal-status-box" effect="dark" :content="item.reject_content" placement="top">
+                    <el-button type="primary" class="appeal-status-1" v-if="item.appeal_status == 1">通过</el-button>
+                    <el-button type="danger" class="appeal-status-2"  v-if="item.appeal_status == 2">驳回</el-button>
+                  </el-tooltip>
+                </div>
+                <div class="list-basis-bottom-btn">
+                  <el-button type="primary" @click="clickAppeal( item,2 )">申诉</el-button>
+                  <el-button @click="clickAppeal( item,1 )">忽略</el-button>
+                </div>
+              </div>
+            </div>
+            
+          </div>
+          
+        </div>
+      </template>
     </el-scrollbar>
   </div>
 </div>
@@ -117,19 +111,13 @@
         }
       }
     },
+    data(){
+      return {
+        tableData: [],
+        is_show: true
+      }
+    },
     computed: {
-      tableData() {
-        let arr = []
-        const keys = Object.keys(this.data.data)
-        for(let i=0; i<keys.length; i++) {
-          let obj = {
-            category: keys[i],
-            children: this.data.data[keys[i]]
-          }
-          arr.push(obj)
-        }
-        return arr
-      },
       scoreLevel() {
         /**
          * 甲>90分
@@ -156,7 +144,19 @@
         return `calc(100vh - 375px)`
       }
     },
+    created(){
+      this.getTableData();
+    },
     methods: {
+      getTableData(){
+        let data = this.data.data;
+        for(let i=0; i<data.length; i++) {
+          data[i].show = false;
+        }
+        data[0].show = true;
+        this.tableData = data;
+        console.log(this.tableData)
+      },
       onScroll(index) {
         const el = this.$el.querySelector(`.category${index}`);
         const node = el.parentNode.parentNode.parentNode
@@ -164,6 +164,43 @@
       },
       hightRight(hightKeyWord, bllb, zyh) {
         this.$emit('hightRight',hightKeyWord,bllb,zyh)
+      },
+      clickListItem(idx){
+        let tableData = this.tableData;
+        tableData[idx].show = !tableData[idx].show;
+        this.is_show = false;
+        this.$nextTick( () =>{
+          this.tableData = tableData; 
+          this.is_show = true;
+        })
+        console.log(tableData)
+
+      },
+      // 点击申诉、忽略按钮
+      clickAppeal(i,type){
+        let that = this;
+        let item = i;
+        let params = {
+          id: item.id, // 质控错误结果的数据ID
+          zyh: item.zyh,
+          type: type,
+          quality_type: item.quality_type,
+          appeal_document: item.appeal_document, //申诉科室名称
+          appeal_docter: item.appeal_docter,  // 申诉医生名称
+        }
+        that.$axios2.post('/appeal', params).then(res => {
+          if(res.code == 200){
+            that.$message({
+              type: 'success',
+              message: res.msg
+            });
+          }else{
+            that.$message({
+              type: 'error',
+              message: res.msg
+            });
+          }
+        })
       }
     }
   }
@@ -225,21 +262,34 @@
   }
   .card-box {
     // height: 175px;
-    background: #FFFFFF;
-    border: 1px solid #E2E2E2;
-    padding: 16px 20px;
+    // background: #FFFFFF;
+    // border: 1px solid #E2E2E2;
+    background: #f1f5fe;
+    padding: 10px;
     box-sizing: border-box;
     margin-bottom: 14px;
+    display: flex;
+    align-items: center;
+    justify-content: space-between;
     .title {
-      font-size: 15px;
+      font-size: 12px;
       font-family: PingFang-SC-Bold, PingFang-SC;
-      font-weight: bold;
+      // font-weight: bold;
       color: #333333;
       line-height: 22px;
       // span {
       //   margin-left: 7px;
       // }
     }
+    .card-icon-btn{
+      width: auto;
+      padding: 4px 8px;
+      border-radius: 4px;
+      background: rgb(254, 240, 240);
+      color: rgb(245, 128, 140);
+      border: 1px solid rgb(245, 128, 140);
+      font-size: 10px;
+    }
     .title2 {
       font-size: 14px;
       font-family: PingFang-SC-Bold, PingFang-SC;
@@ -312,9 +362,9 @@
   }
 }
 .span-index{
-  width: 24px;
-  height: 24px;
-  line-height: 24px;
+  width: 20px;
+  height: 20px;
+  line-height: 20px;
   text-align: center;
   display: inline-block;
   border-radius: 50%;
@@ -322,9 +372,122 @@
   color: #fff;
   margin-right: 10px;
   margin-bottom: 4px;
+  font-size: 12px;
 }
 
 ::v-deep .el-table .el-table__row td {
   color: #fff;
 }
+::v-deep .el-tag{
+  height: auto;
+  line-height: 22px;
+}
+// =================   2024-07-27 新样式  ↓  ===============
+.font-size12{
+  font-size: 12px;
+}
+.list-box{
+  width: 100%;
+  padding: 10px;
+  .title-color{
+    color: rgba(27,100,176,1);
+    font-weight: bold;
+  }
+  .list-score-tips-box{
+    width: 100%;
+    display: flex;
+    .list-left-score{
+      width: 70px;
+      display: flex;
+      flex-direction: column;
+      align-items: center;
+      justify-content: center;
+      font-size: 14px;
+      font-weight: bold;
+      padding: 20px 0;
+      &.hover-1{
+        background: rgb(254, 240, 240);
+        color: rgb(238, 14, 14);
+        border-right: 2px solid rgb(238, 14, 14);
+      }
+      &.hover-2{
+        background: rgb(236, 245, 255);
+        color: rgb(52, 140, 235);
+        border-right: 2px solid rgb(52, 140, 235);
+      }
+    }
+    .list-right-tips{
+      flex: 1;
+      font-size: 12px;
+      padding-left: 10px;
+      .notice-box{
+        margin-top: 8px;
+      }
+    }
+  }
+  .list-basis-box{
+    .list-basis-title{
+      padding: 10px 0;
+      position: relative;
+      &>span{
+        font-size: 12px;
+        color: rgba(27,100,176,1);
+        font-weight: bold;
+      }
+      .typeImg {
+        width: 34px;
+        height: 34px;
+        position: absolute;
+        top: 0;
+        right: 0;
+        z-index: 999;
+      }
+      
+    }
+    .list-basis-text{
+      height: 0;
+      overflow: hidden;
+      position: relative;
+      &.show{
+        height: auto;
+        padding: 10px 0 10px 10px;
+      }
+      
+    }
+    .list-basis-bottom-box{
+      margin-top: 14px;
+      width: 100%;
+      display: flex;
+      align-items: center;
+      justify-content: space-between;
+      .list-basis-bottom-tips{
+        flex: 1;
+        &::v-deep .el-button{
+          padding: 0;
+          font-size: 12px;
+          width: 40px;
+          height: 40px;
+          border-radius: 50%;
+          &>span{
+            font-size: 12px;
+          }
+        }
+      }
+      .list-basis-bottom-btn{
+        width: auto;
+        &::v-deep .el-button{
+          padding: 6px 14px;
+        }
+        &::v-deep .el-button--primary,&::v-deep .el-button--primary:focus,&::v-deep .el-button--primary:hover{
+          background: #185DA6;
+          border-color: #185DA6;
+        }
+      }
+    }
+
+    
+
+  }
+}
+
 </style>