yuwandanmian 2 yıl önce
ebeveyn
işleme
19e6b03830

+ 5 - 5
src/layout/components/AppMain.vue

@@ -10,16 +10,16 @@
 <script>
 export default {
   name: 'AppMain',
-  // data() {
-  //   return {
-  //   pages:["Dashboard"]
-  //   }
-  // },
   computed: {
     key() {
       return this.$route.path;
     },
   },
+  beforeDestroy() {
+    setToken('');
+    sessionStorage.removeItem("route")
+    this.$router.push(`/login`);
+  }
 };
 </script>
 

+ 84 - 47
src/views/allcase/caseIndex.vue

@@ -5,7 +5,16 @@
       <el-col :span="8">
         <div class="box_wrapper">
           <el-input placeholder="输入关键字进行过滤" v-model="filterText"></el-input>
-          <el-tree class="filter-tree" node-key="id" highlight-current :data="menus" :props="defaultProps" :filter-node-method="filterNode" ref="tree" @node-click="handleNodeClick"></el-tree>
+          <el-tree
+            class="filter-tree"
+            node-key="id"
+            highlight-current
+            :data="menuList"
+            :props="defaultProps"
+            :filter-node-method="filterNode"
+            ref="tree"
+            @node-click="handleNodeClick"
+          ></el-tree>
         </div>
       </el-col>
       <!-- 右侧列表 -->
@@ -13,10 +22,19 @@
         <div class="box_wrapper">
           <el-form :inline="true" :model="formInline" class="demo-form-inline">
             <el-form-item label="查询时间">
-              <el-date-picker v-model="formInline.year" :clearable="false" type="year" :picker-options="pickerOptions" format="yyyy年" value-format="yyyy" placeholder="选择年份"></el-date-picker>
+              <el-date-picker
+                v-model="formInline.year"
+                :clearable="false"
+                type="year"
+                :picker-options="pickerOptions"
+                format="yyyy年"
+                value-format="yyyy"
+                placeholder="选择年份"
+              ></el-date-picker>
             </el-form-item>
             <el-form-item>
               <el-button type="primary" @click="onSearch">查询</el-button>
+              <el-button v-if="$route.query.type === 'children'" type="text" @click="onBack">返回</el-button>
             </el-form-item>
           </el-form>
           <el-table :data="tableData" style="width: 100%">
@@ -450,6 +468,22 @@ export default {
           ],
         },
       ],
+      cMenus: [
+        {
+          id: 34,
+          name: '指标十、细菌培养检查记录符合率(子)',
+          children: [
+            {
+              id: 341,
+              name: '细菌培养检查的医嘱、报告单、病程记录相对应的住院患者病历数',
+            },
+            {
+              id: 3432,
+              name: '同期开展细菌培养检查的住院患者病历总数',
+            },
+          ],
+        },
+      ],
       formInline: {
         year: '',
       },
@@ -457,56 +491,60 @@ export default {
       filterText: '',
       defaultProps: {
         children: 'children',
-        label: 'name'
+        label: 'name',
       },
       ruleId: '',
       ruleName: '',
       time: new Date(),
       pickerOptions: {
         disabledDate(time) {
-           const date = new Date()
-           const year = date.getFullYear();
-           const timeYear = time.getFullYear();
-           return year < timeYear
-        }
-      }
+          const date = new Date();
+          const year = date.getFullYear();
+          const timeYear = time.getFullYear();
+          return year < timeYear;
+        },
+      },
     };
   },
   computed: {
     // 判断是取分子还是分母
     judgeNum() {
-      const str = `${this.ruleId}`
-      const length = str.length
-      const lastNum = str[length - 1]
+      const str = `${this.ruleId}`;
+      const length = str.length;
+      const lastNum = str[length - 1];
       if (Number(lastNum) > 1) {
         // 分母
-        return 'denominator'
+        return 'denominator';
       } else {
         // 分子
-        return 'numerator'
+        return 'numerator';
       }
+    },
+    menuList() {
+      return this.$route.query.type === 'children' ? this.cMenus : this.menus
     }
   },
   watch: {
     filterText(val) {
       this.$refs.tree.filter(val);
     },
-    // $route(to, from) {
-    //   console.log(to.path, from.path)
-    //   if (from.path !== '/caseIndexList') {
-    //     console.log(1111)
-    //     this.$router.go(0)
-    //     console.log(1111)
-    //   } else {
-    //     console.log(2222)
-    //   }
-    // }
+    $route(to, from) {
+      if (to.query.type === 'children' || from.query.type === 'children') {
+      }
+      // if (from.path == '/caseIndexList' && from.query.ruleId == 33) {
+      //   this.$router.go(0)
+      // }
+    },
   },
   methods: {
+    // 返回
+    onBack() {
+      this.$router.go(-1)
+    },
     // 病案指标列表跳转
     toCaseIndexPage(row) {
-      const { time } = row
-      this.$router.push({ path: '/caseIndexList', query: { time, ruleId: Number(`${this.ruleId}`.slice(0, 2)), type: this.judgeNum} })
+      const { time } = row;
+      this.$router.push({ path: '/caseIndexList', query: { time, ruleId: Number(`${this.ruleId}`.slice(0, 2)), type: this.judgeNum } });
     },
     // 菜单筛选
     filterNode(value, data) {
@@ -514,53 +552,52 @@ export default {
       return data.name.indexOf(value) !== -1;
     },
     handleNodeClick(data) {
-      const { id, name } = data
-      this.ruleId = id
-      this.ruleName = name
-      if (id>10 && this.formInline.year) {
-        this.getList()
+      const { id, name } = data;
+      this.ruleId = id;
+      this.ruleName = name;
+      if (id > 10 && this.formInline.year) {
+        this.getList();
       }
     },
     // 获取右侧列表数据
     getList() {
-      const { year } = this.formInline
+      const { year } = this.formInline;
       const params = {
         start_time: `${year}0101`,
         end_time: `${year}1231`,
         year,
-        type: Number(`${this.ruleId}`.slice(0, 2))
-      }
+        type: Number(`${this.ruleId}`.slice(0, 2)),
+      };
       this.$axios2.post('/get_assessment_indicators', params).then(res => {
         if (Array.isArray(res.data)) {
           res.data.map(item => {
-            item.name = this.ruleName
-          })
-          this.tableData = res.data
+            item.name = this.ruleName;
+          });
+          this.tableData = res.data;
         } else {
-          this.tableData = []
+          this.tableData = [];
         }
-      })
+      });
     },
     // 查询
     onSearch() {
-      const { year } = this.formInline
+      const { year } = this.formInline;
       if (!year) {
-        this.$message.error('请选择查询时间')
-        return
+        this.$message.error('请选择查询时间');
+        return;
       }
       if (!this.ruleId) {
-        this.$message.error('请选择查询指标')
-        return
+        this.$message.error('请选择查询指标');
+        return;
       }
-      this.getList()
+      this.getList();
     },
   },
 };
 </script>
 
 <style lang="scss" scoped>
-
-.link{
+.link {
   font-weight: 600;
   color: #409eff;
   cursor: pointer;

+ 4 - 0
src/views/allcase/caseIndexList.vue

@@ -31,6 +31,7 @@
           </el-form-item>
         </el-form>
         <div class="btn-box">
+          <el-button v-if="$route.query.ruleId == 33" @click="toChildrenCase">子指标</el-button>
           <el-button type="primary">导出Excel</el-button>
           <el-button @click="toBack">返回</el-button>
         </div>
@@ -121,6 +122,9 @@ export default {
     this.getDepartmentList()
   },
   methods: {
+    toChildrenCase() {
+      this.$router.push({ path: '/caseIndex', query: { type: 'children' }})
+    },
     getDepartmentList() {
       this.$axios.post("/selectInfo").then((res) => {
         // 不要全部选项

+ 11 - 1
src/views/allcase/contFile/mainHomePage.vue

@@ -1369,7 +1369,17 @@ export default {
   },
   methods: {
     jump() {
-      this.$router.push(`/ChargeDetails?MED_REC_ID=${this.data.MED_REC_ID}`);
+      // this.$router.push(`/ChargeDetails?MED_REC_ID=${this.data.MED_REC_ID}`);
+      
+      const { path } = this.$route
+      let toPath
+      if (['/hospital-caseViews', '/hospital-details'].includes(path)) {
+        toPath = '/hospital-chargeDetails'
+      } else {
+        toPath = '/ChargeDetails'
+      }
+      // status = 1 代表不能复制文本
+      this.$router.push({ path: toPath, query: { MED_REC_ID: this.data.MED_REC_ID }})
     },
     getBlankIndex(item) {
       if(item.error_field=='AAA11'||item.error_field=='AAA10'||item.error_field=='AAA09'){

+ 1 - 1
src/views/data/query/ChargeDetails.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="dashboard-container">
     <div class="tableBox">
-      <Title :title="'病案列表'" />
+      <Title :title="'费用明细'" />
       <el-table :data="tableData" style="width: 100%">
         <el-table-column type="index" label="序号"></el-table-column>
         <el-table-column prop="FYXH" label="费用序号"></el-table-column>

+ 1 - 1
src/views/data/query/details.vue

@@ -1409,7 +1409,7 @@ export default {
     jump() {
       const { path } = this.$route
       let toPath
-      if (path === '/hospital-details') {
+      if (['/hospital-caseViews', '/hospital-details'].includes(path)) {
         toPath = '/hospital-chargeDetails'
       } else {
         toPath = '/ChargeDetails'