Browse Source

新分支

28169 9 months ago
parent
commit
d4e0237e22

+ 1 - 1
src/api/role/admin.js View File

@@ -363,4 +363,4 @@ export function GetFiledConfigList(params){
363 363
     method:"Get",
364 364
     params:params,
365 365
   })
366
-}
366
+}

+ 2 - 1
src/xt_pages/dialysis/newDoctorAdvice.vue View File

@@ -1113,7 +1113,8 @@ export default {
1113 1113
            if(this.is_sort == 0){
1114 1114
               newList = schedules
1115 1115
            }
1116
-           if(this.is_sort == 1){
1116
+          
1117
+           if(this.is_sort == 0 ||  this.is_sort == 1){
1117 1118
               schedules.map(item => {
1118 1119
                   item.is_sort = item.device_number.sort
1119 1120
                   item.assess_time = item.dialysisassesmentbefor&&item.dialysisassesmentbefor?item.dialysisassesmentbefor.created_time:"3753619200"

+ 3 - 2
src/xt_pages/role/admin.vue View File

@@ -241,7 +241,7 @@
241 241
           style="float:left"
242 242
           @click="toZiDuanJiaoBen">字段脚本</el-button> -->
243 243
 
244
-
244
+        
245 245
      </div>
246 246
 
247 247
 
@@ -1228,7 +1228,8 @@ export default {
1228 1228
          this.$message.success("脚本成功")
1229 1229
         }
1230 1230
       })
1231
-    }
1231
+    },
1232
+    
1232 1233
 
1233 1234
   },
1234 1235
   watch: {

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

@@ -90,11 +90,16 @@
90 90
               <span v-if="scope.row.consumable_type == 10 || scope.row.consumable_type == 11 || scope.row.consumable_type == 13">{{scope.row.warehousing_order}}</span>
91 91
            </template>
92 92
         </el-table-column>
93
-        <el-table-column prop="drug_name" label="操作日期" align="center">
93
+        <el-table-column prop="drug_name" label="出库日期" align="center">
94 94
            <template slot-scope="scope">
95 95
              {{getTime(scope.row.ctime,"{y}-{h}-{d}")}}
96 96
            </template>
97 97
         </el-table-column>
98
+        <el-table-column prop="drug_name" label="操作日期" align="center">
99
+           <template slot-scope="scope">
100
+             {{getTime(scope.row.operate_time,"{y}-{h}-{d}")}}
101
+           </template>
102
+        </el-table-column>
98 103
         <el-table-column prop="drug_name" label="仓库名称" align="center">
99 104
            <template slot-scope="scope">
100 105
               <span>{{getHouseName(scope.row.storehouse_id)}}</span>

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

@@ -372,15 +372,19 @@
372 372
                     <span v-if="org_id!=10480 && org_id!=10210&&org_id!=10188 && org_id!=10217  && org_id!=0 && org_id!=10088 && org_id!=10510">
373 373
                       <span v-if="is_sys == 1 || is_sys == 5 || is_sys == 12">{{getTotalPrice(item.warehousing_detail_id,scope.row.max_unit,scope.row.min_unit,scope.row.min_number)}} </span>
374 374
                     <span v-if="is_sys == 0">
375
-                      <span v-if="scope.row.child.length == 1">{{item.count * item.retail_price}} </span> 
376
-                      <span v-if="scope.row.child.length > 1">{{item.count * item.price}} </span> 
375
+                      <!-- <span v-if="scope.row.child.length == 1">{{item.count * item.retail_price}} </span> 
376
+                      <span v-if="scope.row.child.length > 1">{{item.count * item.price}} </span>  -->
377
+                      {{(scope.row.count * scope.row.price).toFixed(2)}}
377 378
                     </span>
378 379
                     </span>
379 380
 
380 381
                     <span v-if="org_id ==10480 || org_id==10210 || org_id ==10188 || org_id ==10217 || org_id==0 || org_id ==10088 || org_id ==10510">
381 382
                       <!-- {{(item.count * item.price).toFixed(2)}} -->
382 383
                      <span v-if="is_sys == 1 || is_sys == 5 || is_sys == 12">{{(getOutCountNightTen(item.warehousing_detail_id,scope.row.max_unit,scope.row.min_unit,scope.row.min_number,scope.row.drug_id)*scope.row.min_price).toFixed(2)}}</span>  
383
-                     <span v-if="is_sys==0"> {{(getOutCountNightTenOne(item.batch_number,scope.row.max_unit,scope.row.min_unit,scope.row.min_number,scope.row.drug_id)*item.price).toFixed(2)}}</span>
384
+                     <span v-if="is_sys==0">
385
+                       {{(scope.row.count * scope.row.price).toFixed(2)}}
386
+                       <!-- {{(getOutCountNightTenOne(item.batch_number,scope.row.max_unit,scope.row.min_unit,scope.row.min_number,scope.row.drug_id)*item.price).toFixed(2)}} -->
387
+                      </span>
384 388
                      
385 389
                     </span>
386 390
                   </td>
@@ -1248,10 +1252,7 @@ export default {
1248 1252
     getTime(val) {
1249 1253
       if (val < 0) {
1250 1254
         return "";
1251
-      }
1252
-      if (val == "") {
1253
-        return "";
1254
-      } else {
1255
+      }else{
1255 1256
         return uParseTime(val, "{y}-{m}-{d}");
1256 1257
       }
1257 1258
     },
@@ -1660,11 +1661,69 @@ export default {
1660 1661
               }
1661 1662
             }
1662 1663
           }
1663
-          this.exportList = list;
1664
+          console.log("list---------------------",list)
1665
+          if(list!=null && list.length>0){
1666
+            let dataInfo = {}
1667
+              list.forEach((item, index) => {
1668
+              let { drug_id } = item
1669
+              if (!dataInfo[drug_id]) {
1670
+                dataInfo[drug_id] = {
1671
+                  drug_id:item.drug_id,
1672
+                  drug_name:item.drug_name,
1673
+                  warehouse_out_order_number:item.warehouse_out_order_number,
1674
+                  dose:item.dose,
1675
+                  dose_unit:item.dose_unit,
1676
+                  min_unit:item.min_unit,
1677
+                  max_unit:item.max_unit,
1678
+                  min_number:item.min_number,
1679
+                  child: [],
1680
+                  count:0,
1681
+                  price:item.price,
1682
+                  manufacturer:item.manufacturer,
1683
+                  dealer:item.dealer,
1684
+                  product_date:item.product_date,
1685
+                  expire_date:item.expire_date,
1686
+                  remark:item.remark,
1687
+                  warehouse_out_time:item.warehouse_out_time,
1688
+                  ctime:item.ctime,
1689
+                  drug_type:item.drug_type,
1690
+                  batch_number:item.batch_number,
1691
+                  number:item.number,
1692
+                  min_price:item.min_price,
1693
+                  count_one:item.count_one,
1694
+                }
1695
+              }
1696
+            })
1697
+            let arr = Object.values(dataInfo)
1698
+            if(arr!=null && arr.length>0){
1699
+              for(let i=0;i<arr.length;i++){
1700
+                for(let j=0;j<list.length;j++){
1701
+                  if(arr[i].drug_id == list[j].drug_id){
1702
+                     arr[i].child.push(list[j])
1703
+                  }
1704
+                }
1705
+              }
1706
+            }
1707
+
1708
+            if(arr!=null&& arr.length>0){
1709
+               
1710
+              for(let i=0;i<arr.length;i++){
1711
+                for(let j=0;j<arr[i].child.length;j++){
1712
+                  arr[i].count +=arr[i].child[j].count_one
1713
+                }
1714
+              }
1715
+            }
1716
+            console.log("arr-----------------------",arr)
1717
+            this.exportList = []
1718
+            this.exportList = arr;
1719
+         
1720
+          }
1721
+          
1664 1722
           this.exportLoding = false
1665 1723
           this.manufacturerList = response.data.data.manufacturerList;
1666 1724
           this.dealerList = response.data.data.dealerList;
1667 1725
           this.outInfoList = response.data.data.outInfoList
1726
+        
1668 1727
         }
1669 1728
       });
1670 1729
     },
@@ -1692,48 +1751,42 @@ export default {
1692 1751
         if (this.exportList[i].manufacturer == 0) {
1693 1752
           this.exportList[i].manufacturer = "";
1694 1753
         }
1695
-        this.exportList[i].unit =
1696
-          this.exportList[i].dose +
1697
-          this.exportList[i].dose_unit +
1698
-          "*" +
1699
-          this.exportList[i].min_number +
1700
-          this.exportList[i].min_unit +
1701
-          "/" +
1702
-          this.exportList[i].max_unit;
1703
-
1704
-        // this.exportList[i].total_price = (this.exportList[i].count * this.exportList[i].price).toFixed(2);
1754
+        this.exportList[i].unit =this.exportList[i].dose + this.exportList[i].dose_unit + "*" + this.exportList[i].min_number +this.exportList[i].min_unit +"/" +this.exportList[i].max_unit;
1755
+        this.out_count = ""
1705 1756
         this.exportList[i].out_count = this.getAllOut(this.exportList[i].count,this.exportList[i].max_unit,this.exportList[i].min_unit,this.exportList[i].min_number)
1706
-        this.exportList[i].expiry_date = this.getTime(
1707
-          this.exportList[i].expire_date
1708
-        );
1709
-        this.exportList[i].product_date = this.getTime(
1710
-          this.exportList[i].product_date
1711
-        );
1757
+        this.exportList[i].expiry_date = this.getTime(this.exportList[i].expire_date);
1758
+        this.exportList[i].product_date_one = this.getTime(this.exportList[i].product_date);
1712 1759
         for (let j = 0; j < this.manufacturerList.length; j++) {
1713 1760
           if (this.exportList[i].manufacturer == this.manufacturerList[j].id) {
1714
-            this.exportList[i].manufacturer = this.manufacturerList[j].manufacturer_name;
1761
+            this.exportList[i].manufacturer_name = this.manufacturerList[j].manufacturer_name;
1715 1762
           }
1716 1763
         }
1717 1764
 
1718 1765
         for (let z = 0; z < this.dealerList.length; z++) {
1719 1766
           if (this.exportList[i].dealer == this.dealerList[z].id) {
1720
-            this.exportList[i].dealer = this.dealerList[z].dealer_name;
1767
+            this.exportList[i].dealer_name = this.dealerList[z].dealer_name;
1721 1768
           }
1722 1769
         }
1723
-       
1724
-        this.exportList[i].retail_price = (this.exportList[i].count_one * this.exportList[i].min_price).toFixed(2)
1770
+        this.exportList[i].total_price = 0
1771
+        this.exportList[i].total_price = (this.exportList[i].count * this.exportList[i].min_price).toFixed(2)
1725 1772
         
1726 1773
         this.exportList[i].ctime = this.getTime(this.exportList[i].ctime)
1727 1774
       }
1728
-
1729
-      import("@/vendor/Export2Excel").then((excel) => {
1730
-        for (let i = 0; i < this.exportList.length; i++) {
1731
-          for (let j = 0; j < this.drugTypeList.length; j++) {
1732
-            if (this.exportList[i].drug_type == this.drugTypeList[j].value) {
1733
-              this.exportList[i].drug_type = this.drugTypeList[j].name;
1734
-            }
1775
+      
1776
+    
1777
+      for (let i = 0; i < this.exportList.length; i++) {
1778
+        for (let j = 0; j < this.drugTypeList.length; j++) {
1779
+          if (this.exportList[i].drug_type == this.drugTypeList[j].value) {
1780
+            this.exportList[i].drug_type = this.drugTypeList[j].name;
1735 1781
           }
1736 1782
         }
1783
+        this.exportList[i].price_one = 0
1784
+        this.exportList[i].price_one = this.exportList[i].price
1785
+        this.exportList[i].warehouse_out_time = this.exportList[i].ctime
1786
+      }
1787
+      console.log("到处---------------------",this.exportList)
1788
+      import("@/vendor/Export2Excel").then((excel) => {
1789
+       
1737 1790
         const tHeader = [
1738 1791
           "单据日期",
1739 1792
           "药品名称",
@@ -1741,7 +1794,6 @@ export default {
1741 1794
           "规格&单位",
1742 1795
           "批号",
1743 1796
           "出库数量",
1744
-          "单价",
1745 1797
           "拆零零售价",
1746 1798
           "总价",
1747 1799
           "生产厂家",
@@ -1754,29 +1806,29 @@ export default {
1754 1806
           
1755 1807
         ];
1756 1808
         const filterVal = [
1757
-          "ctime",
1809
+          "warehouse_out_time",
1758 1810
           "drug_name",
1759 1811
           "drug_type",
1760 1812
           "unit",
1761 1813
           "batch_number",
1762 1814
           "out_count",
1763
-          "retail_price_one",
1764
-          "price",
1765
-          "retail_price",
1766
-          "manufacturer",
1767
-          "product_date",
1815
+          "min_price",
1816
+          "total_price",
1817
+          "manufacturer_name",
1818
+          "product_date_one",
1768 1819
           "expiry_date",
1769
-          "dealer",
1820
+          "dealer_name",
1770 1821
           "number",
1771 1822
           "ctime",
1772 1823
           "remark",
1773 1824
         ];
1825
+        
1774 1826
 
1775 1827
       
1776 1828
 
1777 1829
         const data = this.formatJson(filterVal, this.exportList);
1778 1830
         console.log("Datewoo2o2o2o",data)
1779
-      
1831
+       
1780 1832
         excel.export_json_to_excel({
1781 1833
           header: tHeader,
1782 1834
           data,

+ 417 - 0
src/xt_pages/stock/drugs/historyDrugInvetory.vue View File

@@ -0,0 +1,417 @@
1
+<template>
2
+    <!--患者发药-->
3
+    <div class="main-contain new-main-contain">
4
+      <div class="position">
5
+        <bread-crumb :crumbs="crumbs"></bread-crumb>
6
+      </div>
7
+      <div
8
+        class="app-container"
9
+        style="display: flex; flex: 1; padding: 10px 20px 0px 20px"
10
+      >
11
+        <div class="mainLeft">
12
+          <div>
13
+            <div
14
+              class="list"
15
+              style="display: flex; justify-content: space-between"
16
+            >
17
+              <el-input
18
+                size="small"
19
+                style="width: 200px"
20
+                v-model="keywords"
21
+                class="filter-item"
22
+                placeholder="请输入耗材名称"
23
+                clearable
24
+              />
25
+              <el-button
26
+               
27
+                size="small"
28
+                class="filter-item"
29
+                type="primary"
30
+                @click="searchAction"
31
+                >搜索
32
+              </el-button>
33
+            </div>
34
+  
35
+            <el-table
36
+              height="80vh"
37
+              ref="table01"
38
+              :data="drugList"
39
+              highlight-current-row
40
+              @current-change="handleCurrentChange"
41
+              border
42
+              style="width: 100%"
43
+              v-if="state == 1"
44
+              :row-style="{ color: '#303133' }"
45
+              :header-cell-style="{
46
+                backgroundColor: 'rgb(245, 247, 250)',
47
+                color: '#606266',
48
+              }"
49
+            >
50
+              <el-table-column prop="date" label="药品名称" align="center">
51
+                <template slot-scope="scope">
52
+                   {{scope.row.drug_name}}
53
+                </template>
54
+              </el-table-column>
55
+              <el-table-column prop="name" label="规格" align="center">
56
+                <template slot-scope="scope">
57
+                    {{scope.row.dose}}{{ scope.row.dose_unit }} * {{ scope.row.min_number }}{{ scope.row.min_unit }} /{{ scope.row.max_unit }}
58
+                </template>
59
+              </el-table-column>
60
+
61
+              <el-table-column prop="name" label="厂家" align="center">
62
+                <template slot-scope="scope">
63
+                  {{getManufacturerName(scope.row.manufacturer)}}
64
+                </template>
65
+              </el-table-column>
66
+            </el-table>
67
+            
68
+          </div>
69
+        </div>
70
+
71
+        <div class="mainRight">
72
+          <div class="titlelist">
73
+          <div>
74
+            <div>日期:{{nowTime}}   盘点人:{{user_name}} &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
75
+           </div>
76
+          </div>
77
+
78
+        </div>
79
+        <el-divider style="margin-top: 10px"></el-divider>
80
+        <div>
81
+          <el-table
82
+            :height="tableHeight"
83
+            :data="infoList"
84
+            border
85
+            style="width: 100%"
86
+            :row-style="{ color: '#303133' }"
87
+            :header-cell-style="{
88
+              backgroundColor: 'rgb(245, 247, 250)',
89
+              color: '#606266',
90
+            }"
91
+          >
92
+            <el-table-column label="入库单号"  align="center">
93
+              <template slot-scope="scope">
94
+                {{scope.row.warehousing_order}}
95
+              </template>
96
+            </el-table-column>
97
+            <el-table-column label="入库数量"  align="center">
98
+              <template slot-scope="scope">
99
+                {{scope.row.warehousing_count}}
100
+              </template>
101
+            </el-table-column>
102
+            <el-table-column label="有效期"  align="center">
103
+              <template slot-scope="scope">
104
+                {{getTime(scope.row.expiry_date)}}
105
+              </template>
106
+            </el-table-column>
107
+            <el-table-column label="批号"  align="center">
108
+              <template slot-scope="scope">
109
+                 {{scope.row.batch_number}}
110
+              </template>
111
+            </el-table-column>
112
+            <el-table-column label="进货价"  align="center">
113
+              <template slot-scope="scope">
114
+                  {{scope.row.price}}
115
+              </template>
116
+            </el-table-column>
117
+            <el-table-column label="剩余库存"  align="center">
118
+              <template slot-scope="scope">
119
+                 {{scope.row.stock_max_number}}{{ scope.row.max_unit }} 
120
+                 {{scope.row.stock_min_number}}{{ scope.row.min_unit }}
121
+              </template>
122
+            </el-table-column>
123
+            <el-table-column prop="name" label="盘点原因" width="100"  align="center">
124
+                <template slot-scope="scope">
125
+                   <el-select v-model="scope.row.type" placeholder="请选择">
126
+                      <el-option
127
+                        v-for="item in reasonList"
128
+                        :key="item.id"
129
+                        :label="item.name"
130
+                        :value="item.id">
131
+                      </el-option>
132
+                    </el-select>
133
+                 </template> 
134
+              </el-table-column>
135
+            <el-table-column label="盘点后数量"  align="center" width="220">
136
+              <template slot-scope="scope">
137
+                <el-input style="width:80px" v-model="scope.row.last_stock_max_number" type="number"></el-input>
138
+                {{scope.row.max_unit}}
139
+                <el-input style="width:60px" v-model="scope.row.last_stock_min_number" type="number"></el-input>
140
+                {{scope.row.min_unit}}
141
+              </template>
142
+            </el-table-column>
143
+            <el-table-column label="操作"  align="center">
144
+              <template slot-scope="scope">
145
+                <span><el-button type="danger" @click="UpdateDrugWarehouseInfo(scope.row)">保存</el-button></span>
146
+              </template>
147
+            </el-table-column>
148
+           
149
+          </el-table>
150
+        </div>
151
+       
152
+      </div>
153
+    
154
+      </div>
155
+    </div>
156
+  </template>
157
+  
158
+  <script>
159
+  
160
+  import BreadCrumb from "@/xt_pages/components/bread-crumb";
161
+  import {
162
+    getDrugInventoryList,
163
+    getDrugInventoryByDrugId,
164
+    updateDrugInventoryWarehouseInfo
165
+  } from "@/api/pharmacy";
166
+  const moment = require("moment");
167
+  import { uParseTime } from '@/utils/tools'
168
+  export default {
169
+    components: {
170
+      BreadCrumb,
171
+    },
172
+    data() {
173
+      return {
174
+        nowTime: moment(new Date()).format("YYYY-MM-DD HH:MM:SS"),
175
+        patient_id: 0,
176
+        crumbs: [
177
+          { path: false, name: "药品管理" },
178
+          { path: "/Pharmacy/patiantDispensing", name: "药品盘点" },
179
+        ],
180
+        tableHeight: 400,
181
+        start_time: moment(new Date()).add("year", 0).format("YYYY-MM-DD"),
182
+        start_time2: moment(new Date()).add("year", 0).format("YYYY-MM-DD HH:mm"),
183
+        state: 1, //1待发药,2已发药
184
+        waitmount: 0, //待发药人数
185
+        waitmount_data: [],
186
+        alreadmount: 0, //已发药人数
187
+        alreadmount_data: [],
188
+        keywords: "",
189
+        tableData: [],
190
+        propsTable: [],
191
+        tableData_list: [],
192
+        isVisibility: false,
193
+        isVisibilityTwo:false,
194
+        currentRow: null,
195
+        dialogVisible: false,
196
+        is_open: "2",
197
+        banshift: [
198
+          { value: 0, text: "全部班" },
199
+          { value: 1, text: "上午" },
200
+          { value: 2, text: "下午" },
201
+          { value: 3, text: "晚上" },
202
+        ],
203
+        shift: 0, //班次
204
+        fen: [],
205
+        partition: 0, //分区
206
+        drugList:[],
207
+        baseList:[],
208
+        org_id:'',
209
+        patients:{},
210
+        doctors:[],
211
+        diagnosearr:[],
212
+        diagnosis:'',
213
+        goodList:[],
214
+        manufacturerList:[],
215
+        user_name:this.$store.getters.xt_user.user.user_name,
216
+        infoList:[],
217
+        reasonList:[
218
+          {id:6,name:"默认"},
219
+          {id:1,name:"到期退货"},
220
+          {id:2,name:"异常退货"},
221
+          {id:3,name:"退货"},
222
+          {id:4,name:"损坏"},
223
+          {id:5,name:"不计入报损分析"},
224
+          {id:7,name:"有效期到期"},
225
+         ],
226
+      };
227
+    },
228
+    watch: {},
229
+    created() {
230
+      this.org_id = this.$store.getters.xt_user.org.id
231
+
232
+      this.getDrugInventoryList()
233
+    },
234
+   methods:{
235
+    getTime(val) {
236
+        if(val < 0){
237
+        return ""
238
+        }
239
+        if(val == ""){
240
+        return ""
241
+        }else {
242
+        return uParseTime(val, '{y}-{m}-{d}')
243
+        }
244
+     },
245
+    searchAction(){
246
+        this.getDrugInventoryList()
247
+    },
248
+    getDrugInventoryList(){
249
+        var params = {
250
+            keywords:this.keywords
251
+        }
252
+        getDrugInventoryList(params).then(response=>{
253
+            if(response.data.state ==1){
254
+                var list = response.data.data.drugList
255
+                console.log("HHHHHHHHH000000000000000000000",list)
256
+                this.drugList = list
257
+                this.$refs.table01.setCurrentRow(this.drugList[0])
258
+                this.manufacturerList = response.data.data.manufacturerList
259
+            }
260
+        })
261
+     },
262
+     getManufacturerName(id){
263
+       var manufacturer_name = ""
264
+       for(let i=0;i<this.manufacturerList.length;i++){
265
+          if(id == this.manufacturerList[i].id){
266
+            manufacturer_name = this.manufacturerList[i].manufacturer_name
267
+          }
268
+       }
269
+       return manufacturer_name
270
+     },
271
+     handleCurrentChange(val){
272
+       console.log("valo9oooooooooooooo",val)
273
+       getDrugInventoryByDrugId(val.id).then(response=>{
274
+          if(response.data.state ==1){
275
+             
276
+             this.infoList = []
277
+             var infoList = response.data.data.infoList
278
+             for(let i=0;i<infoList.length;i++){
279
+               infoList[i].type = 6
280
+               infoList[i].last_stock_max_number = infoList[i].stock_max_number
281
+               infoList[i].last_stock_min_number = infoList[i].stock_min_number
282
+               this.infoList.push(infoList[i])
283
+             }
284
+            
285
+             console.log("infoList====================",this.infoList)
286
+            
287
+
288
+          }
289
+       })
290
+     },
291
+     UpdateDrugWarehouseInfo(row){
292
+        console.log("row===============",row)
293
+        var stock_in_number = 0
294
+        var now_in_number = 0
295
+        stock_in_number = row.warehousing_count * row.XtBaseDrug.min_number
296
+
297
+        now_in_number = row.last_stock_max_number * row.XtBaseDrug.min_number + row.last_stock_min_number
298
+       if(parseInt(row.last_stock_max_number)<0 && parseInt(row.last_stock_min_number)<0){
299
+        this.$message.error("盘点后数量不能为负数!")
300
+        return false
301
+       }
302
+       console.log("stock_in_number",stock_in_number)
303
+       console.log("now_in_number",now_in_number)
304
+       if(parseInt(now_in_number) >parseInt(stock_in_number)){
305
+         this.$message.error("该批次盘点后数量不能大于或等于入库数量!")
306
+         return false
307
+       }
308
+        var params = {
309
+            id:row.id,
310
+            stock_max_number:parseInt(row.stock_max_number),
311
+            stock_min_number:parseInt(row.stock_min_number),
312
+            last_stock_max_number:parseInt(row.last_stock_max_number),
313
+            last_stock_min_number:parseInt(row.last_stock_min_number),
314
+            drug_id:row.drug_id,
315
+            storehouse_id:parseInt(row.storehouse_id), 
316
+            is_type:parseInt(row.type),
317
+            specification_name:row.XtBaseDrug.dose + row.XtBaseDrug.dose_unit + "*"+row.XtBaseDrug.min_number+row.min_unit+"/"+row.XtBaseDrug.max_unit
318
+        }
319
+        console.log("params22222222222222",params)
320
+       updateDrugInventoryWarehouseInfo(params).then(response=>{
321
+          if(response.data.state ==1){
322
+            var msg = response.data.data.msg
323
+            this.$message.success("保存成功!")
324
+            row.id =row.drug_id
325
+            this.handleCurrentChange(row)
326
+          }
327
+       })
328
+     }
329
+    }
330
+  };
331
+  </script>
332
+  
333
+  <style rel="stylesheet/css" lang="scss" scoped>
334
+  .new-main-contain {
335
+    height: 100%;
336
+    display: flex;
337
+    flex-direction: column;
338
+  }
339
+  
340
+  .app-container {
341
+    height: 100%;
342
+  }
343
+  .mainLeft {
344
+    width: 400px;
345
+    height: 100%;
346
+    display: flex;
347
+    flex-direction: column;
348
+  
349
+    .el-radio {
350
+      margin-right: 5px;
351
+    }
352
+  
353
+    .list {
354
+      margin: 10px 0;
355
+    }
356
+  }
357
+  .mainRight {
358
+    margin-left: 10px;
359
+    flex: 1;
360
+    height: 100%;
361
+    display: flex;
362
+    flex-direction: column;
363
+    overflow-y: auto;
364
+    .titlelist {
365
+      display: flex;
366
+      justify-content: space-between;
367
+      white-space: nowrap;
368
+      color: #909399;
369
+      font-size: 14px;
370
+      /deep/ .el-input__inner {
371
+        font-size: 13px !important;
372
+      }
373
+    }
374
+    .el-table {
375
+      margin-top: -13px;
376
+    }
377
+    .el-button {
378
+      height: 34px;
379
+      width: 65px;
380
+    }
381
+    /deep/ .el-divider {
382
+      height: 2px;
383
+      margin-top: 10px;
384
+    }
385
+  
386
+    /deep/ .el-table__body-wrapper {
387
+      overflow-x: scroll !important;
388
+    }
389
+  }
390
+  
391
+  /deep/ .el-input__inner {
392
+    padding-right: 15px;
393
+  }
394
+  
395
+  /deep/ .el-table--scrollable-x .el-table__body-wrapper {
396
+    overflow: auto;
397
+    overflow-x: hidden;
398
+  }
399
+  /deep/ .gutter {
400
+    width: 15px !important;
401
+    display: inline-block !important;
402
+  }
403
+  /deep/ .el-table__fixed-right-patch {
404
+    width: 15px !important;
405
+  }
406
+  
407
+  /deep/ .el-table__fixed-right {
408
+    bottom: 0 !important;
409
+    left: auto;
410
+    right: 0;
411
+  }
412
+  /deep/ .el-table__body-wrapper::-webkit-scrollbar {
413
+    width: 15px !important;
414
+    height: 15px !important;
415
+  }
416
+  </style>
417
+  

+ 4 - 0
src/xt_pages/stock/query/goodNewQuery.vue View File

@@ -484,6 +484,10 @@ export default {
484 484
     },
485 485
     getlist(){
486 486
        this.loading = true
487
+       if(this.org_id == 10679){
488
+           this.page =1
489
+           this.limit =100
490
+       }
487 491
         var params = {
488 492
           storehouse_id:this.storehouse_id,
489 493
           good_type:this.good_type,

+ 5 - 5
src/xt_pages/stock/stockFlow.vue View File

@@ -93,17 +93,17 @@
93 93
             <span v-if="scope.row.consumable_type == 15">{{scope.row.warehouse_out_order_number}}</span>
94 94
            </template>
95 95
         </el-table-column>
96
-        <el-table-column prop="drug_name" label="操作日期" align="center">
96
+        <el-table-column prop="drug_name" label="出库日期" align="center">
97 97
            <template slot-scope="scope">
98 98
              {{getTime(scope.row.ctime)}}
99 99
            </template>
100 100
         </el-table-column>
101
-<!-- 
102
-        <el-table-column prop="drug_name" label="出库日期" align="center">
101
+
102
+        <el-table-column prop="drug_name" label="操作日期" align="center">
103 103
            <template slot-scope="scope">
104
-             {{getTime(scope.row.system_time)}}
104
+             {{getTime(scope.row.operate_time)}}
105 105
            </template>
106
-        </el-table-column> -->
106
+        </el-table-column>
107 107
         <el-table-column prop="drug_name" label="仓库名称"  align="center">
108 108
            <template slot-scope="scope">
109 109
              <span>{{getHouseName(scope.row.storehouse_id)}}</span>

+ 54 - 4
src/xt_pages/stock/stockOutOrder.vue View File

@@ -2153,7 +2153,8 @@ export default {
2153 2153
       };
2154 2154
       getOutExportList(params).then((response) => {
2155 2155
         if (response.data.state == 1) {
2156
-          var list = response.data.data.list;
2156
+          var list = response.data.data.list
2157
+        
2157 2158
           var outCount = response.data.data.outCount;
2158 2159
           
2159 2160
           for (let i = 0; i < list.length; i++) {
@@ -2178,9 +2179,58 @@ export default {
2178 2179
               }
2179 2180
             }
2180 2181
           }
2181
-          console.log("list232332232332323223",list)
2182
-          this.exportList = list;
2183
-          this.exportLoding = false
2182
+          console.log("list============",list)
2183
+          if(list!=null && list.length>0){
2184
+            let dataInfo = {}
2185
+              list.forEach((item, index) => {
2186
+              let { good_id } = item
2187
+              if (!dataInfo[good_id]) {
2188
+                dataInfo[good_id] = {
2189
+                  good_id:item.good_id,
2190
+                  good_name:item.good_name,
2191
+                  warehouse_out_order_number:item.warehouse_out_order_number,
2192
+                  specification_name:item.specification_name,
2193
+                  child: [],
2194
+                  count:0,
2195
+                  price:item.price,
2196
+                  manufacturer:item.manufacturer,
2197
+                  dealer:item.dealer,
2198
+                  product_date:item.product_date,
2199
+                  expiry_date:item.expiry_date,
2200
+                  remark:item.remark,
2201
+                  warehouse_out_time:item.warehouse_out_time,
2202
+                  good_type_id:item.good_type_id,
2203
+                  ctime:item.ctime
2204
+                }
2205
+              }
2206
+            })
2207
+            let arr = Object.values(dataInfo)
2208
+         
2209
+
2210
+            if(arr!=null && arr.length>0){
2211
+              for(let i=0;i<arr.length;i++){
2212
+                for(let j=0;j<list.length;j++){
2213
+                  if(arr[i].good_id == list[j].good_id){
2214
+                     arr[i].child.push(list[j])
2215
+                  }
2216
+                }
2217
+              }
2218
+            }
2219
+
2220
+            if(arr!=null&& arr.length>0){
2221
+               
2222
+              for(let i=0;i<arr.length;i++){
2223
+                for(let j=0;j<arr[i].child.length;j++){
2224
+                  arr[i].count +=arr[i].child[j].count
2225
+                }
2226
+              }
2227
+            }
2228
+
2229
+            console.log("arr0233333333333333",arr)
2230
+            this.exportList = arr;
2231
+            this.exportLoding = false
2232
+          }
2233
+         
2184 2234
         }
2185 2235
       });
2186 2236
     },