Browse Source

Merge branch 'vue_statistics_branch' of http://git.shengws.com/csx/Vue_New into vue_statistics_branch

XMLWAN 4 years ago
parent
commit
d542ecf8bd

+ 2 - 2
src/router/modules/qcd.js View File

7
   name: "qcd",
7
   name: "qcd",
8
   alwaysShow: true,
8
   alwaysShow: true,
9
   meta: {
9
   meta: {
10
-    title: "科室质控",
10
+    title: "质控管理",
11
     icon: "statistics"
11
     icon: "statistics"
12
   },
12
   },
13
   children: [
13
   children: [
244
       component: () => import("@/xt_pages/qcd/workAnalysis/doctor"),
244
       component: () => import("@/xt_pages/qcd/workAnalysis/doctor"),
245
       name: "workAnalysisDoctor",
245
       name: "workAnalysisDoctor",
246
       meta: {
246
       meta: {
247
-        title: "工作量分析统计医生",
247
+        title: "工作量分析统计",
248
         noCache: true
248
         noCache: true
249
       }
249
       }
250
     },
250
     },

+ 32 - 5
src/xt_pages/dialysis/batch_print/batch_print_order_thirteen.vue View File

32
                     血液净化治疗记录单
32
                     血液净化治疗记录单
33
                     </div>
33
                     </div>
34
                 </div>
34
                 </div>
35
-                <div class="row">
35
+                <div class="row" style="display:flex;justify-content: space-between;">
36
                     <div class="inline_block" style="margin-right:30px;">
36
                     <div class="inline_block" style="margin-right:30px;">
37
                         日期 <div class="inline_block under_line" style="width:50px">{{ getTime(record.schedule_date, "{y}") }}</div>年
37
                         日期 <div class="inline_block under_line" style="width:50px">{{ getTime(record.schedule_date, "{y}") }}</div>年
38
                         <div class="inline_block under_line" style="width:50px">{{ getTime(record.schedule_date, "{m}") }}</div>月
38
                         <div class="inline_block under_line" style="width:50px">{{ getTime(record.schedule_date, "{m}") }}</div>月
41
                     <div class="inline_block" style="margin-right:30px;">
41
                     <div class="inline_block" style="margin-right:30px;">
42
                         机器编号 
42
                         机器编号 
43
                         <div class="inline_block under_line" style="width:80px;">
43
                         <div class="inline_block under_line" style="width:80px;">
44
-                        {{ record.device_zone.name && record.device_number.number ? record.device_zone.name + record.device_number.number : '' }}
44
+                          {{ record.device_zone.name && record.device_number.number ? getNewNumber(record.device_zone.name,record.device_number.number) : '' }}
45
+                        <!-- {{ record.device_zone.name && record.device_number.number ? record.device_zone.name + record.device_number.number : '' }} -->
45
                         </div>
46
                         </div>
46
                     </div>
47
                     </div>
47
                     <div class="inline_block" style="margin-right:30px;">
48
                     <div class="inline_block" style="margin-right:30px;">
64
                     <div class="inline_block" style="margin-right:30px;">
65
                     <div class="inline_block" style="margin-right:30px;">
65
                         年龄:
66
                         年龄:
66
                         <div class="under_line" style="width: 50px;text-align: center">
67
                         <div class="under_line" style="width: 50px;text-align: center">
67
-                            {{ getAge(record.patient) }}
68
+                            {{ getNewAge(record.patient.id_card_no) }}
68
                         </div>
69
                         </div>
69
70
70
                     </div>
71
                     </div>
112
                     抗凝药物 
113
                     抗凝药物 
113
                     <div class="inline_block under_line" style="width:93%;text-align: left;">
114
                     <div class="inline_block under_line" style="width:93%;text-align: left;">
114
                     <label-box :isChecked="record.prescription.anticoagulant == 2 ? true : false" showValue="普通肝素"></label-box>&nbsp;
115
                     <label-box :isChecked="record.prescription.anticoagulant == 2 ? true : false" showValue="普通肝素"></label-box>&nbsp;
115
-                    <label-box :isChecked="record.prescription.anticoagulant == 6 ? true : record.prescription.anticoagulant == 7 ? true : false" showValue="低分子肝素"></label-box>
116
+                    <label-box :isChecked="record.prescription.anticoagulant == 3 ?  true : record.prescription.anticoagulant == 6 ? true : record.prescription.anticoagulant == 7 ? true : false" showValue="低分子肝素"></label-box>
116
                     (<label-box :isChecked="record.prescription.anticoagulant == 6 ? true : false" showValue="钙"></label-box>
117
                     (<label-box :isChecked="record.prescription.anticoagulant == 6 ? true : false" showValue="钙"></label-box>
117
                         <label-box :isChecked="record.prescription.anticoagulant == 7 ? true : false" showValue="钠"></label-box>)
118
                         <label-box :isChecked="record.prescription.anticoagulant == 7 ? true : false" showValue="钠"></label-box>)
118
                     <div class="inline_block">
119
                     <div class="inline_block">
336
                         <td>&nbsp;{{monitor.dialysate_temperature ? monitor.dialysate_temperature : ''}}</td>
337
                         <td>&nbsp;{{monitor.dialysate_temperature ? monitor.dialysate_temperature : ''}}</td>
337
                         <td>&nbsp;
338
                         <td>&nbsp;
338
                             <span v-if="monitor.operate_time">
339
                             <span v-if="monitor.operate_time">
339
-                                {{ record.assessment_before_dislysis.dialysate_flow ? record.assessment_before_dislysis.dialysate_flow : "" }}
340
+                                {{ record.prescription.dialysate_flow ? record.prescription.dialysate_flow : "" }}
340
                             </span>
341
                             </span>
341
                         </td>
342
                         </td>
342
                         <td>&nbsp;{{monitor.ultrafiltration_volume?monitor.ultrafiltration_volume:''}}</td>
343
                         <td>&nbsp;{{monitor.ultrafiltration_volume?monitor.ultrafiltration_volume:''}}</td>
720
       });
721
       });
721
   },
722
   },
722
   methods: {
723
   methods: {
724
+    getNewNumber(name,number){
725
+      if(name.indexOf("区") > -1){
726
+          return (
727
+            name + number
728
+          );
729
+        } else {
730
+          return (
731
+            name + "区" + number
732
+            
733
+          );
734
+        }
735
+    },
736
+    getNewAge(UUserCard) {
737
+      if (UUserCard != null && UUserCard != '') {
738
+        //获取年龄
739
+        var myDate = new Date();
740
+        var month = myDate.getMonth() + 1;
741
+        var day = myDate.getDate();
742
+        var age = myDate.getFullYear() - UUserCard.substring(6, 10) - 1;
743
+        if (UUserCard.substring(10, 12) < month || UUserCard.substring(10, 12) == month && UUserCard.substring(12, 14) <= day) {
744
+        age++;
745
+        }
746
+        return age;
747
+      }
748
+    },
723
     getIsCheckDataConfig(pName, cName, targetName){
749
     getIsCheckDataConfig(pName, cName, targetName){
724
         var arr = getDataConfig(pName,cName)
750
         var arr = getDataConfig(pName,cName)
751
+        console.log(arr)
725
         for (let i = 0; i < arr.length; i++){
752
         for (let i = 0; i < arr.length; i++){
726
             if (arr[i].name == targetName){
753
             if (arr[i].name == targetName){
727
             return arr[i].id
754
             return arr[i].id

+ 37 - 28
src/xt_pages/qcd/treatmentControlAnalysis/components/CheckAll.vue View File

66
           :key="index"
66
           :key="index"
67
         >
67
         >
68
           <template slot-scope="scope">
68
           <template slot-scope="scope">
69
-              {{ scope.row.data[1].Count}}
69
+              {{ scope.row.data[index].Count}}
70
           </template>
70
           </template>
71
         </el-table-column>
71
         </el-table-column>
72
         </el-table>
72
         </el-table>
109
     };
109
     };
110
   },
110
   },
111
   methods: {
111
   methods: {
112
+    handleDelete(index, row) {
113
+        console.log(index, row);
114
+      },
112
     changeTime(val) {
115
     changeTime(val) {
113
       var time = this.getTimestamp(val) - this.getTimestamp(this.listQuery.end_time);
116
       var time = this.getTimestamp(val) - this.getTimestamp(this.listQuery.end_time);
114
       if (time > 0) {
117
       if (time > 0) {
122
       SearchDetailCheck(this.listQuery.search,this.listQuery.start_time,this.listQuery.end_time).then(response=>{
125
       SearchDetailCheck(this.listQuery.search,this.listQuery.start_time,this.listQuery.end_time).then(response=>{
123
           if(response.data.state === 1){
126
           if(response.data.state === 1){
124
            var  checkDetail =  response.data.data.checkDetail
127
            var  checkDetail =  response.data.data.checkDetail
125
-           console.log("checkDetail",checkDetail)
126
              var arr = []
128
              var arr = []
127
             for(let i=0;i<checkDetail.length;i++){
129
             for(let i=0;i<checkDetail.length;i++){
128
               for(let j=0;j<this.tableName.length;j++){
130
               for(let j=0;j<this.tableName.length;j++){
168
         if(response.data.state === 1){
170
         if(response.data.state === 1){
169
            var inspection = response.data.data.inspection
171
            var inspection = response.data.data.inspection
170
            console.log("inspection",inspection)
172
            console.log("inspection",inspection)
171
-           var a=[1];
173
+           var a=[];
172
            for(let i=0;i<inspection.length;i++){
174
            for(let i=0;i<inspection.length;i++){
173
              a.push(inspection[i])
175
              a.push(inspection[i])
174
            }
176
            }
175
            console.log("a",a)
177
            console.log("a",a)
178
+           this.newArr = a
176
            var arr = this.arrayToObj(a)
179
            var arr = this.arrayToObj(a)
177
-
178
-           console.log("arrtwo",arr)
180
+           
181
+           console.log("arr",arr)
179
            this.ObjectData = arr
182
            this.ObjectData = arr
180
            this.tableName = inspection
183
            this.tableName = inspection
181
         }
184
         }
240
 
243
 
241
 
244
 
242
           var list = response.data.data.list
245
           var list = response.data.data.list
243
-           console.log("list",list)
244
-            var dtd = []
245
-            for(let i=0;i<list.length;i++){
246
-                for(let j=0;j<this.tableName.length;j++){
247
-                    if(list[i].ProjectId == this.tableName[j].inspection_major){
248
-                      dtd.push(list[i])
249
-                    }
250
-                }
251
-            }
252
-           console.log("dtd",dtd)
246
+          console.log("list",list)
247
+          var dtd = []
248
+          for(let i=0;i<list.length;i++){
249
+              for(let j=0;j<this.tableName.length;j++){
250
+                  if(list[i].ProjectId == this.tableName[j].inspection_major){
251
+                    dtd.push(list[i])
252
+                  }
253
+              }
254
+          }
255
+          console.log("dtd",dtd)
253
           var dd = {};
256
           var dd = {};
254
            for (const index in dtd) {
257
            for (const index in dtd) {
255
             if (!(dtd[index].name in dd)) {
258
             if (!(dtd[index].name in dd)) {
256
                dd[dtd[index].name] = {};
259
                dd[dtd[index].name] = {};
257
             }
260
             }
258
             if (!(dtd[index].ProjectId in dd[dtd[index].name]) && dtd[index].ProjectId != 0) {
261
             if (!(dtd[index].ProjectId in dd[dtd[index].name]) && dtd[index].ProjectId != 0) {
259
-              dd[dtd[index].name][dtd[index].ProjectId] = dtd[index];
262
+              dd[dtd[index].name][dtd[index].ProjectName] = dtd[index];
260
             }
263
             }
261
           }
264
           }
262
-
263
-           for(const key in dd){
265
+          console.log("ddd",dd)
266
+            for(const key in dd){
264
               for(const mkey in this.ObjectData){
267
               for(const mkey in this.ObjectData){
265
-               if (mkey in dd[key]) {
266
-                    dd[key][mkey].ProjectName = this.ObjectData[mkey].project_name;
267
-                    var Count = parseInt(dd[key][mkey].Count);
268
-                    console.log("Count",Count)
269
-
270
-                }else{
271
-                   dd[key][mkey] = {
268
+                if (!(this.ObjectData[mkey].project_name in dd[key])) {
269
+                  dd[key][this.ObjectData[mkey].project_name] = {
272
                     ProjectName: this.ObjectData[mkey].project_name,
270
                     ProjectName: this.ObjectData[mkey].project_name,
273
                     name: mkey,
271
                     name: mkey,
274
-                   Count: 0
272
+                    Count: 0
275
                   };
273
                   };
276
                 }
274
                 }
277
-             }
278
-             this.tableData.push({ name: key, data: dd[key]});
275
+              }
276
+              this.tableData.push({ name: key, data: dd[key]});
279
             }
277
             }
280
             console.log("表",this.tableData)
278
             console.log("表",this.tableData)
279
+            let projectArr = []
280
+            this.newArr.map(item => {
281
+              projectArr.push(item.project_name)
282
+            })
283
+            this.tableData.map(item => {
284
+              let arr = Object.values(item.data);
285
+              arr.sort((a,b)=>{
286
+                return projectArr.indexOf(a.ProjectName)-projectArr.indexOf(b.ProjectName);
287
+              });
288
+              item.data = arr
289
+            })
281
          }
290
          }
282
       })
291
       })
283
     },
292
     },

+ 0 - 1
src/xt_pages/qcd/treatmentControlAnalysis/components/CheckPersonal.vue View File

114
                   if(this.obj.length > 0){
114
                   if(this.obj.length > 0){
115
                       let str = ''
115
                       let str = ''
116
                       str = params.data +'次' + '\n(参考值'+ this.obj[params.dataIndex] +'次)'
116
                       str = params.data +'次' + '\n(参考值'+ this.obj[params.dataIndex] +'次)'
117
-                      console.log(str)
118
                     return str
117
                     return str
119
                   }else{
118
                   }else{
120
                     let str = ''
119
                     let str = ''