Browse Source

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

csx 3 years ago
parent
commit
3c51906a12

+ 0 - 1
src/lang/zh.js View File

258
     hospitalRecord:"住院登记",
258
     hospitalRecord:"住院登记",
259
     hisTool:"HIS工具",
259
     hisTool:"HIS工具",
260
     hospitalCharges:'住院收费',
260
     hospitalCharges:'住院收费',
261
-
262
   },
261
   },
263
   navbar: {
262
   navbar: {
264
     logOut: '退出登录',
263
     logOut: '退出登录',

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

15
     {
15
     {
16
       path: '/hospitalCharges/outpatientChargesManagement',
16
       path: '/hospitalCharges/outpatientChargesManagement',
17
       component: () => import('@/xt_pages/hospitalStation/outpatientChargesManagement'),
17
       component: () => import('@/xt_pages/hospitalStation/outpatientChargesManagement'),
18
-      name: 'outpatientChargesManagement',
19
-      meta: { title: 'outpatientChargesManagement', noCache: true }
18
+      name: 'hospitalChargesManagement',
19
+      meta: { title: 'hospitalChargesManagement', noCache: true }
20
     },
20
     },
21
     // {
21
     // {
22
     //   path: '/outpatientCharges/outpatientInvoice',
22
     //   path: '/outpatientCharges/outpatientInvoice',

+ 15 - 0
src/store/modules/globalConfig.js View File

751
         zongliang_unit: 'mg',
751
         zongliang_unit: 'mg',
752
         gaimingcheng_unit: '',
752
         gaimingcheng_unit: '',
753
         gaijiliang_unit: ''
753
         gaijiliang_unit: ''
754
+      },
755
+      12: {
756
+        id: 12,
757
+        name: '无抗凝剂',
758
+        type: 1,
759
+        shouji: 2,
760
+        weichi: 2,
761
+        zongliang: 2,
762
+        gaimingcheng: -1,
763
+        gaijiliang: -1,
764
+        shouji_unit: 'mg',
765
+        weichi_unit: 'mg/h',
766
+        zongliang_unit: 'mg',
767
+        gaimingcheng_unit: '',
768
+        gaijiliang_unit: ''
754
       }
769
       }
755
     },
770
     },
756
     anticoagulants_set: {
771
     anticoagulants_set: {

+ 1 - 1
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue View File

2036
           if (minites < 10) {
2036
           if (minites < 10) {
2037
             minites = '0' + minites
2037
             minites = '0' + minites
2038
           }
2038
           }
2039
-          if (this.$store.getters.xt_user.org.id == 10016) {
2039
+          if (this.$store.getters.xt_user.org.id == 10016 || this.$store.getters.xt_user.org.id == 10121 || this.$store.getters.xt_user.org.id == 4  ) {
2040
             this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
2040
             this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
2041
           } else {
2041
           } else {
2042
             if (schedual.schedule_type == 1) {
2042
             if (schedual.schedule_type == 1) {

+ 1 - 0
src/xt_pages/dialysis/details/dialog/monitor_dialog.vue View File

411
              <span v-if="scope.row.monitor_anticoagulant == 7">低分子肝素钠</span>
411
              <span v-if="scope.row.monitor_anticoagulant == 7">低分子肝素钠</span>
412
              <span v-if="scope.row.monitor_anticoagulant == 8">依诺肝素</span>
412
              <span v-if="scope.row.monitor_anticoagulant == 8">依诺肝素</span>
413
              <span v-if="scope.row.monitor_anticoagulant == 9">达肝素</span>
413
              <span v-if="scope.row.monitor_anticoagulant == 9">达肝素</span>
414
+             <span v-if="scope.row.monitor_anticoagulant == 12">无抗凝剂</span>
414
              <span v-if="scope.row.monitor_anticoagulant_value!=''">({{ scope.row.monitor_anticoagulant_value ? scope.row.monitor_anticoagulant_value : ""  }})</span>
415
              <span v-if="scope.row.monitor_anticoagulant_value!=''">({{ scope.row.monitor_anticoagulant_value ? scope.row.monitor_anticoagulant_value : ""  }})</span>
415
 
416
 
416
             </template>
417
             </template>

+ 1 - 0
src/xt_pages/dialysis/details/dialysisMonitoring.vue View File

75
             <span v-if="monitor.monitor_anticoagulant == 7">低分子肝素钠</span>
75
             <span v-if="monitor.monitor_anticoagulant == 7">低分子肝素钠</span>
76
             <span v-if="monitor.monitor_anticoagulant == 8">依诺肝素</span>
76
             <span v-if="monitor.monitor_anticoagulant == 8">依诺肝素</span>
77
             <span v-if="monitor.monitor_anticoagulant == 9">达肝素</span>
77
             <span v-if="monitor.monitor_anticoagulant == 9">达肝素</span>
78
+            <span v-if="monitor.monitor_anticoagulant == 12">无抗凝剂</span>
78
             <span v-if="monitor.monitor_anticoagulant_value!=''">({{monitor.monitor_anticoagulant_value ? monitor.monitor_anticoagulant_value : ""  }})</span>
79
             <span v-if="monitor.monitor_anticoagulant_value!=''">({{monitor.monitor_anticoagulant_value ? monitor.monitor_anticoagulant_value : ""  }})</span>
79
           </td>
80
           </td>
80
           <!-- <th v-if="isShow('血压监测部位')">{{getBloodPressure(monitor.blood_pressure_monitoring_site)}}</th>
81
           <!-- <th v-if="isShow('血压监测部位')">{{getBloodPressure(monitor.blood_pressure_monitoring_site)}}</th>

+ 7 - 1
src/xt_pages/hospitalStation/components/prescriptionTable.vue View File

2
   <div class="prescriptionTable">
2
   <div class="prescriptionTable">
3
     <el-table v-if="activeType  == 1" :data="prescription.advices" border style="width: 99%;" :row-style="{ color: '#303133' }"
3
     <el-table v-if="activeType  == 1" :data="prescription.advices" border style="width: 99%;" :row-style="{ color: '#303133' }"
4
               :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
4
               :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
5
-      <el-table-column align="center" type="index" width="40" label="序号"></el-table-column>
5
+      <el-table-column align="center" prop="day" width="70" label="序号">
6
+        <template slot-scope="scope">
7
+          <div style="display:flex;align-items:center;">
8
+            <el-input v-model="scope.row.groupno" placeholder=""></el-input>
9
+          </div>
10
+        </template>
11
+      </el-table-column>
6
       <el-table-column align="center" prop="drug_name" label="名称">
12
       <el-table-column align="center" prop="drug_name" label="名称">
7
         <template slot-scope="scope"><span :title="scope.row.drug_name">{{ scope.row.drug_name }}</span></template>
13
         <template slot-scope="scope"><span :title="scope.row.drug_name">{{ scope.row.drug_name }}</span></template>
8
       </el-table-column>
14
       </el-table-column>

+ 20 - 153
src/xt_pages/hospitalStation/doctorDesk.vue View File

43
                 </div>
43
                 </div>
44
 
44
 
45
                 <div class="mainCell" style="margin-bottom:10px;">
45
                 <div class="mainCell" style="margin-bottom:10px;">
46
-                    <el-input size="small" placeholder="请输入姓名或就诊号" @input="searchAction"
47
-                              @keyup.enter.native='searchAction'
46
+                    <el-input size="small" placeholder="请输入姓名或就诊号"
48
                               v-model="search_input" class="filter-item"/>
47
                               v-model="search_input" class="filter-item"/>
49
                     <el-button size="small" style="margin-left:10px;" class="filter-item" type="primary"
48
                     <el-button size="small" style="margin-left:10px;" class="filter-item" type="primary"
50
                                @click="searchAction">
49
                                @click="searchAction">
445
             return false
444
             return false
446
           } else {
445
           } else {
447
             this.patientTableData = response.data.data.list
446
             this.patientTableData = response.data.data.list
447
+            this.all_data = this.patientTableData
448
+
448
             this.patientTableDataTwo = response.data.data.list
449
             this.patientTableDataTwo = response.data.data.list
449
             this.cal_one = response.data.data.total_one
450
             this.cal_one = response.data.data.total_one
450
             this.cal_two = response.data.data.total_two
451
             this.cal_two = response.data.data.total_two
499
 
500
 
500
       searchAction() {
501
       searchAction() {
501
         if (this.search_input.length == 0) {
502
         if (this.search_input.length == 0) {
502
-          switch (this.radio) {
503
-            case 0:
504
-              this.all_data = this.all_data_two
505
-              break
506
-            case 2:
507
-              this.cure_data = this.cure_data_two
508
-              break
509
-            case 1:
510
-              this.un_cure_data = this.un_cure_data_two
511
-              break
512
-          }
503
+          this.patientTableData = this.all_data
513
         } else {
504
         } else {
514
-
515
           switch (this.radio) {
505
           switch (this.radio) {
516
-            case 0:
517
-              let arr = []
518
-              for (let i = 0; i < this.all_data.length; i++) {
519
-                if (this.all_data[i].name.indexOf(this.search_input) != -1 || this.all_data[i].number.indexOf(this.search_input) != -1) {
520
-                  arr = arr.concat(this.all_data[i])
521
-                  console.log(arr)
522
-                }
523
-              }
524
-              this.all_data = arr
525
-
526
-              break
527
             case 2:
506
             case 2:
528
               let arr2 = []
507
               let arr2 = []
529
-              for (let i = 0; i < this.cure_data.length; i++) {
530
-                if (this.cure_data[i].name.indexOf(this.search_input) != -1 || this.cure_data[i].number.indexOf(this.search_input) != -1) {
531
-                  arr2 = arr2.concat(this.cure_data[i])
508
+              for (let i = 0; i < this.all_data.length; i++) {
509
+                if (this.all_data[i].name.indexOf(this.search_input) != -1 || this.all_data[i].his_patient.number.indexOf(this.search_input) != -1) {
510
+                  arr2 = arr2.concat(this.all_data[i])
532
                 }
511
                 }
533
               }
512
               }
534
-              this.cure_data = arr2
513
+              this.patientTableData = arr2
535
 
514
 
536
               break
515
               break
537
             case 1:
516
             case 1:
538
               let arr3 = []
517
               let arr3 = []
539
-              for (let i = 0; i < this.un_cure_data.length; i++) {
540
-                if (this.un_cure_data[i].name.indexOf(this.search_input) != -1 || this.un_cure_data[i].number.indexOf(this.search_input) != -1) {
541
-                  arr3 = arr3.concat(this.un_cure_data[i])
518
+              for (let i = 0; i < this.all_data.length; i++) {
519
+                if (this.all_data[i].name.indexOf(this.search_input) != -1 || this.all_data[i].his_patient.number.indexOf(this.search_input) != -1) {
520
+                  arr3 = arr3.concat(this.all_data[i])
542
                 }
521
                 }
543
               }
522
               }
544
-              this.un_cure_data = arr3
523
+              this.patientTableData = arr3
545
               break
524
               break
546
           }
525
           }
547
         }
526
         }
562
             return false
541
             return false
563
           } else {
542
           } else {
564
             this.patientTableData = response.data.data.list
543
             this.patientTableData = response.data.data.list
544
+            this.all_data = this.patientTableData
545
+
565
             this.patientTableDataTwo = response.data.data.list
546
             this.patientTableDataTwo = response.data.data.list
566
             this.cal_one = response.data.data.total_one
547
             this.cal_one = response.data.data.total_one
567
             this.cal_two = response.data.data.total_two
548
             this.cal_two = response.data.data.total_two
592
             return false
573
             return false
593
           } else {
574
           } else {
594
             this.patientTableData = response.data.data.list
575
             this.patientTableData = response.data.data.list
576
+            this.all_data = this.patientTableData
577
+
595
             this.patientTableDataTwo = response.data.data.list
578
             this.patientTableDataTwo = response.data.data.list
596
             this.cal_one = response.data.data.total_one
579
             this.cal_one = response.data.data.total_one
597
             this.cal_two = response.data.data.total_two
580
             this.cal_two = response.data.data.total_two
980
             return false
963
             return false
981
           } else {
964
           } else {
982
             this.patientTableData = response.data.data.list
965
             this.patientTableData = response.data.data.list
966
+            this.all_data = this.patientTableData
983
             this.patientTableDataTwo = response.data.data.list
967
             this.patientTableDataTwo = response.data.data.list
984
             this.cal_one = response.data.data.total_one
968
             this.cal_one = response.data.data.total_one
985
             this.cal_two = response.data.data.total_two
969
             this.cal_two = response.data.data.total_two
1217
             } else {
1201
             } else {
1218
 
1202
 
1219
               if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
1203
               if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
1220
-                for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
1221
-                  var prescription = response.data.data.sch_prescriptions[i]
1222
-                  for (let b = 0; b < prescription.advices.length; b++) {
1223
-                    console.log(prescription.advices[b].drug.is_special_diseases)
1224
-                    if (prescription.med_type == '14' && prescription.advices[b].drug.is_special_diseases != 1) {
1225
-                      prescription.advices.splice(b--, 1)
1226
-                    }
1227
-                  }
1228
-                  for (let b = 0; b < prescription.project.length; b++) {
1229
-                    if (prescription.project[b].type == 2) {
1230
-                      if (prescription.med_type == '14' && prescription.project[b].project.disease_directory != 1) {
1231
-                        prescription.project.splice(b--, 1)
1232
-                      }
1233
-                    } else if (prescription.project[b].type == 3) {
1234
-                      if (prescription.med_type == '14' && prescription.project[b].good_info.is_special_diseases != 1) {
1235
-                        prescription.project.splice(b--, 1)
1236
-                      }
1237
-                    }
1238
-                  }
1239
-                }
1204
+
1240
 
1205
 
1241
                 for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
1206
                 for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
1242
                   var prescription = response.data.data.sch_prescriptions[i]
1207
                   var prescription = response.data.data.sch_prescriptions[i]
1613
 
1578
 
1614
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
1579
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
1615
 
1580
 
1616
-                      for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
1617
-                        var prescription = response.data.data.sch_prescriptions[i]
1618
-                        for (let b = 0; b < prescription.advices.length; b++) {
1619
-                          console.log(prescription.advices[b].drug.is_special_diseases)
1620
-                          if (prescription.med_type == '14' && prescription.advices[b].drug.is_special_diseases != 1) {
1621
-                            prescription.advices.splice(b--, 1)
1622
-                          }
1623
-                        }
1624
-                        for (let b = 0; b < prescription.project.length; b++) {
1625
-                          if (prescription.project[b].type == 2) {
1626
-                            if (prescription.med_type == '14' && prescription.project[b].project.disease_directory != 1) {
1627
-                              prescription.project.splice(b--, 1)
1628
-                            }
1629
-                          } else if (prescription.project[b].type == 3) {
1630
-                            if (prescription.med_type == '14' && prescription.project[b].good_info.is_special_diseases != 1) {
1631
-                              prescription.project.splice(b--, 1)
1632
-                            }
1633
-                          }
1634
-                        }
1635
-                      }
1636
 
1581
 
1637
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
1582
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
1638
                         var prescription = response.data.data.sch_prescriptions[i]
1583
                         var prescription = response.data.data.sch_prescriptions[i]
2101
                   } else {
2046
                   } else {
2102
 
2047
 
2103
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
2048
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
2104
-                      for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
2105
-                        var prescription = response.data.data.sch_prescriptions[i]
2106
-                        for (let b = 0; b < prescription.advices.length; b++) {
2107
-                          console.log(prescription.advices[b].drug.is_special_diseases)
2108
-                          if (prescription.med_type == '14' && prescription.advices[b].drug.is_special_diseases != 1) {
2109
-                            prescription.advices.splice(b--, 1)
2110
-                          }
2111
-                        }
2112
-                        for (let b = 0; b < prescription.project.length; b++) {
2113
-                          if (prescription.project[b].type == 2) {
2114
-                            if (prescription.med_type == '14' && prescription.project[b].project.disease_directory != 1) {
2115
-                              prescription.project.splice(b--, 1)
2116
-                            }
2117
-                          } else if (prescription.project[b].type == 3) {
2118
-                            if (prescription.med_type == '14' && prescription.project[b].good_info.is_special_diseases != 1) {
2119
-                              prescription.project.splice(b--, 1)
2120
-                            }
2121
-                          }
2122
-                        }
2123
-                      }
2049
+
2124
 
2050
 
2125
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
2051
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
2126
                         var prescription = response.data.data.sch_prescriptions[i]
2052
                         var prescription = response.data.data.sch_prescriptions[i]
2576
                 } else {
2502
                 } else {
2577
 
2503
 
2578
                   if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
2504
                   if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
2579
-                    for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
2580
-                      var prescription = response.data.data.sch_prescriptions[i]
2581
-                      for (let b = 0; b < prescription.advices.length; b++) {
2582
-                        console.log(prescription.advices[b].drug.is_special_diseases)
2583
-                        if (prescription.med_type == '14' && prescription.advices[b].drug.is_special_diseases != 1) {
2584
-                          prescription.advices.splice(b--, 1)
2585
-                        }
2586
-                      }
2587
-                      for (let b = 0; b < prescription.project.length; b++) {
2588
-                        if (prescription.project[b].type == 2) {
2589
-                          if (prescription.med_type == '14' && prescription.project[b].project.disease_directory != 1) {
2590
-                            prescription.project.splice(b--, 1)
2591
-                          }
2592
-                        } else if (prescription.project[b].type == 3) {
2593
-                          if (prescription.med_type == '14' && prescription.project[b].good_info.is_special_diseases != 1) {
2594
-                            prescription.project.splice(b--, 1)
2595
-                          }
2596
-                        }
2597
-                      }
2598
-                    }
2599
 
2505
 
2600
                     for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
2506
                     for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
2601
                       var prescription = response.data.data.sch_prescriptions[i]
2507
                       var prescription = response.data.data.sch_prescriptions[i]
3118
                   } else {
3024
                   } else {
3119
 
3025
 
3120
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
3026
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
3121
-                      for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
3122
-                        var prescription = response.data.data.sch_prescriptions[i]
3123
-                        for (let b = 0; b < prescription.advices.length; b++) {
3124
-                          console.log(prescription.advices[b].drug.is_special_diseases)
3125
-                          if (prescription.med_type == '14' && prescription.advices[b].drug.is_special_diseases != 1) {
3126
-                            prescription.advices.splice(b--, 1)
3127
-                          }
3128
-                        }
3129
-                        for (let b = 0; b < prescription.project.length; b++) {
3130
-                          if (prescription.project[b].type == 2) {
3131
-                            if (prescription.med_type == '14' && prescription.project[b].project.disease_directory != 1) {
3132
-                              prescription.project.splice(b--, 1)
3133
-                            }
3134
-                          } else if (prescription.project[b].type == 3) {
3135
-                            if (prescription.med_type == '14' && prescription.project[b].good_info.is_special_diseases != 1) {
3136
-                              prescription.project.splice(b--, 1)
3137
-                            }
3138
-                          }
3139
-                        }
3140
-                      }
3141
 
3027
 
3142
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
3028
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
3143
                         var prescription = response.data.data.sch_prescriptions[i]
3029
                         var prescription = response.data.data.sch_prescriptions[i]
3683
                   } else {
3569
                   } else {
3684
 
3570
 
3685
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
3571
                     if (response.data.data.count <= 1 && response.data.data.schedule.id > 0 && response.data.data.sch_prescriptions.length > 0) {
3686
-                      for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
3687
-                        var prescription = response.data.data.sch_prescriptions[i]
3688
-                        for (let b = 0; b < prescription.advices.length; b++) {
3689
-                          console.log(prescription.advices[b].drug.is_special_diseases)
3690
-                          if (prescription.med_type == '14' && prescription.advices[b].drug.is_special_diseases != 1) {
3691
-                            prescription.advices.splice(b--, 1)
3692
-                          }
3693
-                        }
3694
-                        for (let b = 0; b < prescription.project.length; b++) {
3695
-                          if (prescription.project[b].type == 2) {
3696
-                            if (prescription.med_type == '14' && prescription.project[b].project.disease_directory != 1) {
3697
-                              prescription.project.splice(b--, 1)
3698
-                            }
3699
-                          } else if (prescription.project[b].type == 3) {
3700
-                            if (prescription.med_type == '14' && prescription.project[b].good_info.is_special_diseases != 1) {
3701
-                              prescription.project.splice(b--, 1)
3702
-                            }
3703
-                          }
3704
-                        }
3705
-                      }
3572
+
3706
 
3573
 
3707
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
3574
                       for (let i = 0; i < response.data.data.sch_prescriptions.length; i++) {
3708
                         var prescription = response.data.data.sch_prescriptions[i]
3575
                         var prescription = response.data.data.sch_prescriptions[i]

+ 50 - 1
src/xt_pages/hospitalStation/outpatientChargesManagement.vue View File

43
                     </el-radio-group>
43
                     </el-radio-group>
44
                 </div>
44
                 </div>
45
                 <div class="mainCell" style="margin-bottom:10px;">
45
                 <div class="mainCell" style="margin-bottom:10px;">
46
-                    <el-input size="small" @keyup.enter.native='searchAction' v-model.trim="search_input"
46
+                    <el-input size="small"  v-model.trim="search_input"
47
                               class="filter-item"/>
47
                               class="filter-item"/>
48
                     <el-button size="small" style="margin-left:10px;" class="filter-item" type="primary"
48
                     <el-button size="small" style="margin-left:10px;" class="filter-item" type="primary"
49
                                @click="searchAction">
49
                                @click="searchAction">
518
         patient_id: 0,
518
         patient_id: 0,
519
         prescription_id: 0,
519
         prescription_id: 0,
520
         all_table_data: [],
520
         all_table_data: [],
521
+        all_charge_table_data: [],
522
+
521
         hisPatientDatas: [],
523
         hisPatientDatas: [],
522
         order: {},
524
         order: {},
523
         addtions_charge: [],
525
         addtions_charge: [],
860
             this.patientTableData = []
862
             this.patientTableData = []
861
             this.all_table_data = []
863
             this.all_table_data = []
862
             this.hisPatientDatas = []
864
             this.hisPatientDatas = []
865
+            this.all_charge_table_data = []
863
 
866
 
864
             let one_count = 0
867
             let one_count = 0
865
             let two_count = 0
868
             let two_count = 0
882
             this.hisPatientDatas = response.data.data.list_two
885
             this.hisPatientDatas = response.data.data.list_two
883
             this.cal_one = one_count
886
             this.cal_one = one_count
884
             this.cal_two = response.data.data.charge_list.length
887
             this.cal_two = response.data.data.charge_list.length
888
+            this.all_charge_table_data = response.data.data.charge_list
885
             this.cal_three = three_count
889
             this.cal_three = three_count
886
             this.current_index = 0
890
             this.current_index = 0
887
 
891
 
994
 
998
 
995
             this.cal_one = one_count
999
             this.cal_one = one_count
996
             this.cal_two = response.data.data.charge_list.length
1000
             this.cal_two = response.data.data.charge_list.length
1001
+            this.all_charge_table_data = response.data.data.charge_list
997
             this.cal_three = three_count
1002
             this.cal_three = three_count
998
             this.current_index = 0
1003
             this.current_index = 0
999
 
1004
 
1076
 
1081
 
1077
       },
1082
       },
1078
       searchAction() {
1083
       searchAction() {
1084
+        if (this.search_input.length == 0) {
1085
+          switch (this.radio) {
1086
+            case 1:
1087
+             this.patientTableData = this.all_table_data
1088
+
1089
+              break
1090
+            case 2:
1091
+
1092
+              this.chargePatientTableData = this.all_charge_table_data
1093
+
1094
+              break
1095
+          }
1096
+
1097
+
1098
+        } else {
1099
+          switch (this.radio) {
1100
+            case 1:
1101
+              let arr3 = []
1102
+              for (let i = 0; i < this.all_table_data.length; i++) {
1103
+                if (this.all_table_data[i].name.indexOf(this.search_input) != -1 || this.all_table_data[i].his_patient.number.indexOf(this.search_input) != -1) {
1104
+                  arr3 = arr3.concat(this.all_table_data[i])
1105
+                }
1106
+              }
1107
+              this.patientTableData = arr3
1108
+              break
1109
+            case 2:
1110
+              let arr2 = []
1111
+              for (let i = 0; i < this.all_charge_table_data.length; i++) {
1112
+                if (this.all_charge_table_data[i].name.indexOf(this.search_input) != -1 || this.all_charge_table_data[i].his_number.indexOf(this.search_input) != -1) {
1113
+                  arr2 = arr2.concat(this.all_charge_table_data[i])
1114
+                }
1115
+              }
1116
+              this.chargePatientTableData = arr2
1117
+
1118
+              break
1119
+
1120
+          }
1121
+        }
1122
+
1123
+
1124
+
1079
 
1125
 
1080
       }, tabclickEventTwo(val) {
1126
       }, tabclickEventTwo(val) {
1081
         for (let i = 0; i < this.month_prescriptions.length; i++) {
1127
         for (let i = 0; i < this.month_prescriptions.length; i++) {
2025
 
2071
 
2026
             this.cal_one = one_count
2072
             this.cal_one = one_count
2027
             this.cal_two = response.data.data.charge_list.length
2073
             this.cal_two = response.data.data.charge_list.length
2074
+            this.all_charge_table_data = response.data.data.charge_list
2028
             this.cal_three = three_count
2075
             this.cal_three = three_count
2029
 
2076
 
2030
             switch (temp_id) {
2077
             switch (temp_id) {
2178
 
2225
 
2179
             this.cal_one = one_count
2226
             this.cal_one = one_count
2180
             this.cal_two = response.data.data.charge_list.length
2227
             this.cal_two = response.data.data.charge_list.length
2228
+            this.all_charge_table_data = response.data.data.charge_list
2181
             // this.cal_three = three_count;
2229
             // this.cal_three = three_count;
2182
 
2230
 
2183
             switch (temp_id) {
2231
             switch (temp_id) {
2314
             this.hisPatientDatas = response.data.data.list_two
2362
             this.hisPatientDatas = response.data.data.list_two
2315
             this.cal_one = one_count
2363
             this.cal_one = one_count
2316
             this.cal_two = response.data.data.charge_list.length
2364
             this.cal_two = response.data.data.charge_list.length
2365
+            this.all_charge_table_data = response.data.data.charge_list
2317
             this.current_index = 0
2366
             this.current_index = 0
2318
 
2367
 
2319
             switch (this.radio) {
2368
             switch (this.radio) {

+ 14 - 5
src/xt_pages/hospitalStation/pastInquiries.vue View File

159
         })
159
         })
160
       },
160
       },
161
       getDiagnosis(id){
161
       getDiagnosis(id){
162
-        var name = "";
163
-        for(let i=0;i<this.diagnoses.length;i++){
164
-           if(id == this.diagnoses[i].id){
165
-              name = this.diagnoses[i].class_name
166
-           }
162
+        let ids = id.split(",")
163
+        var name = ""
164
+        for(let i = 0; i < ids.length; i++){
165
+
166
+          for(let b=0;b<this.diagnoses.length;b++){
167
+            if(parseInt(ids[i]) == this.diagnoses[b].id){
168
+              if(name.length == 0){
169
+                name = this.diagnoses[b].class_name
170
+              }else{
171
+                name = name +"," + this.diagnoses[b].class_name
172
+
173
+              }
174
+            }
175
+          }
167
         }
176
         }
168
         return name
177
         return name
169
       }
178
       }

File diff suppressed because it is too large
+ 404 - 341
src/xt_pages/hospitalStation/summary.vue


+ 1 - 1
src/xt_pages/hospitalStation/treatTemplate/printOne.vue View File

52
                     <tr v-for="(it,index) in item.project" :key="index">
52
                     <tr v-for="(it,index) in item.project" :key="index">
53
                         <td>{{index+1}}</td>
53
                         <td>{{index+1}}</td>
54
                         <td>{{it.type == 2 ? it.project.project_name : it.good_info.good_name}}</td>
54
                         <td>{{it.type == 2 ? it.project.project_name : it.good_info.good_name}}</td>
55
-                        <td>{{it.single_dose}}</td>
55
+                        <td>{{it.count}}</td>
56
                         <td>{{getUnit(it.unit)}}</td>
56
                         <td>{{getUnit(it.unit)}}</td>
57
                         <td>{{it.price}}</td>
57
                         <td>{{it.price}}</td>
58
                         <td></td>
58
                         <td></td>

+ 28 - 10
src/xt_pages/qcd/workAnalysis/nurse.vue View File

149
               </template>
149
               </template>
150
             </el-table-column>
150
             </el-table-column>
151
 
151
 
152
-            <el-table-column label="开瘘" align="center">
153
-              <template slot-scope="scope">
154
-                {{scope.row.new_nuser_count?scope.row.new_nuser_count:''}}
155
-
156
-              </template>
157
-            </el-table-column>
158
-
159
             <el-table-column label="上机" align="center" width="300">
152
             <el-table-column label="上机" align="center" width="300">
160
               <template slot-scope="scope">
153
               <template slot-scope="scope">
161
                 {{scope.row.start_nuser_count?scope.row.start_nuser_count:''}}
154
                 {{scope.row.start_nuser_count?scope.row.start_nuser_count:''}}
162
                 <span v-if="getTotalCount(scope.row.admin_user_id)!=''">({{getTotalCount(scope.row.admin_user_id)}})</span>
155
                 <span v-if="getTotalCount(scope.row.admin_user_id)!=''">({{getTotalCount(scope.row.admin_user_id)}})</span>
163
               </template>
156
               </template>
164
             </el-table-column>
157
             </el-table-column>
158
+            
159
+             <el-table-column label="下机" align="center">
160
+              <template slot-scope="scope">
161
+                {{scope.row.finish_nuser_count?scope.row.finish_nuser_count:''}}
162
+              </template>
163
+            </el-table-column>
165
 
164
 
165
+            <el-table-column label="冲管" align="center">
166
+              <template slot-scope="scope">
167
+                {{scope.row.finish_nuser_count?scope.row.finish_nuser_count:''}}
168
+              </template>
169
+            </el-table-column>
166
 
170
 
167
             <el-table-column label="宣教/小结" align="center">
171
             <el-table-column label="宣教/小结" align="center">
168
               <template slot-scope="scope">
172
               <template slot-scope="scope">
176
                 start_nurse_count:total_start_nurse, -->
180
                 start_nurse_count:total_start_nurse, -->
177
             <el-table-column label="合计" align="center">
181
             <el-table-column label="合计" align="center">
178
               <template slot-scope="scope">
182
               <template slot-scope="scope">
179
-                {{scope.row.puncture_count + scope.row.cure_count + scope.row.mission_count + scope.row.change_nuser_count+scope.row.difficult_nuser_count+scope.row.new_nuser_count +scope.row.start_nuser_count ?scope.row.puncture_count  + scope.row.cure_count + scope.row.mission_count+scope.row.change_nuser_count+scope.row.difficult_nuser_count+scope.row.new_nuser_count+scope.row.start_nuser_count:''}}
183
+                {{scope.row.finish_nuser_count + scope.row.washpipe_nuser_count + scope.row.puncture_count + scope.row.cure_count + scope.row.mission_count + scope.row.change_nuser_count+scope.row.difficult_nuser_count+scope.row.new_nuser_count +scope.row.start_nuser_count ?scope.row.puncture_count  + scope.row.cure_count + scope.row.mission_count+scope.row.change_nuser_count+scope.row.difficult_nuser_count+scope.row.new_nuser_count+scope.row.start_nuser_count:''}}
180
               </template>
184
               </template>
181
             </el-table-column>
185
             </el-table-column>
182
           </el-table>
186
           </el-table>
231
           {value:5, name:"疑难穿刺"},
235
           {value:5, name:"疑难穿刺"},
232
           {value:6, name:"开瘘"},
236
           {value:6, name:"开瘘"},
233
           {value:7, name:"上机"},
237
           {value:7, name:"上机"},
238
+          {value:8, name:"下机"},
239
+          {value:9, name:"冲管"},
234
         ],
240
         ],
235
         crumbs: [
241
         crumbs: [
236
           { path: false, name: "质控管理" },
242
           { path: false, name: "质控管理" },
394
         GetNurseWorkloadTableData(params)
400
         GetNurseWorkloadTableData(params)
395
           .then(rs => {
401
           .then(rs => {
396
             var resp = rs.data
402
             var resp = rs.data
397
-            console.log("resp232323",resp)
403
+            console.log("列表2323323232323233232332323223233223233223",resp)
398
             if (resp.state == 1) {
404
             if (resp.state == 1) {
399
 
405
 
400
               let total_cure = 0
406
               let total_cure = 0
404
               let total_diffcult_nurse = 0
410
               let total_diffcult_nurse = 0
405
               let total_new_fistula_nurse = 0
411
               let total_new_fistula_nurse = 0
406
               let total_start_nurse = 0
412
               let total_start_nurse = 0
413
+              let total_finish_nurse = 0
414
+              let total_washpipe_nurse = 0
407
               this.loading = false
415
               this.loading = false
408
 
416
 
409
               for (let i = 0; i < resp.data.data.length; i++) {
417
               for (let i = 0; i < resp.data.data.length; i++) {
415
                 total_diffcult_nurse = total_diffcult_nurse + resp.data.data[i].difficult_nuser_count
423
                 total_diffcult_nurse = total_diffcult_nurse + resp.data.data[i].difficult_nuser_count
416
                 total_new_fistula_nurse = total_new_fistula_nurse + resp.data.data[i].new_nuser_count
424
                 total_new_fistula_nurse = total_new_fistula_nurse + resp.data.data[i].new_nuser_count
417
                 total_start_nurse = total_start_nurse + resp.data.data[i].start_nuser_count
425
                 total_start_nurse = total_start_nurse + resp.data.data[i].start_nuser_count
426
+                total_finish_nurse = total_finish_nurse + resp.data.data[i].finish_nuser_count
427
+                total_washpipe_nurse = total_washpipe_nurse + resp.data.data[i].washpipe_nuser_count
418
                 this.tableData.push(resp.data.data[i])
428
                 this.tableData.push(resp.data.data[i])
419
              }
429
              }
420
               this.tableData.push( {
430
               this.tableData.push( {
426
                 difficult_nuser_count:total_diffcult_nurse,
436
                 difficult_nuser_count:total_diffcult_nurse,
427
                 new_nuser_count:total_new_fistula_nurse,
437
                 new_nuser_count:total_new_fistula_nurse,
428
                 start_nuser_count:total_start_nurse,
438
                 start_nuser_count:total_start_nurse,
439
+                finish_nuser_count:total_finish_nurse,
440
+                washpipe_nuser_count:total_washpipe_nurse,
429
               })
441
               })
430
-
442
+              console.log("hhhhhhh23232233223",this.tableData)
431
               var dialysisCount = resp.data.dialysisCount
443
               var dialysisCount = resp.data.dialysisCount
432
                 console.log("dialysisCount",dialysisCount)
444
                 console.log("dialysisCount",dialysisCount)
433
               for(let i=0;i<dialysisCount.length;i++){
445
               for(let i=0;i<dialysisCount.length;i++){
564
                 }else if(this.query.statistics_type == 7){
576
                 }else if(this.query.statistics_type == 7){
565
                   this.bar.series[0].data.push(resp.data.data[i].start_nuser_count)
577
                   this.bar.series[0].data.push(resp.data.data[i].start_nuser_count)
566
                   this.percent.push(resp.data.data[i].start_nurse_ratio)
578
                   this.percent.push(resp.data.data[i].start_nurse_ratio)
579
+                }else if(this.query.statistics_type == 8){
580
+                  this.bar.series[0].data.push(resp.data.data[i].finish_nuser_count)
581
+                  this.percent.push(resp.data.data[i].finish_nurse_ratio)
582
+                }else if(this.query.statistics_type == 9){
583
+                  this.bar.series[0].data.push(resp.data.data[i].washpipe_nuser_count)
584
+                  this.percent.push(resp.data.data[i].washpipe_nurse_ratio)
567
                 }
585
                 }
568
               }
586
               }
569
               this.getArrLength(this.bar.xAxis.data)
587
               this.getArrLength(this.bar.xAxis.data)

+ 119 - 8
src/xt_pages/stock/detail/cancelStockDetail.vue View File

7
       @click="PrintAction"
7
       @click="PrintAction"
8
       type="primary"
8
       type="primary"
9
       >打印
9
       >打印
10
+    </el-button>
11
+     <el-button
12
+      style="float: right;margin-right:10px"
13
+      size="small"
14
+      @click="exportListDetail"
15
+      type="primary"
16
+      >明细导出
10
     </el-button>
17
     </el-button>
11
     <el-button
18
     <el-button
12
       style="float: right;margin-right:10px"
19
       style="float: right;margin-right:10px"
13
       size="small"
20
       size="small"
14
       @click="exportList"
21
       @click="exportList"
15
       type="primary"
22
       type="primary"
16
-      >导出
23
+      >汇总导出
17
     </el-button>
24
     </el-button>
18
     <div class="cell clearfix">
25
     <div class="cell clearfix">
19
       <el-input
26
       <el-input
149
 
156
 
150
         <el-table-column label="操作时间" align="center">
157
         <el-table-column label="操作时间" align="center">
151
           <template slot-scope="scope">
158
           <template slot-scope="scope">
152
-            {{ scope.row.CancelStock.return_time | parseTime("{y}-{m}-{d}") }}
159
+            <span v-if="scope.row.is_total == 0">{{ scope.row.CancelStock.return_time | parseTime("{y}-{m}-{d}") }}</span> 
160
+            <span v-if="scope.row.is_total == 1"></span>
153
           </template>
161
           </template>
154
         </el-table-column>
162
         </el-table-column>
155
         <el-table-column label="制单人" align="center">
163
         <el-table-column label="制单人" align="center">
163
             {{ scope.row.count }}
171
             {{ scope.row.count }}
164
           </template>
172
           </template>
165
         </el-table-column>
173
         </el-table-column>
174
+
175
+        <el-table-column label="退库价" align="center">
176
+          <template slot-scope="scope">
177
+            {{ scope.row.price }}
178
+          </template>
179
+        </el-table-column>
180
+
181
+       <el-table-column label="总价" align="center">
182
+          <template slot-scope="scope">
183
+          
184
+             <!-- <span v-if="scope.row.is_total == 0">{{ (scope.row.count * scope.row.price).toFixed(2) }}</span>
185
+            <span v-else>{{ scope.row.total }}</span> -->
186
+            {{scope.row.total}}
187
+          </template>
188
+        </el-table-column>
166
       </el-table>
189
       </el-table>
167
 
190
 
168
       <el-pagination
191
       <el-pagination
243
       selectedTableData: [],
266
       selectedTableData: [],
244
       dealer: [],
267
       dealer: [],
245
       tableList:[],
268
       tableList:[],
246
-      goodUnit:[]
269
+      goodUnit:[],
270
+      tableDataList:[],
271
+      table:[],
247
     };
272
     };
248
   },
273
   },
249
   methods: {
274
   methods: {
353
         } else {
378
         } else {
354
           this.total = response.data.data.total;
379
           this.total = response.data.data.total;
355
           console.log("数据源头",response.data.data.list)
380
           console.log("数据源头",response.data.data.list)
381
+          var total = 0
356
           for (let i = 0; i < response.data.data.list.length; i++) {
382
           for (let i = 0; i < response.data.data.list.length; i++) {
357
-            this.cancelStockDate.push(response.data.data.list[i]);
358
-            this.tableList.push(response.data.data.list[i])
383
+            
384
+            var obj = response.data.data.list[i];
385
+            response.data.data.list[i].total = (response.data.data.list[i].price * response.data.data.list[i].count).toFixed(2)
386
+            total += response.data.data.list[i].price * response.data.data.list[i].count
387
+            obj["is_total"] = 0;
388
+            this.cancelStockDate.push(obj);
389
+            
390
+          }
391
+          console.log("2322323323232323223322323")
392
+          this.tableDataList = response.data.data.list
393
+         
394
+          var listgroup = response.data.data.listgroup
395
+          console.log("hh2322322332",listgroup)
396
+
397
+          this.cancelStockDate.push({
398
+            order_number: "合计",
399
+            is_total: 1,
400
+            total: total.toFixed(2),
401
+            CancelStock: {
402
+              return_count: 0
403
+            }
404
+          });
405
+        for(let i=0;i<listgroup.length;i++){
406
+            listgroup[i].child = []
407
+          for(let j=0;j<response.data.data.list.length;j++){
408
+             if(listgroup[i].GoodInfo.id == response.data.data.list[j].GoodInfo.id){
409
+                 listgroup[i].child.push(response.data.data.list[j])
410
+             }
359
           }
411
           }
360
         }
412
         }
413
+        this.tableList = listgroup
414
+        console.log("退库列表",this.tableList)
415
+        }
361
       });
416
       });
362
     },
417
     },
363
     getXuserName(id) {
418
     getXuserName(id) {
558
         .catch(() => {});
613
         .catch(() => {});
559
     },
614
     },
560
       exportList(){
615
       exportList(){
561
-     
616
+        console.log("hhhhhh",this.tableList)
562
         for(let i=0;i<this.tableList.length;i++){
617
         for(let i=0;i<this.tableList.length;i++){
563
           this.tableList[i].index = i+1
618
           this.tableList[i].index = i+1
564
           this.tableList[i].good_name = this.tableList[i].GoodInfo.good_name
619
           this.tableList[i].good_name = this.tableList[i].GoodInfo.good_name
565
           this.tableList[i].specification_name = this.tableList[i].GoodInfo.specification_name
620
           this.tableList[i].specification_name = this.tableList[i].GoodInfo.specification_name
566
           this.tableList[i].packing_unit = this.tableList[i].GoodInfo.packing_unit
621
           this.tableList[i].packing_unit = this.tableList[i].GoodInfo.packing_unit
567
-          this.tableList[i].total_price = (this.tableList[i].count * this.tableList[i].price).toFixed(2)
622
+          this.tableList[i].total = this.getTotalCount(this.tableList[i].child)
623
+          this.tableList[i].total_price = (this.tableList[i].total * this.tableList[i].price).toFixed(2)
624
+         
568
         }
625
         }
626
+       var obj = {"index":"合计","total_price":0}
627
+       for(let i=0;i<this.tableList.length;i++){
628
+           obj.total_price +=this.tableList[i].total * this.tableList[i].price
629
+       }
630
+       obj.total_price = obj.total_price.toFixed(2)
631
+       console.log("obj23233",obj)
632
+       this.tableList.push(obj)
569
        import('@/vendor/Export2Excel').then(excel => {
633
        import('@/vendor/Export2Excel').then(excel => {
570
        const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','退库价','总价','备注']
634
        const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','退库价','总价','备注']
571
-       const filterVal = ['index','good_name', 'specification_name', 'packing_unit','count','price','total_price','remark']
635
+       const filterVal = ['index','good_name', 'specification_name', 'packing_unit','total','price','total_price','remark']
572
        
636
        
573
        const data = this.formatJson(filterVal, this.tableList)
637
        const data = this.formatJson(filterVal, this.tableList)
574
        console.log("data",data)
638
        console.log("data",data)
581
           this.downloadLoading = false
645
           this.downloadLoading = false
582
         })
646
         })
583
        },
647
        },
648
+     exportListDetail(){
649
+        var obj = {index:"合计",total_price:0}
650
+        var total = 0
651
+        for(let i=0;i<this.tableDataList.length;i++){
652
+          this.tableDataList[i].index = i + 1
653
+          this.tableDataList[i].good_type_name = this.typeName(this.tableDataList[i].good_type_id)
654
+          this.tableDataList[i].good_name = this.typeNameOne(this.tableDataList[i].good_id)
655
+          this.tableDataList[i].specification_name = this.specificationName(this.tableDataList[i].good_id)
656
+          this.tableDataList[i].time = this.getTime(this.tableDataList[i].CancelStock.return_time)
657
+          this.tableDataList[i].user_name = this.getXuserName(this.tableDataList[i].CancelStock.creater)
658
+          this.tableDataList[i].out_count = this.tableDataList[i].count
659
+          this.tableDataList[i].total_price = (this.tableDataList[i].count * this.tableDataList[i].price).toFixed(2)
660
+          total += this.tableDataList[i].count * this.tableDataList[i].price
661
+        }
662
+        obj.total_price = total.toFixed(2)
663
+        this.tableDataList.push(obj)
664
+       import('@/vendor/Export2Excel').then(excel => {
665
+       const tHeader = ['序号','单据编号', '耗材类型', '耗材名称','规格型号','操作时间','制单人','出货价','数量','总价']
666
+       const filterVal = ['index','order_number', 'good_type_name', 'good_name','specification_name','time','user_name','price','out_count','total_price']
667
+
668
+       const data = this.formatJson(filterVal, this.tableDataList)
669
+       console.log("data",data)
670
+      
671
+        excel.export_json_to_excel({
672
+           header: tHeader,
673
+           data,
674
+           filename: '耗材出库明细'
675
+         })
676
+          this.downloadLoading = false
677
+        })
678
+     },
584
      formatJson(filterVal, jsonData) {
679
      formatJson(filterVal, jsonData) {
585
         return jsonData.map(v => filterVal.map(j => v[j]));
680
         return jsonData.map(v => filterVal.map(j => v[j]));
586
      },
681
      },
593
        }
688
        }
594
       return name
689
       return name
595
      },
690
      },
691
+    getTime: function(val) {
692
+      if (val == 0) {
693
+        return "";
694
+      } else {
695
+        return uParseTime(val, "{y}-{m}-{d}");
696
+      }
697
+    },
698
+    getTotalCount(val){
699
+      var total = 0
700
+      if (val.length > 0) {
701
+        for(let i=0;i<val.length;i++){
702
+           total += val[i].count
703
+        }
704
+      }
705
+      return total
706
+    }
596
   }
707
   }
597
 };
708
 };
598
 </script>
709
 </script>

+ 39 - 22
src/xt_pages/stock/detail/stockInDetail.vue View File

217
   name: "stockInDetail",
217
   name: "stockInDetail",
218
 
218
 
219
   created() {
219
   created() {
220
+    
220
     var nowDate = new Date();
221
     var nowDate = new Date();
221
     var nowYear = nowDate.getFullYear();
222
     var nowYear = nowDate.getFullYear();
222
     var nowMonth = nowDate.getMonth() + 1;
223
     var nowMonth = nowDate.getMonth() + 1;
237
       (nowMonth < 10 ? "0" + nowMonth : nowMonth) +
238
       (nowMonth < 10 ? "0" + nowMonth : nowMonth) +
238
       "-" +
239
       "-" +
239
       (nowDay < 10 ? "0" + nowDay : nowDay);
240
       (nowDay < 10 ? "0" + nowDay : nowDay);
241
+    var start_time =  window.sessionStorage.getItem('start_time')
242
+    var end_time =  window.sessionStorage.getItem('end_time')
243
+    console.log("start_time",start_time,end_time)
244
+    if(start_time !=null){
245
+      this.start_time = start_time
246
+    }
247
+    if(end_time!=null){
248
+      this.end_time = end_time
249
+    }
250
+    window.sessionStorage.removeItem('start_time')
251
+    window.sessionStorage.removeItem('end_time')  
240
     this.GetCancelStock();
252
     this.GetCancelStock();
241
     this.GetConfigInfo();
253
     this.GetConfigInfo();
242
     this.fetchAllAdminUsers();
254
     this.fetchAllAdminUsers();
243
     this.goodUnit = this.$store.getters.good_unit
255
     this.goodUnit = this.$store.getters.good_unit
244
-
245
-    // this.getPrintStockGood()
246
     this.org_id = this.$store.getters.xt_user.template_info.org_id
256
     this.org_id = this.$store.getters.xt_user.template_info.org_id
247
-    console.log("机构ID",this.org_id)
257
+   
248
     this.getGoodDetailPrintList()
258
     this.getGoodDetailPrintList()
249
   },
259
   },
250
   data() {
260
   data() {
282
       stockTotal:[],
292
       stockTotal:[],
283
       org_id:0,
293
       org_id:0,
284
       tableInfo:[],
294
       tableInfo:[],
295
+      tableDataList:[],
285
     };
296
     };
286
   },
297
   },
287
   methods: {
298
   methods: {
415
             obj["is_total"] = 0;
426
             obj["is_total"] = 0;
416
             this.cancelStockDate.push(obj);
427
             this.cancelStockDate.push(obj);
417
           }
428
           }
418
-        
429
+          this.tableDataList = response.data.data.list
419
           this.cancelStockDate.push({
430
           this.cancelStockDate.push({
420
             warehousing_order: "合计",
431
             warehousing_order: "合计",
421
             is_total: 1,
432
             is_total: 1,
483
         this.$message.error("结束时间不能小于开始时间");
494
         this.$message.error("结束时间不能小于开始时间");
484
         this.start_time = "";
495
         this.start_time = "";
485
       } else {
496
       } else {
497
+         window.sessionStorage.removeItem('start_time')
486
         this.GetCancelStock();
498
         this.GetCancelStock();
487
-        // this.getPrintStockGood()
499
+       
488
       }
500
       }
489
     },
501
     },
490
     endTimeChange(val) {
502
     endTimeChange(val) {
493
         this.$message.error("结束时间不能小于开始时间");
505
         this.$message.error("结束时间不能小于开始时间");
494
         this.end_time = "";
506
         this.end_time = "";
495
       } else {
507
       } else {
508
+        window.sessionStorage.removeItem('end_time')
496
         this.GetCancelStock();
509
         this.GetCancelStock();
497
-        // this.getPrintStockGood()
498
       }
510
       }
499
     },
511
     },
500
     getTimestamp(time) {
512
     getTimestamp(time) {
646
       return (r1 * r2) / Math.pow(10, m);
658
       return (r1 * r2) / Math.pow(10, m);
647
     },
659
     },
648
     PrintAction: function() {
660
     PrintAction: function() {
661
+      window.sessionStorage.setItem('start_time',this.start_time)
662
+      window.sessionStorage.setItem('end_time',this.end_time)
649
       this.$router.push({
663
       this.$router.push({
650
         path: "/stock/print",
664
         path: "/stock/print",
651
         query: {
665
         query: {
764
         const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','进货价','总价','备注']
778
         const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','进货价','总价','备注']
765
         const filterVal = ['index','good_name', 'specification_name', 'packing_unit','warehousing_count','price','total_price','remark']
779
         const filterVal = ['index','good_name', 'specification_name', 'packing_unit','warehousing_count','price','total_price','remark']
766
         console.log("hhhhhhhh",this.tableInfo)
780
         console.log("hhhhhhhh",this.tableInfo)
767
-       
781
+        
768
         const data = this.formatJson(filterVal, this.tableInfo)
782
         const data = this.formatJson(filterVal, this.tableInfo)
769
         console.log("data222222222",data)
783
         console.log("data222222222",data)
784
+      
770
           excel.export_json_to_excel({
785
           excel.export_json_to_excel({
771
             header: tHeader,
786
             header: tHeader,
772
             data,
787
             data,
776
         })
791
         })
777
       },
792
       },
778
       exportListDetal(){
793
       exportListDetal(){
794
+        console.log("l可悲2233",this.tableDataList)
779
         var obj = {index:"合计",total_price:0}
795
         var obj = {index:"合计",total_price:0}
780
-        var total_price = 0
781
-        for(let i=0;i<this.cancelStockDate.length;i++){
782
-          this.cancelStockDate[i].index = i + 1
783
-          this.cancelStockDate[i].good_type_name = this.typeName(this.cancelStockDate[i].good_type_id)
784
-          this.cancelStockDate[i].good_name = this.typeNameOne(this.cancelStockDate[i].good_id)
785
-          this.cancelStockDate[i].specification_name = this.specificationName(this.cancelStockDate[i].good_id)
786
-          this.cancelStockDate[i].warehousing_time = this.getTime(this.cancelStockDate[i].Warehousing.warehousing_time)
787
-          this.cancelStockDate[i].user_name = this.getXuserName(this.cancelStockDate[i].Warehousing.creater)
788
-          this.cancelStockDate[i].total_price = (this.cancelStockDate[i].warehousing_count * this.cancelStockDate[i].price).toFixed(2)
789
-          total_price += this.cancelStockDate[i].warehousing_count * this.cancelStockDate[i].price
796
+        var total = 0
797
+        for(let i=0;i<this.tableDataList.length;i++){
798
+          this.tableDataList[i].index = i + 1
799
+          this.tableDataList[i].good_type_name = this.typeName(this.tableDataList[i].good_type_id)
800
+          this.tableDataList[i].good_name = this.typeNameOne(this.tableDataList[i].good_id)
801
+          this.tableDataList[i].specification_name = this.specificationName(this.tableDataList[i].good_id)
802
+          this.tableDataList[i].time = this.getTime(this.tableDataList[i].Warehousing.warehousing_time)
803
+          this.tableDataList[i].user_name = this.getXuserName(this.tableDataList[i].Warehousing.creater)
804
+          this.tableDataList[i].total_price = (this.tableDataList[i].warehousing_count * this.tableDataList[i].price).toFixed(2)
805
+          total += this.tableDataList[i].warehousing_count * this.tableDataList[i].price
790
         }
806
         }
791
-        obj.total_price = total_price.toFixed(2)
792
-        this.cancelStockDate.push(obj)
807
+        obj.total_price = total.toFixed(2)
808
+        this.tableDataList.push(obj)
793
         import('@/vendor/Export2Excel').then(excel => {
809
         import('@/vendor/Export2Excel').then(excel => {
794
         const tHeader = ['序号','单据编号', '耗材类型', '耗材名称','规格型号','操作时间','制单人','进货价','数量','总价']
810
         const tHeader = ['序号','单据编号', '耗材类型', '耗材名称','规格型号','操作时间','制单人','进货价','数量','总价']
795
-        const filterVal = ['index','warehousing_count', 'good_type_name', 'good_name','specification_name','warehousing_time','user_name','price','warehousing_count','total_price']
796
-        console.log("hhhhhhhh",this.cancelStockDate)
811
+        const filterVal = ['index','warehousing_order', 'good_type_name', 'good_name','specification_name','time','user_name','price','warehousing_count','total_price']
812
+        console.log("hhhhhhhh",this.tableDataList)
797
       
813
       
798
         
814
         
799
-        const data = this.formatJson(filterVal, this.cancelStockDate)
815
+        const data = this.formatJson(filterVal, this.tableDataList)
800
         console.log("data222222222",data)
816
         console.log("data222222222",data)
817
+        return
801
           excel.export_json_to_excel({
818
           excel.export_json_to_excel({
802
             header: tHeader,
819
             header: tHeader,
803
             data,
820
             data,

+ 48 - 8
src/xt_pages/stock/detail/stockOutDetail.vue View File

7
       @click="PrintAction"
7
       @click="PrintAction"
8
       type="primary"
8
       type="primary"
9
       >打印
9
       >打印
10
+    </el-button>
11
+     <el-button
12
+      style="float: right;margin-right:10px"
13
+      size="small"
14
+      @click="exportListDetail"
15
+      type="primary"
16
+      >明细导出
10
     </el-button>
17
     </el-button>
11
      <el-button
18
      <el-button
12
       style="float: right;margin-right:10px"
19
       style="float: right;margin-right:10px"
13
       size="small"
20
       size="small"
14
       @click="exportList"
21
       @click="exportList"
15
       type="primary"
22
       type="primary"
16
-      >导出
23
+      >汇总导出
17
     </el-button>
24
     </el-button>
18
     <div class="cell clearfix">
25
     <div class="cell clearfix">
19
       <el-input
26
       <el-input
38
           v-model="start_time"
45
           v-model="start_time"
39
           prefix-icon="el-icon-date"
46
           prefix-icon="el-icon-date"
40
           :editable="false"
47
           :editable="false"
41
-          style="width: 196px;"
48
+          style="width: 150px;"
42
           type="date"
49
           type="date"
43
           placeholder="选择日期时间"
50
           placeholder="选择日期时间"
44
           align="right"
51
           align="right"
52
           v-model="end_time"
59
           v-model="end_time"
53
           prefix-icon="el-icon-date"
60
           prefix-icon="el-icon-date"
54
           :editable="false"
61
           :editable="false"
55
-          style="width: 196px;"
62
+          style="width: 150px;"
56
           type="date"
63
           type="date"
57
           placeholder="选择日期时间"
64
           placeholder="选择日期时间"
58
           align="right"
65
           align="right"
226
     this.GetConfigInfo();
233
     this.GetConfigInfo();
227
     this.fetchAllAdminUsers();
234
     this.fetchAllAdminUsers();
228
     this.goodUnit = this.$store.getters.good_unit
235
     this.goodUnit = this.$store.getters.good_unit
229
-    // this.getPrintStockGood()
230
-    // this.getList()
231
     var org_id = this.$store.getters.xt_user.org.id
236
     var org_id = this.$store.getters.xt_user.org.id
232
     this.orgId = org_id
237
     this.orgId = org_id
233
     console.log("机构信息",org_id)
238
     console.log("机构信息",org_id)
270
       orgId:"",
275
       orgId:"",
271
       tableData:[],
276
       tableData:[],
272
       tableOut:[],
277
       tableOut:[],
278
+      tableDataList:[],
273
     };
279
     };
274
   },
280
   },
275
   methods: {
281
   methods: {
385
         } else {
391
         } else {
386
 
392
 
387
           this.total = response.data.data.total;
393
           this.total = response.data.data.total;
388
-          console.log("详情23233323",response.data.data.list)
394
+         
395
+          var total = 0
389
           for (let i = 0; i < response.data.data.list.length; i++) {
396
           for (let i = 0; i < response.data.data.list.length; i++) {
390
             this.tableData.push(response.data.data.list[i])
397
             this.tableData.push(response.data.data.list[i])
391
             var obj = response.data.data.list[i];
398
             var obj = response.data.data.list[i];
392
-
399
+            total += response.data.data.list[i].price * response.data.data.list[i].count
393
             obj["is_total"] = 0;
400
             obj["is_total"] = 0;
394
             this.cancelStockDate.push(obj);
401
             this.cancelStockDate.push(obj);
395
             
402
             
396
           }
403
           }
404
+          this.tableDataList = response.data.data.list
397
           this.cancelStockDate.push({
405
           this.cancelStockDate.push({
398
             warehouse_out_order_number: "合计",
406
             warehouse_out_order_number: "合计",
399
             is_total: 1,
407
             is_total: 1,
400
-            total: response.data.data.total_price,
408
+            total: total.toFixed(2),
401
             WarehouseOut: {
409
             WarehouseOut: {
402
               warehouse_out_time: 0
410
               warehouse_out_time: 0
403
             }
411
             }
783
           this.downloadLoading = false
791
           this.downloadLoading = false
784
         })
792
         })
785
      },
793
      },
794
+     exportListDetail(){
795
+
796
+        var obj = {index:"合计",total_price:0}
797
+        var total = 0
798
+        for(let i=0;i<this.tableDataList.length;i++){
799
+          this.tableDataList[i].index = i + 1
800
+          this.tableDataList[i].good_type_name = this.typeName(this.tableDataList[i].good_type_id)
801
+          this.tableDataList[i].good_name = this.typeNameOne(this.tableDataList[i].good_id)
802
+          this.tableDataList[i].specification_name = this.specificationName(this.tableDataList[i].good_id)
803
+          this.tableDataList[i].time = this.getTime(this.tableDataList[i].WarehouseOut.warehouse_out_time)
804
+          this.tableDataList[i].user_name = this.getXuserName(this.tableDataList[i].WarehouseOut.creater)
805
+          this.tableDataList[i].out_count = this.tableDataList[i].count
806
+          this.tableDataList[i].total_price = (this.tableDataList[i].count * this.tableDataList[i].price).toFixed(2)
807
+          total += this.tableDataList[i].count * this.tableDataList[i].price
808
+        }
809
+        obj.total_price = total.toFixed(2)
810
+        this.tableDataList.push(obj)
811
+       import('@/vendor/Export2Excel').then(excel => {
812
+       const tHeader = ['序号','单据编号', '耗材类型', '耗材名称','规格型号','操作时间','制单人','出货价','数量','总价']
813
+       const filterVal = ['index','warehouse_out_order_number', 'good_type_name', 'good_name','specification_name','time','user_name','price','out_count','total_price']
814
+
815
+       const data = this.formatJson(filterVal, this.tableDataList)
816
+       console.log("data",data)
817
+      
818
+        excel.export_json_to_excel({
819
+           header: tHeader,
820
+           data,
821
+           filename: '耗材出库明细'
822
+         })
823
+          this.downloadLoading = false
824
+        })
825
+     },
786
      formatJson(filterVal, jsonData) {
826
      formatJson(filterVal, jsonData) {
787
         return jsonData.map(v => filterVal.map(j => v[j]));
827
         return jsonData.map(v => filterVal.map(j => v[j]));
788
      },
828
      },

+ 70 - 22
src/xt_pages/stock/drugs/components/drugCancelDetail.vue View File

8
       type="primary"
8
       type="primary"
9
       >打印
9
       >打印
10
     </el-button>
10
     </el-button>
11
-    <!-- <el-button
11
+    <el-button
12
       style="float: right;margin-right:10px"
12
       style="float: right;margin-right:10px"
13
       size="small"
13
       size="small"
14
       @click="exportListOne"
14
       @click="exportListOne"
15
       type="primary"
15
       type="primary"
16
       >明细导出
16
       >明细导出
17
-    </el-button> -->
17
+    </el-button>
18
     <el-button
18
     <el-button
19
       style="float: right;margin-right:10px"
19
       style="float: right;margin-right:10px"
20
       size="small"
20
       size="small"
146
 
146
 
147
         <el-table-column label="规格型号" align="center">
147
         <el-table-column label="规格型号" align="center">
148
           <template slot-scope="scope">
148
           <template slot-scope="scope">
149
-            <span>{{scope.row.dose}}{{scope.row.dose_unit}}*{{scope.row.min_number}}{{scope.row.min_unit}}/{{scope.row.max_unit}}</span>
149
+            <span>{{scope.row.specification_name}}</span>
150
           </template>
150
           </template>
151
         </el-table-column>
151
         </el-table-column>
152
 
152
 
179
         </el-table-column>
179
         </el-table-column>
180
         <el-table-column label="总价" align="center">
180
         <el-table-column label="总价" align="center">
181
           <template slot-scope="scope">
181
           <template slot-scope="scope">
182
-            {{scope.row.count * scope.row.price}}
182
+            {{scope.row.total_price}}
183
           </template>
183
           </template>
184
         </el-table-column>
184
         </el-table-column>
185
       </el-table>
185
       </el-table>
262
       selectedTableData: [],
262
       selectedTableData: [],
263
       dealer: [],
263
       dealer: [],
264
       tableData:[],
264
       tableData:[],
265
-      tableList:[]
265
+      tableList:[],
266
+      tableDataList:[],
266
     };
267
     };
267
   },
268
   },
268
   methods: {
269
   methods: {
373
       getDrugCancelDetail(params).then(response=>{
374
       getDrugCancelDetail(params).then(response=>{
374
          if(response.data.state == 1){
375
          if(response.data.state == 1){
375
            var order =  response.data.data.order
376
            var order =  response.data.data.order
376
-          //  console.log("退库详细222222222222222222",order)
377
+           var list = response.data.data.orderPrint
378
+           console.log("lsit232332",list)
379
+           for(let i=0;i<list.length;i++){
380
+             list[i].child = []
381
+            for(let j=0;j<order.length;j++){
382
+               if(list[i].drug_id == order[j].drug_id){
383
+                  list[i].child.push(order[j])
384
+               }
385
+            }
386
+           }
387
+           this.tableDataList = list
388
+           console.log("hh2323223",this.tableDataList)
389
+           var total_price = 0
390
+          for(let i=0;i<order.length;i++){
391
+             order[i].specification_name  = order[i].dose + order[i].dose_unit + "*" + order[i].min_number +  order[i].min_unit + "/" + order[i].max_unit
392
+             order[i].is_total = 0
393
+             order[i].total_price = order[i].count * order[i].price
394
+             total_price += order[i].count * order[i].price
395
+          }
396
+           order.push({
397
+            order_number: "合计",
398
+            is_total: 1,
399
+            specification_name:"",
400
+            ctime:"",
401
+            total_price:total_price.toFixed(2),
402
+          });
377
            this.tableData = order
403
            this.tableData = order
378
            this.tableList = order
404
            this.tableList = order
379
            var total = response.data.data.total
405
            var total = response.data.data.total
400
       }
426
       }
401
     },
427
     },
402
     exportList(){
428
     exportList(){
403
-       for(let i=0;i<this.tableList.length;i++){
404
-          this.tableList[i].index = i+1
405
-          this.tableList[i].unit = this.tableList[i].dose + this.tableList[i].dose_unit + "*"+this.tableList[i].min_number + this.tableList[i].min_unit+"/"+this.tableList[i].max_unit
429
+       for(let i=0;i<this.tableDataList.length;i++){
430
+          if(this.tableDataList[i].drug_type == 1){
431
+            this.tableDataList[i].drug_type == "西药"
432
+          }
433
+          if(this.tableDataList[i].drug_type == 2){
434
+            this.tableDataList[i].drug_type == "草药"
435
+          }
436
+         if(this.tableDataList[i].drug_type == 3){
437
+            this.tableDataList[i].drug_type == "成药"
438
+          }
439
+          this.tableDataList[i].index = i+1
440
+          this.tableDataList[i].unit = this.tableDataList[i].dose + this.tableDataList[i].dose_unit + "*"+this.tableDataList[i].min_number + this.tableDataList[i].min_unit+"/"+this.tableDataList[i].max_unit
441
+          this.tableDataList[i].user_name = this.getAdminUser(this.tableDataList[i].creater)
442
+          this.tableDataList[i].total_count  = this.getTotalCount(this.tableDataList[i].child)
443
+          this.tableDataList[i].total_price = this.tableDataList[i].total_count * this.tableDataList[i].price
444
+          this.tableDataList[i].ctime = this.getTime(this.tableDataList[i].ctime)
406
         }
445
         }
407
        import('@/vendor/Export2Excel').then(excel => {
446
        import('@/vendor/Export2Excel').then(excel => {
408
-       const tHeader = ['序号','单据编号', '药品名称', '规格型号','单据类型','操作时间','制单人','数量']
409
-       const filterVal = ['index','drug_name', 'unit', 'min_unit','count','price','remark']
410
-       
411
-       const data = this.formatJson(filterVal, this.tableList)
412
-       console.log("data",data)
413
-       
414
-       excel.export_json_to_excel({
415
-           header: tHeader,
416
-           data,
417
-           filename: '药品退库明细'
447
+        const tHeader = ['序号','单据编号', '药品名称', '规格型号','单据类型','操作时间','制单人','数量','退库价','总价']
448
+        const filterVal = ['index','order_number','drug_name', 'unit', 'drug_type','ctime','user_name','total_count','price','total_price']
449
+        
450
+        const data = this.formatJson(filterVal, this.tableDataList)
451
+        console.log("data",data)
452
+        console.log("表格玩2323",this.tableDataList)
453
+        
454
+        excel.export_json_to_excel({
455
+            header: tHeader,
456
+            data,
457
+            filename: '药品退库明细'
458
+          })
459
+            this.downloadLoading = false
418
          })
460
          })
419
-          this.downloadLoading = false
420
-        })
421
        },
461
        },
422
      formatJson(filterVal, jsonData) {
462
      formatJson(filterVal, jsonData) {
423
         return jsonData.map(v => filterVal.map(j => v[j]));
463
         return jsonData.map(v => filterVal.map(j => v[j]));
462
           this.downloadLoading = false
502
           this.downloadLoading = false
463
         })
503
         })
464
      },
504
      },
465
-
505
+    getTotalCount(val){
506
+      var total = 0
507
+      if(val.length > 0){
508
+         for(let i=0;i<val.length;i++){
509
+           total +=val[i].count
510
+         }
511
+      }
512
+      return total
513
+    }
466
   }
514
   }
467
 };
515
 };
468
 </script>
516
 </script>

+ 17 - 1
src/xt_pages/stock/drugs/components/drugInOrder.vue View File

150
         <el-table-column label="规格型号" align="center">
150
         <el-table-column label="规格型号" align="center">
151
           <template slot-scope="scope">
151
           <template slot-scope="scope">
152
            <!-- {{scope.row.drug_spec}} -->
152
            <!-- {{scope.row.drug_spec}} -->
153
-           {{scope.row.dose}}{{scope.row.dose_unit}} * {{scope.row.min_number}}{{scope.row.min_unit}} / {{scope.row.max_unit}}
153
+           {{scope.row.specification_name}}
154
+           <!-- {{scope.row.dose}}{{scope.row.dose_unit}} * {{scope.row.min_number}}{{scope.row.min_unit}} / {{scope.row.max_unit}} -->
154
           </template>
155
           </template>
155
         </el-table-column>
156
         </el-table-column>
156
 
157
 
380
         if(response.data.state == 1){
381
         if(response.data.state == 1){
381
           var drugInOrder = response.data.data.detail
382
           var drugInOrder = response.data.data.detail
382
           console.log("drug3434444",drugInOrder)
383
           console.log("drug3434444",drugInOrder)
384
+          var total_price = 0
385
+          for(let i=0;i<drugInOrder.length;i++){
386
+             drugInOrder[i].specification_name  = drugInOrder[i].dose + drugInOrder[i].dose_unit + "*" + drugInOrder[i].min_number +  drugInOrder[i].min_unit + "/" + drugInOrder[i].max_unit
387
+             drugInOrder[i].is_total = 0
388
+             total_price += drugInOrder[i].warehousing_count * drugInOrder[i].price
389
+          }
390
+           drugInOrder.push({
391
+            warehousing_order: "合计",
392
+            is_total: 1,
393
+            specification_name:"",
394
+            ctime:"",
395
+            total_price:total_price.toFixed(2),
396
+          });
397
+          console.log("hh23232323323223232332",drugInOrder)
383
           this.cancelStockDate = drugInOrder
398
           this.cancelStockDate = drugInOrder
384
            let objInfo = {}
399
            let objInfo = {}
385
           drugInOrder.forEach((item,index)=>{
400
           drugInOrder.forEach((item,index)=>{
424
             list[i].total_price = list[i].warehousing_count * list[i].price  
439
             list[i].total_price = list[i].warehousing_count * list[i].price  
425
           }
440
           }
426
           console.log("list666666666",list)
441
           console.log("list666666666",list)
442
+         
427
           this.tableList = list
443
           this.tableList = list
428
           var total = response.data.data.total
444
           var total = response.data.data.total
429
           this.total = total
445
           this.total = total

+ 17 - 2
src/xt_pages/stock/drugs/components/drugOutDetail.vue View File

148
         <el-table-column label="规格型号" align="center">
148
         <el-table-column label="规格型号" align="center">
149
           <template slot-scope="scope">
149
           <template slot-scope="scope">
150
            <!-- {{scope.row.drug_spec}} -->
150
            <!-- {{scope.row.drug_spec}} -->
151
-           {{scope.row.dose}}{{scope.row.dose_unit}}*{{scope.row.min_number}}{{scope.row.min_unit}}/{{scope.row.max_unit}}
151
+           {{scope.row.specification_name}}
152
           </template>
152
           </template>
153
         </el-table-column>
153
         </el-table-column>
154
 
154
 
181
         </el-table-column>
181
         </el-table-column>
182
         <el-table-column label="总价" align="center">
182
         <el-table-column label="总价" align="center">
183
           <template slot-scope="scope">
183
           <template slot-scope="scope">
184
-            {{scope.row.price * scope.row.count}}
184
+            <!-- {{scope.row.price * scope.row.count}} -->
185
+            {{scope.row.total_price}}
185
           </template>
186
           </template>
186
         </el-table-column>
187
         </el-table-column>
187
       </el-table>
188
       </el-table>
402
         if(response.data.state == 1){
403
         if(response.data.state == 1){
403
           var order = response.data.data.order
404
           var order = response.data.data.order
404
           console.log("出库数据",order)
405
           console.log("出库数据",order)
406
+          var total_price = 0
407
+          for(let i=0;i<order.length;i++){
408
+             order[i].specification_name  = order[i].dose + order[i].dose_unit + "*" + order[i].min_number +  order[i].min_unit + "/" + order[i].max_unit
409
+             order[i].is_total = 0
410
+             order[i].total_price = order[i].count * order[i].price
411
+             total_price += order[i].count * order[i].price
412
+          }
413
+           order.push({
414
+            warehouse_out_order_number: "合计",
415
+            is_total: 1,
416
+            specification_name:"",
417
+            ctime:"",
418
+            total_price:total_price.toFixed(2),
419
+          });
405
           this.tableData = order
420
           this.tableData = order
406
            let objInfo = {}
421
            let objInfo = {}
407
           order.forEach((item,index)=>{
422
           order.forEach((item,index)=>{

+ 1 - 1
src/xt_pages/stock/drugs/drugStockOutOrder.vue View File

1237
               total += this.drugFlowList[i].count
1237
               total += this.drugFlowList[i].count
1238
           }
1238
           }
1239
         }
1239
         }
1240
-        all_price = total * min_price
1240
+        all_price = total * price
1241
         console.log("total",total,min_price)
1241
         console.log("total",total,min_price)
1242
         return  all_price
1242
         return  all_price
1243
       },
1243
       },

+ 87 - 33
src/xt_pages/stock/drugs/inventory.vue View File

65
             </el-table-column>
65
             </el-table-column>
66
             <el-table-column prop="name" label="盘点数量" align="center">
66
             <el-table-column prop="name" label="盘点数量" align="center">
67
                 <template slot-scope="scope">
67
                 <template slot-scope="scope">
68
-                  {{scope.row.count}}
68
+                  {{scope.row.count}}{{scope.row.warehousing_unit}}<span v-if="scope.row.min_count>0">{{scope.row.min_count}}{{scope.row.min_unit}}</span>
69
                 </template>
69
                 </template>
70
             </el-table-column>
70
             </el-table-column>
71
             <el-table-column prop="name" label="盘点人" align="center">
71
             <el-table-column prop="name" label="盘点人" align="center">
156
                 </el-form-item>
156
                 </el-form-item>
157
 
157
 
158
                 <div style="width:100%;display:flex;">
158
                 <div style="width:100%;display:flex;">
159
-                    <el-form-item prop="dose" label="盘点数量" >
159
+                    <el-form-item prop="dose" label="盘点数量" style="width:100%;">
160
                       <el-input v-model="form.count" type="number" style="width:160px;" placeholder="盘点数量"></el-input>
160
                       <el-input v-model="form.count" type="number" style="width:160px;" placeholder="盘点数量"></el-input>
161
-                    </el-form-item>
162
-                    <el-form-item prop="dose_unit" class="noMargin">
163
-                      <el-select v-model="form.warehousing_unit" style="width:160px;" placeholder="最大单位">
161
+                      <el-select v-model="form.warehousing_unit" style="width:160px;" placeholder="最大单位" :disabled="true">
164
                       <el-option
162
                       <el-option
165
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
163
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
166
                         :key="index"
164
                         :key="index"
168
                         :value="item.name">
166
                         :value="item.name">
169
                       </el-option>
167
                       </el-option>
170
                     </el-select>
168
                     </el-select>
171
-                    </el-form-item>
172
-                    <el-form-item prop="min_count" class="noMargin">
173
-                     <el-input v-model="form.min_count"  style="width:160px;margin-left:10px" placeholder="盘点数量"></el-input>
174
-                    </el-form-item>
175
-                    <el-form-item prop="min_unit" class="noMargin">
176
-                     <el-select v-model="form.min_unit"  style="width:160px;" placeholder="最小单位">
169
+                    <el-input v-model="form.min_count"  style="width:160px;margin-left:10px" placeholder="盘点数量" ></el-input>
170
+                    <el-select v-model="form.min_unit"  style="width:160px;" placeholder="最小单位" :disabled="true">
177
                       <el-option
171
                       <el-option
178
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
172
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
179
                         :key="index"
173
                         :key="index"
182
                       </el-option>
176
                       </el-option>
183
                     </el-select>
177
                     </el-select>
184
                     </el-form-item>
178
                     </el-form-item>
179
+                      
185
                 </div>
180
                 </div>
186
 
181
 
187
                 <el-form-item label="库存">
182
                 <el-form-item label="库存">
226
                 </el-table-column>
221
                 </el-table-column>
227
                 <el-table-column prop="name"  label="盘点数量" width="100" align="center">
222
                 <el-table-column prop="name"  label="盘点数量" width="100" align="center">
228
                      <template slot-scope="scope">
223
                      <template slot-scope="scope">
229
-                       {{scope.row.count}}
224
+                       {{scope.row.count}}{{scope.row.warehousing_unit}}{{scope.row.min_count}}{{scope.row.min_unit}}
230
                     </template>
225
                     </template>
231
                 </el-table-column>
226
                 </el-table-column>
232
                 <el-table-column prop="name" label="原进货价" width="100" align="center">
227
                 <el-table-column prop="name" label="原进货价" width="100" align="center">
317
                       </el-option>
312
                       </el-option>
318
                   </el-select>
313
                   </el-select>
319
                 </el-form-item>
314
                 </el-form-item>
320
-                <!-- <el-form-item label="单位">
321
-                    <el-input v-model="form.warehousing_unit" :disabled="true"></el-input>
322
-                </el-form-item> -->
323
-               <el-form-item prop="warehousing_unit" label="单位">
324
-                    <el-select v-model="form.warehousing_unit" style="width:160px;" placeholder="单位" @change="changeMaxUnit">
315
+              
316
+                <el-form-item label="进货价">
317
+                    <el-input v-model="form.last_price" :disabled="true"></el-input>
318
+                </el-form-item>
319
+                <el-form-item label="零售价">
320
+                    <el-input v-model="form.retail_price" :disabled="true"></el-input>
321
+                </el-form-item>
322
+
323
+                <div style="width:100%;display:flex;">
324
+                    <el-form-item prop="dose" label="盘点数量" style="width:100%;">
325
+                      <el-input v-model="form.count" type="number" style="width:160px;" placeholder="盘点数量"></el-input>
326
+                      <el-select v-model="form.warehousing_unit" style="width:160px;" placeholder="最大单位" :disabled="true">
325
                       <el-option
327
                       <el-option
326
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
328
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
327
                         :key="index"
329
                         :key="index"
329
                         :value="item.name">
331
                         :value="item.name">
330
                       </el-option>
332
                       </el-option>
331
                     </el-select>
333
                     </el-select>
332
-                </el-form-item>
333
-                <el-form-item label="进货价">
334
-                    <el-input v-model="form.last_price" :disabled="true"></el-input>
335
-                </el-form-item>
336
-                <el-form-item label="零售价">
337
-                    <el-input v-model="form.retail_price" :disabled="true"></el-input>
338
-                </el-form-item>
339
-                <el-form-item label="盘点数量">
340
-                    <el-input v-model="form.count"></el-input>
341
-                </el-form-item>
334
+                    <el-input v-model="form.min_count"  style="width:160px;margin-left:10px" placeholder="盘点数量" ></el-input>
335
+                    <el-select v-model="form.min_unit"  style="width:160px;" placeholder="最小单位" :disabled="true">
336
+                      <el-option
337
+                        v-for="(item,index) in getDataConfig('hemodialysis','units')"
338
+                        :key="index"
339
+                        :label="item.name"
340
+                        :value="item.name">
341
+                      </el-option>
342
+                    </el-select>
343
+                 </el-form-item>
344
+                </div>
342
                 <el-form-item label="库存">
345
                 <el-form-item label="库存">
343
                     <el-input v-model="form.total" :disabled="true"></el-input>
346
                     <el-input v-model="form.total" :disabled="true"></el-input>
344
                 </el-form-item>
347
                 </el-form-item>
438
                 <!-- <el-form-item label="单位">
441
                 <!-- <el-form-item label="单位">
439
                     <el-input v-model="form.warehousing_unit" :disabled="true"></el-input>
442
                     <el-input v-model="form.warehousing_unit" :disabled="true"></el-input>
440
                 </el-form-item> -->
443
                 </el-form-item> -->
441
-                <el-form-item prop="warehousing_unit" label="单位">
444
+                <!-- <el-form-item prop="warehousing_unit" label="单位">
442
                     <el-select v-model="form.warehousing_unit" style="width:160px;" placeholder="单位" @change="changeMaxUnit">
445
                     <el-select v-model="form.warehousing_unit" style="width:160px;" placeholder="单位" @change="changeMaxUnit">
443
                       <el-option
446
                       <el-option
444
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
447
                         v-for="(item,index) in getDataConfig('hemodialysis','units')"
447
                         :value="item.name">
450
                         :value="item.name">
448
                       </el-option>
451
                       </el-option>
449
                     </el-select>
452
                     </el-select>
450
-                </el-form-item>
453
+                </el-form-item> -->
451
                 <el-form-item label="进货价">
454
                 <el-form-item label="进货价">
452
                     <el-input v-model="form.last_price" :disabled="true"></el-input>
455
                     <el-input v-model="form.last_price" :disabled="true"></el-input>
453
                 </el-form-item>
456
                 </el-form-item>
454
                 <el-form-item label="零售价">
457
                 <el-form-item label="零售价">
455
                     <el-input v-model="form.retail_price" :disabled="true"></el-input>
458
                     <el-input v-model="form.retail_price" :disabled="true"></el-input>
456
                 </el-form-item>
459
                 </el-form-item>
457
-                <el-form-item label="盘点数量">
460
+                <!-- <el-form-item label="盘点数量">
458
                     <el-input v-model="form.count"></el-input>
461
                     <el-input v-model="form.count"></el-input>
459
-                </el-form-item>
462
+                </el-form-item> -->
463
+              
464
+                <div style="width:100%;display:flex;">
465
+                    <el-form-item prop="dose" label="盘点数量" style="width:100%;">
466
+                      <el-input v-model="form.count" type="number" style="width:160px;" placeholder="盘点数量"></el-input>
467
+                      <el-select v-model="form.warehousing_unit" style="width:160px;" placeholder="最大单位" :disabled="true">
468
+                      <el-option
469
+                        v-for="(item,index) in getDataConfig('hemodialysis','units')"
470
+                        :key="index"
471
+                        :label="item.name"
472
+                        :value="item.name">
473
+                      </el-option>
474
+                    </el-select>
475
+                    <el-input v-model="form.min_count"  style="width:160px;margin-left:10px" placeholder="盘点数量" ></el-input>
476
+                    <el-select v-model="form.min_unit"  style="width:160px;" placeholder="最小单位" :disabled="true">
477
+                      <el-option
478
+                        v-for="(item,index) in getDataConfig('hemodialysis','units')"
479
+                        :key="index"
480
+                        :label="item.name"
481
+                        :value="item.name">
482
+                      </el-option>
483
+                    </el-select>
484
+                 </el-form-item>
485
+                </div>
460
                 <el-form-item label="库存">
486
                 <el-form-item label="库存">
461
                     <el-input v-model="form.total" :disabled="true"></el-input>
487
                     <el-input v-model="form.total" :disabled="true"></el-input>
462
                 </el-form-item>
488
                 </el-form-item>
708
                 this.form.expiry_date = val.expiry_date
734
                 this.form.expiry_date = val.expiry_date
709
                 this.form.product_date =val.product_date
735
                 this.form.product_date =val.product_date
710
                 this.form.drug_origin_place = val.drug_origin_place
736
                 this.form.drug_origin_place = val.drug_origin_place
737
+                this.form.min_unit = val.min_unit
711
              }
738
              }
712
            })
739
            })
713
         },
740
         },
740
             return str + min_str
767
             return str + min_str
741
         },
768
         },
742
         addInventory(){
769
         addInventory(){
770
+          console.log("this.for",this.form.batch_number,this.form.warehousing_order)
771
+          if(this.form.drug_name == ""){
772
+            this.$message.error("请输入药品名称")
773
+            return
774
+          }
775
+          if(this.form.batch_number == undefined){
776
+            this.$message.error("请选择批次")
777
+            return
778
+          }
779
+          if(this.form.count == ""){
780
+            this.$message.error("请输入盘点数量")
781
+            return
782
+          }
743
           var obj = {
783
           var obj = {
744
             drug_id:this.form.drug_id,
784
             drug_id:this.form.drug_id,
745
             drug_name:this.form.drug_name,
785
             drug_name:this.form.drug_name,
746
             warehousing_unit:this.form.warehousing_unit,
786
             warehousing_unit:this.form.warehousing_unit,
747
             count:this.form.count,
787
             count:this.form.count,
788
+            min_count:this.form.min_count,
789
+            min_unit:this.form.min_unit,
748
             retail_price:this.form.retail_price.toString(),
790
             retail_price:this.form.retail_price.toString(),
749
             manufacturer:this.form.manufacturer,
791
             manufacturer:this.form.manufacturer,
750
             drug_origin_place:this.form.drug_origin_place,
792
             drug_origin_place:this.form.drug_origin_place,
763
             product_date:this.form.product_date,
805
             product_date:this.form.product_date,
764
             warehouse_info_id:this.form.warehouse_info_id,
806
             warehouse_info_id:this.form.warehouse_info_id,
765
          } 
807
          } 
808
+         console.log("表格9999999",this.tableData)
766
          this.tableData.push(obj) 
809
          this.tableData.push(obj) 
767
          this.form.drug_name = ""  
810
          this.form.drug_name = ""  
768
          this.form.warehousing_unit = ""
811
          this.form.warehousing_unit = ""
796
            this.form.dealer = val.dealer
839
            this.form.dealer = val.dealer
797
            this.form.manufacturer = val.manufacturer
840
            this.form.manufacturer = val.manufacturer
798
            this.form.remark = val.remark
841
            this.form.remark = val.remark
799
-           this.form.warehousing_unit = val.max_unit  
842
+           this.form.warehousing_unit = val.warehousing_unit  
800
            this.form.total = val.total
843
            this.form.total = val.total
801
            this.form.batch_number = val.batch_number
844
            this.form.batch_number = val.batch_number
802
            this.form.last_price = val.last_price
845
            this.form.last_price = val.last_price
804
            this.form.expiry_date = val.expiry_date
847
            this.form.expiry_date = val.expiry_date
805
            this.form.product_date =val.product_date  
848
            this.form.product_date =val.product_date  
806
            this.form.count = val.count
849
            this.form.count = val.count
850
+           this.form.min_count = val.min_count
851
+           this.form.min_unit = val.min_unit
807
            this.index = index
852
            this.index = index
808
            this.editdialogVisible = true
853
            this.editdialogVisible = true
809
         },
854
         },
826
                this.tableData[i].expiry_date = this.form.expiry_date
871
                this.tableData[i].expiry_date = this.form.expiry_date
827
                this.tableData[i].product_date = this.form.product_date
872
                this.tableData[i].product_date = this.form.product_date
828
                this.tableData[i].count =this.form.count
873
                this.tableData[i].count =this.form.count
874
+               this.tableData[i].min_unit = this.form.min_unit
875
+               this.tableData[i].min_count = this.form.min_count
829
              }
876
              }
830
             if(this.index == i){
877
             if(this.index == i){
831
                this.tableData[i].drug_id = this.form.drug_id
878
                this.tableData[i].drug_id = this.form.drug_id
844
                this.tableData[i].expiry_date = this.form.expiry_date
891
                this.tableData[i].expiry_date = this.form.expiry_date
845
                this.tableData[i].product_date = this.form.product_date
892
                this.tableData[i].product_date = this.form.product_date
846
                this.tableData[i].count =this.form.count
893
                this.tableData[i].count =this.form.count
894
+               this.tableData[i].min_unit = this.form.min_unit
895
+               this.tableData[i].min_count = this.form.min_count
847
              }
896
              }
848
           }   
897
           }   
849
           this.editdialogVisible = false
898
           this.editdialogVisible = false
853
               this.tableData[i].retail_price = this.tableData[i].retail_price.toString()
902
               this.tableData[i].retail_price = this.tableData[i].retail_price.toString()
854
               this.tableData[i].last_price = this.tableData[i].last_price.toString()
903
               this.tableData[i].last_price = this.tableData[i].last_price.toString()
855
               this.tableData[i].count = parseInt(this.tableData[i].count)
904
               this.tableData[i].count = parseInt(this.tableData[i].count)
905
+              this.tableData[i].min_count = parseInt(this.tableData[i].min_count)
856
               if(this.tableData[i].expiry_date == undefined){
906
               if(this.tableData[i].expiry_date == undefined){
857
                 this.tableData[i].expiry_date  = 0
907
                 this.tableData[i].expiry_date  = 0
858
               }else{
908
               }else{
984
             this.form.stock_max_number = detail.stock_max_number
1034
             this.form.stock_max_number = detail.stock_max_number
985
             this.form.stock_min_number = detail.stock_min_number
1035
             this.form.stock_min_number = detail.stock_min_number
986
             this.form.warehouse_info_id = detail.warehouse_info_id
1036
             this.form.warehouse_info_id = detail.warehouse_info_id
1037
+            this.form.min_unit = detail.min_unit
1038
+            this.form.min_count = detail.min_count
987
             this.modifydialogVisible = true
1039
             this.modifydialogVisible = true
988
          }
1040
          }
989
        })
1041
        })
997
           warehousing_unit:this.form.warehousing_unit,
1049
           warehousing_unit:this.form.warehousing_unit,
998
           last_price:this.form.last_price,
1050
           last_price:this.form.last_price,
999
           retail_price:this.form.retail_price,
1051
           retail_price:this.form.retail_price,
1000
-          count:this.form.count,
1052
+          count:parseInt(this.form.count),
1001
           total:this.form.total,
1053
           total:this.form.total,
1002
           drug_origin_place:this.form.drug_origin_place,
1054
           drug_origin_place:this.form.drug_origin_place,
1003
           batch_number:this.form.batch_number,
1055
           batch_number:this.form.batch_number,
1006
           stock_max_number:this.form.stock_max_number,
1058
           stock_max_number:this.form.stock_max_number,
1007
           stock_min_number:this.form.stock_min_number,
1059
           stock_min_number:this.form.stock_min_number,
1008
           warehouse_info_id:this.form.warehouse_info_id,
1060
           warehouse_info_id:this.form.warehouse_info_id,
1061
+          min_count:parseInt(this.form.min_count),
1062
+          min_unit:this.form.min_unit,
1009
        }
1063
        }
1010
        console.log("params2222",params)
1064
        console.log("params2222",params)
1011
       
1065
       

+ 5 - 5
src/xt_pages/stock/drugs/inventoryDetails.vue View File

41
                 <el-button size="small" type="primary">导出</el-button>
41
                 <el-button size="small" type="primary">导出</el-button>
42
             </div> -->
42
             </div> -->
43
         </div>
43
         </div>
44
-        <el-table :data="tableData" border :header-cell-style="{ backgroundColor: 'rgb(245, 247, 250)' }">
45
-            <el-table-column prop="date" label="药品名称" width="100" align="center">
44
+        <el-table :data="tableData" border :header-cell-style="{ backgroundColor: 'rgb(245, 247, 250)' }" style="width:100%">
45
+            <el-table-column prop="date" label="药品名称" width="200" align="center">
46
                <template slot-scope="scope">
46
                <template slot-scope="scope">
47
                  {{scope.row.drug_name}}
47
                  {{scope.row.drug_name}}
48
                </template>
48
                </template>
89
             </el-table-column>
89
             </el-table-column>
90
             <el-table-column prop="name" label="实盘点" width="100"  align="center">
90
             <el-table-column prop="name" label="实盘点" width="100"  align="center">
91
                <template slot-scope="scope">
91
                <template slot-scope="scope">
92
-                  {{scope.row.count}}
92
+                  {{scope.row.count}}{{scope.row.warehousing_unit}} <span v-if="scope.row.min_count">{{scope.row.min_count}}{{scope.row.min_unit}}</span>
93
                 </template> 
93
                 </template> 
94
             </el-table-column>
94
             </el-table-column>
95
-            <el-table-column  prop="name" label="亏损价格" width="100"  align="center">
95
+            <!-- <el-table-column  prop="name" label="亏损价格" width="100"  align="center">
96
                <template slot-scope="scope">
96
                <template slot-scope="scope">
97
                
97
                
98
                 </template>  
98
                 </template>  
99
-            </el-table-column>
99
+            </el-table-column> -->
100
             <el-table-column prop="name" label="生产日期" width="100"  align="center">
100
             <el-table-column prop="name" label="生产日期" width="100"  align="center">
101
                 <template slot-scope="scope">
101
                 <template slot-scope="scope">
102
                   {{getTime(scope.row.product_date)}}
102
                   {{getTime(scope.row.product_date)}}

+ 4 - 6
src/xt_pages/stock/stockQuery.vue View File

546
         }
546
         }
547
       getStockDrugCount(params).then(response=>{
547
       getStockDrugCount(params).then(response=>{
548
          if(response.data.state == 1){
548
          if(response.data.state == 1){
549
-          //  var count = response.data.data.count
550
-          //  console.log("入库统计",count)
551
-          //  this.countList = count
549
+         
552
            var outlist = response.data.data.outList
550
            var outlist = response.data.data.outList
553
            console.log("出库数量",outlist)
551
            console.log("出库数量",outlist)
554
            this.outCountList = outlist
552
            this.outCountList = outlist
555
            var autoCount = response.data.data.autoCount
553
            var autoCount = response.data.data.autoCount
556
            console.log("autoCount",autoCount)
554
            console.log("autoCount",autoCount)
557
            this.autoCountList = autoCount
555
            this.autoCountList = autoCount
558
-          //  var totalCount = response.data.data.totalCount
559
-          //  console.log("totalcount",totalCount)
560
-          //  this.cancelCountList = totalCount
556
+           var totalCount = response.data.data.totalCount
557
+           console.log("totalcount",totalCount)
558
+           this.cancelCountList = totalCount
561
          }
559
          }
562
       })
560
       })
563
     },
561
     },

+ 1 - 1
src/xt_pages/workforce/remind_print_setting.vue View File

46
                 </div> 
46
                 </div> 
47
                 <div v-if="org_id == 10188">干体重:{{main_collection.assessmentbefor.dry_weight}}</div>
47
                 <div v-if="org_id == 10188">干体重:{{main_collection.assessmentbefor.dry_weight}}</div>
48
                 <div v-if="org_id == 10188">透前体重:{{main_collection.assessmentbefor.weight_before}}</div>
48
                 <div v-if="org_id == 10188">透前体重:{{main_collection.assessmentbefor.weight_before}}</div>
49
-                <div v-if="org_id == 10188">体重增加:{{main_collection.assessmentbefor.weight_before - main_collection.assessmentbefor.dry_weight}}</div>
49
+                <div v-if="org_id == 10188">体重增加:{{(main_collection.assessmentbefor.weight_before - main_collection.assessmentbefor.dry_weight).toFixed(2)}}</div>
50
                 <div>用法:静脉注射</div> 
50
                 <div>用法:静脉注射</div> 
51
                 <div>打印时间:{{currentDate}}</div>
51
                 <div>打印时间:{{currentDate}}</div>
52
               </div>
52
               </div>