XMLWAN 4 jaren geleden
bovenliggende
commit
fda8599d90

+ 4 - 2
src/xt_pages/data/components/drugTableSon.vue Bestand weergeven

@@ -389,11 +389,13 @@
389 389
         });
390 390
       },
391 391
       createData() {
392
-        
392
+        if(this.temp.code == undefined){
393
+           this.temp.code = ""
394
+        }
393 395
         this.$refs["dataForm"].validate(valid => {
394 396
           if (valid) {
395 397
             console.log("33333333",this.temp)
396
-           
398
+            
397 399
             createDictionaryChildConfig(this.temp).then(response => {
398 400
               if (!response.data) {
399 401
                 // 由于mockjs 不支持自定义状态码只能这样hack

+ 351 - 21
src/xt_pages/outpatientCharges/outpatientChargesManagement.vue Bestand weergeven

@@ -22,15 +22,17 @@
22 22
             <el-radio :label=2>已收费<span style="color: red;margin-bottom:10px;display: inline-block;">{{cal_two}}</span>人
23 23
             </el-radio>
24 24
             <!--<el-radio :label=3>已退费<span-->
25
-              <!--style="color: red;margin-bottom:10px;display: inline-block;">{{cal_three}}</span>人-->
25
+            <!--style="color: red;margin-bottom:10px;display: inline-block;">{{cal_three}}</span>人-->
26 26
             <!--</el-radio>-->
27 27
             <el-radio :label=4>全部</el-radio>
28 28
 
29 29
           </el-radio-group>
30 30
         </div>
31 31
         <div class="mainCell" style="margin-bottom:10px;">
32
-          <el-input size="small" @keyup.enter.native='searchAction' v-model.trim="search_input" class="filter-item"/>
33
-          <el-button size="small" style="margin-left:10px;" class="filter-item" type="primary" @click="searchAction">
32
+          <el-input size="small" @keyup.enter.native='searchAction' v-model.trim="search_input"
33
+                    class="filter-item"/>
34
+          <el-button size="small" style="margin-left:10px;" class="filter-item" type="primary"
35
+                     @click="searchAction">
34 36
             搜索
35 37
           </el-button>
36 38
         </div>
@@ -45,14 +47,53 @@
45 47
               <template slot-scope="scope">{{scope.row.name}}</template>
46 48
             </el-table-column>
47 49
             <el-table-column align="center" prop="name" label="就诊号" width="110">
48
-              <template slot-scope="scope">{{ scope.row.his_patient ?scope.row.his_patient.number:''}}</template>
50
+              <template slot-scope="scope">{{ scope.row.his_patient ?scope.row.his_patient.number:''}}
51
+              </template>
49 52
             </el-table-column>
50 53
           </el-table>
51 54
         </div>
52 55
       </div>
56
+
53 57
       <div class="mainRight">
54 58
 
55 59
         <div class="mainCell fixedCell" style="margin-bottom:10px;">
60
+          <el-button v-loading="loadingone" size="small"
61
+                     @click="sz_open(1)"
62
+
63
+                     type="primary">深圳挂号
64
+          </el-button>
65
+
66
+          <el-button v-loading="loadingtwo"
67
+                     v-if="(this.hisPatientInfo.id > 0 && this.order.id == 0) || this.order.order_status == 1"
68
+                     size="small"
69
+                     @click="sz_open(3)"
70
+                     type="primary">深圳收费
71
+          </el-button>
72
+
73
+          <el-button size="small" @click="sz_open(5)" type="primary"
74
+                     v-if="this.order.order_status == 2"
75
+          >
76
+            深圳退费
77
+          </el-button>
78
+
79
+          <!--<el-button size="small" @click="sz_open(8)" type="primary"-->
80
+          <!--&gt;-->
81
+          <!--跨月退费-->
82
+          <!--</el-button>-->
83
+
84
+          <el-button  size="small" @click="sz_open(6)" type="primary"
85
+                      v-if="this.order.order_status == 2"
86
+          >深圳结算单
87
+          </el-button>
88
+
89
+          <el-button
90
+            v-if="$store.getters.xt_user.org_id == 4  ||  this.$store.getters.xt_user.org_id == 3877"
91
+            size="small" @click="sz_open(7)" type="primary"
92
+          >深圳撤销明细
93
+          </el-button>
94
+
95
+
96
+
56 97
           <!-- <el-button size="small" @click="open(1)" type="primary" style="margin-left:10px;">打印处置单</el-button>
57 98
           <el-button size="small" @click="open(2)" type="primary">打印治疗单</el-button> -->
58 99
           <el-button size="small" @click="open(3)" type="primary">打印</el-button>
@@ -69,23 +110,26 @@
69 110
 
70 111
 
71 112
           <!--<el-button v-loading="loadingtwo" v-if="this.hisPatientInfo.id > 0 && this.order.id == 0" size="small"-->
72
-                     <!--@click="open(20)"-->
73
-                     <!--type="primary">预结算!-->
113
+          <!--@click="open(20)"-->
114
+          <!--type="primary">预结算!-->
74 115
           <!--</el-button>-->
75 116
 
76 117
           <!--<el-button v-loading="loadingtwo" v-if="(this.hisPatientInfo.id > 0 && this.order.id == 0) || this.order.order_status == 1 ||  this.order.order_status == 3" size="small"-->
77
-                     <!--@click="open(21)"-->
78
-                     <!--type="primary">收费!-->
118
+          <!--@click="open(21)"-->
119
+          <!--type="primary">收费!-->
79 120
           <!--</el-button>-->
80 121
 
81 122
 
82
-          <el-button v-loading="loadingtwo" v-if="(this.hisPatientInfo.id > 0 && this.order.id == 0) || this.order.order_status == 1 ||  this.order.order_status == 3" size="small"
123
+          <el-button v-loading="loadingtwo"
124
+                     v-if="(this.hisPatientInfo.id > 0 && this.order.id == 0) || this.order.order_status == 1 ||  this.order.order_status == 3"
125
+                     size="small"
83 126
                      @click="open(4)"
84 127
                      type="primary">收费
85 128
           </el-button>
86 129
 
87 130
           <el-button size="small" @click="open(5)" type="primary"
88
-                     v-if="this.hisPatientInfo.id > 0 && this.order.id > 0 &&  this.order.order_status == 2">退费
131
+                     v-if="this.hisPatientInfo.id > 0 && this.order.id > 0 &&  this.order.order_status == 2">
132
+            退费
89 133
           </el-button>
90 134
 
91 135
           <!--<el-button size="small" @click="open(5)" type="primary"-->
@@ -105,8 +149,9 @@
105 149
           >结算单
106 150
           </el-button>
107 151
 
108
-          <el-button v-if="this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 3877"
109
-                     size="small" @click="open(10)" type="primary"
152
+          <el-button
153
+            v-if="this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 3877"
154
+            size="small" @click="open(10)" type="primary"
110 155
           >退号
111 156
           </el-button>
112 157
 
@@ -126,13 +171,16 @@
126 171
           <!--&gt;查待遇-->
127 172
           <!--</el-button>-->
128 173
 
129
-          <el-button  size="small" @click="query" type="primary"
174
+          <el-button size="small" @click="query" type="primary"
130 175
           >查询
131 176
           </el-button>
132 177
 
133 178
 
134 179
         </div>
135 180
 
181
+
182
+
183
+
136 184
         <div class="mainCenter" v-loading="loading">
137 185
           <el-tabs class="settlementTabs" v-model="activeName" @tab-click="handleClick">
138 186
             <el-tab-pane label="日结" name="first">
@@ -140,7 +188,8 @@
140 188
                 <div class="centerLeft">
141 189
                   <div class="tabsBox">
142 190
                     <!--<el-button type="text" class="addTab" @click="addCharges" icon="el-icon-circle-plus">附加收费</el-button>-->
143
-                    <el-tabs class="preTabs" v-model="editableTabsValue" type="border-card" @tab-click="tabclickEvent">
191
+                    <el-tabs class="preTabs" v-model="editableTabsValue" type="border-card"
192
+                             @tab-click="tabclickEvent">
144 193
                       <el-tab-pane
145 194
                         v-for="(item, index) in prescriptions"
146 195
                         :key="index"
@@ -294,7 +343,8 @@
294 343
                     <li style="width:50%;">医生:{{ info.doctor }}</li>
295 344
                     <li style="width:50%;">科室:{{ getDepartment(info.departments) }}</li>
296 345
                     <li style="width:100%;" v-if="activeName == 'first'">总费用:{{ getTotal() }}</li>
297
-                    <li style="width:100%;" v-if="activeName == 'second'">总费用:{{ getTotalTwo() }}</li>
346
+                    <li style="width:100%;" v-if="activeName == 'second'">总费用:{{ getTotalTwo() }}
347
+                    </li>
298 348
 
299 349
                     <li style="width:100%;">判断结果:{{info.diagnosis}}</li>
300 350
                     <!--<li style="width:100%;">是否有传染病:</li>-->
@@ -568,7 +618,48 @@
568 618
         }
569 619
 
570 620
         this.loadingtwo = true
571
-        if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 3877) {
621
+        if (this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538){
622
+
623
+          var that = this
624
+          axios.get('http://127.0.0.1:9532/sz/api/settle/get', {
625
+            params: form
626
+          })
627
+            .then(function(response) {
628
+              if (response.data.state == 0) {
629
+                that.$message.error(response.data.msg)
630
+                that.loadingtwo = false
631
+                that.$refs.charge.hide()
632
+                return false
633
+              } else {
634
+                if (response.data.data.failed_code == -10){
635
+
636
+                  that.$message.error(response.data.data.msg)
637
+
638
+                }else{
639
+                  that.changeRadio(2)
640
+                  that.radio = 2
641
+
642
+                  that.$refs.charge.hide()
643
+                  that.loadingtwo = false
644
+                  that.state = '已收费'
645
+                  that.$message({ message: '收费成功', type: 'success' })
646
+                  that.loadingtwo = false
647
+                  that.cal_one = this.cal_one - 1
648
+                  that.cal_two = this.cal_two + 1
649
+                  that.patientTableData.splice(this.current_index, 1)
650
+
651
+
652
+                }
653
+
654
+
655
+              }
656
+            })
657
+            .catch(function(error) {
658
+
659
+            })
660
+
661
+
662
+        }else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 3877) {
572 663
           var that = this
573 664
           axios.get('http://127.0.0.1:9532/api/upload/get', {
574 665
             params: form
@@ -620,14 +711,88 @@
620 711
         this.$refs.charge.hide()
621 712
       },
622 713
       confirm(forms) {
714
+        console.log(forms)
715
+
623 716
         forms['record_time'] = this.record_date
624 717
         forms['admin_user_id'] = this.$store.getters.xt_user.user.id
625 718
         forms['org_id'] = this.$store.getters.xt_user.org_id
626 719
 
627 720
         this.loadingone = true
628 721
 
629
-        if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 3877) {
630
-          var that = this
722
+        var that = this
723
+
724
+
725
+        if(this.$store.getters.xt_user.org_id == 9538 ||this.$store.getters.xt_user.org_id == 4 ){
726
+
727
+          axios.get('http://127.0.0.1:9532/sz/api/register/get', {
728
+            params: forms
729
+          })
730
+            .then(function(response) {
731
+              if (response.data.state == 0) {
732
+                that.$message.error(response.data.msg)
733
+                that.loadingone = false
734
+                that.$refs.register.hide()
735
+                return false
736
+              } else {
737
+                if (response.data.data.failed_code == -10){
738
+                  that.$message.error(response.data.data.msg)
739
+                  return
740
+                }else {
741
+                  that.$refs.register.hide()
742
+                  let params = {
743
+                    'record_date': that.record_date
744
+                  }
745
+                  getChargeHisPatientList(params).then(response => {
746
+                    if (response.data.state == 0) {
747
+                      that.$message.error(response.data.msg)
748
+                      return false
749
+                    } else {
750
+                      that.loadingone = false
751
+
752
+                      that.patientTableData = []
753
+                      that.all_table_data = []
754
+                      that.hisPatientDatas = []
755
+
756
+                      let one_count = 0
757
+                      let two_count = 0
758
+                      let three_count = 0
759
+                      for (let i = 0; i < response.data.data.list.length; i++) {
760
+                        that.all_table_data.push(response.data.data.list[i])
761
+                        if (response.data.data.list[i].order.order_status == 0 || response.data.data.list[i].order.order_status == 1 || response.data.data.list[i].order.order_status == 3) {
762
+                          one_count = one_count + 1
763
+                          that.patientTableData.push(response.data.data.list[i])
764
+                        }
765
+                        if (response.data.data.list[i].order.order_status == 2) {
766
+                          two_count = two_count + 1
767
+                          that.patientTableData.push(response.data.data.list[i])
768
+                        }
769
+                      }
770
+                      that.hisPatientDatas = response.data.data.list_two
771
+                      that.cal_one = one_count
772
+                      that.cal_two = two_count
773
+                      that.cal_three = three_count
774
+                      that.current_index = 0
775
+
776
+                      for (let i = 0; i < that.patientTableData.length; i++) {
777
+                        if (this.patientTableData[i].id == this.patientInfo.id) {
778
+                          that.$refs.tab.setCurrentRow(that.patientTableData[i])
779
+                          that.getPatientInformation(that.patientTableData[i].id, that.patientTableData[i].order.number)
780
+                        }
781
+                      }
782
+                      that.$message({ message: '挂号成功', type: 'success' })
783
+                      that.loadingone = false
784
+                      var his_info = response.data.data.his_info
785
+                      that.hisPatientInfo = his_info
786
+                    }
787
+                  })
788
+                }
789
+              }
790
+            })
791
+            .catch(function(error) {
792
+
793
+            })
794
+
795
+        } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 3877 ) {
631 796
 
632 797
           axios.get('http://127.0.0.1:9532/api/register/get', {
633 798
             params: forms
@@ -1344,10 +1509,11 @@
1344 1509
               .then(function(response) {
1345 1510
                 if (response.data.state == 0) {
1346 1511
                   that.$message.error(response.data.msg)
1347
-                  that.loadingtwo = false
1512
+                  // that.loadingtwo = false
1348 1513
                   return false
1349 1514
                 } else {
1350 1515
 
1516
+
1351 1517
                 }
1352 1518
               })
1353 1519
               .catch(function(error) {
@@ -1391,7 +1557,7 @@
1391 1557
 
1392 1558
             'patient_id': this.patientInfo.id,
1393 1559
             'record_time': this.record_date,
1394
-            "org_id": this.$store.getters.xt_user.org_id
1560
+            'org_id': this.$store.getters.xt_user.org_id
1395 1561
           }
1396 1562
           axios.get('http://127.0.0.1:9532/api/refundnumber/post', {
1397 1563
             params: params
@@ -1414,7 +1580,7 @@
1414 1580
             'number': this.order.number,
1415 1581
             'patient_id': this.patientInfo.id,
1416 1582
             'record_time': this.record_date,
1417
-            "org_id": this.$store.getters.xt_user.org_id
1583
+            'org_id': this.$store.getters.xt_user.org_id
1418 1584
           }
1419 1585
           axios.get('http://127.0.0.1:9532/api/refunddetail/post', {
1420 1586
             params: params
@@ -2256,6 +2422,170 @@
2256 2422
 
2257 2423
           }
2258 2424
         })
2425
+      },
2426
+      sz_open(index) {
2427
+        switch (index) {
2428
+          case 1:
2429
+            this.$refs.register.show()
2430
+            break
2431
+          case 2:
2432
+            var that = this
2433
+            if (this.activeName == 'first') {
2434
+              this.settle_accounts_type = 1
2435
+
2436
+            } else {
2437
+              this.settle_accounts_type = 2
2438
+              this.start_time = this.other_start_time
2439
+              this.end_time = this.other_end_time
2440
+              this.settle_accounts_type = 2
2441
+
2442
+            }
2443
+            let params = {
2444
+              'patient_id': this.patientInfo.id,
2445
+              'record_time': this.record_date,
2446
+              'settle_accounts_type':this.settle_accounts_type,
2447
+              'admin_user_id': this.$store.getters.xt_user.user.id,
2448
+            }
2449
+            axios.get('http://127.0.0.1:9532/sz/api/upload/get', {
2450
+              params: params
2451
+            })
2452
+              .then(function(response) {
2453
+                if (response.data.state == 0) {
2454
+                  that.$message.error(response.data.msg)
2455
+                  return false
2456
+                } else {
2457
+
2458
+                  if (response.data.data.failed_code == -10){
2459
+                    that.$message.error(response.data.data.msg)
2460
+
2461
+                  }else {
2462
+                    that.changeRadio(1)
2463
+                    that.$message({ message: '预结算成功', type: 'success' })
2464
+                  }
2465
+
2466
+                }
2467
+              })
2468
+              .catch(function(error) {
2469
+              })
2470
+            break
2471
+          case 3:
2472
+            if (this.activeName == 'first') {
2473
+              this.$refs.charge.show(this.getTotal())
2474
+            } else {
2475
+              this.$refs.charge.show(this.getTotalTwo())
2476
+            }
2477
+            break
2478
+          case 4:
2479
+            break
2480
+          case 5:
2481
+            var that = this
2482
+            this.$confirm('是否退费', '退费', {
2483
+              confirmButtonText: '确 定',
2484
+              cancelButtonText: '取 消',
2485
+              type: 'warning'
2486
+            }).then(() => {
2487
+              axios.get('http://127.0.0.1:9532/sz/api/refund/get', {
2488
+                params: {
2489
+                  order_id:this.order.id,
2490
+                  record_time: this.record_date,
2491
+                  admin_user_id:this.$store.getters.xt_user.user.id,
2492
+                  patient_id:this.patientInfo.id
2493
+                }
2494
+              })
2495
+                .then(function(response) {
2496
+                  if (response.data.state == 0) {
2497
+                    that.$message.error(response.data.msg)
2498
+                    return false
2499
+                  } else {
2500
+                    if (response.data.data.failed_code == -10){
2501
+                      that.$message.error(response.data.data.msg)
2502
+
2503
+                    }else {
2504
+                      that.changeRadio(1)
2505
+                      that.$message({ message: '退费成功', type: 'success' })
2506
+                    }
2507
+                  }
2508
+                })
2509
+                .catch(function(error) {
2510
+                })
2511
+            }).catch(() => {
2512
+            })
2513
+            break
2514
+          case 6:
2515
+            var that = this
2516
+            axios.get('http://127.0.0.1:9532/sz/api/settle/query', {
2517
+              params: {
2518
+                order_id:this.order.id,
2519
+                record_time: this.record_date,
2520
+                admin_user_id:this.$store.getters.xt_user.user.id,
2521
+                patient_id:this.patientInfo.id
2522
+
2523
+              }
2524
+            })
2525
+              .then(function(response) {
2526
+                if (response.data.state == 0) {
2527
+                  that.$message.error(response.data.msg)
2528
+                  return false
2529
+                } else {
2530
+                  if (response.data.data.failed_code == -10){
2531
+
2532
+                    that.$message.error(response.data.data.msg)
2533
+
2534
+                  }else{
2535
+                    if (response.data.data.failed_code == -10){
2536
+                      that.$message.error(response.data.data.msg)
2537
+
2538
+                    }else {
2539
+                      that.$message({ message: '查询成功', type: 'success' })
2540
+
2541
+                    }
2542
+
2543
+
2544
+                  }
2545
+                }
2546
+              })
2547
+              .catch(function(error) {
2548
+              })
2549
+            break
2550
+          case 7:
2551
+            var that = this
2552
+            axios.get('http://127.0.0.1:9532/sz/api/detail/cancel', {
2553
+              params: {
2554
+                order_id:this.order.id,
2555
+                record_time: this.record_date,
2556
+                admin_user_id:this.$store.getters.xt_user.user.id,
2557
+                patient_id:this.patientInfo.id
2558
+
2559
+              }
2560
+            })
2561
+              .then(function(response) {
2562
+                if (response.data.state == 0) {
2563
+                  that.$message.error(response.data.msg)
2564
+                  return false
2565
+                } else {
2566
+                  if (response.data.data.failed_code == -10){
2567
+
2568
+                    that.$message.error(response.data.data.msg)
2569
+
2570
+                  }else{
2571
+                    if (response.data.data.failed_code == -10){
2572
+                      that.$message.error(response.data.data.msg)
2573
+
2574
+                    }else {
2575
+                      that.$message({ message: '明细撤销成功', type: 'success' })
2576
+
2577
+                    }
2578
+
2579
+
2580
+                  }
2581
+                }
2582
+              })
2583
+              .catch(function(error) {
2584
+              })
2585
+            break
2586
+
2587
+        }
2588
+
2259 2589
       }
2260 2590
     },
2261 2591
     mounted() {

+ 36 - 29
src/xt_pages/stock/detail/stockInDetail.vue Bestand weergeven

@@ -723,36 +723,43 @@ export default {
723 723
         r2 = Number(total.toString().replace('.', ''))
724 724
         return r1 * r2 / Math.pow(10, m)
725 725
       },
726
-    
727
-    exportList(){
728
-       var obj = {index:"合计",total:0}
729
-       obj.total = this.calTotalPrice()
730
-      for(let i=0;i<this.tableList.length;i++){
731
-        this.tableList[i].index = i+1
732
-        this.tableList[i].min_unit = this.getUnit(this.tableList[i].good_unit)
733
-        this.tableList[i].count = this.calCount(this.tableList[i])
734
-        this.tableList[i].total = this.calTotal(this.tableList[i])
735
-        this.tableList[i].price = this.tableList[i].query_warehousing_info[0].price
736
-        this.tableList[i].remark = this.tableList[i].query_warehousing_info[0].remark
726
+      unique(arr) {
727
+        const res = new Map();
728
+        return arr.filter((arr) => !res.has(arr.specification_name) && res.set(arr.specification_name, 1));
729
+      },
730
+      exportList(){
731
+        var obj = {index:"合计",total:0}
732
+        obj.total = this.calTotalPrice()
733
+     
734
+        for(let i=0;i<this.tableList.length;i++){
735
+          this.tableList[i].index = i+1
736
+          this.tableList[i].min_unit = this.getUnit(this.tableList[i].good_unit)
737
+          this.tableList[i].count = this.calCount(this.tableList[i])
738
+          this.tableList[i].total = this.calTotal(this.tableList[i])
739
+          this.tableList[i].price = this.tableList[i].query_warehousing_info[0].price
740
+          this.tableList[i].remark = this.tableList[i].query_warehousing_info[0].remark
737 741
 
738
-       }
739
-       this.tableList.push(obj)
740
-       console.log("数据222222",this.tableList)
741
-    
742
-       import('@/vendor/Export2Excel').then(excel => {
743
-       const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']
744
-       const filterVal = ['index','good_name', 'specification_name', 'min_unit','count','price','total','remark']
745
-       
746
-       const data = this.formatJson(filterVal, this.tableList)
747
-       
748
-        excel.export_json_to_excel({
749
-           header: tHeader,
750
-           data,
751
-           filename: '耗材入库明细'
752
-         })
753
-          this.downloadLoading = false
754
-        })
755
-       },
742
+        }
743
+        var arr = this.unique(this.tableList)
744
+        console.log("arrrr",arr)
745
+        this.tableList = arr
746
+        this.tableList.push(obj)
747
+        console.log("数据222222",this.tableList)
748
+      
749
+        import('@/vendor/Export2Excel').then(excel => {
750
+        const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']
751
+        const filterVal = ['index','good_name', 'specification_name', 'min_unit','count','price','total','remark']
752
+        
753
+        const data = this.formatJson(filterVal, this.tableList)
754
+        
755
+          excel.export_json_to_excel({
756
+            header: tHeader,
757
+            data,
758
+            filename: '耗材入库明细'
759
+          })
760
+            this.downloadLoading = false
761
+          })
762
+        },
756 763
      formatJson(filterVal, jsonData) {
757 764
         return jsonData.map(v => filterVal.map(j => v[j]));
758 765
      },

+ 7 - 1
src/xt_pages/stock/detail/stockOutDetail.vue Bestand weergeven

@@ -709,7 +709,10 @@ export default {
709 709
         r2 = Number(total.toString().replace('.', ''))
710 710
         return r1 * r2 / Math.pow(10, m)
711 711
       },
712
-
712
+      unique(arr) {
713
+        const res = new Map();
714
+        return arr.filter((arr) => !res.has(arr.specification_name) && res.set(arr.specification_name, 1));
715
+      },
713 716
 
714 717
      exportList(){
715 718
 
@@ -723,6 +726,9 @@ export default {
723 726
         this.tableList[i].total = (this.getStockCount(this.tableList[i].id) * this.tableList[i].query_warehouseout_info[0].price).toFixed(2)
724 727
         this.tableList[i].remark = this.tableList[i].query_warehouseout_info[0].remark
725 728
        }
729
+       var arr = this.unique(this.tableList)
730
+       console.log("22222222222222222气",arr)
731
+       this.tableList = arr
726 732
        this.tableList.push(obj)
727 733
        import('@/vendor/Export2Excel').then(excel => {
728 734
        const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']

+ 1 - 1
src/xt_pages/stock/drugs/components/drugOutDetail.vue Bestand weergeven

@@ -180,7 +180,7 @@
180 180
       <el-pagination
181 181
         @size-change="handleSizeChange"
182 182
         @current-change="handleCurrentChange"
183
-        :page-sizes="[10, 50, 100]"
183
+        :page-sizes="[10, 50, 100,1000]"
184 184
         :page-size="10"
185 185
         background
186 186
         style="margin-top:20px;float: right"