Browse Source

8月15日

XMLWAN 2 years ago
parent
commit
67c34ced46

+ 8 - 0
src/api/dialysis.js View File

387
     params: params
387
     params: params
388
   })
388
   })
389
 }
389
 }
390
+
391
+export function getSolutionlistByOrgId(params) {
392
+  return request({
393
+    url: '/api/patient/getsolutionlistbyorgid',
394
+    method: 'get',
395
+    params: params
396
+  })
397
+}

+ 7 - 8
src/router/modules/dialysis.js View File

131
       is_menu: false,
131
       is_menu: false,
132
       hidden: true
132
       hidden: true
133
     },
133
     },
134
-
135
-    // {
136
-    //   path: '/dialysis/consumable/dialysis/print',
137
-    //   component: () => import('@/xt_pages/dialysis/details/consumable/signPrint'),
138
-    //   name: '标签打印',
139
-    //   is_menu: false,
140
-    //   hidden: true
141
-    // },
134
+    {
135
+      path: '/dialysis/consumable/dialysis/print',
136
+      component: () => import('@/xt_pages/dialysis/details/consumable/signPrint'),
137
+      name: '标签打印',
138
+      is_menu: false,
139
+      hidden: true
140
+    },
142
     {
141
     {
143
       path: '/dialysis/consumable/dialysis/parameter/print',
142
       path: '/dialysis/consumable/dialysis/parameter/print',
144
       component: () => import('@/xt_pages/dialysis/details/consumable/dialysisParameterPrint'),
143
       component: () => import('@/xt_pages/dialysis/details/consumable/dialysisParameterPrint'),

+ 92 - 34
src/xt_pages/dialysis/details/consumable/dialysisDrug.vue View File

20
                       :editable="false" :clearable="false" style="width: 196px;margin-right:10px;" type="date"
20
                       :editable="false" :clearable="false" style="width: 196px;margin-right:10px;" type="date"
21
                       format="yyyy-MM-dd"
21
                       format="yyyy-MM-dd"
22
                       value-format="yyyy-MM-dd"
22
                       value-format="yyyy-MM-dd"
23
-                      placeholder="选择日期时间" align="right"></el-date-picker>
23
+                      placeholder="选择日期时间" align="right"
24
+                     :picker-options="pickerOptions"></el-date-picker>
24
       <el-input size="small" style="width: 180px;" @keyup.enter.native='searchAction' v-model.trim="search_input"
25
       <el-input size="small" style="width: 180px;" @keyup.enter.native='searchAction' v-model.trim="search_input"
25
                 class="filter-item" v-model="query.keywords"/>
26
                 class="filter-item" v-model="query.keywords"/>
26
       <el-button size="small" class="filter-item" type="primary" icon="el-icon-search" @click="search">搜索</el-button>
27
       <el-button size="small" class="filter-item" type="primary" icon="el-icon-search" @click="search">搜索</el-button>
43
       </div>
44
       </div>
44
       <div>
45
       <div>
45
         <el-button size="small" type="primary" @click="statistics">统计表</el-button>
46
         <el-button size="small" type="primary" @click="statistics">统计表</el-button>
46
-        <el-button size="small" icon="el-icon-printer" @click="exportList" type="primary">导出</el-button>
47
-        <el-button size="small" icon="el-icon-printer" @click="toPrint" type="primary">打印</el-button>
47
+        <el-button size="small"  @click="exportList" type="primary">导出</el-button>
48
+        <el-button size="small" icon="el-icon-printer"  @click="toPrint" type="primary">打印</el-button>
48
       </div>
49
       </div>
49
     </div>
50
     </div>
50
   
51
   
72
 
73
 
73
         <el-table-column label="透析机号" align="center" width="55">
74
         <el-table-column label="透析机号" align="center" width="55">
74
            <template slot-scope="scope">
75
            <template slot-scope="scope">
75
-              {{scope.row.device_number.number}}
76
+              {{scope.row.device_number.zone.name}}  {{scope.row.device_number.number}}
76
            </template>
77
            </template>
77
         </el-table-column>
78
         </el-table-column>
78
 
79
 
137
               :value="item.id">
138
               :value="item.id">
138
             </el-option>
139
             </el-option>
139
            </el-select>
140
            </el-select>
140
-           <el-button size="small" icon="el-icon-printer" @click="toPrintOne" type="primary">打印</el-button>
141
-           <el-button size="small" icon="el-icon-printer" @click="toExportListOne" type="primary">导出</el-button>
141
+           <el-button size="small" icon="el-icon-printer"  @click="toPrintOne" type="primary">打印</el-button>
142
+           <el-button size="small"  @click="toExportListOne" type="primary">导出</el-button>
142
         </div> 
143
         </div> 
143
 
144
 
144
        <el-table
145
        <el-table
168
        
169
        
169
         <el-table-column  align="center"   label="数量">
170
         <el-table-column  align="center"   label="数量">
170
            <template slot-scope="scope">
171
            <template slot-scope="scope">
171
-              {{getCount(scope.row.child)}}
172
+             <span v-if="config.is_open!=1">{{getCount(scope.row.child)}}</span>
173
+             <span v-if="config.is_open ==1">{{getHisCount(scope.row.child,scope.row.max_unit,scope.row.min_unit,scope.row.min_number)}}</span>
172
            </template>
174
            </template>
173
         </el-table-column>
175
         </el-table-column>
174
         
176
         
250
         tableList:[],
252
         tableList:[],
251
         config:{},
253
         config:{},
252
         ids:"",
254
         ids:"",
255
+        pickerOptions:{ //禁用当前日期之前的日期
256
+           disabledDate(v) {
257
+            //Date.now()是javascript中的内置函数,它返回自1970年1月1日00:00:00 UTC以来经过的毫秒数。
258
+            return v.getTime() < new Date().getTime() - 86400000;
259
+          },
260
+        },
253
       }
261
       }
254
     },
262
     },
255
     created() {
263
     created() {
284
             this.total = response.data.data.total
292
             this.total = response.data.data.total
285
             var adviceList = response.data.data.adviceList
293
             var adviceList = response.data.data.adviceList
286
             this.adviceList = adviceList
294
             this.adviceList = adviceList
287
-            // var templateList = response.data.data.templateList
295
+          
288
             var druglist = response.data.data.drugList
296
             var druglist = response.data.data.drugList
289
-            // for(let i=0;i<templateList.length;i++){
290
-            //   templateList[i].advice_desc = ""
291
-            //  for(let j=0;j<druglist.length;j++){
292
-            //    if(templateList[i].drug_id == druglist[j].id){
293
-            //      templateList[i].advice_desc = druglist[j].dose + druglist[j].dose_unit +"*"+druglist[j].min_unit +druglist[j].min_number+"/"+druglist[j].max_unit
294
-            //    }
295
-            //  }
296
-            // }
297
-            // console.log("医嘱模版",templateList)
298
-            // this.templateList = templateList
297
+          
299
            
298
            
300
             this.config = response.data.data.config
299
             this.config = response.data.data.config
301
              
300
              
318
                }
317
                }
319
              }
318
              }
320
             console.log("hisArr223323323223",hisArr)
319
             console.log("hisArr223323323223",hisArr)
320
+            var newHisArr = []
321
             for(let i=0;i<hisArr.length;i++){
321
             for(let i=0;i<hisArr.length;i++){
322
-              hisArr[i].advice_desc = ""
322
+              for(let j=0;j<druglist.length;j++){
323
+                if(hisArr[i].drug_id == druglist[j].id){
324
+                   newHisArr.push(hisArr[i])
325
+                }
326
+              }
327
+            }
328
+            for(let i=0;i<newHisArr.length;i++){
329
+              newHisArr[i].advice_desc = ""
323
              for(let j=0;j<druglist.length;j++){
330
              for(let j=0;j<druglist.length;j++){
324
-               if(hisArr[i].drug_id == druglist[j].id){
325
-                 hisArr[i].advice_desc = druglist[j].dose + druglist[j].dose_unit +"*" +druglist[j].min_number+ druglist[j].min_unit +"/"+druglist[j].max_unit
331
+               if(newHisArr[i].drug_id == druglist[j].id){
332
+                 newHisArr[i].advice_desc = druglist[j].dose + druglist[j].dose_unit +"*" +druglist[j].min_number+ druglist[j].min_unit +"/"+druglist[j].max_unit
326
                }
333
                }
327
              }
334
              }
328
             }
335
             }
329
-            this.templateList = hisArr
336
+            this.templateList = newHisArr
330
           }
337
           }
331
         })
338
         })
332
       },
339
       },
439
                       child: [],
446
                       child: [],
440
                       count:0,
447
                       count:0,
441
                       drug_id:item.drug_id,
448
                       drug_id:item.drug_id,
442
-                      specification_name:item.advice_desc,
449
+                      specification_name:item.advice_desc +item.drug_spec_unit,
443
                       patient_id:item.patient_id,
450
                       patient_id:item.patient_id,
444
                     }
451
                     }
445
                   }
452
                   }
471
            
478
            
472
 
479
 
473
 
480
 
474
-             var templateList = response.data.data.templateList
475
-             console.log("templatelist",templateList)
481
+             
476
              var tablelist =  response.data.data.tablelist
482
              var tablelist =  response.data.data.tablelist
477
              console.log("tablelist233232232",tablelist)
483
              console.log("tablelist233232232",tablelist)
478
              var hisArr= []
484
              var hisArr= []
492
                  }
498
                  }
493
                }
499
                }
494
              }
500
              }
495
-             console.log("hisArr223323323223",hisArr)
501
+            //  console.log("下盘子3223323223",hisArr)
502
+          
503
+            var newHisArr = []
504
+            for(let i=0;i<hisArr.length;i++){
505
+               hisArr[i].count_one = 0
506
+              for(let j=0;j<druglist.length;j++){
507
+                 if(hisArr[i].prescribing_number_unit == hisArr[i].drug.max_unit){
508
+                    hisArr[i].prescribing_number = parseInt(hisArr[i].prescribing_number) * hisArr[i].drug.min_number
509
+                    hisArr[i].count_one =  parseInt(hisArr[i].prescribing_number) * hisArr[i].drug.min_number
510
+                 }
511
+                if(hisArr[i].drug_id == druglist[j].id){
512
+                   newHisArr.push(hisArr[i])
513
+                }
514
+              }
515
+            }
516
+            console.log("下盘子3223323223",newHisArr)
517
+            
496
              if(config.is_open == 1){
518
              if(config.is_open == 1){
497
-               if(hisArr!=null && hisArr.length > 0){
519
+               if(newHisArr!=null && newHisArr.length > 0){
498
                   let dataInfoOne = {}
520
                   let dataInfoOne = {}
499
-                  hisArr.forEach((item, index) => {
521
+                  newHisArr.forEach((item, index) => {
500
                   let { advice_name } = item
522
                   let { advice_name } = item
501
                   if (!dataInfoOne[advice_name]) {
523
                   if (!dataInfoOne[advice_name]) {
502
                     dataInfoOne[advice_name] = {
524
                     dataInfoOne[advice_name] = {
506
                       specification_name:this.getSpecification(item.drug_id),
528
                       specification_name:this.getSpecification(item.drug_id),
507
                       drug_id:item.drug_id,
529
                       drug_id:item.drug_id,
508
                       patient_id:item.patient_id,
530
                       patient_id:item.patient_id,
531
+                      min_number:item.drug.min_number,
532
+                      max_unit:item.drug.max_unit,
533
+                      min_unit:item.drug.min_unit
509
                     }
534
                     }
510
                   }
535
                   }
511
                 })
536
                 })
512
                 let hisarr = Object.values(dataInfoOne)
537
                 let hisarr = Object.values(dataInfoOne)
513
                 console.log("hisarr233232233232",hisarr)
538
                 console.log("hisarr233232233232",hisarr)
514
                 if(hisarr.length > 0){
539
                 if(hisarr.length > 0){
515
-                  for(let i=0;i<hisArr.length;i++){
540
+                  for(let i=0;i<newHisArr.length;i++){
516
                     for(let j=0;j<hisarr.length;j++){
541
                     for(let j=0;j<hisarr.length;j++){
517
-                      if(hisArr[i].drug_id == hisarr[j].drug_id){
518
-                          hisarr[j].child.push(hisArr[i])
542
+                      if(newHisArr[i].drug_id == hisarr[j].drug_id){
543
+                          hisarr[j].child.push(newHisArr[i])
519
                       }
544
                       }
520
                     }
545
                     }
521
                   }
546
                   }
530
                   }
555
                   }
531
                 }
556
                 }
532
               }
557
               }
558
+
559
+              console.log("中国人民解放军",this.tableList)
533
              }
560
              }
534
      
561
      
535
            
562
            
554
           if(this.list!=null && this.list.length > 0){
581
           if(this.list!=null && this.list.length > 0){
555
             for(let i=0;i<this.list.length;i++){
582
             for(let i=0;i<this.list.length;i++){
556
               this.list[i].index = i+1
583
               this.list[i].index = i+1
557
-              this.list[i].number = this.list[i].device_number.number
584
+              this.list[i].number =this.list[i].device_number.zone.name + this.list[i].device_number.number
558
               this.list[i].patient_name = this.list[i].patient.name
585
               this.list[i].patient_name = this.list[i].patient.name
559
               this.list[i].dialysis_no = this.list[i].patient.dialysis_no
586
               this.list[i].dialysis_no = this.list[i].patient.dialysis_no
560
               if(this.config.is_open != 1){
587
               if(this.config.is_open != 1){
583
           if(this.tableList!=null && this.tableList.length > 0){
610
           if(this.tableList!=null && this.tableList.length > 0){
584
             for(let i=0;i<this.tableList.length;i++){
611
             for(let i=0;i<this.tableList.length;i++){
585
               this.tableList[i].index = i+1
612
               this.tableList[i].index = i+1
586
-              this.tableList[i].total_count = this.getCount(this.tableList[i].child)
613
+              if(this.config.is_open == 1){
614
+                this.tableList[i].total_count = this.getHisCount(this.tableList[i].child,this.tableList[i].max_unit,this.tableList[i].min_unit,this.tableList[i].min_number)
615
+              }
616
+              if(this.config.is_open!=1){
617
+                this.tableList[i].total_count = this.getCount(this.tableList[i].child)
618
+              }
619
+             
587
             }
620
             }
588
           }
621
           }
589
           const tHeader = ['序号','药品名称','规格','数量']
622
           const tHeader = ['序号','药品名称','规格','数量']
614
         }
647
         }
615
         if(newArr!=null && newArr.length > 0){
648
         if(newArr!=null && newArr.length > 0){
616
           for(let i=0;i<newArr.length;i++){
649
           for(let i=0;i<newArr.length;i++){
617
-            his_str += newArr[i].advice_name +' '+newArr[i].advice_desc +' '+ newArr[i].prescribing_number +' '+newArr[i].prescribing_number_unit + "。"
650
+            his_str += newArr[i].advice_name +' '+newArr[i].advice_desc  +newArr[i].drug_spec_unit +' ' +newArr[i].prescribing_number  +newArr[i].prescribing_number_unit + "。"
618
           }
651
           }
619
         }
652
         }
620
         return his_str
653
         return his_str
655
        }else{
688
        }else{
656
         return 0
689
         return 0
657
        }
690
        }
691
+      },
692
+      getHisCount(val,max_unit,min_unit,min_number){
693
+        var total = 0
694
+        var max_str = "";
695
+        var min_str = "";
696
+        for(let i=0;i<val.length;i++){
697
+          total+=parseInt(val[i].prescribing_number)
698
+        }
699
+        if (total < min_number) {
700
+        min_str = total + min_unit;
701
+      }
702
+      if (total == 0) {
703
+        min_str = "";
704
+        max_str = "";
705
+      }
706
+      if (total >= min_number) {
707
+        if (parseInt(total / min_number) != 0) {
708
+          max_str = parseInt(total / min_number) + max_unit;
709
+        }
710
+        if (total % min_number != 0) {
711
+          min_str = (total % min_number) + min_unit;
712
+        }
713
+      }
714
+      return max_str + min_str;
715
+        
658
       },
716
       },
659
       handleSelectionChange(val){
717
       handleSelectionChange(val){
660
         var arr = []
718
         var arr = []

+ 78 - 56
src/xt_pages/dialysis/details/consumable/dialysisGood.vue View File

44
       </div>
44
       </div>
45
       <div>
45
       <div>
46
         <el-button size="small" icon="el-icon-printer" @click="toSett" type="primary" v-if="his_config.is_open == 1">设置</el-button>
46
         <el-button size="small" icon="el-icon-printer" @click="toSett" type="primary" v-if="his_config.is_open == 1">设置</el-button>
47
+        <el-button size="small" icon="el-icon-printer" @click="toClick" type="primary">脚本</el-button>
47
         <el-button size="small" icon="el-icon-printer" @click="toPrint" type="primary">打印</el-button>
48
         <el-button size="small" icon="el-icon-printer" @click="toPrint" type="primary">打印</el-button>
48
-        <el-button size="small" icon="el-icon-printer" @click="exportListOne" type="primary" v-if="his_config.is_open == 1">导出</el-button>
49
-        <el-button size="small" icon="el-icon-printer" @click="exportList" type="primary" v-if="his_config.is_open != 1">导出</el-button>
49
+        <el-button size="small"  @click="exportListOne" type="primary" v-if="his_config.is_open == 1">导出</el-button>
50
+        <el-button size="small" @click="exportList" type="primary" v-if="his_config.is_open != 1">导出</el-button>
50
         <el-button size="small" type="primary" v-if="his_config.is_open != 1" @click="statistics">统计表</el-button>
51
         <el-button size="small" type="primary" v-if="his_config.is_open != 1" @click="statistics">统计表</el-button>
51
         <el-button size="small" type="primary" v-if="his_config.is_open == 1" @click="toStatistics">统计表</el-button>
52
         <el-button size="small" type="primary" v-if="his_config.is_open == 1" @click="toStatistics">统计表</el-button>
52
       </div>
53
       </div>
73
              {{scope.$index + 1}}
74
              {{scope.$index + 1}}
74
            </template>
75
            </template>
75
         </el-table-column>
76
         </el-table-column>
76
-        <el-table-column  align="center"  width="55" label="透析机号">
77
+        <el-table-column  align="center"  width="100" label="透析机号">
77
          <template slot-scope="scope">
78
          <template slot-scope="scope">
78
-             {{scope.row.device_number.number}}
79
+             {{scope.row.device_number.zone.name}}  {{scope.row.device_number.number}}
79
            </template>
80
            </template>
80
         </el-table-column>
81
         </el-table-column>
81
         <el-table-column  align="center"  width="55" label="姓名">
82
         <el-table-column  align="center"  width="55" label="姓名">
146
              {{scope.$index + 1}}
147
              {{scope.$index + 1}}
147
            </template>
148
            </template>
148
         </el-table-column>
149
         </el-table-column>
149
-        <el-table-column  align="center"  width="55" label="透析机号">
150
+        <el-table-column  align="center"  width="100" label="透析机号">
150
          <template slot-scope="scope">
151
          <template slot-scope="scope">
151
-             {{scope.row.device_number.number}}
152
+             {{scope.row.device_number.zone.name}}  {{scope.row.device_number.number}}
152
            </template>
153
            </template>
153
         </el-table-column>
154
         </el-table-column>
154
         <el-table-column  align="center"  width="55" label="姓名">
155
         <el-table-column  align="center"  width="55" label="姓名">
182
 
183
 
183
       <el-pagination
184
       <el-pagination
184
         @size-change="handleSizeChangeOne"
185
         @size-change="handleSizeChangeOne"
185
-        @current-change="handleSizeChangeOne"
186
+        @current-change="handleCurrentChangeOne"
186
         :page-sizes="[10, 50, 100]"
187
         :page-sizes="[10, 50, 100]"
187
         :page-size="10"
188
         :page-size="10"
188
         background
189
         background
220
             </el-option>
221
             </el-option>
221
            </el-select>
222
            </el-select>
222
 
223
 
223
-         <el-button size="small" icon="el-icon-printer" @click="toPrintOne" type="primary">打印</el-button>
224
-         <el-button size="small" icon="el-icon-printer" @click="toExportListOne" type="primary">导出</el-button>
224
+         <el-button size="small" icon="el-icon-printer"  @click="toPrintOne" type="primary">打印</el-button>
225
+         <el-button size="small"  @click="toExportListOne" type="primary">导出</el-button>
225
         </div> 
226
         </div> 
226
        <el-table
227
        <el-table
227
         :data="tableList"
228
         :data="tableList"
328
             </el-option>
329
             </el-option>
329
            </el-select>
330
            </el-select>
330
            <el-button size="small" icon="el-icon-printer" @click="toHisPrint" type="primary">打印</el-button>
331
            <el-button size="small" icon="el-icon-printer" @click="toHisPrint" type="primary">打印</el-button>
331
-           <el-button size="small" icon="el-icon-printer" @click="toExportListTwo" type="primary">导出</el-button>
332
+           <el-button size="small"  @click="toExportListTwo" type="primary">导出</el-button>
332
         </div> 
333
         </div> 
333
        <el-table
334
        <el-table
334
         :data="tableList"
335
         :data="tableList"
376
 
377
 
377
 
378
 
378
 <script>
379
 <script>
379
-  import { GetAllZone,getPatientDialysisSolutionGroupList,getDialysisGoodTotalCount,saveHisDialysis,getHisDialysisGoodCount } from '@/api/dialysis'
380
+  import { GetAllZone,getPatientDialysisSolutionGroupList,getDialysisGoodTotalCount,saveHisDialysis,getHisDialysisGoodCount,getSolutionlistByOrgId } from '@/api/dialysis'
380
  import {GetAllGoodType} from '@/api/stock'
381
  import {GetAllGoodType} from '@/api/stock'
381
   import { uParseTime } from "@/utils/tools";
382
   import { uParseTime } from "@/utils/tools";
382
   import { getDataConfig } from '@/utils/data'
383
   import { getDataConfig } from '@/utils/data'
472
         checkedTwentyNight:false,
473
         checkedTwentyNight:false,
473
         startHisDialogVisible:false,
474
         startHisDialogVisible:false,
474
         typeList:[],
475
         typeList:[],
475
-        ids:""
476
+        ids:"",
477
+        org_id:0,
476
       }
478
       }
477
     },
479
     },
478
     created() {
480
     created() {
481
+      this.org_id = this.$store.getters.xt_user.org.id
479
       let date = uParseTime(new Date(), "{y}-{m}-{d}")
482
       let date = uParseTime(new Date(), "{y}-{m}-{d}")
480
       var newDate = new Date();
483
       var newDate = new Date();
481
       var y = newDate.getFullYear();
484
       var y = newDate.getFullYear();
541
         if(this.list!=null && this.list.length > 0){
544
         if(this.list!=null && this.list.length > 0){
542
           for(let i=0;i<this.list.length;i++){
545
           for(let i=0;i<this.list.length;i++){
543
             this.list[i].name0 = i+1
546
             this.list[i].name0 = i+1
544
-            this.list[i].name1= this.list[i].device_number.number
547
+            this.list[i].name1= this.list[i].device_number.zone.name + this.list[i].device_number.number
545
             this.list[i].name2 = this.list[i].patient.name
548
             this.list[i].name2 = this.list[i].patient.name
546
             this.list[i].name3 = this.list[i].patient.dialysis_no
549
             this.list[i].name3 = this.list[i].patient.dialysis_no
547
             if(this.rowList!=null && this.rowList.length > 0){
550
             if(this.rowList!=null && this.rowList.length > 0){
588
         //  console.log("arrTwo",arrTwo)
591
         //  console.log("arrTwo",arrTwo)
589
          const tHeader = arr
592
          const tHeader = arr
590
         const filterVal = arrTwo
593
         const filterVal = arrTwo
591
-        
594
+        console.log("list23323223wo",this.list)
592
         if(this.list!=null && this.list.length > 0){
595
         if(this.list!=null && this.list.length > 0){
593
           for(let i=0;i<this.list.length;i++){
596
           for(let i=0;i<this.list.length;i++){
594
             this.list[i].name0 = i+1
597
             this.list[i].name0 = i+1
595
-            this.list[i].name1= this.list[i].device_number.number
598
+            this.list[i].name1= this.list[i].device_number.zone.name + this.list[i].device_number.number
596
             this.list[i].name2 = this.list[i].patient.name
599
             this.list[i].name2 = this.list[i].patient.name
597
             this.list[i].name3 = this.list[i].patient.dialysis_no
600
             this.list[i].name3 = this.list[i].patient.dialysis_no
598
             if(this.typeList!=null && this.typeList.length > 0){
601
             if(this.typeList!=null && this.typeList.length > 0){
603
          
606
          
604
           }
607
           }
605
         }
608
         }
606
-        // console.log("list32232232323wi",this.list)
609
+
610
+        console.log("list32232232323wi",this.list)
611
+      
607
         const data = this.formatJson(filterVal, this.list)
612
         const data = this.formatJson(filterVal, this.list)
608
          excel.export_json_to_excel({
613
          excel.export_json_to_excel({
609
            header: tHeader,
614
            header: tHeader,
624
         return obj;
629
         return obj;
625
       },
630
       },
626
       open(){
631
       open(){
632
+        this.rowList = []
633
+        var filedList = this.$store.getters.xt_user.fileds
634
+        for (let i = 0; i < filedList.length; i++) {
635
+          if ( filedList[i].module == 1 && filedList[i].is_show == 1 && (filedList[i].filed_name_cn == '透析器/灌流器' || filedList[i].filed_name_cn == '透析器' || filedList[i].filed_name_cn == '灌流器'  || filedList[i].filed_name_cn == '钾' || filedList[i].filed_name_cn == '钠' || filedList[i].filed_name_cn == '钙' || filedList[i].filed_name_cn == '葡萄糖'  || filedList[i].filed_name_cn == '穿刺针')) {
636
+            this.rowList.push(filedList[i])
637
+          }
638
+        }
627
        this.getlist()
639
        this.getlist()
628
       },
640
       },
629
       getlist(){
641
       getlist(){
630
-        //  console.log("paramsy2332322323",this.query)
631
         getPatientDialysisSolutionGroupList(this.query).then(response=>{
642
         getPatientDialysisSolutionGroupList(this.query).then(response=>{
632
            if(response.data.state == 1){
643
            if(response.data.state == 1){
633
              var list = response.data.data.list
644
              var list = response.data.data.list
672
                    }
683
                    }
673
                    
684
                    
674
                  }
685
                  }
675
-                // console.log("list列表",list)
676
                  this.list = list 
686
                  this.list = list 
677
                }
687
                }
678
              }
688
              }
807
                   calciumArr.push(list[i].dialysis_solution)
817
                   calciumArr.push(list[i].dialysis_solution)
808
                 }
818
                 }
809
 
819
 
810
-                if(list[i].dialysis_solution!=null&&list[i].dialysis_solution.glucose > 0){
811
-                  list[i].dialysis_solution.specification_three = "葡萄糖" + list[i].dialysis_solution.glucose
820
+                if(list[i].dialysis_solution!=null&&list[i].dialysis_solution.amylaceum !=0){
821
+                  list[i].dialysis_solution.specification_three = "葡萄糖" + list[i].dialysis_solution.amylaceum
812
                   glucoseArr.push(list[i].dialysis_solution)
822
                   glucoseArr.push(list[i].dialysis_solution)
813
                 }
823
                 }
814
               
824
               
816
               }
826
               }
817
             }
827
             }
818
 
828
 
819
-            console.log("kaliumArr",kaliumArr)
829
+            console.log("glucoseArr",glucoseArr)
820
             if(kaliumArr!=null && kaliumArr.length > 0){
830
             if(kaliumArr!=null && kaliumArr.length > 0){
821
               let dataInfo = {}
831
               let dataInfo = {}
822
               kaliumArr.forEach((item, index) => {
832
               kaliumArr.forEach((item, index) => {
843
             }
853
             }
844
 
854
 
845
             for(let i=0;i<newArr.length;i++){
855
             for(let i=0;i<newArr.length;i++){
846
-              for(let j=0;j<newArr[i].child.length;j++){
847
-                newArr[i].count += newArr[i].child[j].kalium
848
-              }
856
+               newArr[i].count = newArr[i].child.length
849
             }
857
             }
850
            
858
            
851
             console.log("newArr",newArr)
859
             console.log("newArr",newArr)
882
             }
890
             }
883
 
891
 
884
             for(let i=0;i<newArr.length;i++){
892
             for(let i=0;i<newArr.length;i++){
885
-              for(let j=0;j<newArr[i].child.length;j++){
886
-                newArr[i].count += newArr[i].child[j].sodium
887
-              }
893
+             newArr[i].count += newArr[i].child.length
894
+              
888
             }
895
             }
889
            
896
            
890
             console.log("newArr",newArr)
897
             console.log("newArr",newArr)
920
             }
927
             }
921
 
928
 
922
             for(let i=0;i<newArr.length;i++){
929
             for(let i=0;i<newArr.length;i++){
923
-              for(let j=0;j<newArr[i].child.length;j++){
924
-                newArr[i].count += newArr[i].child[j].calcium
925
-              }
930
+              newArr[i].count = newArr[i].child.length
931
+              
926
             }
932
             }
927
            
933
            
928
             console.log("newArr",newArr)
934
             console.log("newArr",newArr)
939
               let { specification_three } = item
945
               let { specification_three } = item
940
               if (!dataInfo[specification_three]) {
946
               if (!dataInfo[specification_three]) {
941
                 dataInfo[specification_three] = {
947
                 dataInfo[specification_three] = {
942
-                  name:"钠(mmol/L)",
948
+                  name:"葡萄糖",
943
                   specification_three:item.specification_three,
949
                   specification_three:item.specification_three,
944
-                  specification_name:item.glucose,
950
+                  specification_name:item.amylaceum,
945
                   child: [],
951
                   child: [],
946
                   count:0,
952
                   count:0,
947
                 }
953
                 }
959
             }
965
             }
960
 
966
 
961
             for(let i=0;i<newArr.length;i++){
967
             for(let i=0;i<newArr.length;i++){
962
-              for(let j=0;j<newArr[i].child.length;j++){
963
-                newArr[i].count += newArr[i].child[j].glucose
964
-              }
968
+             newArr[i].count += newArr[i].child.length
969
+              
965
             }
970
             }
966
            
971
            
967
             console.log("newArr",newArr)
972
             console.log("newArr",newArr)
1184
           
1189
           
1185
         }
1190
         }
1186
         if(filed_name_cn == "目标超滤量"){
1191
         if(filed_name_cn == "目标超滤量"){
1187
-          return val.target_ultrafiltration
1192
+
1193
+          return val.target_ultrafiltration?val.target_ultrafiltration:""
1188
         }
1194
         }
1189
         if(filed_name_cn == "透析液配方"){
1195
         if(filed_name_cn == "透析液配方"){
1190
           return this.getDialysateFormulation(val.dialysate_formulation)
1196
           return this.getDialysateFormulation(val.dialysate_formulation)
1193
           return this.getAnticoagulant(val.anticoagulant)
1199
           return this.getAnticoagulant(val.anticoagulant)
1194
         }
1200
         }
1195
         if(filed_name_cn == "首剂"){
1201
         if(filed_name_cn == "首剂"){
1196
-          return val.anticoagulant_shouji
1202
+          return val.anticoagulant_shouji?val.anticoagulant_shouji:""
1197
         }
1203
         }
1198
         if(filed_name_cn == "维持"){
1204
         if(filed_name_cn == "维持"){
1199
-          return val.anticoagulant_weichi
1205
+          return val.anticoagulant_weichi?val.anticoagulant_weichi:""
1200
         }
1206
         }
1201
         if(filed_name_cn == "总量"){
1207
         if(filed_name_cn == "总量"){
1202
-          return val.anticoagulant_zongliang
1208
+          return val.anticoagulant_zongliang?val.anticoagulant_zongliang:""
1203
         }
1209
         }
1204
         if(filed_name_cn == "置换量"){
1210
         if(filed_name_cn == "置换量"){
1205
-           return val.replacement_total
1211
+           return val.replacement_total?val.replacement_total:""
1206
         }
1212
         }
1207
         if(filed_name_cn == "钾"){
1213
         if(filed_name_cn == "钾"){
1208
-          return val.kalium
1214
+          return val.kalium?val.kalium:""
1209
         }
1215
         }
1210
         if(filed_name_cn == "钠"){
1216
         if(filed_name_cn == "钠"){
1211
-           return val.sodium
1217
+           return val.sodium?val.sodium:""
1212
         }
1218
         }
1213
         if(filed_name_cn == "钙"){
1219
         if(filed_name_cn == "钙"){
1214
-           return val.calcium
1220
+           return val.calcium?val.calcium:""
1215
         }
1221
         }
1216
         if(filed_name_cn == "碳酸氢盐"){
1222
         if(filed_name_cn == "碳酸氢盐"){
1217
-           return val.bicarbonate
1223
+           return val.bicarbonate?val.bicarbonate:""
1218
         }
1224
         }
1219
         if(filed_name_cn == "透析液流量"){
1225
         if(filed_name_cn == "透析液流量"){
1220
-            return val.dialysate_flow
1226
+            return val.dialysate_flow?val.dialysate_flow:""
1221
         }
1227
         }
1222
         if(filed_name_cn == "透析液温度"){
1228
         if(filed_name_cn == "透析液温度"){
1223
-           return val.dialysate_temperature
1229
+           return val.dialysate_temperature?val.dialysate_temperature:""
1224
         }
1230
         }
1225
         if(filed_name_cn == "电导度"){
1231
         if(filed_name_cn == "电导度"){
1226
-           return val.conductivity
1232
+           return val.conductivity?val.conductivity:""
1227
         }
1233
         }
1228
         if(filed_name_cn == "透析器/灌流器"){
1234
         if(filed_name_cn == "透析器/灌流器"){
1229
            return val.dialyzer_perfusion_apparatus
1235
            return val.dialyzer_perfusion_apparatus
1230
         }
1236
         }
1231
         if(filed_name_cn == "钙名称"){
1237
         if(filed_name_cn == "钙名称"){
1232
-          return val.anticoagulant_gaimingcheng
1238
+          return val.anticoagulant_gaimingcheng?val.anticoagulant_gaimingcheng:""
1233
         }
1239
         }
1234
        if(filed_name_cn == "钙剂量"){
1240
        if(filed_name_cn == "钙剂量"){
1235
-           return val.anticoagulant_gaijiliang
1241
+           return val.anticoagulant_gaijiliang?val.anticoagulant_gaijiliang:""
1236
         }
1242
         }
1237
        if(filed_name_cn == "体液过多症状"){
1243
        if(filed_name_cn == "体液过多症状"){
1238
           return this.getBodyFluid(val.body_fluid)
1244
           return this.getBodyFluid(val.body_fluid)
1256
           return   val.dialysis_duration_hour + "小时" + val.dialysis_duration_minute + "分钟"
1262
           return   val.dialysis_duration_hour + "小时" + val.dialysis_duration_minute + "分钟"
1257
         }
1263
         }
1258
         if(filed_name_cn == "置换液总量"){
1264
         if(filed_name_cn == "置换液总量"){
1259
-         return val.displace_liqui_value
1265
+         return val.displace_liqui_value?val.displace_liqui_value:""
1260
         }
1266
         }
1261
         if(filed_name_cn == "透析器"){
1267
         if(filed_name_cn == "透析器"){
1262
           return val.dialysis_dialyszers
1268
           return val.dialysis_dialyszers
1292
           return ""
1298
           return ""
1293
         }
1299
         }
1294
         if(filed_name_cn == "葡萄糖"){
1300
         if(filed_name_cn == "葡萄糖"){
1295
-           return val.glucose
1301
+           return val.amylaceum?val.amylaceum:""
1296
         }
1302
         }
1297
         if(filed_name_cn == "单超时长"){
1303
         if(filed_name_cn == "单超时长"){
1298
            return  ""
1304
            return  ""
1304
           return  ""
1310
           return  ""
1305
         }
1311
         }
1306
         if(filed_name_cn == "血浆分离器"){
1312
         if(filed_name_cn == "血浆分离器"){
1307
-           return val.plasma_separator
1313
+           return val.plasma_separator?val.plasma_separator:""
1308
         }
1314
         }
1309
        if(filed_name_cn == "透析管路"){
1315
        if(filed_name_cn == "透析管路"){
1310
           return this.getHemodialysisPipelines(val.hemodialysis_pipelines)
1316
           return this.getHemodialysisPipelines(val.hemodialysis_pipelines)
1313
           return ""
1319
           return ""
1314
         }
1320
         }
1315
        if(filed_name_cn == "穿刺针"){
1321
        if(filed_name_cn == "穿刺针"){
1316
-          return val.puncture_needle
1322
+          return val.puncture_needle?val.puncture_needle:""
1317
         }
1323
         }
1318
       //  if(filed_name_cn == "穿刺针支数"){
1324
       //  if(filed_name_cn == "穿刺针支数"){
1319
       //     return val.puncture_needle_count
1325
       //     return val.puncture_needle_count
1320
       //   }
1326
       //   }
1321
        if(filed_name_cn == "促红素"){
1327
        if(filed_name_cn == "促红素"){
1322
-          return val.epo_count
1328
+          return val.epo_count?val.epo_count:""
1323
         }
1329
         }
1324
         if(filed_name_cn == "促红素支数"){
1330
         if(filed_name_cn == "促红素支数"){
1325
-          return val.epo_count
1331
+          return val.epo_count?val.epo_count:""
1326
         }
1332
         }
1327
         if(filed_name_cn == "最大超滤率"){
1333
         if(filed_name_cn == "最大超滤率"){
1328
-          return val.max_ultrafiltration_rate
1334
+          return val.max_ultrafiltration_rate?val.max_ultrafiltration_rate:""
1329
         }
1335
         }
1330
       },
1336
       },
1331
       getModeName(id){
1337
       getModeName(id){
2040
        this.tableList = []
2046
        this.tableList = []
2041
        this.toStatistics()
2047
        this.toStatistics()
2042
      }
2048
      }
2049
+    },
2050
+    toClick(){
2051
+      const loading = this.$loading({
2052
+          lock: true,
2053
+          text: 'Loading',
2054
+          spinner: 'el-icon-loading',
2055
+          background: 'rgba(0, 0, 0, 0.7)'
2056
+       })
2057
+      getSolutionlistByOrgId().then(response=>{
2058
+        if(response.data.state == 1){
2059
+          var list =  response.data.data.list
2060
+          console.log("list23322323",list)
2061
+          loading.close()
2062
+          this.$message.success("更新成功!")
2063
+        }
2064
+      })
2043
     }
2065
     }
2044
    }
2066
    }
2045
   }
2067
   }

+ 121 - 130
src/xt_pages/dialysis/details/consumable/dialysisParameter.vue View File

20
                       :editable="false" :clearable="false" style="width: 196px;margin-right:10px;" type="date"
20
                       :editable="false" :clearable="false" style="width: 196px;margin-right:10px;" type="date"
21
                       format="yyyy-MM-dd"
21
                       format="yyyy-MM-dd"
22
                       value-format="yyyy-MM-dd"
22
                       value-format="yyyy-MM-dd"
23
-                      placeholder="选择日期时间" align="right"></el-date-picker>
23
+                      placeholder="选择日期时间" align="right"
24
+                      :picker-options="pickerOptions"></el-date-picker>
24
       <el-input size="small" style="width: 180px;" @keyup.enter.native='searchAction' v-model.trim="search_input"
25
       <el-input size="small" style="width: 180px;" @keyup.enter.native='searchAction' v-model.trim="search_input"
25
                 class="filter-item" v-model="query.keywords"/>
26
                 class="filter-item" v-model="query.keywords"/>
26
       <el-button size="small" class="filter-item" type="primary" icon="el-icon-search" @click="search">搜索</el-button>
27
       <el-button size="small" class="filter-item" type="primary" icon="el-icon-search" @click="search">搜索</el-button>
46
         <el-button size="small" icon="el-icon-printer" @click="toSign" type="primary">标签打印</el-button>
47
         <el-button size="small" icon="el-icon-printer" @click="toSign" type="primary">标签打印</el-button>
47
         <el-button size="small" icon="el-icon-printer" @click="printAction" type="primary">标签打印设置</el-button>
48
         <el-button size="small" icon="el-icon-printer" @click="printAction" type="primary">标签打印设置</el-button>
48
         
49
         
49
-        <el-button size="small" icon="el-icon-printer" @click="exportList" type="primary">导出</el-button>
50
-        <el-button size="small" icon="el-icon-printer" @click="toPrint" type="primary">打印</el-button>
50
+        <el-button size="small"  @click="exportList" type="primary">导出</el-button>
51
+        <el-button size="small"  @click="toPrint" icon="el-icon-printer" type="primary">打印</el-button>
51
         <el-button size="small" type="primary" @click="statistics">统计表</el-button>
52
         <el-button size="small" type="primary" @click="statistics">统计表</el-button>
52
       </div>
53
       </div>
53
     </div>
54
     </div>
198
 
199
 
199
        <el-table-column align="center" label="封管液" v-if="dialysisSett.sealing_fluid_dispose == 1">
200
        <el-table-column align="center" label="封管液" v-if="dialysisSett.sealing_fluid_dispose == 1">
200
            <template slot-scope="scope">
201
            <template slot-scope="scope">
201
-             <span v-if="scope.row.xt_assesment_after_dislysis.sealing_fluid_dispose>0">{{scope.row.xt_assesment_after_dislysis.sealing_fluid_dispose}} </span> 
202
+             <span>{{scope.row.xt_assesment_after_dislysis.sealing_fluid_dispose}} </span> 
202
            </template>
203
            </template>
203
         </el-table-column>
204
         </el-table-column>
204
 
205
 
205
         <el-table-column align="center" label="葡萄糖"  v-if="dialysisSett.glucose==1">
206
         <el-table-column align="center" label="葡萄糖"  v-if="dialysisSett.glucose==1">
206
            <template slot-scope="scope">
207
            <template slot-scope="scope">
207
-             <span  v-if="scope.row.dialysis_prescription.amylaceum>0">{{scope.row.dialysis_prescription.amylaceum}} </span> 
208
+             <span>{{scope.row.dialysis_prescription.amylaceum?scope.row.dialysis_prescription.amylaceum:""}} </span> 
209
+           </template>
210
+        </el-table-column>
211
+
212
+       <el-table-column align="center" label="血流量"  v-if="dialysisSett.blood_flow_volume==1">
213
+           <template slot-scope="scope">
214
+             <span>{{scope.row.dialysis_prescription.blood_flow_volume?scope.row.dialysis_prescription.blood_flow_volume:""}} </span> 
208
            </template>
215
            </template>
209
         </el-table-column>
216
         </el-table-column>
210
       </el-table>
217
       </el-table>
342
               :value="item.id">
349
               :value="item.id">
343
             </el-option>
350
             </el-option>
344
            </el-select>
351
            </el-select>
345
-           <el-button size="small" icon="el-icon-printer" @click="toPrintOne" type="primary">打印</el-button>
346
-           <el-button size="small" icon="el-icon-printer" @click="exportListOne" type="primary">导出</el-button>
352
+           <el-button size="small" @click="toPrintOne" icon="el-icon-printer" type="primary">打印</el-button>
353
+           <el-button size="small"  @click="exportListOne" type="primary">导出</el-button>
347
         </div> 
354
         </div> 
348
        <el-table
355
        <el-table
349
         :data="tableList"
356
         :data="tableList"
497
         anticoagulant_zongliang: false,
504
         anticoagulant_zongliang: false,
498
         doctor_advice: false,
505
         doctor_advice: false,
499
         displace_liqui_part_option:[],
506
         displace_liqui_part_option:[],
500
-        ids:""
507
+        ids:"",
508
+        form: {
509
+          id: 0,
510
+          prescription_status: '',
511
+          week: '',
512
+          name: '',
513
+          zone: '',
514
+          classes: '',
515
+          number: '',
516
+          mode: '',
517
+          dialyzers: '',
518
+          perfusion_apparatus: '',
519
+          anticoagulant: '',
520
+          anticoagulant_zongliang: '',
521
+          doctor_advice: ''
522
+        },
523
+        pickerOptions:{ //禁用当前日期之前的日期
524
+           disabledDate(v) {
525
+            //Date.now()是javascript中的内置函数,它返回自1970年1月1日00:00:00 UTC以来经过的毫秒数。
526
+            return v.getTime() < new Date().getTime() - 86400000;
527
+          },
528
+        },
501
       }
529
       }
502
     },
530
     },
503
     created() {
531
     created() {
642
            if(response.data.state == 1){
670
            if(response.data.state == 1){
643
             this.startdialogVisible = true
671
             this.startdialogVisible = true
644
             var list = response.data.data.list
672
             var list = response.data.data.list
645
-            // console.log("list232323223222wid",list)
646
-            var total = 0
647
-            var total_one = 0
648
-            var total_two = 0
649
-            var total_three = 0
650
-            var total_four = 0
651
-            var total_five = 0
652
-            var total_six = 0
653
-            var total_seven =0
654
-            var total_eight = 0
655
-            var total_night =0
656
-            var total_ten = 0
657
-            var total_elven = 0
658
-            var total_twenty = 0
659
-          
673
+            var anticoagulantList = []
660
             if(list!=null && list.length>0){
674
             if(list!=null && list.length>0){
661
               for(let i=0;i<list.length;i++){
675
               for(let i=0;i<list.length;i++){
662
                  list[i].dialysis_dialyszers_arr = []
676
                  list[i].dialysis_dialyszers_arr = []
671
                  if(list[i].dialysis_prescription.dialysis_irrigation!=""){
685
                  if(list[i].dialysis_prescription.dialysis_irrigation!=""){
672
                    list[i].dialysis_irrigation_arr = list[i].dialysis_prescription.dialysis_irrigation.split(",")
686
                    list[i].dialysis_irrigation_arr = list[i].dialysis_prescription.dialysis_irrigation.split(",")
673
                  }
687
                  }
688
+
689
+                
674
                  if(list[i].dialysis_prescription.anticoagulant == 1){
690
                  if(list[i].dialysis_prescription.anticoagulant == 1){
675
-                     total += list[i].dialysis_prescription.anticoagulant_zongliang 
691
+                    anticoagulantList.push(list[i].dialysis_prescription)
676
                  }
692
                  }
677
                  if(list[i].dialysis_prescription.anticoagulant == 2){
693
                  if(list[i].dialysis_prescription.anticoagulant == 2){
678
-                     total_one += list[i].dialysis_prescription.anticoagulant_zongliang 
694
+                    anticoagulantList.push(list[i].dialysis_prescription)
679
                  }
695
                  }
680
                 if(list[i].dialysis_prescription.anticoagulant == 3){
696
                 if(list[i].dialysis_prescription.anticoagulant == 3){
681
-                     total_two += list[i].dialysis_prescription.anticoagulant_zongliang 
697
+                    anticoagulantList.push(list[i].dialysis_prescription)
682
                  }
698
                  }
683
                  if(list[i].dialysis_prescription.anticoagulant == 4){
699
                  if(list[i].dialysis_prescription.anticoagulant == 4){
684
-                     total_three += list[i].dialysis_prescription.anticoagulant_zongliang 
700
+                    anticoagulantList.push(list[i].dialysis_prescription)
685
                  }
701
                  }
686
                 if(list[i].dialysis_prescription.anticoagulant == 5){
702
                 if(list[i].dialysis_prescription.anticoagulant == 5){
687
-                     total_four += list[i].dialysis_prescription.anticoagulant_zongliang 
703
+                   anticoagulantList.push(list[i].dialysis_prescription)
688
                  }
704
                  }
689
                   if(list[i].dialysis_prescription.anticoagulant == 6){
705
                   if(list[i].dialysis_prescription.anticoagulant == 6){
690
-                     total_five += list[i].dialysis_prescription.anticoagulant_zongliang 
706
+                    anticoagulantList.push(list[i].dialysis_prescription)
691
                  }
707
                  }
692
                   if(list[i].dialysis_prescription.anticoagulant == 7){
708
                   if(list[i].dialysis_prescription.anticoagulant == 7){
693
-                     total_six += list[i].dialysis_prescription.anticoagulant_zongliang 
709
+                   anticoagulantList.push(list[i].dialysis_prescription)
694
                  }
710
                  }
695
                   if(list[i].dialysis_prescription.anticoagulant == 8){
711
                   if(list[i].dialysis_prescription.anticoagulant == 8){
696
-                     total_seven += list[i].dialysis_prescription.anticoagulant_zongliang 
712
+                   anticoagulantList.push(list[i].dialysis_prescription)
697
                  }
713
                  }
698
                  if(list[i].dialysis_prescription.anticoagulant == 9){
714
                  if(list[i].dialysis_prescription.anticoagulant == 9){
699
-                     total_eight += list[i].dialysis_prescription.anticoagulant_zongliang 
715
+                   anticoagulantList.push(list[i].dialysis_prescription)
700
                  }
716
                  }
701
                   if(list[i].dialysis_prescription.anticoagulant == 10){
717
                   if(list[i].dialysis_prescription.anticoagulant == 10){
702
-                     total_night += list[i].dialysis_prescription.anticoagulant_zongliang 
718
+                    anticoagulantList.push(list[i].dialysis_prescription)
703
                  }
719
                  }
704
                   if(list[i].dialysis_prescription.anticoagulant == 11){
720
                   if(list[i].dialysis_prescription.anticoagulant == 11){
705
-                     total_ten+= list[i].dialysis_prescription.anticoagulant_zongliang 
721
+                    anticoagulantList.push(list[i].dialysis_prescription)
706
                  }
722
                  }
707
                   if(list[i].dialysis_prescription.anticoagulant == 12){
723
                   if(list[i].dialysis_prescription.anticoagulant == 12){
708
-                     total_elven+= list[i].dialysis_prescription.anticoagulant_zongliang 
724
+                    anticoagulantList.push(list[i].dialysis_prescription)
709
                  }
725
                  }
710
-                   if(list[i].dialysis_prescription.anticoagulant == 13){
711
-                     total_twenty+= list[i].dialysis_prescription.anticoagulant_zongliang 
726
+                 if(list[i].dialysis_prescription.anticoagulant == 13){
727
+                   anticoagulantList.push(list[i].dialysis_prescription)
712
                  }
728
                  }
713
               }
729
               }
714
             }
730
             }
731
+            console.log("anticoagulantList",anticoagulantList)
732
+           this.tableList = []
733
+           if(anticoagulantList!=null && anticoagulantList.length > 0){
734
+                let dataInfoOne = {}
735
+                anticoagulantList.forEach((item, index) => {
736
+                let { anticoagulant } = item
737
+                if (!dataInfoOne[anticoagulant]) {
738
+                  dataInfoOne[anticoagulant] = {
739
+                    anticoagulant:item.anticoagulant,
740
+                    name: "抗凝剂",
741
+                    specification_name:this.getAnticoagualnt(item.anticoagulant),
742
+                    count:0,
743
+                    child:[]
744
+                  }
745
+                }
746
+              })
747
+            let hisarr = Object.values(dataInfoOne)
748
+            if(hisarr!=null && hisarr.length > 0){
749
+              for(let i=0;i<anticoagulantList.length;i++){
750
+                for(let j=0;j<hisarr.length;j++){
751
+                  if(anticoagulantList[i].anticoagulant == hisarr[j].anticoagulant){
752
+                     hisarr[j].child.push(anticoagulantList[i])
753
+                  }
754
+                }
755
+              }
756
+            }
757
+            for(let i=0;i<hisarr.length;i++){
758
+              hisarr[i].count = hisarr[i].child.length
759
+              this.tableList.push(hisarr[i])
760
+            }
761
+            console.log("hisarr",hisarr)
762
+           }
715
             var dialysisDialyszersArr = []
763
             var dialysisDialyszersArr = []
716
             var dialyzerPerfusionApparaArr = []
764
             var dialyzerPerfusionApparaArr = []
717
             var dialysisIrrigationArr = []
765
             var dialysisIrrigationArr = []
718
             for(let i=0;i<list.length;i++){
766
             for(let i=0;i<list.length;i++){
719
              for(let j=0;j<list[i].dialysis_dialyszers_arr.length;j++){
767
              for(let j=0;j<list[i].dialysis_dialyszers_arr.length;j++){
720
-              // console.log("list23323232",list[i].dialysis_dialyszers_arr[j])
721
                dialysisDialyszersArr.push(list[i].dialysis_dialyszers_arr[j])  
768
                dialysisDialyszersArr.push(list[i].dialysis_dialyszers_arr[j])  
722
              }
769
              }
723
              for(let z=0;z<list[i].dialyzer_perfusion_apparatus_arr.length;z++){
770
              for(let z=0;z<list[i].dialyzer_perfusion_apparatus_arr.length;z++){
727
               dialysisIrrigationArr.push(list[i].dialysis_irrigation_arr[y])
774
               dialysisIrrigationArr.push(list[i].dialysis_irrigation_arr[y])
728
              }
775
              }
729
             }
776
             }
730
-            // console.log("透析器",dialysisDialyszersArr)
731
-            // console.log("透析器/灌流器",dialyzerPerfusionApparaArr)
732
-            // console.log("灌流器",dialysisIrrigationArr)
733
-             
734
            let obj = {}
777
            let obj = {}
735
            let objOne = {}
778
            let objOne = {}
736
            let objTwo = {}
779
            let objTwo = {}
784
               a.specification_name = i
827
               a.specification_name = i
785
               Arr.push(a);
828
               Arr.push(a);
786
             }
829
             }
787
-          //   console.log("newa",Arr)
788
-          //  console.log("total_one",total_one)
789
-           var  objArr = {name:"抗凝剂",specification_name:"无肝素",count:0}
790
-           objArr.count = total
791
-           var objArrOne = {name:"抗凝剂",specification_name:"普通肝素",count:0}
792
-            objArrOne.count = total_one
793
-           var objArrTwo = {name:"抗凝剂",specification_name:"低分子肝素",count:0}
794
-            objArrTwo.count = total_two
795
-           var objArrThree = {name:"抗凝剂",specification_name:"阿加曲班",count:0}
796
-            objArrThree.count = total_three
797
-           var objArrFour = {name:"抗凝剂",specification_name:"枸橼酸钠",count:0}
798
-            objArrFour.count = total_four
799
-           var objArrFive = {name:"抗凝剂",specification_name:"低分子肝素钙",count:0}
800
-            objArrFive.count = total_five
801
-           var objArrSix = {name:"抗凝剂",specification_name:"低分子肝素钠",count:0}
802
-            objArrSix.count = total_six
803
-           var objArrSeven = {name:"抗凝剂",specification_name:"依诺肝素",count:0}
804
-            objArrSeven.count = total_seven
805
-           var objArrEight = {name:"抗凝剂",specification_name:"达肝素",count:0}
806
-            objArrSeven.count = total_eight
807
-           var objArrNight = {name:"抗凝剂",specification_name:"体外抗凝",count:0}
808
-            objArrNight.count = total_eight
809
-           var objArrTen = {name:"抗凝剂",specification_name:"那屈肝素",count:0}
810
-            objArrTen.count = total_ten
811
-           var objArrEleven = {name:"抗凝剂",specification_name:"无抗凝剂",count:0}
812
-            objArrEleven.count = total_elven
813
-           var objArrTwenty = {name:"抗凝剂",specification_name:"那屈肝素钙",count:0}
814
-            objArrTwenty.count = total_twenty
815
-            //  console.log("objArrOne",objArrOne.count)
816
-             this.tableList = []
817
-              if(parseInt(objArr.count) > 0){
818
-                this.tableList.push(objArr)
819
-              }
820
-              // console.log("objArrOne",parseInt(objArrOne.count))
821
-             if(parseInt(objArrOne.count) > 0){
822
-                // console.log("j你了了呃呃呃呃呃呃")
823
-                this.tableList.push(objArrOne)
824
-              }
825
-              if(parseInt(objArrTwo).count > 0){
826
-                this.tableList.push(objArrTwo)
827
-              }
828
-               if(parseInt(objArrThree).count > 0){
829
-                this.tableList.push(objArrThree)
830
-              }
831
-               if(parseInt(objArrFour.count) > 0){
832
-                this.tableList.push(objArrFour)
833
-              }
834
-               if(parseInt(objArrFive.count) > 0){
835
-                this.tableList.push(objArrFive)
836
-              }
837
-               if(parseInt(objArrSix.count) > 0){
838
-                this.tableList.push(objArrSix)
839
-              }
840
-               if(parseInt(objArrSeven.count) > 0){
841
-                this.tableList.push(objArrSeven)
842
-              }
843
-               if(parseInt(objArrEight.count) > 0){
844
-                this.tableList.push(objArrEight)
845
-              }
846
-               if(parseInt(objArrNight.count) > 0){
847
-                this.tableList.push(objArrNight)
848
-              }
849
-               if(parseInt(objArrTen.count) > 0){
850
-                this.tableList.push(objArrTen)
851
-              }
852
-               if(parseInt(objArrEleven.count) > 0){
853
-                this.tableList.push(objArrEleven)
854
-              }
855
-               if(parseInt(objArrTwenty).count > 0){
856
-                this.tableList.push(objArrTwenty)
857
-              }
858
-              
859
-            
830
+
860
             if(Arr.length >0){
831
             if(Arr.length >0){
861
               for(let i=0;i<Arr.length;i++){
832
               for(let i=0;i<Arr.length;i++){
862
                  this.tableList.push(Arr[i])
833
                  this.tableList.push(Arr[i])
886
               this.list[i].patient_name = this.list[i].patient.name
857
               this.list[i].patient_name = this.list[i].patient.name
887
               this.list[i].dialysis_no = this.list[i].patient.dialysis_no
858
               this.list[i].dialysis_no = this.list[i].patient.dialysis_no
888
               this.list[i].admission_number = this.list[i].xt_receive_treatment_asses.admission_number
859
               this.list[i].admission_number = this.list[i].xt_receive_treatment_asses.admission_number
889
-              this.list[i].weight_before = this.list[i].assessment_befor_dislysis.weight_befor
890
-              this.list[i].dry_weight = this.list[i].assessment_befor_dislysis.dry_weight
891
-              this.list[i].blood_pressure = this.list[i].assessment_befor_dislysis.systolic_blood_pressure + "/" + this.list[i].assessment_befor_dislysis.diastolic_blood_pressure
892
-              this.list[i].ultrafiltration_volume = this.list[i].dialysis_prescription.target_ultrafiltration
860
+              this.list[i].weight_before = this.list[i].assessment_befor_dislysis.weight_before?this.list[i].assessment_befor_dislysis.weight_before:"",
861
+              this.list[i].dry_weight = this.list[i].assessment_befor_dislysis.dry_weight?this.list[i].assessment_befor_dislysis.dry_weight:""
862
+              this.list[i].blood_pressure = this.list[i].assessment_befor_dislysis.systolic_blood_pressure?this.list[i].assessment_befor_dislysis.systolic_blood_pressure:"" + "/" + this.list[i].assessment_befor_dislysis.diastolic_blood_pressure? this.list[i].assessment_befor_dislysis.diastolic_blood_pressure:""
863
+              if(this.list[i].blood_pressure == 0){
864
+                this.list[i].blood_pressure = ""
865
+              }
866
+              this.list[i].ultrafiltration_volume = this.list[i].dialysis_prescription.target_ultrafiltration?this.list[i].dialysis_prescription.target_ultrafiltration:""
893
              
867
              
894
-              this.list[i].anticoagulant_one = this.getAnticoagualnt(this.list[i].dialysis_prescription.anticoagulant) + this.list[i].dialysis_prescription.anticoagulant_shouji + this.list[i].dialysis_prescription.anticoagulant_weichi+this.list[i].dialysis_prescription.anticoagulant_zongliang
895
-              
896
-              this.list[i].dialysis_time = this.list[i].dialysis_prescription.dialysis_duration_hour + "时"+ this.list[i].dialysis_prescription.dialysis_duration_minute + "分"
868
+              this.list[i].anticoagulant_one = this.getAnticoagualnt(this.list[i].dialysis_prescription.anticoagulant) + "(" + this.list[i].dialysis_prescription.anticoagulant_shouji?this.list[i].dialysis_prescription.anticoagulant_shouji:"" +")" + "("+this.list[i].dialysis_prescription.anticoagulant_weichi?this.list[i].dialysis_prescription.anticoagulant_weichi:"" +")"+ +"("+this.list[i].dialysis_prescription.anticoagulant_zongliang?this.list[i].dialysis_prescription.anticoagulant_zongliang:""+")"
869
+              if(this.list[i].anticoagulant_one == 0){
870
+                this.list[i].anticoagulant_one = ""
871
+              }
872
+              this.list[i].dialysis_time = this.list[i].dialysis_prescription.dialysis_duration_hour?this.list[i].dialysis_prescription.dialysis_duration_hour:"" + "时"+ this.list[i].dialysis_prescription.dialysis_duration_minute?this.list[i].dialysis_prescription.dialysis_duration_minute:"" + "分"
873
+              if(this.list[i].dialysis_time == 0){
874
+               this.list[i].dialysis_time = ""
875
+              }
897
               this.list[i].device_type = this.list[i].assessment_befor_dislysis.machine_type
876
               this.list[i].device_type = this.list[i].assessment_befor_dislysis.machine_type
898
               this.list[i].dialyzer_perfusion_apparatus = this.list[i].dialysis_prescription.dialyzer_perfusion_apparatus
877
               this.list[i].dialyzer_perfusion_apparatus = this.list[i].dialysis_prescription.dialyzer_perfusion_apparatus
899
               this.list[i].dialysis_dialyszers = this.list[i].dialysis_prescription.dialysis_dialyszers
878
               this.list[i].dialysis_dialyszers = this.list[i].dialysis_prescription.dialysis_dialyszers
900
               this.list[i].dialysis_irrigation = this.list[i].dialysis_prescription.dialysis_irrigation
879
               this.list[i].dialysis_irrigation = this.list[i].dialysis_prescription.dialysis_irrigation
901
-              this.list[i].displace_liqui_value = this.list[i].dialysis_prescription.replacement_total
902
-              this.list[i].kalium = this.list[i].dialysis_prescription.kalium
903
-              this.list[i].sodium = this.list[i].dialysis_prescription.sodium
904
-              this.list[i].calcium = this.list[i].dialysis_prescription.bicarbonate
880
+              this.list[i].displace_liqui_part = this.getDisplaceLiquiPart(this.list[i].dialysis_prescription.displace_liqui_part)
881
+              this.list[i].displace_liqui_value = this.list[i].dialysis_prescription.displace_liqui_value? this.list[i].dialysis_prescription.displace_liqui_value:""
882
+              this.list[i].kalium = this.list[i].dialysis_prescription.kalium?this.list[i].dialysis_prescription.kalium:""
883
+              this.list[i].sodium = this.list[i].dialysis_prescription.sodium?this.list[i].dialysis_prescription.sodium:""
884
+              this.list[i].calcium = this.list[i].dialysis_prescription.calcium?this.list[i].dialysis_prescription.calcium:""
905
               this.list[i].blood_access = this.getBloodAccessOption(this.list[i].dialysis_prescription.blood_access)
885
               this.list[i].blood_access = this.getBloodAccessOption(this.list[i].dialysis_prescription.blood_access)
906
               this.list[i].sealing_fluid_dispose =this.list[i].xt_assesment_after_dislysis.sealing_fluid_dispose
886
               this.list[i].sealing_fluid_dispose =this.list[i].xt_assesment_after_dislysis.sealing_fluid_dispose
907
-              this.list[i].glucose = this.list[i].dialysis_prescription.amylaceum
887
+              this.list[i].glucose = this.list[i].dialysis_prescription.glucose?this.list[i].dialysis_prescription.glucose:""
888
+              this.list[i].blood_flow_volume = this.list[i].dialysis_prescription.blood_flow_volume?this.list[i].dialysis_prescription.blood_flow_volume:""
889
+              this.list[i].bicarbonate = this.list[i].dialysis_prescription.bicarbonate? this.list[i].dialysis_prescription.bicarbonate:""
908
             }
890
             }
909
          }
891
          }
910
 
892
 
911
-        // console.log("list23323232322323wode",this.list)
893
+         console.log("list23323232322323wode",this.list)
894
+         
912
          var arr= []
895
          var arr= []
913
          var arrTwo = []
896
          var arrTwo = []
914
          arr.push('序号')
897
          arr.push('序号')
931
          }
914
          }
932
          if(this.dialysisSett.weight_befor == 1){
915
          if(this.dialysisSett.weight_befor == 1){
933
            arr.push("透前体重")
916
            arr.push("透前体重")
934
-           arrTwo.push("weight_befor")
917
+           arrTwo.push("weight_before")
935
          }
918
          }
936
          if(this.dialysisSett.dry_weight == 1){
919
          if(this.dialysisSett.dry_weight == 1){
937
            arr.push("干体重")
920
            arr.push("干体重")
969
            arr.push("灌流器")
952
            arr.push("灌流器")
970
            arrTwo.push("dialysis_irrigation")
953
            arrTwo.push("dialysis_irrigation")
971
          }
954
          }
955
+         if(this.dialysisSett.displace_liqui_part == 1){
956
+           arr.push("置换液")
957
+           arrTwo.push("displace_liqui_part")
958
+         }
972
          if(this.dialysisSett.displace_liqui_value == 1){
959
          if(this.dialysisSett.displace_liqui_value == 1){
973
            arr.push("置换液总量")
960
            arr.push("置换液总量")
974
            arrTwo.push("displace_liqui_value")
961
            arrTwo.push("displace_liqui_value")
1003
            arr.push("葡萄糖")
990
            arr.push("葡萄糖")
1004
            arrTwo.push("glucose")
991
            arrTwo.push("glucose")
1005
         }
992
         }
993
+       if(this.dialysisSett.blood_flow_volume == 1){
994
+           arr.push("血流量")
995
+           arrTwo.push("blood_flow_volume")
996
+        }
1006
          
997
          
1007
        
998
        
1008
         const tHeader = arr
999
         const tHeader = arr
1488
         getRemindPrintList().then(response => {
1479
         getRemindPrintList().then(response => {
1489
           if (response.data.state == 1) {
1480
           if (response.data.state == 1) {
1490
             var list = response.data.data.list
1481
             var list = response.data.data.list
1491
-            // console.log('list222332', list)
1482
+            console.log('list222332', list)
1492
             if (list.anticoagulant == 1) {
1483
             if (list.anticoagulant == 1) {
1493
               // console.log('进来22222')
1484
               // console.log('进来22222')
1494
               this.anticoagulant = true
1485
               this.anticoagulant = true

+ 3 - 2
src/xt_pages/dialysis/dialysisPrintOrder.vue View File

1154
             v-if="org_template_info.template_id == 50"
1154
             v-if="org_template_info.template_id == 50"
1155
           >
1155
           >
1156
           </DialysisPrintOrderFifty>
1156
           </DialysisPrintOrderFifty>
1157
-          <DialysisPrintOrderSixtyOne
1157
+          
1158
+          <DialysisPrintOrderFiftyOne
1158
             v-bind:childResponse="childResponse"
1159
             v-bind:childResponse="childResponse"
1159
             v-if="org_template_info.template_id == 51"
1160
             v-if="org_template_info.template_id == 51"
1160
           >
1161
           >
1161
-          </DialysisPrintOrderSixtyOne>
1162
+          </DialysisPrintOrderFiftyOne>
1162
           <DialysisPrintOrderFiftyTwo
1163
           <DialysisPrintOrderFiftyTwo
1163
             v-bind:childResponse="childResponse"
1164
             v-bind:childResponse="childResponse"
1164
             v-if="org_template_info.template_id == 52"
1165
             v-if="org_template_info.template_id == 52"

+ 1 - 0
src/xt_pages/dialysis/template/DialysisPrintOrderFiftyOne.vue View File

3422
         console.log("ooo");
3422
         console.log("ooo");
3423
         name = name.replace("区", "");
3423
         name = name.replace("区", "");
3424
       }
3424
       }
3425
+      console.log("name2232323",name)
3425
       return name;
3426
       return name;
3426
     },
3427
     },
3427
 
3428
 

+ 1 - 1
src/xt_pages/dialysis/template/DialysisPrintOrderFiftyThree.vue View File

55
                           </span>
55
                           </span>
56
                         </div>
56
                         </div>
57
                         <div style="width: 250px">
57
                         <div style="width: 250px">
58
-                          透析次数:&nbsp;<span>
58
+                          透析次数:&nbsp;<span>
59
                             {{
59
                             {{
60
                               patientInfo.total_dialysis +
60
                               patientInfo.total_dialysis +
61
                               patientInfo.user_sys_before_count
61
                               patientInfo.user_sys_before_count

+ 10 - 3
src/xt_pages/user/dialysisSolution.vue View File

193
             <el-col :span="6" v-if="isShows('透析器')"><div class="grid-content bg-purple">透析器:{{current_solution.dialysis_dialyszers}}</div></el-col>
193
             <el-col :span="6" v-if="isShows('透析器')"><div class="grid-content bg-purple">透析器:{{current_solution.dialysis_dialyszers}}</div></el-col>
194
             <el-col :span="6" v-if="isShows('灌流器')"><div class="grid-content bg-purple">灌流器:{{current_solution.dialysis_irrigation}}</div></el-col>
194
             <el-col :span="6" v-if="isShows('灌流器')"><div class="grid-content bg-purple">灌流器:{{current_solution.dialysis_irrigation}}</div></el-col>
195
             <el-col :span="6" v-if="isShows('碳酸氢盐')"><div class="grid-content bg-purple">碳酸氢盐(mmol/L):{{current_solution.bicarbonate}}</div></el-col>
195
             <el-col :span="6" v-if="isShows('碳酸氢盐')"><div class="grid-content bg-purple">碳酸氢盐(mmol/L):{{current_solution.bicarbonate}}</div></el-col>
196
-            <el-col :span="6" v-if="isShows('葡萄糖')"><div class="grid-content bg-purple">葡萄糖(mmol/L):{{current_solution.glucose}}</div></el-col>
196
+            <el-col :span="6" v-if="isShows('葡萄糖')"><div class="grid-content bg-purple">葡萄糖(mmol/L):{{current_solution.amylaceum}}</div></el-col>
197
          </el-row>
197
          </el-row>
198
 
198
 
199
             <el-row :gutter="20">
199
             <el-row :gutter="20">
523
               <el-input v-model="addPlan.bicarbonate"></el-input>
523
               <el-input v-model="addPlan.bicarbonate"></el-input>
524
             </el-form-item>
524
             </el-form-item>
525
           </el-col>
525
           </el-col>
526
-          <el-col :span="8" v-if="isShows('葡萄糖')">
526
+          <!-- <el-col :span="8" v-if="isShows('葡萄糖')">
527
             <el-form-item label="葡萄糖(mmol/L): " prop="glucose">
527
             <el-form-item label="葡萄糖(mmol/L): " prop="glucose">
528
               <el-input v-model="addPlan.glucose"></el-input>
528
               <el-input v-model="addPlan.glucose"></el-input>
529
             </el-form-item>
529
             </el-form-item>
530
+          </el-col> -->
531
+          
532
+          <el-col :span="8" v-if="isShows('葡萄糖')">
533
+            <el-form-item label="葡萄糖(mmol/L): " prop="amylaceum">
534
+              <el-input v-model="addPlan.amylaceum"></el-input>
535
+            </el-form-item>
530
           </el-col>
536
           </el-col>
531
 
537
 
538
+
532
           <el-col :span="8" v-if="isShows('透析液流量')">
539
           <el-col :span="8" v-if="isShows('透析液流量')">
533
             <el-form-item label="透析液流量(ml/min): " prop="dialysate_flow">
540
             <el-form-item label="透析液流量(ml/min): " prop="dialysate_flow">
534
               <el-input v-model="addPlan.dialysate_flow"></el-input>
541
               <el-input v-model="addPlan.dialysate_flow"></el-input>
1066
         epo:"",
1073
         epo:"",
1067
         epo_count:"",
1074
         epo_count:"",
1068
         max_ultrafiltration_rate:"",
1075
         max_ultrafiltration_rate:"",
1069
-
1076
+        amylaceum:"",
1070
       },
1077
       },
1071
       childPlan: {
1078
       childPlan: {
1072
         mode: '',
1079
         mode: '',