XMLWAN 3 年前
父节点
当前提交
29c6b3d406

+ 1 - 1
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue 查看文件

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) {

+ 30 - 5
src/xt_pages/qcd/workAnalysis/nurse.vue 查看文件

149
               </template>
149
               </template>
150
             </el-table-column>
150
             </el-table-column>
151
 
151
 
152
-            <el-table-column label="开瘘" align="center">
152
+            <el-table-column label="冲管" align="center">
153
               <template slot-scope="scope">
153
               <template slot-scope="scope">
154
-                {{scope.row.new_nuser_count?scope.row.new_nuser_count:''}}
154
+                {{scope.row.total_washpipe_nurse?scope.row.total_washpipe_nurse:''}}
155
 
155
 
156
               </template>
156
               </template>
157
             </el-table-column>
157
             </el-table-column>
162
                 <span v-if="getTotalCount(scope.row.admin_user_id)!=''">({{getTotalCount(scope.row.admin_user_id)}})</span>
162
                 <span v-if="getTotalCount(scope.row.admin_user_id)!=''">({{getTotalCount(scope.row.admin_user_id)}})</span>
163
               </template>
163
               </template>
164
             </el-table-column>
164
             </el-table-column>
165
+            
166
+             <el-table-column label="下机" align="center">
167
+              <template slot-scope="scope">
168
+                {{scope.row.finish_nuser_count?scope.row.finish_nuser_count:''}}
169
+              </template>
170
+            </el-table-column>
165
 
171
 
172
+            <el-table-column label="冲管" align="center">
173
+              <template slot-scope="scope">
174
+                {{scope.row.finish_nuser_count?scope.row.finish_nuser_count:''}}
175
+              </template>
176
+            </el-table-column>
166
 
177
 
167
             <el-table-column label="宣教/小结" align="center">
178
             <el-table-column label="宣教/小结" align="center">
168
               <template slot-scope="scope">
179
               <template slot-scope="scope">
176
                 start_nurse_count:total_start_nurse, -->
187
                 start_nurse_count:total_start_nurse, -->
177
             <el-table-column label="合计" align="center">
188
             <el-table-column label="合计" align="center">
178
               <template slot-scope="scope">
189
               <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:''}}
190
+                {{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>
191
               </template>
181
             </el-table-column>
192
             </el-table-column>
182
           </el-table>
193
           </el-table>
231
           {value:5, name:"疑难穿刺"},
242
           {value:5, name:"疑难穿刺"},
232
           {value:6, name:"开瘘"},
243
           {value:6, name:"开瘘"},
233
           {value:7, name:"上机"},
244
           {value:7, name:"上机"},
245
+          {value:8, name:"下机"},
246
+          {value:9, name:"冲管"},
234
         ],
247
         ],
235
         crumbs: [
248
         crumbs: [
236
           { path: false, name: "质控管理" },
249
           { path: false, name: "质控管理" },
394
         GetNurseWorkloadTableData(params)
407
         GetNurseWorkloadTableData(params)
395
           .then(rs => {
408
           .then(rs => {
396
             var resp = rs.data
409
             var resp = rs.data
397
-            console.log("resp232323",resp)
410
+            console.log("列表2323323232323233232332323223233223233223",resp)
398
             if (resp.state == 1) {
411
             if (resp.state == 1) {
399
 
412
 
400
               let total_cure = 0
413
               let total_cure = 0
404
               let total_diffcult_nurse = 0
417
               let total_diffcult_nurse = 0
405
               let total_new_fistula_nurse = 0
418
               let total_new_fistula_nurse = 0
406
               let total_start_nurse = 0
419
               let total_start_nurse = 0
420
+              let total_finish_nurse = 0
421
+              let total_washpipe_nurse = 0
407
               this.loading = false
422
               this.loading = false
408
 
423
 
409
               for (let i = 0; i < resp.data.data.length; i++) {
424
               for (let i = 0; i < resp.data.data.length; i++) {
415
                 total_diffcult_nurse = total_diffcult_nurse + resp.data.data[i].difficult_nuser_count
430
                 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
431
                 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
432
                 total_start_nurse = total_start_nurse + resp.data.data[i].start_nuser_count
433
+                total_finish_nurse = total_finish_nurse + resp.data.data[i].finish_nuser_count
434
+                total_washpipe_nurse = total_washpipe_nurse + resp.data.data[i].washpipe_nuser_count
418
                 this.tableData.push(resp.data.data[i])
435
                 this.tableData.push(resp.data.data[i])
419
              }
436
              }
420
               this.tableData.push( {
437
               this.tableData.push( {
426
                 difficult_nuser_count:total_diffcult_nurse,
443
                 difficult_nuser_count:total_diffcult_nurse,
427
                 new_nuser_count:total_new_fistula_nurse,
444
                 new_nuser_count:total_new_fistula_nurse,
428
                 start_nuser_count:total_start_nurse,
445
                 start_nuser_count:total_start_nurse,
446
+                finish_nuser_count:total_finish_nurse,
447
+                washpipe_nuser_count:total_washpipe_nurse,
429
               })
448
               })
430
-
449
+              console.log("hhhhhhh23232233223",this.tableData)
431
               var dialysisCount = resp.data.dialysisCount
450
               var dialysisCount = resp.data.dialysisCount
432
                 console.log("dialysisCount",dialysisCount)
451
                 console.log("dialysisCount",dialysisCount)
433
               for(let i=0;i<dialysisCount.length;i++){
452
               for(let i=0;i<dialysisCount.length;i++){
564
                 }else if(this.query.statistics_type == 7){
583
                 }else if(this.query.statistics_type == 7){
565
                   this.bar.series[0].data.push(resp.data.data[i].start_nuser_count)
584
                   this.bar.series[0].data.push(resp.data.data[i].start_nuser_count)
566
                   this.percent.push(resp.data.data[i].start_nurse_ratio)
585
                   this.percent.push(resp.data.data[i].start_nurse_ratio)
586
+                }else if(this.query.statistics_type == 8){
587
+                  this.bar.series[0].data.push(resp.data.data[i].finish_nuser_count)
588
+                  this.percent.push(resp.data.data[i].finish_nurse_ratio)
589
+                }else if(this.query.statistics_type == 9){
590
+                  this.bar.series[0].data.push(resp.data.data[i].washpipe_nuser_count)
591
+                  this.percent.push(resp.data.data[i].washpipe_nurse_ratio)
567
                 }
592
                 }
568
               }
593
               }
569
               this.getArrLength(this.bar.xAxis.data)
594
               this.getArrLength(this.bar.xAxis.data)

+ 119 - 8
src/xt_pages/stock/detail/cancelStockDetail.vue 查看文件

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>

+ 19 - 17
src/xt_pages/stock/detail/stockInDetail.vue 查看文件

282
       stockTotal:[],
282
       stockTotal:[],
283
       org_id:0,
283
       org_id:0,
284
       tableInfo:[],
284
       tableInfo:[],
285
+      tableDataList:[],
285
     };
286
     };
286
   },
287
   },
287
   methods: {
288
   methods: {
415
             obj["is_total"] = 0;
416
             obj["is_total"] = 0;
416
             this.cancelStockDate.push(obj);
417
             this.cancelStockDate.push(obj);
417
           }
418
           }
418
-        
419
+          this.tableDataList = response.data.data.list
419
           this.cancelStockDate.push({
420
           this.cancelStockDate.push({
420
             warehousing_order: "合计",
421
             warehousing_order: "合计",
421
             is_total: 1,
422
             is_total: 1,
776
         })
777
         })
777
       },
778
       },
778
       exportListDetal(){
779
       exportListDetal(){
780
+        console.log("l可悲2233",this.tableDataList)
779
         var obj = {index:"合计",total_price:0}
781
         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
782
+        var total = 0
783
+        for(let i=0;i<this.tableDataList.length;i++){
784
+          this.tableDataList[i].index = i + 1
785
+          this.tableDataList[i].good_type_name = this.typeName(this.tableDataList[i].good_type_id)
786
+          this.tableDataList[i].good_name = this.typeNameOne(this.tableDataList[i].good_id)
787
+          this.tableDataList[i].specification_name = this.specificationName(this.tableDataList[i].good_id)
788
+          this.tableDataList[i].time = this.getTime(this.tableDataList[i].Warehousing.warehousing_time)
789
+          this.tableDataList[i].user_name = this.getXuserName(this.tableDataList[i].Warehousing.creater)
790
+          this.tableDataList[i].total_price = (this.tableDataList[i].warehousing_count * this.tableDataList[i].price).toFixed(2)
791
+          total += this.tableDataList[i].warehousing_count * this.tableDataList[i].price
790
         }
792
         }
791
-        obj.total_price = total_price.toFixed(2)
792
-        this.cancelStockDate.push(obj)
793
+        obj.total_price = total.toFixed(2)
794
+        this.tableDataList.push(obj)
793
         import('@/vendor/Export2Excel').then(excel => {
795
         import('@/vendor/Export2Excel').then(excel => {
794
         const tHeader = ['序号','单据编号', '耗材类型', '耗材名称','规格型号','操作时间','制单人','进货价','数量','总价']
796
         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)
797
+        const filterVal = ['index','warehousing_count', 'good_type_name', 'good_name','specification_name','time','user_name','price','warehousing_count','total_price']
798
+        console.log("hhhhhhhh",this.tableDataList)
797
       
799
       
798
-        
799
-        const data = this.formatJson(filterVal, this.cancelStockDate)
800
+      
801
+        const data = this.formatJson(filterVal, this.tableDataList)
800
         console.log("data222222222",data)
802
         console.log("data222222222",data)
801
           excel.export_json_to_excel({
803
           excel.export_json_to_excel({
802
             header: tHeader,
804
             header: tHeader,

+ 48 - 8
src/xt_pages/stock/detail/stockOutDetail.vue 查看文件

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 查看文件

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 查看文件

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 查看文件

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 查看文件

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 查看文件

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 查看文件

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 查看文件

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 查看文件

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>