XMLWAN 2 年 前
コミット
44f0b4cb52

+ 4 - 4
src/router/index.js ファイルの表示

@@ -158,10 +158,10 @@ var _asy_router_map = [
158 158
   dialysis,
159 159
   stock,
160 160
   drugs,
161
-  selfPreparedMedicine,  //自备药管理模块
162
-  wareHouseManage,  //仓库管理模块
163
-  DepositManagement, //押金管理模块
164
-  inventoryTransfer,    //库存调拨模块
161
+  selfPreparedMedicine, // 自备药管理模块
162
+  wareHouseManage, // 仓库管理模块
163
+  DepositManagement, // 押金管理模块
164
+  inventoryTransfer, // 库存调拨模块
165 165
   PatientDispensing, // 患者发药模块
166 166
   DrugDispensing, // 药房管理模块
167 167
   DispensingDetails, // 药房管理模块

+ 1 - 1
src/store/modules/globalConfig.js ファイルの表示

@@ -676,7 +676,7 @@ const global_config = {
676 676
         bicarbonate: 1
677 677
       },
678 678
       32: {
679
-        id: 31,
679
+        id: 32,
680 680
         name: 'HDP',
681 681
         dialysis_duration: 1,
682 682
         replacement_way: 1,

+ 5 - 5
src/xt_pages/Pharmacy/DrugDispensing.vue ファイルの表示

@@ -262,11 +262,11 @@
262 262
 import drugPrint from "./print/drugPrint.vue";
263 263
 import BreadCrumb from "@/xt_pages/components/bread-crumb";
264 264
 import { getTodayAdviceList,getPharmacyBaseDrug,updatePharmacyBaseDrug,SaveSetting,getPharmacyConfig,getUserdDrugList } from "@/api/his/advice";
265
-import {
266
-  waitingdrug,
267
-  issueddrugs,
268
-  getpharmacycontent
269
-} from "@/api/pharmacy"
265
+// import {
266
+//   waitingdrug,
267
+//   issueddrugs,
268
+//   getpharmacycontent
269
+// } from "@/api/pharmacy"
270 270
 const moment = require('moment')
271 271
 export default {
272 272
   components: {

+ 56 - 32
src/xt_pages/stock/detail/print.vue ファイルの表示

@@ -10,7 +10,7 @@
10 10
         <div class="dialysis-print-order">
11 11
           <div class="order-yy-name">{{orgname}}</div>
12 12
           <div class="order-title" v-if="type == 1">入库单</div>
13
-        
13
+
14 14
           <div class="order-title" v-if="type == 2">出库单</div>
15 15
           <div class="order-title" v-if="type == 4">退库单</div>
16 16
 
@@ -27,11 +27,11 @@
27 27
               <td style="line-height: 50px" width="200">规格型号</td>
28 28
               <td style="line-height: 50px" width="80">数量</td>
29 29
               <td style="line-height: 50px" width="50">单位</td>
30
-            
30
+
31 31
               <td style="line-height:50px" width="80">
32
-                <span v-if="type == 1">进货价</span> 
33
-                <span v-if="type == 2">出货价</span> 
34
-                <span v-if="type == 4">退库价</span> 
32
+                <span v-if="type == 1">进货价</span>
33
+                <span v-if="type == 2">出货价</span>
34
+                <span v-if="type == 4">退库价</span>
35 35
               </td>
36 36
               <td style="line-height: 50px" width="80">总价</td>
37 37
               <td style="line-height: 50px" width="80">备 注</td>
@@ -47,15 +47,16 @@
47 47
               <td style="line-height: 50px">
48 48
                 {{item.specification_name}}
49 49
               </td>
50
-             
50
+
51 51
               <td style="line-height: 50px">
52 52
                 <span v-if="type == 1"> {{ item.warehousing_count }}</span>
53
-                <span v-if="type == 2"> 
54
-                  <span  v-if="org_id == 3907 || org_id == 9919 || org_id == 9583">{{getStockCount(item.good_id) }}</span> 
55
-                   <span  v-if="org_id == 10265 || org_id == 10215">{{getMySelfCount(item.good_id) }}</span>   
56
-                  <span v-if="org_id!=3907&&org_id!=10265&&org_id!=10285&&org_id!=9583&&org_id!=10215">{{getStockCount(item.good_id) }}</span>
53
+                <span v-if="type == 2">
54
+                  <span  v-if="org_id == 3907 || org_id == 9919 || org_id == 9583">{{getStockCount(item.good_id) }}</span>
55
+                   <span  v-if="org_id == 10265 || org_id == 10215">{{getMySelfCount(item.good_id) }}</span>
56
+                   <span v-if="org_id == 10210 || org_id == 9671">{{getWarehouseOut(item.good_id)}}</span>
57
+                  <span v-if="org_id!=3907&&org_id!=10265&&org_id!=10285&&org_id!=9583&&org_id!=10215&&org_id!=10210&&org_id!=9671">{{getStockCount(item.good_id) }}</span>
57 58
                 </span>
58
-               
59
+
59 60
                 <span v-if="type == 4"> {{ item.count }}</span>
60 61
               </td>
61 62
               <td style="line-height: 50px">
@@ -63,11 +64,11 @@
63 64
               </td>
64 65
               <td style="line-height:50px">
65 66
                 <span v-if="type == 1"> {{ item.price }}</span>
66
-                <span v-if="type == 2"> 
67
-                  <span v-if="org_id == 9919">{{ item.buy_price }}</span>  
67
+                <span v-if="type == 2">
68
+                  <span v-if="org_id == 9919">{{ item.buy_price }}</span>
68 69
                   <span v-else>
69
-                    {{ item.packing_price }} 
70
-                  </span>  
70
+                    {{ item.packing_price }}
71
+                  </span>
71 72
                 </span>
72 73
                  <span v-if="type == 4"> {{ item.price }}</span>
73 74
               </td>
@@ -77,8 +78,9 @@
77 78
                   <span v-if="org_id == 3907 || org_id ==9919">
78 79
                      {{(getStockCount(item.good_id) * item.buy_price).toFixed(2)}}
79 80
                   </span>
80
-                  <span v-if="org_id == 10265 || org_id == 10215">{{(getMySelfCount(item.good_id)*item.packing_price).toFixed(2)}}</span>
81
-                  <span v-if="org_id!=3907&&org_id!=10265&&org_id!=9919&&org_id!=10215">{{(getStockCount(item.good_id) * item.packing_price).toFixed(2)}}</span>
81
+                  <span v-if="org_id == 10265 || org_id == 10215 || org_id == 10188 || org_id == 10217 || org_id == 9956 || org_id == 10191 ">{{(getMySelfCount(item.good_id)*item.packing_price).toFixed(2)}}</span>
82
+                   <span v-if="org_id == 10210 || org_id == 9671 ">{{(getWarehouseOut(item.good_id)*item.packing_price).toFixed(2)}}</span>
83
+                  <span v-if="org_id!=3907&&org_id!=10265&&org_id!=9919&&org_id!=10215&&org_id!=9671 && org_id!=10188 && org_id!=10217 && org_id!= 9956 && org_id!=10191">{{(getStockCount(item.good_id) * item.packing_price).toFixed(2)}}</span>
82 84
                 </span>
83 85
                 <span v-if="type == 4">{{(item.count * item.price).toFixed(2)}}</span>
84 86
               </td>
@@ -97,19 +99,19 @@
97 99
               <td style="line-height: 50px"  width="50"></td>
98 100
               <td style="line-height: 50px"   width="80"></td>
99 101
               <td style="line-height: 50px"  width="80">
100
-                <span v-if="type == 1">{{getWareInfoTotal().toFixed(2)}}</span> 
102
+                <span v-if="type == 1">{{getWareInfoTotal().toFixed(2)}}</span>
101 103
                 <span v-if="type == 2">
102 104
                   <span v-if="org_id == 3907 || org_id == 9919">{{getWareOutTotalOne().toFixed(2)}}</span>
103 105
                   <span v-if="org_id == 10265 || org_id == 10215">{{getWareOutTotalSix().toFixed(2)}}</span>
104 106
                   <span v-if="org_id!=3907 && org_id!=9919 && org_id!=10265 && org_id!=10215"> {{getWareOutTotal().toFixed(2)}}</span>
105
-                 </span> 
106
-                <span v-if="type == 4">{{getWareOutTotal().toFixed(2)}}</span> 
107
+                 </span>
108
+                <span v-if="type == 4">{{getWareOutTotal().toFixed(2)}}</span>
107 109
               </td>
108 110
               <td style="line-height: 50px" width="80">
109
-               
111
+
110 112
               </td>
111 113
             </tr>
112
-          </table> 
114
+          </table>
113 115
 
114 116
           <div style="display:flex;margin-top:20px;float:right;">
115 117
             <div style="width:50px;">审批:</div><div style="width:100px;"></div>
@@ -165,7 +167,8 @@
165 167
         stockTotal:[],
166 168
         wareOutInfo:[],
167 169
         org_id:this.$store.getters.xt_user.org.id,
168
-        informationList:[]
170
+        informationList:[],
171
+        wareOutList:[],
169 172
       }
170 173
     },
171 174
     methods: {
@@ -206,7 +209,7 @@
206 209
         })
207 210
       },
208 211
       calCount(stock) {
209
-      
212
+
210 213
         let total = 0
211 214
         var array = []
212 215
         if (this.type == 1) {
@@ -306,7 +309,7 @@
306 309
       },
307 310
 
308 311
      getStockCount(id){
309
-       
312
+
310 313
        var count = ""
311 314
        for(let i=0;i<this.stockTotal.length;i++){
312 315
           if(id == this.stockTotal[i].good_id){
@@ -329,19 +332,19 @@
329 332
        for(let i=0;i<this.informationList.length;i++){
330 333
         for(let j=0;j<this.wareOutInfo.length;j++){
331 334
            if(this.informationList[i].id == this.wareOutInfo[j].good_id){
332
-             this.wareOutInfo[j].buy_price =  this.informationList[i].buy_price 
335
+             this.wareOutInfo[j].buy_price =  this.informationList[i].buy_price
333 336
            }
334 337
         }
335 338
        }
336
-      
339
+
337 340
        for(let j=0;j<this.wareOutInfo.length;j++){
338 341
          if(id == this.wareOutInfo[j].good_id){
339 342
             sum += (this.wareOutInfo[j].buy_price * this.wareOutInfo[j].count).toFixed(2)
340 343
          }
341 344
        }
342
-       
345
+
343 346
        return sum
344
-       
347
+
345 348
      },
346 349
      getReailPrice(id){
347 350
        var price = 0
@@ -379,8 +382,8 @@
379 382
            this.stockDatas = list
380 383
            var stockTotal = response.data.data.stockTotal
381 384
           this.stockTotal = stockTotal
382
-           
383
-           
385
+
386
+
384 387
          }
385 388
       })
386 389
      },
@@ -390,7 +393,7 @@
390 393
         if(response.data.state == 1){
391 394
           var total =   response.data.data.total
392 395
           var list = response.data.data.list
393
-          this.stockDatas = list
396
+          this.wareOutList = list
394 397
         }
395 398
       })
396 399
      },
@@ -431,12 +434,33 @@
431 434
        }
432 435
        return total
433 436
      },
437
+    //  getPrintStockGood(){
438
+
439
+    //   getPrintStockGood(this.queryParams).then(response=>{
440
+    //       if(response.data.state == 1){
441
+    //         var list =  response.data.data.list
442
+    //         console.log("list23323232323232",list)
443
+    //         this.stockDatas = list
444
+
445
+    //       }
446
+    //   })
447
+    // },
448
+    getWarehouseOut(good_id){
449
+      var total = 0
450
+      for(let i=0;i<this.wareOutList.length;i++){
451
+         if(this.wareOutList[i].good_id == good_id){
452
+            total += this.wareOutList[i].count
453
+         }
454
+      }
455
+      return total
456
+    }
434 457
     },
435 458
     created() {
436 459
       var xtuser = this.$store.getters.xt_user
437 460
       this.orgname = xtuser.org.org_name
438 461
       this.goodUnit = this.$store.getters.good_unit
439 462
       this.getGoodDetailPrintList()
463
+      this.getStockDetail()
440 464
     }
441 465
 
442 466
   }

+ 32 - 5
src/xt_pages/stock/detail/stockOutDetail.vue ファイルの表示

@@ -265,6 +265,7 @@ export default {
265 265
       tableDataList:[],
266 266
       storehouse_id:0,
267 267
       houseList:[],
268
+      wareOutList:[],
268 269
     };
269 270
   },
270 271
   methods: {
@@ -391,6 +392,7 @@ export default {
391 392
           for(let i=0;i<response.data.data.houseList.length;i++){
392 393
            this.houseList.push(response.data.data.houseList[i])
393 394
           }
395
+          this.wareOutList =  response.data.data.list
394 396
           var total = 0
395 397
           for (let i = 0; i < response.data.data.list.length; i++) {
396 398
             this.tableData.push(response.data.data.list[i])
@@ -778,15 +780,31 @@ export default {
778 780
           this.tableOut[i].total_price = (this.getMySelfCount(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
779 781
         }else if(this.orgId == 10215){
780 782
           this.tableOut[i].total_price = (this.getMySelfCount(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
783
+        }else if(this.orgId == 10210){
784
+          this.tableOut[i].total_price = (this.getWarehouseOut(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
785
+        }else if(this.orgId == 9671){
786
+          this.tableOut[i].total_price = (this.getWarehouseOut(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
787
+        }else if(this.orgId == 9956){
788
+          this.tableOut[i].total_price = (this.getWarehouseOut(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
789
+        }else if(this.orgId == 10217){
790
+          this.tableOut[i].total_price = (this.getWarehouseOut(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
791
+        }else if(this.orgId == 10191){
792
+          this.tableOut[i].total_price = (this.getWarehouseOut(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
793
+        }else if(this.orgId == 10188){
794
+          this.tableOut[i].total_price = (this.getWarehouseOut(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
781 795
         }else{
782 796
           this.tableOut[i].total_price = (this.getStockCount(this.tableOut[i].good_id) * this.tableOut[i].retail_price).toFixed(2)
783 797
         }
784 798
 
785
-        if(this.orgId  == 10265 || this.orgId ==10215 ){
799
+        if(this.orgId  == 10265 || this.orgId ==10215){
786 800
 
787 801
          this.tableOut[i].out_count = this.getMySelfCount(this.tableOut[i].good_id)
788 802
         }
789
-        if(this.orgId!=10265 && this.orgId !=10215){
803
+        if(this.orgId == 10210 || this.orgId == 9671 || this.orgId == 10210 || this.orgId == 9956 || this.orgId == 10217 || this.orgId == 10188 || this.orgId == 10191){
804
+          this.tableOut[i].out_count = this.getWarehouseOut(this.tableOut[i].good_id)
805
+          console.log("out_count232233232332",this.tableOut[i].out_count)
806
+        }
807
+        if(this.orgId!=10265 && this.orgId !=10215 && this.orgId!=10210&&this.orgId!=9671){
790 808
           this.tableOut[i].out_count = this.getStockCount(this.tableOut[i].good_id)
791 809
         }
792 810
        }
@@ -821,12 +839,12 @@ export default {
821 839
           if(this.orgId == 9919){
822 840
              this.tableDataList[i].total_price = (this.tableDataList[i].count * this.tableDataList[i].GoodInfo.buy_price).toFixed(2)
823 841
              total += this.tableDataList[i].count * this.tableDataList[i].buy_price
824
-          }else{
842
+          }
843
+          if(this.orgId != 9919){
825 844
             this.tableDataList[i].total_price = (this.tableDataList[i].count * this.tableDataList[i].price).toFixed(2)
826 845
             total += this.tableDataList[i].count * this.tableDataList[i].price
827 846
           }
828 847
 
829
-
830 848
         }
831 849
         obj.total_price = total.toFixed(2)
832 850
 
@@ -926,7 +944,16 @@ export default {
926 944
      changeHouseList(){
927 945
        this.houseList = []
928 946
        this.GetCancelStock()
929
-     }
947
+     },
948
+     getWarehouseOut(good_id){
949
+      var total = 0
950
+      for(let i=0;i<this.wareOutList.length;i++){
951
+         if(this.wareOutList[i].good_id == good_id){
952
+            total += this.wareOutList[i].count
953
+         }
954
+      }
955
+      return total
956
+    }
930 957
   }
931 958
 };
932 959
 </script>