陈少旭 před 13 hodinami
rodič
revize
81753ff5e9

+ 62 - 47
src/xt_pages/Pharmacy/PatientDispensing.vue Zobrazit soubor

@@ -398,7 +398,6 @@ export default {
398 398
       currentIndex:0,
399 399
       is_drug_open:"2",
400 400
       textarea:"",
401
-      drug_code_open:0,
402 401
       patientList:[]
403 402
 
404 403
     };
@@ -419,6 +418,7 @@ export default {
419 418
       getpartitionlist(params).then((res) => {
420 419
         if (res.data.state == 1) {
421 420
           this.fen = res.data.data.list;
421
+          this.is_drug_open = res.data.data.config.is_open
422 422
         }
423 423
       });
424 424
     },
@@ -536,7 +536,7 @@ export default {
536 536
           this.waitmount = res.data.data.itotal;
537 537
           this.alreadmount = res.data.data.wtotal;
538 538
           this.drugList = res.data.data.drug
539
-          this.drug_code_open = res.data.data.config.is_open
539
+          this.is_drug_open = res.data.data.config.is_open
540 540
         }
541 541
       });
542 542
       // console.log("2222222")
@@ -926,61 +926,68 @@ export default {
926 926
               cancelButtonText: "取 消",
927 927
               type: "warning",
928 928
             }).then(() => {
929
-              var tmp = that.currentRow.PatientID;
930
-              var params = {
931
-                patient_id: that.currentRow.PatientID,
932
-                time: that.start_time,
933
-              };
934
-              that.$confirm("确定是否对该患者进行发药?", "患者发药", {
935
-                confirmButtonText: "确 定",
936
-                cancelButtonText: "取 消",
937
-                type: "warning",
938
-              }).then(() => {
939
-                dispensingmedicine(params).then((res) => {
940
-                  if (res.data.state == 1) {
941
-                    that.$message.success("操作成功");
942
-                    that.gettodaynumber();
943
-                    that.searchAction();
944
-                    that.tableData = null;
945
-                    that.fun4(tmp);
946
-                    that.state = 2;
947
-
948
-                    //进行追溯码上传
949
-                    axios.get('http://127.0.0.1:9532/api/changedrug/four', {
950
-                      params:params
951
-                    })
952
-                      .then(function(response) {
953
-                        if (response.data.state == 0) {
954
-                          that.$message.error(response.data.msg)
955
-                          return false
929
+
930
+            })
931
+              .catch(() => {});
932
+            return false
933
+          } else {
934
+            var tmp = that.currentRow.PatientID;
935
+            var params = {
936
+              patient_id: that.currentRow.PatientID,
937
+              time: that.start_time,
938
+              admin_user_id: that.$store.getters.xt_user.user.id,
939
+            };
940
+            that.$confirm("确定是否对该患者进行发药?", "患者发药", {
941
+              confirmButtonText: "确 定",
942
+              cancelButtonText: "取 消",
943
+              type: "warning",
944
+            }).then(() => {
945
+              dispensingmedicine(params).then((res) => {
946
+                if (res.data.state == 1) {
947
+                  that.$message.success("操作成功");
948
+                  that.gettodaynumber();
949
+                  that.searchAction();
950
+                  that.tableData = null;
951
+                  that.fun4(tmp);
952
+                  that.state = 2;
953
+                  //进行追溯码上传
954
+                  axios.get('http://127.0.0.1:9532/api/changedrug/four', {
955
+                    params:params
956
+                  })
957
+                    .then(function(response) {
958
+                      if (response.data.state == 0) {
959
+                        that.$message.error(response.data.msg)
960
+                        return false
961
+                      } else {
962
+                        if (response.data.data.failed_code == -10) {
963
+                          that.$confirm(response.data.data.msg, '医保错误信息', {
964
+                            confirmButtonText: '确 定',
965
+                            type: 'warning'
966
+                          }).then(() => {
967
+
968
+                          }).catch(() => {
969
+                          })
956 970
                         } else {
957
-                          if (response.data.data.failed_code == -10) {
958
-                            that.$confirm(response.data.data.msg, '医保错误信息', {
971
+                          if(response.data.data.msg.length > 0){
972
+                            that.$confirm(response.data.data.msg, '上传信息', {
959 973
                               confirmButtonText: '确 定',
960 974
                               type: 'warning'
961 975
                             }).then(() => {
962 976
 
963 977
                             }).catch(() => {
964 978
                             })
965
-
966
-                          } else {
967
-
968 979
                           }
969 980
                         }
970
-                      })
971
-                      .catch(function(error) {
972
-                      })
973
-                  } else {
974
-                    that.$message.error(res.data.msg);
975
-                  }
976
-                });
977
-              })
978
-                .catch(() => {});
981
+                      }
982
+                    })
983
+                    .catch(function(error) {
984
+                    })
985
+                } else {
986
+                  that.$message.error(res.data.msg);
987
+                }
988
+              });
979 989
             })
980 990
               .catch(() => {});
981
-            return false
982
-          } else {
983
-
984 991
           }
985 992
         }).catch(function(error) {
986 993
           that.$confirm("数据异常,请检查医保程序是否有打开", "提示", {
@@ -1072,6 +1079,7 @@ export default {
1072 1079
             var tmp = that.currentRow.PatientID;
1073 1080
             var params = {
1074 1081
               patient_id: that.currentRow.PatientID,
1082
+              admin_user_id: that.$store.getters.xt_user.user.id,
1075 1083
               time: that.start_time,
1076 1084
             };
1077 1085
             that.$confirm("确定是否对该患者进行退药?", "患者退药", {
@@ -1105,9 +1113,16 @@ export default {
1105 1113
 
1106 1114
                           }).catch(() => {
1107 1115
                           })
1108
-
1109 1116
                         } else {
1117
+                          if(response.data.data.msg.length > 0){
1118
+                            that.$confirm(response.data.data.msg, '上传信息', {
1119
+                              confirmButtonText: '确 定',
1120
+                              type: 'warning'
1121
+                            }).then(() => {
1110 1122
 
1123
+                            }).catch(() => {
1124
+                            })
1125
+                          }
1111 1126
                         }
1112 1127
                       }
1113 1128
                     })

+ 127 - 73
src/xt_pages/drugSourceCode/drugChange.vue Zobrazit soubor

@@ -48,25 +48,10 @@
48 48
             </el-option>
49 49
           </el-select>
50 50
         </div>
51
-        <div>
52
-          <span>变更状态:</span>
53
-          <el-select size="small" v-model="change_type" placeholder="请选择"
54
-                    style="width:100px;" @change="change">
55
-            <el-option
56
-              label="不限"
57
-              value="3">
58
-            </el-option>
59
-            <el-option
60
-              v-for="item,index in changes"
61
-              :key="index"
62
-              :label="item.name"
63
-              :value="item.id">
64
-            </el-option>
65
-          </el-select>
66
-        </div>
51
+
67 52
         <div>
68 53
           <el-button type="primary" @click="query()">查询</el-button>
69
-          <el-button type="primary" @click="change_stock()">销售变更</el-button>
54
+          <el-button type="primary" @click="change_stock()">批量销售上传</el-button>
70 55
           <el-button type="primary" @click="exportdata()">导出</el-button>
71 56
 
72 57
           <!--        <el-button type="primary" @click="change()">变更</el-button>-->
@@ -128,12 +113,6 @@
128 113
           </template>
129 114
         </el-table-column>
130 115
 
131
-        <el-table-column align="center" prop="total" label="变更状态">
132
-          <template slot-scope="scope">
133
-            <div>{{scope.row.is_bg?'已变更':'未变更'}}</div>
134
-          </template>
135
-        </el-table-column>
136
-
137 116
         <el-table-column align="center" prop="total" label="盘存日期">
138 117
           <template slot-scope="scope">
139 118
             <div>{{scope.row.pc_date}}</div>
@@ -142,8 +121,8 @@
142 121
 
143 122
         <el-table-column label="操作" width="200">
144 123
           <template slot-scope="scope">
145
-            <el-button v-if="!scope.row.is_sale || scope.row.is_sale == 0 || scope.row.is_bg == 0" type="primary" @click="sigle_stock(scope.row)">销售变更</el-button>
146
-            <el-button v-if="scope.row.is_sale == 1 || scope.row.is_bg == 1" type="warning" @click="deleteStock(scope.row)">撤销</el-button>
124
+            <el-button v-if="!scope.row.is_sale || scope.row.is_sale == 0" type="primary" @click="sigle_stock(scope.row)">销售上传</el-button>
125
+            <el-button v-if="scope.row.is_sale == 1" type="warning" @click="deleteStock(scope.row)">撤销</el-button>
147 126
           </template>
148 127
         </el-table-column>
149 128
       </el-table>
@@ -210,12 +189,6 @@
210 189
           </template>
211 190
         </el-table-column>
212 191
 
213
-        <el-table-column align="center" prop="total" label="变更状态">
214
-          <template slot-scope="scope">
215
-            <div>{{scope.row.is_bg?'已变更':'未变更'}}</div>
216
-          </template>
217
-        </el-table-column>
218
-
219 192
         <el-table-column align="center" prop="total" label="盘存日期">
220 193
           <template slot-scope="scope">
221 194
             <div>{{scope.row.pc_date}}</div>
@@ -291,7 +264,7 @@ export default {
291 264
       patientList:[],
292 265
       crumbs: [
293 266
         { path: false, name: '药品追溯' },
294
-        { path: false, name: '药品变更' }
267
+        { path: false, name: '药品销售' }
295 268
       ],
296 269
     }
297 270
   },
@@ -336,33 +309,51 @@ export default {
336 309
         ids:ids,
337 310
         admin_user_id:this.$store.getters.xt_user.user.id
338 311
       };
339
-      this.isloading = true
340
-      axios.get('http://127.0.0.1:9532/api/delete_xs_bg',{params:params}).then(function(response) {
312
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
341 313
         if (response.data.state == 0) {
342
-          this.isloading = false
314
+          // that.$message.error(response.data.data.msg);
315
+          that.$confirm("请检查医保程序是否有打开", "提示", {
316
+            confirmButtonText: "确 定",
317
+            cancelButtonText: "取 消",
318
+            type: "warning",
319
+          }).then(() => {
320
+            axios.get('http://127.0.0.1:9532/api/delete_xs_bg',{params:params}).then(function(response) {
321
+              if (response.data.state == 0) {
322
+                that.$message.error(response.data.data.msg);
323
+                return false
324
+              } else {
325
+                if(response.data.data.failed_code == -10){
326
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
327
+                    confirmButtonText: '确 定',
328
+                    type: 'warning'
329
+                  }).then(() => {
330
+
331
+                  }).catch(() => {
332
+                  })
333
+                }else{
334
+                  that.GetDrugStock()
335
+
336
+                }
337
+              }
338
+            }).catch(function(error) {
339
+            })
343 340
 
344
-          that.$message.error(response.data.data.msg);
341
+          })
342
+            .catch(() => {});
345 343
           return false
346 344
         } else {
347
-          this.isloading = false
348
-          if(response.data.data.failed_code == -10){
349
-            that.$confirm(response.data.data.msg, '医保错误信息', {
350
-              confirmButtonText: '确 定',
351
-              type: 'warning'
352
-            }).then(() => {
353
-
354
-            }).catch(() => {
355
-            })
356
-          }else{
357
-            that.GetDrugStock()
358
-
359 345
 
360
-          }
361 346
         }
362 347
       }).catch(function(error) {
348
+        that.$confirm("请检查医保程序是否有打开", "提示", {
349
+          confirmButtonText: "确 定",
350
+          cancelButtonText: "取 消",
351
+          type: "warning",
352
+        }).then(() => {
353
+        })
354
+          .catch(() => {});
363 355
       })
364 356
 
365
-
366 357
     },
367 358
     sigle_stock(row){
368 359
       var that = this;
@@ -370,24 +361,52 @@ export default {
370 361
         ids:row.id,
371 362
         admin_user_id:this.$store.getters.xt_user.user.id
372 363
       };
373
-      axios.get('http://127.0.0.1:9532/api/changedrug',{params:params}).then(function(response) {
364
+
365
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
374 366
         if (response.data.state == 0) {
375
-          that.$message.error(response.data.data.msg);
367
+          // that.$message.error(response.data.data.msg);
368
+          that.$confirm("请检查医保程序是否有打开", "提示", {
369
+            confirmButtonText: "确 定",
370
+            cancelButtonText: "取 消",
371
+            type: "warning",
372
+          }).then(() => {
373
+
374
+
375
+          })
376
+            .catch(() => {});
376 377
           return false
377 378
         } else {
378
-          if(response.data.data.failed_code == -10){
379
-            that.$confirm(response.data.data.msg, '医保错误信息', {
380
-              confirmButtonText: '确 定',
381
-              type: 'warning'
382
-            }).then(() => {
383
-            }).catch(() => {
384
-            })
385
-          }else{
386 379
 
387
-          }
380
+          axios.get('http://127.0.0.1:9532/api/changedrug',{params:params}).then(function(response) {
381
+            if (response.data.state == 0) {
382
+              that.$message.error(response.data.data.msg);
383
+              return false
384
+            } else {
385
+              if(response.data.data.failed_code == -10){
386
+                that.$confirm(response.data.data.msg, '医保错误信息', {
387
+                  confirmButtonText: '确 定',
388
+                  type: 'warning'
389
+                }).then(() => {
390
+                }).catch(() => {
391
+                })
392
+              }else{
393
+
394
+
395
+              }
396
+            }
397
+          }).catch(function(error) {
398
+          })
388 399
         }
389 400
       }).catch(function(error) {
401
+        that.$confirm("请检查医保程序是否有打开", "提示", {
402
+          confirmButtonText: "确 定",
403
+          cancelButtonText: "取 消",
404
+          type: "warning",
405
+        }).then(() => {
406
+        })
407
+          .catch(() => {});
390 408
       })
409
+
391 410
     },
392 411
     handleSizeChange(val) {
393 412
       this.limit = val
@@ -445,6 +464,7 @@ export default {
445 464
       return jsonData.map(v => filterVal.map(j => v[j]))
446 465
     },
447 466
     change_stock(){
467
+
448 468
       let ids  = ""
449 469
       for (var i = 0; i < this.selection.length; i++){
450 470
         if (ids.length == 0){
@@ -453,30 +473,64 @@ export default {
453 473
           ids = ids + "," + this.selection[i].id
454 474
         }
455 475
       }
476
+      if(ids.length == 0 ){
477
+        this.$message.error("请勾选需要上传的数据");
478
+        return
479
+      }
480
+
456 481
       var that = this;
457 482
       let params = {
458 483
         ids:ids,
459 484
         admin_user_id:this.$store.getters.xt_user.user.id
460 485
       };
461
-      axios.get('http://127.0.0.1:9532/api/changedrug',{params:params}).then(function(response) {
486
+
487
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
462 488
         if (response.data.state == 0) {
463
-          that.$message.error(response.data.data.msg);
489
+          // that.$message.error(response.data.data.msg);
490
+          that.$confirm("请检查医保程序是否有打开", "提示", {
491
+            confirmButtonText: "确 定",
492
+            cancelButtonText: "取 消",
493
+            type: "warning",
494
+          }).then(() => {
495
+          })
496
+            .catch(() => {});
464 497
           return false
465 498
         } else {
466
-          if(response.data.data.failed_code == -10){
467
-            that.$confirm(response.data.data.msg, '医保错误信息', {
468
-              confirmButtonText: '确 定',
469
-              type: 'warning'
470
-            }).then(() => {
471
-            }).catch(() => {
472
-            })
473
-          }else{
474
-
475
-          }
499
+          axios.get('http://127.0.0.1:9532/api/changedrug',{params:params}).then(function(response) {
500
+            if (response.data.state == 0) {
501
+              that.$message.error(response.data.data.msg);
502
+              return false
503
+            } else {
504
+              if(response.data.data.failed_code == -10){
505
+                that.$confirm(response.data.data.msg, '医保错误信息', {
506
+                  confirmButtonText: '确 定',
507
+                  type: 'warning'
508
+                }).then(() => {
509
+                }).catch(() => {
510
+                })
511
+              }else{
512
+
513
+              }
514
+            }
515
+          }).catch(function(error) {
516
+          })
476 517
         }
477 518
       }).catch(function(error) {
519
+        that.$confirm("请检查医保程序是否有打开", "提示", {
520
+          confirmButtonText: "确 定",
521
+          cancelButtonText: "取 消",
522
+          type: "warning",
523
+        }).then(() => {
524
+        })
525
+          .catch(() => {});
478 526
       })
479 527
 
528
+
529
+
530
+
531
+
532
+
533
+
480 534
     },
481 535
     query(){
482 536
       this.GetDrugStock()

+ 30 - 31
src/xt_pages/drugSourceCode/drugCodeQuery.vue Zobrazit soubor

@@ -30,8 +30,8 @@
30 30
             value-format="yyyy-MM-dd"
31 31
           ></el-date-picker>
32 32
         </div>
33
-  
34
-  
33
+
34
+
35 35
         <div>
36 36
           <div>上传状态:
37 37
             <el-select size="small" v-model="is_sale" placeholder="请选择" style="width:100px;" @change="changeStock">
@@ -44,7 +44,7 @@
44 44
             </el-select>
45 45
          </div>
46 46
         </div>
47
-  
47
+
48 48
         <div>
49 49
           <el-button type="primary" @click="query()">查询</el-button>
50 50
           <el-button type="primary" @click="exportdata()">导出</el-button>
@@ -74,7 +74,7 @@
74 74
         </el-table-column>
75 75
         <el-table-column align="center" prop="name" label="药品追溯码">
76 76
           <template slot-scope="scope">
77
-            <div @click="getDrugCode(scope.row.id,scope.row.DataSources,scope.row.drug_code,scope.$index)"><el-input style="width: 100;" v-model="scope.row.drug_code"></el-input></div> 
77
+            <div @click="getDrugCode(scope.row.id,scope.row.DataSources,scope.row.drug_code,scope.$index)"><el-input style="width: 100;" v-model="scope.row.drug_code"></el-input></div>
78 78
           </template>
79 79
         </el-table-column>
80 80
         <el-table-column align="center" prop="name" label="上传状态">
@@ -94,14 +94,14 @@
94 94
         <el-table-column align="center" prop="name" label="操作" width="200">
95 95
           <template slot-scope="scope">
96 96
             <div>
97
-             <el-button v-if="scope.row.is_upload == 1" type="primary" @click="sigle_stock(scope.row)">未上传</el-button>   
97
+             <el-button v-if="scope.row.is_upload == 1" type="primary" @click="sigle_stock(scope.row)">撤销</el-button>
98 98
             <el-button type="primary" v-if="scope.row.is_upload == 0 || scope.row.is_upload == 2" @click="toUpload(scope.row)">上传</el-button>
99
-            <el-button v-if="faShow == true" type="primary" @click="toFaYao(scope.row)">发药</el-button>   
99
+            <el-button v-if="faShow == true" type="primary" @click="toFaYao(scope.row)">发药</el-button>
100 100
             </div>
101 101
           </template>
102 102
         </el-table-column>
103
-  
104
-       
103
+
104
+
105 105
       </el-table>
106 106
       <el-pagination
107 107
         @size-change="handleSizeChange"
@@ -112,10 +112,10 @@
112 112
         style="margin-top:20px;float: right"
113 113
         :total="value"
114 114
       ></el-pagination>
115
-  
116
-    
117
- 
118
-  
115
+
116
+
117
+
118
+
119 119
 
120 120
       <el-dialog
121 121
         title="药品追溯码"
@@ -137,18 +137,18 @@
137 137
       </span>
138 138
       </el-dialog>
139 139
     </div>
140
-  
141
-   
140
+
141
+
142 142
   </template>
143
-  
144
-  
143
+
144
+
145 145
   <script>
146 146
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
147 147
   import { getHisDrugCodeQueryList,createUploadDrugCode,getPatientDrugCode } from '../../api/new_stock/stock'
148 148
   import { getDictionaryDataConfig } from "@/utils/data";
149 149
   import { uParseTime } from '@/utils/tools'
150 150
   import { changeDrugCode } from "@/api/pharmacy";
151
-  
151
+
152 152
   import axios from 'axios'
153 153
   const moment = require('moment')
154 154
   export default {
@@ -160,7 +160,7 @@
160 160
         drugTypeList: [{ id: 0, name: "全部" }],
161 161
         start_time: new Date(new Date().getFullYear(), new Date().getMonth(), 1).toLocaleDateString('en-CA'),
162 162
         end_time: new Date(new Date().getFullYear(), new Date().getMonth() + 1, 0).toLocaleDateString('en-CA'),
163
-  
163
+
164 164
         tableData: [],
165 165
         change_type:"3",
166 166
         selection:[],
@@ -198,7 +198,7 @@
198 198
         }
199 199
        },
200 200
        getDrugCode(id,DataSources,DrugCode,index){
201
-            this.id = id 
201
+            this.id = id
202 202
             this.textarea = DrugCode
203 203
             this.currentIndex = index
204 204
             this.dialogVisibleOne = true
@@ -276,8 +276,8 @@
276 276
         this.selection = selection
277 277
       },
278 278
       delete(){
279
-  
280
-  
279
+
280
+
281 281
       },
282 282
       exportdata(){
283 283
         console.log("hahahahh",this.tableData)
@@ -301,7 +301,7 @@
301 301
              this.tableData[i].specification_name = this.getDrugSpec(this.tableData[i].drug_id)
302 302
            }
303 303
         }
304
-       
304
+
305 305
         import('@/vendor/Export2Excel').then(excel => {
306 306
           const tHeader = ['患者姓名', '处方日期', '药品名称', '规格', '开药总量', '药品追溯码','上传状态','发药状态']
307 307
           const filterVal = ['patient_name', 'advice_date_str', 'advice_name', 'specification_name', 'prescribing_numbers', 'drug_code','is_upload_name','is_medicine_name']
@@ -313,11 +313,11 @@
313 313
            filename: '药品追溯'
314 314
          })
315 315
         })
316
-  
316
+
317 317
       },formatJson(filterVal, jsonData) {
318 318
         return jsonData.map(v => filterVal.map(j => v[j]))
319 319
       },
320
-    
320
+
321 321
       query(){
322 322
         this.getlist()
323 323
       },
@@ -328,9 +328,9 @@
328 328
             name = this.drugTypeList[i].name;
329 329
           }
330 330
         }
331
-  
331
+
332 332
         return name;
333
-      },  
333
+      },
334 334
       getTime(val) {
335 335
         if(val == "" || val == undefined){
336 336
           return ""
@@ -346,7 +346,7 @@
346 346
           page:this.page,
347 347
           limit:this.limit,
348 348
           is_sale:this.is_sale,
349
-        
349
+
350 350
         }
351 351
         getHisDrugCodeQueryList(params).then(response => {
352 352
           if (response.data.state == 0) {
@@ -389,7 +389,7 @@
389 389
         })
390 390
       },
391 391
       toFaYao(row){
392
-        
392
+
393 393
         if(this.is_open == 1){
394 394
           if(row.drug_code==''){
395 395
              this.$message.error("药品追溯码不能为空!")
@@ -405,7 +405,7 @@
405 405
           if(response.data.state == 1){
406 406
              this.$message.success("发药成功!")
407 407
              this.getlist()
408
-          } 
408
+          }
409 409
         })
410 410
       }
411 411
     },
@@ -416,5 +416,4 @@
416 416
     }
417 417
   }
418 418
   </script>
419
-  
420
-  
419
+

+ 178 - 142
src/xt_pages/drugSourceCode/drugQuery.vue Zobrazit soubor

@@ -1,5 +1,9 @@
1 1
 <template>
2 2
   <div>
3
+    <div class="position">
4
+      <BreadCrumb :crumbs="crumbs"></BreadCrumb>
5
+    </div>
6
+    <div class="app-container">
3 7
     <div style="display: flex;justify-content: space-between;margin-bottom:10px;">
4 8
       <div class="cell clearfix">
5 9
         <span>入库时间:</span>
@@ -31,8 +35,7 @@
31 35
         ></el-date-picker>
32 36
       </div>
33 37
 
34
-
35
-      <div>
38
+      <div class="cell clearfix">
36 39
         <div>查询类型:</div>
37 40
         <el-select size="small" v-model="stock_type" placeholder="请选择"
38 41
                    style="width:100px;margin-left:10px;" @change="changeStockType">
@@ -45,7 +48,7 @@
45 48
         </el-select>
46 49
       </div>
47 50
 
48
-      <div>
51
+      <div class="cell clearfix">
49 52
         <div>药品:</div>
50 53
         <el-select size="small" v-model="drug_id" placeholder="请选择"
51 54
                    style="width:100px;margin-left:10px;" @change="change">
@@ -65,6 +68,7 @@
65 68
         <el-button type="primary" @click="query()">查询</el-button>
66 69
       </div>
67 70
     </div>
71
+    </div>
68 72
     <el-table v-if="stock_type == 1" :data="tableData" border :row-style="{ color: '#303133' }" ref="table"
69 73
               :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
70 74
               max-height="600"
@@ -609,7 +613,6 @@ export default {
609 613
 
610 614
     },
611 615
     query(){
612
-
613 616
       var that = this;
614 617
       let params = {
615 618
         id:this.drug_id,
@@ -617,162 +620,195 @@ export default {
617 620
         end_time:this.end_time,
618 621
         admin_user_id:this.$store.getters.xt_user.user.id
619 622
       };
620
-      this.tableData = []
621
-      if(this.stock_type == 1){
622
-
623
-        axios.get('http://127.0.0.1:9532/api/3508',{params:params}).then(function(response) {
624
-          if (response.data.state == 0) {
625
-            that.$message.error(response.data.data.msg);
626
-            return false
627
-          } else {
628
-            if(response.data.data.failed_code == -10){
629
-              that.$confirm(response.data.data.msg, '医保错误信息', {
630
-                confirmButtonText: '确 定',
631
-                type: 'warning'
632
-              }).then(() => {
633
-
634
-              }).catch(() => {
635
-              })
636
-            }else{
637
-              this.tableData = this.tableData.concat(response.data.data.info)
638 623
 
639
-            }
640
-          }
641
-        }).catch(function(error) {
642
-        })
643 624
 
644
-      }else if(this.stock_type == 2){
645
-        axios.get('http://127.0.0.1:9532/api/3509',{params:params}).then(function(response) {
646
-          if (response.data.state == 0) {
647
-            that.$message.error(response.data.data.msg);
648
-            return false
649
-          } else {
650
-            if(response.data.data.failed_code == -10){
651
-              that.$confirm(response.data.data.msg, '医保错误信息', {
652
-                confirmButtonText: '确 定',
653
-                type: 'warning'
654
-              }).then(() => {
655
-
656
-              }).catch(() => {
625
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
626
+        if (response.data.state == 0) {
627
+          that.isloading = false
628
+
629
+          // that.$message.error(response.data.data.msg);
630
+          that.$confirm("请检查医保程序是否有打开", "提示", {
631
+            confirmButtonText: "确 定",
632
+            cancelButtonText: "取 消",
633
+            type: "warning",
634
+          }).then(() => {
635
+
636
+            this.tableData = []
637
+            if(that.stock_type == 1){
638
+
639
+              axios.get('http://127.0.0.1:9532/api/3508',{params:params}).then(function(response) {
640
+                if (response.data.state == 0) {
641
+                  that.$message.error(response.data.data.msg);
642
+                  return false
643
+                } else {
644
+                  if(response.data.data.failed_code == -10){
645
+                    that.$confirm(response.data.data.msg, '医保错误信息', {
646
+                      confirmButtonText: '确 定',
647
+                      type: 'warning'
648
+                    }).then(() => {
649
+
650
+                    }).catch(() => {
651
+                    })
652
+                  }else{
653
+                    that.tableData = that.tableData.concat(response.data.data.info)
654
+
655
+                  }
656
+                }
657
+              }).catch(function(error) {
657 658
               })
658
-            }else{
659
-              this.tableData = this.tableData.concat(response.data.data.info)
660
-
661
-            }
662
-          }
663
-        }).catch(function(error) {
664
-        })
665 659
 
666
-      }else if(this.stock_type == 3){
667
-        axios.get('http://127.0.0.1:9532/api/3511',{params:params}).then(function(response) {
668
-          if (response.data.state == 0) {
669
-            that.$message.error(response.data.data.msg);
670
-            return false
671
-          } else {
672
-            if(response.data.data.failed_code == -10){
673
-              that.$confirm(response.data.data.msg, '医保错误信息', {
674
-                confirmButtonText: '确 定',
675
-                type: 'warning'
676
-              }).then(() => {
677
-
678
-              }).catch(() => {
660
+            }else if(that.stock_type == 2){
661
+              axios.get('http://127.0.0.1:9532/api/3509',{params:params}).then(function(response) {
662
+                if (response.data.state == 0) {
663
+                  that.$message.error(response.data.data.msg);
664
+                  return false
665
+                } else {
666
+                  if(response.data.data.failed_code == -10){
667
+                    that.$confirm(response.data.data.msg, '医保错误信息', {
668
+                      confirmButtonText: '确 定',
669
+                      type: 'warning'
670
+                    }).then(() => {
671
+
672
+                    }).catch(() => {
673
+                    })
674
+                  }else{
675
+                    that.tableData = that.tableData.concat(response.data.data.info)
676
+
677
+                  }
678
+                }
679
+              }).catch(function(error) {
679 680
               })
680
-            }else{
681
-              this.tableData = this.tableData.concat(response.data.data.info)
682 681
 
683
-            }
684
-          }
685
-        }).catch(function(error) {
686
-        })
682
+            }else if(that.stock_type == 3){
683
+              axios.get('http://127.0.0.1:9532/api/3511',{params:params}).then(function(response) {
684
+                if (response.data.state == 0) {
685
+                  that.$message.error(response.data.data.msg);
686
+                  return false
687
+                } else {
688
+                  if(response.data.data.failed_code == -10){
689
+                    that.$confirm(response.data.data.msg, '医保错误信息', {
690
+                      confirmButtonText: '确 定',
691
+                      type: 'warning'
692
+                    }).then(() => {
693
+
694
+                    }).catch(() => {
695
+                    })
696
+                  }else{
697
+                    that.tableData = that.tableData.concat(response.data.data.info)
698
+
699
+                  }
700
+                }
701
+              }).catch(function(error) {
702
+              })
687 703
 
688
-      }else if(this.stock_type == 4){
689
-        axios.get('http://127.0.0.1:9532/api/3512',{params:params}).then(function(response) {
690
-          if (response.data.state == 0) {
691
-            that.$message.error(response.data.data.msg);
692
-            return false
693
-          } else {
694
-            if(response.data.data.failed_code == -10){
695
-              that.$confirm(response.data.data.msg, '医保错误信息', {
696
-                confirmButtonText: '确 定',
697
-                type: 'warning'
698
-              }).then(() => {
699
-
700
-              }).catch(() => {
704
+            }else if(that.stock_type == 4){
705
+              axios.get('http://127.0.0.1:9532/api/3512',{params:params}).then(function(response) {
706
+                if (response.data.state == 0) {
707
+                  that.$message.error(response.data.data.msg);
708
+                  return false
709
+                } else {
710
+                  if(response.data.data.failed_code == -10){
711
+                    that.$confirm(response.data.data.msg, '医保错误信息', {
712
+                      confirmButtonText: '确 定',
713
+                      type: 'warning'
714
+                    }).then(() => {
715
+
716
+                    }).catch(() => {
717
+                    })
718
+                  }else{
719
+                    that.tableData = that.tableData.concat(response.data.data.info)
720
+
721
+                  }
722
+                }
723
+              }).catch(function(error) {
701 724
               })
702
-            }else{
703
-              this.tableData = this.tableData.concat(response.data.data.info)
704 725
 
705
-            }
706
-          }
707
-        }).catch(function(error) {
708
-        })
726
+            }else if(that.stock_type == 5){
727
+              axios.get('http://127.0.0.1:9532/api/3513',{params:params}).then(function(response) {
728
+                if (response.data.state == 0) {
729
+                  that.$message.error(response.data.data.msg);
730
+                  return false
731
+                } else {
732
+                  if(response.data.data.failed_code == -10){
733
+                    that.$confirm(response.data.data.msg, '医保错误信息', {
734
+                      confirmButtonText: '确 定',
735
+                      type: 'warning'
736
+                    }).then(() => {
737
+
738
+                    }).catch(() => {
739
+                    })
740
+                  }else{
741
+                    that.tableData = that.tableData.concat(response.data.data.info)
742
+
743
+                  }
744
+                }
745
+              }).catch(function(error) {
746
+              })
709 747
 
710
-      }else if(this.stock_type == 5){
711
-        axios.get('http://127.0.0.1:9532/api/3513',{params:params}).then(function(response) {
712
-          if (response.data.state == 0) {
713
-            that.$message.error(response.data.data.msg);
714
-            return false
715
-          } else {
716
-            if(response.data.data.failed_code == -10){
717
-              that.$confirm(response.data.data.msg, '医保错误信息', {
718
-                confirmButtonText: '确 定',
719
-                type: 'warning'
720
-              }).then(() => {
721
-
722
-              }).catch(() => {
748
+            }else if(this.stock_type == 6){
749
+              axios.get('http://127.0.0.1:9532/api/35081',{params:params}).then(function(response) {
750
+                if (response.data.state == 0) {
751
+                  that.$message.error(response.data.data.msg);
752
+                  return false
753
+                } else {
754
+                  if(response.data.data.failed_code == -10){
755
+                    that.$confirm(response.data.data.msg, '医保错误信息', {
756
+                      confirmButtonText: '确 定',
757
+                      type: 'warning'
758
+                    }).then(() => {
759
+
760
+                    }).catch(() => {
761
+                    })
762
+                  }else{
763
+                    that.tableData = that.tableData.concat(response.data.data.info)
764
+
765
+                  }
766
+                }
767
+              }).catch(function(error) {
723 768
               })
724
-            }else{
725
-              this.tableData = this.tableData.concat(response.data.data.info)
726 769
 
770
+            }else if(that.stock_type == 7){
771
+              axios.get('http://127.0.0.1:9532/api/35082',{params:params}).then(function(response) {
772
+                if (response.data.state == 0) {
773
+                  that.$message.error(response.data.data.msg);
774
+                  return false
775
+                } else {
776
+                  if(response.data.data.failed_code == -10){
777
+                    that.$confirm(response.data.data.msg, '医保错误信息', {
778
+                      confirmButtonText: '确 定',
779
+                      type: 'warning'
780
+                    }).then(() => {
781
+
782
+                    }).catch(() => {
783
+                    })
784
+                  }else{
785
+                    that.tableData = that.tableData.concat(response.data.data.info)
786
+
787
+                  }
788
+                }
789
+              }).catch(function(error) {
790
+              })
727 791
             }
728
-          }
729
-        }).catch(function(error) {
730
-        })
731 792
 
732
-      }else if(this.stock_type == 6){
733
-        axios.get('http://127.0.0.1:9532/api/35081',{params:params}).then(function(response) {
734
-          if (response.data.state == 0) {
735
-            that.$message.error(response.data.data.msg);
736
-            return false
737
-          } else {
738
-            if(response.data.data.failed_code == -10){
739
-              that.$confirm(response.data.data.msg, '医保错误信息', {
740
-                confirmButtonText: '确 定',
741
-                type: 'warning'
742
-              }).then(() => {
743
-
744
-              }).catch(() => {
745
-              })
746
-            }else{
747
-              this.tableData = this.tableData.concat(response.data.data.info)
748 793
 
749
-            }
750
-          }
751
-        }).catch(function(error) {
794
+          })
795
+            .catch(() => {});
796
+          return false
797
+        } else {
798
+
799
+        }
800
+      }).catch(function(error) {
801
+        that.$confirm("请检查医保程序是否有打开", "提示", {
802
+          confirmButtonText: "确 定",
803
+          cancelButtonText: "取 消",
804
+          type: "warning",
805
+        }).then(() => {
752 806
         })
807
+          .catch(() => {});
808
+      })
809
+
753 810
 
754
-      }else if(this.stock_type == 7){
755
-        axios.get('http://127.0.0.1:9532/api/35082',{params:params}).then(function(response) {
756
-          if (response.data.state == 0) {
757
-            that.$message.error(response.data.data.msg);
758
-            return false
759
-          } else {
760
-            if(response.data.data.failed_code == -10){
761
-              that.$confirm(response.data.data.msg, '医保错误信息', {
762
-                confirmButtonText: '确 定',
763
-                type: 'warning'
764
-              }).then(() => {
765
-
766
-              }).catch(() => {
767
-              })
768
-            }else{
769
-              this.tableData = this.tableData.concat(response.data.data.info)
770 811
 
771
-            }
772
-          }
773
-        }).catch(function(error) {
774
-        })
775
-      }
776 812
     },
777 813
     change(){
778 814
 

+ 143 - 87
src/xt_pages/drugSourceCode/drugStock.vue Zobrazit soubor

@@ -33,12 +33,10 @@
33 33
             value-format="yyyy-MM-dd"
34 34
             @change="endTimeChange"
35 35
           ></el-date-picker>
36
-        </div>
37 36
 
38
-        <div>
39
-          <span>盘存状态:</span>
37
+          <span>销售状态:</span>
40 38
           <el-select size="small" v-model="stock_type" placeholder="请选择"
41
-                    style="width:100px;" @change="changeStock">
39
+                     style="width:100px;" @change="changeStock">
42 40
             <el-option
43 41
               label="不限"
44 42
               value="0">
@@ -52,32 +50,19 @@
52 50
           </el-select>
53 51
         </div>
54 52
 
55
-        <div>
56
-          <span>变更状态:</span>
57
-          <el-select size="small" v-model="change_type" placeholder="请选择"
58
-                    style="width:100px;" @change="change">
59
-            <el-option
60
-              label="不限"
61
-              value="0">
62
-            </el-option>
63
-            <el-option
64
-              v-for="item,index in changes"
65
-              :key="index"
66
-              :label="item.name"
67
-              :value="item.id">
68
-            </el-option>
69
-          </el-select>
70
-        </div>
53
+<!--        <el-input size="small" style="width:150px;" v-model="keywords" @input="searchAction"-->
54
+<!--                  @keyup.enter.native='searchAction'-->
55
+<!--                  placeholder="请输入药品名称"-->
56
+<!--                  class="filter-item"/>-->
57
+
71 58
         <div>
72 59
           <el-button type="primary" @click="query()" >查询</el-button>
73 60
           <el-button type="primary" v-loading="isloading" @click="stock()">盘存</el-button>
74 61
           <el-button type="primary" @click="exportdata()">导出</el-button>
75
-
76
-          <!--        <el-button type="primary" @click="change()">变更</el-button>-->
77 62
         </div>
78 63
       </div>
79
-      <el-table :data="tableData" border :row-style="{ color: '#303133' }" ref="table2"
80
-                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
64
+      <el-table :data="tableData" border :row-style="{ color: '#303133', height: '40px' }" ref="table2"
65
+                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266' }"
81 66
                 max-height="600"
82 67
                 @select="selectCostInfo"
83 68
                 @selection-change="changeCostInfoTableData"
@@ -96,17 +81,15 @@
96 81
           <template slot-scope="scope">{{scope.row.spec}}</template>
97 82
         </el-table-column>
98 83
 
99
-        <el-table-column align="center" prop="name" label="追溯码">
100
-          <template slot-scope="scope">{{scope.row.drug_code}}</template>
101
-        </el-table-column>
102
-
103
-        <el-table-column align="center" prop="name" label="批号">
84
+        <el-table-column  width="100px"   align="center" prop="name" label="追溯码">
104 85
           <template slot-scope="scope">{{scope.row.drug_code}}</template>
105 86
         </el-table-column>
106 87
 
107 88
         <el-table-column align="center" prop="name" label="批号">
108 89
           <template slot-scope="scope">{{scope.row.batch_number}}</template>
109 90
         </el-table-column>
91
+
92
+
110 93
         <el-table-column align="center" prop="name" label="入库数量">
111 94
           <template slot-scope="scope">
112 95
             <div>{{scope.row.count}}{{scope.row.unit}}</div>
@@ -129,11 +112,7 @@
129 112
           </template>
130 113
         </el-table-column>
131 114
 
132
-        <el-table-column align="center" prop="total" label="变更状态">
133
-          <template slot-scope="scope">
134
-            <div>{{scope.row.is_bg?'已变更':'未变更'}}</div>
135
-          </template>
136
-        </el-table-column>
115
+
137 116
 
138 117
         <el-table-column align="center" prop="total" label="盘存日期">
139 118
           <template slot-scope="scope">
@@ -203,11 +182,6 @@
203 182
           </template>
204 183
         </el-table-column>
205 184
 
206
-        <el-table-column align="center" prop="total" label="变更状态">
207
-          <template slot-scope="scope">
208
-            <div>{{scope.row.is_bg?'已变更':'未变更'}}</div>
209
-          </template>
210
-        </el-table-column>
211 185
 
212 186
         <el-table-column align="center" prop="total" label="盘存日期">
213 187
           <template slot-scope="scope">
@@ -239,6 +213,7 @@ export default {
239 213
   },
240 214
   data() {
241 215
     return {
216
+      keywords:"",
242 217
       drugTypeList: [{ id: 0, name: "全部" }],
243 218
       start_time: new Date(new Date().getFullYear(), new Date().getMonth(), 1).toLocaleDateString('en-CA'),
244 219
       end_time: new Date(new Date().getFullYear(), new Date().getMonth() + 3, 0).toLocaleDateString('en-CA'),
@@ -263,34 +238,66 @@ export default {
263 238
     }
264 239
   },
265 240
   methods: {
241
+    searchAction(){
242
+
243
+
244
+    },
266 245
     sigle_stock(row){
267 246
       let ids  = row.id
268 247
       var that = this;
248
+
269 249
       let params = {
270 250
         ids:ids,
271 251
         admin_user_id:this.$store.getters.xt_user.user.id
272 252
       };
273
-      axios.get('http://127.0.0.1:9532/api/pc_bg',{params:params}).then(function(response) {
253
+
254
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
274 255
         if (response.data.state == 0) {
275
-          that.$message.error(response.data.data.msg);
256
+          // that.$message.error(response.data.data.msg);
257
+          that.$confirm("请检查医保程序是否有打开", "提示", {
258
+            confirmButtonText: "确 定",
259
+            cancelButtonText: "取 消",
260
+            type: "warning",
261
+          }).then(() => {
262
+
263
+
264
+          })
265
+            .catch(() => {});
276 266
           return false
277 267
         } else {
278
-          if(response.data.data.failed_code == -10){
279
-            that.$confirm(response.data.data.msg, '医保错误信息', {
280
-              confirmButtonText: '确 定',
281
-              type: 'warning'
282
-            }).then(() => {
283 268
 
284
-            }).catch(() => {
285
-            })
286
-          }else{
287
-            that.GetDrugStock()
288
-
289
-          }
269
+          //有打开则调用接口
270
+          axios.get('http://127.0.0.1:9532/api/pc_bg',{params:params}).then(function(response) {
271
+            if (response.data.state == 0) {
272
+              that.$message.error(response.data.data.msg);
273
+              return false
274
+            } else {
275
+              if(response.data.data.failed_code == -10){
276
+                that.$confirm(response.data.data.msg, '医保错误信息', {
277
+                  confirmButtonText: '确 定',
278
+                  type: 'warning'
279
+                }).then(() => {
280
+
281
+                }).catch(() => {
282
+                })
283
+              }else{
284
+                that.GetDrugStock()
285
+              }
286
+            }
287
+          }).catch(function(error) {
288
+          })
290 289
         }
291 290
       }).catch(function(error) {
291
+        that.$confirm("请检查医保程序是否有打开", "提示", {
292
+          confirmButtonText: "确 定",
293
+          cancelButtonText: "取 消",
294
+          type: "warning",
295
+        }).then(() => {
296
+        })
297
+          .catch(() => {});
292 298
       })
293 299
 
300
+
294 301
     },
295 302
     selectCostInfo(selection, row) {
296 303
       this.selection = selection
@@ -306,32 +313,56 @@ export default {
306 313
         ids:ids,
307 314
         admin_user_id:this.$store.getters.xt_user.user.id
308 315
       };
309
-      this.isloading = true
310
-      axios.get('http://127.0.0.1:9532/api/delete_pc_bg',{params:params}).then(function(response) {
316
+
317
+
318
+
319
+
320
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
311 321
         if (response.data.state == 0) {
312
-          this.isloading = false
322
+          // that.$message.error(response.data.data.msg);
323
+          that.$confirm("请检查医保程序是否有打开", "提示", {
324
+            confirmButtonText: "确 定",
325
+            cancelButtonText: "取 消",
326
+            type: "warning",
327
+          }).then(() => {
313 328
 
314
-          that.$message.error(response.data.data.msg);
329
+
330
+          })
331
+            .catch(() => {});
315 332
           return false
316 333
         } else {
317
-          this.isloading = false
318
-          if(response.data.data.failed_code == -10){
319
-            that.$confirm(response.data.data.msg, '医保错误信息', {
320
-              confirmButtonText: '确 定',
321
-              type: 'warning'
322
-            }).then(() => {
334
+          axios.get('http://127.0.0.1:9532/api/delete_pc_bg',{params:params}).then(function(response) {
335
+            if (response.data.state == 0) {
323 336
 
324
-            }).catch(() => {
325
-            })
326
-          }else{
327
-            that.GetDrugStock()
337
+              that.$message.error(response.data.data.msg);
338
+              return false
339
+            } else {
340
+              if(response.data.data.failed_code == -10){
341
+                that.$confirm(response.data.data.msg, '医保错误信息', {
342
+                  confirmButtonText: '确 定',
343
+                  type: 'warning'
344
+                }).then(() => {
328 345
 
346
+                }).catch(() => {
347
+                })
348
+              }else{
349
+                that.GetDrugStock()
329 350
 
330
-          }
351
+
352
+              }
353
+            }
354
+          }).catch(function(error) {
355
+          })
331 356
         }
332 357
       }).catch(function(error) {
358
+        that.$confirm("请检查医保程序是否有打开", "提示", {
359
+          confirmButtonText: "确 定",
360
+          cancelButtonText: "取 消",
361
+          type: "warning",
362
+        }).then(() => {
363
+        })
364
+          .catch(() => {});
333 365
       })
334
-
335 366
     },
336 367
     exportdata(){
337 368
       let list = []
@@ -381,38 +412,62 @@ export default {
381 412
       var that = this;
382 413
       let params = {
383 414
         ids:ids,
384
-        admin_user_id:this.$store.getters.xt_user.user.id
415
+        admin_user_id:that.$store.getters.xt_user.user.id
385 416
       };
386
-      this.isloading = true
387
-      axios.get('http://127.0.0.1:9532/api/pc_bg',{params:params}).then(function(response) {
417
+      var  that= this
418
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
388 419
         if (response.data.state == 0) {
389
-          this.isloading = false
420
+          // that.$message.error(response.data.data.msg);
421
+          that.$confirm("请检查医保程序是否有打开", "提示", {
422
+            confirmButtonText: "确 定",
423
+            cancelButtonText: "取 消",
424
+            type: "warning",
425
+          }).then(() => {
426
+
390 427
 
391
-          that.$message.error(response.data.data.msg);
428
+          })
429
+            .catch(() => {});
392 430
           return false
393 431
         } else {
394
-          this.isloading = false
395
-          if(response.data.data.failed_code == -10){
396
-            that.$confirm(response.data.data.msg, '医保错误信息', {
397
-              confirmButtonText: '确 定',
398
-              type: 'warning'
399
-            }).then(() => {
400
-
401
-            }).catch(() => {
402
-            })
403
-          }else{
404
-            that.GetDrugStock()
405
-
432
+          that.isloading = true
433
+          //有打开则调用接口
434
+          axios.get('http://127.0.0.1:9532/api/pc_bg',{params:params}).then(function(response) {
435
+            if (response.data.state == 0) {
436
+              that.isloading = false
437
+              that.$message.error(response.data.data.msg);
438
+              return false
439
+            } else {
440
+              that.isloading = false
441
+              if(response.data.data.failed_code == -10){
442
+                that.$confirm(response.data.data.msg, '医保错误信息', {
443
+                  confirmButtonText: '确 定',
444
+                  type: 'warning'
445
+                }).then(() => {
446
+
447
+                }).catch(() => {
448
+                })
449
+              }else{
450
+                that.GetDrugStock()
451
+              }
452
+            }
453
+          }).catch(function(error) {
454
+          })
406 455
 
407
-          }
408 456
         }
409 457
       }).catch(function(error) {
458
+        that.$confirm("请检查医保程序是否有打开", "提示", {
459
+          confirmButtonText: "确 定",
460
+          cancelButtonText: "取 消",
461
+          type: "warning",
462
+        }).then(() => {
463
+        })
464
+          .catch(() => {});
410 465
       })
466
+
411 467
     },
412 468
     query(){
413 469
       this.GetDrugStock()
414 470
 
415
-
416 471
     },
417 472
     change(){
418 473
 
@@ -461,6 +516,7 @@ export default {
461 516
             let obj = {
462 517
               id:response.data.data.info[i].id,
463 518
               drug_name:response.data.data.info[i].drug.drug_name,
519
+              drug_code:response.data.data.info[i].drug_code,
464 520
               drug_type:this.getDrugType(response.data.data.info[i].drug.drug_type),
465 521
               spec: response.data.data.info[i].drug.dose + response.data.data.info[i].drug.dose_unit + "*" + response.data.data.info[i].drug.min_number + response.data.data.info[i].drug.min_unit+"/" +response.data.data.info[i].drug.max_unit,
466 522
               code:response.data.data.info[i].drug.medical_insurance_number,