XMLWAN 3 anni fa
parent
commit
0f48884dec

+ 9 - 6
src/xt_pages/outpatientTool/components/drugDetail.vue Vedi File

159
     },
159
     },
160
     methods:{
160
     methods:{
161
       changeDate(){
161
       changeDate(){
162
+        this.tableData = []
162
         this.getlist()
163
         this.getlist()
163
        },
164
        },
164
        getlist(){
165
        getlist(){
183
                
184
                
184
               for(let j=0;j<drug.length;j++){
185
               for(let j=0;j<drug.length;j++){
185
                 if(list[i].drug_id == drug[j].id){
186
                 if(list[i].drug_id == drug[j].id){
186
-                  for(let z=0;z<list[i].child.length;z++){
187
-                    if(list[i].child[z].prescribing_number_unit == drug[j].max_unit){
188
-                       list[i].child[z].prescribing_number = parseInt(list[i].child[z].prescribing_number) * drug[j].min_number
187
+                  if(list[i].child!=null && list[i].child.length > 0){
188
+                    for(let z=0;z<list[i].child.length;z++){
189
+                      if(list[i].child[z].prescribing_number_unit == drug[j].max_unit){
190
+                        list[i].child[z].prescribing_number = parseInt(list[i].child[z].prescribing_number) * drug[j].min_number
191
+                      }
189
                     }
192
                     }
190
                   }
193
                   }
191
                 }
194
                 }
207
                }
210
                }
208
              }
211
              }
209
             }
212
             }
210
-            console.log("tabl2323323232",this.tableData)
211
           }
213
           }
212
         })  
214
         })  
213
       },
215
       },
240
        return specification_name    
242
        return specification_name    
241
      },
243
      },
242
      searchAction(){
244
      searchAction(){
245
+       this.tableData = []
243
        this.getlist()  
246
        this.getlist()  
244
      },
247
      },
245
      getDrugTypeName(drug_id){
248
      getDrugTypeName(drug_id){
259
        return type_name
262
        return type_name
260
      },
263
      },
261
      getCount(val,min_number,max_unit,min_unit){
264
      getCount(val,min_number,max_unit,min_unit){
262
-   
265
+      
263
        var total = 0
266
        var total = 0
264
        var min_str = ""
267
        var min_str = ""
265
        var max_str = ""
268
        var max_str = ""
266
-       if(val.length > 0){
269
+       if(val!=null && val!=undefined  && val.length > 0){
267
          for(let i=0;i<val.length;i++){
270
          for(let i=0;i<val.length;i++){
268
            total += parseInt(val[i].prescribing_number)
271
            total += parseInt(val[i].prescribing_number)
269
          }
272
          }

+ 4 - 2
src/xt_pages/outpatientTool/components/goodDetail.vue Vedi File

154
     },
154
     },
155
     methods:{
155
     methods:{
156
      changeDate(){
156
      changeDate(){
157
-         
157
+      this.tableData = []
158
+      this.getlist()
158
      },
159
      },
159
      getlist(){
160
      getlist(){
160
        let start_time = this.chargeDate[0]
161
        let start_time = this.chargeDate[0]
245
       getCount(val){
246
       getCount(val){
246
         var total = 0
247
         var total = 0
247
         for(let i=0;i<val.length;i++){
248
         for(let i=0;i<val.length;i++){
248
-           total +=val[i].count
249
+           total += parseInt(val[i].count)
249
         }
250
         }
250
         return total
251
         return total
251
       },
252
       },
259
         return packing_unit
260
         return packing_unit
260
       },
261
       },
261
       searchAction(){
262
       searchAction(){
263
+        this.tableData = []
262
         this.getlist()
264
         this.getlist()
263
       }
265
       }
264
     },
266
     },

+ 28 - 64
src/xt_pages/stock/drugs/components/drugCancelDetail.vue Vedi File

23
       >汇总导出
23
       >汇总导出
24
     </el-button>
24
     </el-button>
25
     <div class="cell clearfix">
25
     <div class="cell clearfix">
26
-     <label class="title"><span class="name">仓库</span> :</label>
27
-      <el-select size="small" v-model="storehouse_id" filterable placeholder="请选择仓库" style="width:200px" @change="changeHouseList">
28
-          <el-option
29
-            v-for="(option, index) in houseList"
30
-            :key="index"
31
-            :label="option.storehouse_name"
32
-            :value="option.id">
33
-          </el-option>
34
-      </el-select>  
35
       <el-input
26
       <el-input
36
         size="small"
27
         size="small"
37
-        style="width: 200px;"
28
+        style="width: 400px;"
38
         class="filter-item"
29
         class="filter-item"
39
         v-model.trim="searchKey"
30
         v-model.trim="searchKey"
40
         placeholder="单据编码/制单人/药品名称"
31
         placeholder="单据编码/制单人/药品名称"
47
         @click="search"
38
         @click="search"
48
         >搜索</el-button
39
         >搜索</el-button
49
       >
40
       >
50
-    
41
+      <div style="margin-left:10px;">
51
         <label class="title"><span class="name">日期查询</span> : </label>
42
         <label class="title"><span class="name">日期查询</span> : </label>
52
         <el-date-picker
43
         <el-date-picker
53
           size="small"
44
           size="small"
76
           value-format="yyyy-MM-dd"
67
           value-format="yyyy-MM-dd"
77
           @change="endTimeChange"
68
           @change="endTimeChange"
78
         ></el-date-picker>
69
         ></el-date-picker>
79
-     
70
+      </div>
80
     </div>
71
     </div>
81
 
72
 
82
     <el-row :gutter="12" style="margin-top: 10px">
73
     <el-row :gutter="12" style="margin-top: 10px">
137
           {{getAdminUser(scope.row.creater)}}
128
           {{getAdminUser(scope.row.creater)}}
138
           </template>
129
           </template>
139
         </el-table-column>
130
         </el-table-column>
140
-       <el-table-column label="仓库名称" align="center">
141
-          <template slot-scope="scope">
142
-          {{getStorehouseName(scope.row.storehouse_id)}}
143
-          </template>
144
-        </el-table-column>
145
         <el-table-column label="退货价" align="center">
131
         <el-table-column label="退货价" align="center">
146
           <template slot-scope="scope">
132
           <template slot-scope="scope">
147
           {{scope.row.price}}
133
           {{scope.row.price}}
249
       tableList:[],
235
       tableList:[],
250
       tableDataList:[],
236
       tableDataList:[],
251
       drugTypeList:[],
237
       drugTypeList:[],
252
-      storehouse_id:0,
253
-      houseList:[],
254
     };
238
     };
255
   },
239
   },
256
   methods: {
240
   methods: {
288
    
272
    
289
     fetchAllAdminUsers() {
273
     fetchAllAdminUsers() {
290
       fetchAllAdminUsers().then(response => {
274
       fetchAllAdminUsers().then(response => {
291
-     
275
+        console.log(response);
292
         if (response.data.state == 1) {
276
         if (response.data.state == 1) {
293
           this.adminUserOptions = response.data.data.users;
277
           this.adminUserOptions = response.data.data.users;
294
         }
278
         }
359
         keyword:this.searchKey,
343
         keyword:this.searchKey,
360
         limit:this.limit,
344
         limit:this.limit,
361
         page:this.page,
345
         page:this.page,
362
-        storehouse_id:this.storehouse_id,
363
        }
346
        }
364
       getDrugCancelDetail(params).then(response=>{
347
       getDrugCancelDetail(params).then(response=>{
365
          if(response.data.state == 1){
348
          if(response.data.state == 1){
366
            var order =  response.data.data.order
349
            var order =  response.data.data.order
367
            var list = response.data.data.orderPrint
350
            var list = response.data.data.orderPrint
368
-           var obj = {id:0,storehouse_name:"全部"}
369
-            this.houseList = []
370
-            this.houseList.push(obj)
371
-            for(let i=0;i<response.data.data.houseList.length;i++){
372
-            this.houseList.push(response.data.data.houseList[i])
373
-            }
351
+           //this.drugTypeList = response.data.data.drugTypeList
374
            for(let i=0;i<list.length;i++){
352
            for(let i=0;i<list.length;i++){
375
              list[i].child = []
353
              list[i].child = []
376
             for(let j=0;j<order.length;j++){
354
             for(let j=0;j<order.length;j++){
391
             order_number: "合计",
369
             order_number: "合计",
392
             is_total: 1,
370
             is_total: 1,
393
             specification_name:"",
371
             specification_name:"",
372
+            unit:"",
394
             ctime:"",
373
             ctime:"",
395
             total_price:total_price.toFixed(2),
374
             total_price:total_price.toFixed(2),
396
           });
375
           });
430
         //  if(this.tableDataList[i].drug_type == 3){
409
         //  if(this.tableDataList[i].drug_type == 3){
431
         //     this.tableDataList[i].drug_type == "成药"
410
         //     this.tableDataList[i].drug_type == "成药"
432
         //   }
411
         //   }
433
-          this.tableList[i].drug_type = this.getTypeList(scope.row.drug_type)
412
+          this.tableDataList[i].drug_type = this.getTypeList(this.tableDataList[i].drug_type)
434
           this.tableDataList[i].index = i+1
413
           this.tableDataList[i].index = i+1
435
           this.tableDataList[i].unit = this.tableDataList[i].dose + this.tableDataList[i].dose_unit + "*"+this.tableDataList[i].min_number + this.tableDataList[i].min_unit+"/"+this.tableDataList[i].max_unit
414
           this.tableDataList[i].unit = this.tableDataList[i].dose + this.tableDataList[i].dose_unit + "*"+this.tableDataList[i].min_number + this.tableDataList[i].min_unit+"/"+this.tableDataList[i].max_unit
436
           this.tableDataList[i].user_name = this.getAdminUser(this.tableDataList[i].creater)
415
           this.tableDataList[i].user_name = this.getAdminUser(this.tableDataList[i].creater)
440
         }
419
         }
441
        import('@/vendor/Export2Excel').then(excel => {
420
        import('@/vendor/Export2Excel').then(excel => {
442
         const tHeader = ['序号','单据编号', '药品名称', '规格型号','单据类型','操作时间','制单人','数量','退库价','总价']
421
         const tHeader = ['序号','单据编号', '药品名称', '规格型号','单据类型','操作时间','制单人','数量','退库价','总价']
443
-        const filterVal = ['index','order_number','drug_name', 'unit', 'drug_type','ctime','user_name','total_count','price','total_price']
422
+        const filterVal = ['index','order_number','drug_name', 'specification_name', 'drug_type','ctime','user_name','total_count','price','total_price']
444
         
423
         
445
         const data = this.formatJson(filterVal, this.tableDataList)
424
         const data = this.formatJson(filterVal, this.tableDataList)
446
 
425
 
456
         return jsonData.map(v => filterVal.map(j => v[j]));
435
         return jsonData.map(v => filterVal.map(j => v[j]));
457
      },
436
      },
458
     exportListOne(){
437
     exportListOne(){
459
-      let obj = {'index':'合计','total_price':0}
438
+      // let obj = {'index':'合计','total_price':0}
439
+      console.log("@332322323232332",this.tableList)
440
+      
460
        for(let i=0;i<this.tableList.length;i++){
441
        for(let i=0;i<this.tableList.length;i++){
461
           this.tableList[i].index = i+1
442
           this.tableList[i].index = i+1
462
           this.tableList[i].unit = this.tableList[i].dose + this.tableList[i].dose_unit + "*"+this.tableList[i].min_number + this.tableList[i].min_unit+"/"+this.tableList[i].max_unit
443
           this.tableList[i].unit = this.tableList[i].dose + this.tableList[i].dose_unit + "*"+this.tableList[i].min_number + this.tableList[i].min_unit+"/"+this.tableList[i].max_unit
463
-          if(this.tableData[i].drug_type == 1){
464
-             this.tableData[i].drugtype = "西药"
444
+          if(this.tableList[i].drug_type == 1){
445
+             this.tableList[i].drugtype = "西药"
465
           }
446
           }
466
-          if(this.tableData[i].drug_type == 2){
467
-             this.tableData[i].drugtype = "草药"
447
+          if(this.tableList[i].drug_type == 2){
448
+             this.tableList[i].drugtype = "草药"
468
           }
449
           }
469
-          if(this.tableData[i].drug_type == 3){
470
-             this.tableData[i].drugtype = "成药"
450
+          if(this.tableList[i].drug_type == 3){
451
+             this.tableList[i].drugtype = "成药"
471
           }
452
           }
472
-          this.tableData[i].time = this.getTime(this.tableData[i].ctime)
473
-          this.tableData[i].user_name = this.getAdminUser(this.tableData[i].creater)
453
+          this.tableList[i].time = this.getTime(this.tableList[i].ctime)
454
+          this.tableList[i].user_name = this.getAdminUser(this.tableList[i].creater)
474
           
455
           
475
-          this.tableData[i].total_price = this.tableData[i].count * this.tableData[i].price
476
-           obj.total_price += this.tabelePrintList[i].count * this.tabelePrintList[i].price
456
+          //this.tableList[i].total_price = this.tableList[i].count * this.tableList[i].price
457
+          //  obj.total_price += this.tableList[i].count * this.tableList[i].price
477
         }
458
         }
478
-        obj.total_price = obj.total_price.toFixed(2)
479
-       this.tableData.push(obj)
480
-       for(let i=0;i<this.tableData.length;i++){
481
-         this.tableData[i].total_price = this.tableData[i].total_price.toFixed(2)
482
-       }
459
+      //   obj.total_price = obj.total_price.toFixed(2)
460
+      //  this.tableList.push(obj)
461
+      //  for(let i=0;i<this.tableData.length;i++){
462
+      //    this.tableData[i].total_price = (this.tableData[i].total_price).toFixed(2)
463
+      //  }
483
        import('@/vendor/Export2Excel').then(excel => {
464
        import('@/vendor/Export2Excel').then(excel => {
484
        const tHeader = ['序号','单据编号', '药品类型','药品名称', '规格型号','操作时间','制单人','退货价','数量','总价']
465
        const tHeader = ['序号','单据编号', '药品类型','药品名称', '规格型号','操作时间','制单人','退货价','数量','总价']
485
-       const filterVal = ['index','order_number','drugtype','drug_name', 'unit', 'time','user_name','price','count','total_price']
466
+       const filterVal = ['index','order_number','drugtype','drug_name', 'specification_name', 'time','user_name','price','count','total_price']
486
        
467
        
487
        const data = this.formatJson(filterVal, this.tableList)
468
        const data = this.formatJson(filterVal, this.tableList)
488
        
469
        
511
         }
492
         }
512
       }
493
       }
513
       return name
494
       return name
514
-    },
515
-    getStorehouseName(id){
516
-       var storehouse_name = ""
517
-       for(let i=0;i<this.houseList.length;i++){
518
-         if(id == this.houseList[i].id){
519
-           storehouse_name = this.houseList[i].storehouse_name
520
-         }
521
-       }
522
-       if(storehouse_name == "全部"){
523
-          return ""
524
-       }else{
525
-         return storehouse_name
526
-       }
527
-     },
528
-     changeHouseList(){
529
-       this.houseList = []
530
-       this.getlist()
531
-     }  
495
+    } 
532
   }
496
   }
533
 };
497
 };
534
 </script>
498
 </script>

+ 6 - 6
src/xt_pages/workforce/remind_print_setting.vue Vedi File

36
                    <span>{{getAnticoagulant(main_collection.dialysissolution.mode_id)}}</span>
36
                    <span>{{getAnticoagulant(main_collection.dialysissolution.mode_id)}}</span>
37
                   </span>
37
                   </span>
38
                 </div>
38
                 </div>
39
-               <div v-if="org_id == 10188">首剂:{{main_collection.dialysissolution.anticoagulant_shouji}}</div>
40
-                <div v-if="org_id == 10188">维持:{{main_collection.dialysissolution.anticoagulant_weichi}}</div>
39
+               <div v-if="org_id == 10188 || org_id == 10217">首剂:{{main_collection.dialysissolution.anticoagulant_shouji}}</div>
40
+                <div v-if="org_id == 10188 || org_id == 10217">维持:{{main_collection.dialysissolution.anticoagulant_weichi}}</div>
41
                 <div v-if="printObj.anticoagulant_zongliang == 1">
41
                 <div v-if="printObj.anticoagulant_zongliang == 1">
42
                   用量:
42
                   用量:
43
                   <span v-if="main_collection.dialysissolution.anticoagulant == 1">
43
                   <span v-if="main_collection.dialysissolution.anticoagulant == 1">
74
                     {{main_collection.dialysissolution.anticoagulant_zongliang}}iu
74
                     {{main_collection.dialysissolution.anticoagulant_zongliang}}iu
75
                    </span>
75
                    </span>
76
                 </div>
76
                 </div>
77
-                <div v-if="org_id == 10188">干体重:{{main_collection.assessmentbefor.dry_weight}}</div>
78
-                <div v-if="org_id == 10188">透前体重:{{main_collection.assessmentbefor.weight_before}}</div>
79
-                <div v-if="org_id == 10188">体重增加:{{(main_collection.assessmentbefor.weight_before - main_collection.assessmentbefor.dry_weight).toFixed(2)}}</div>
77
+                <div v-if="org_id == 10188 || org_id == 10217">干体重:{{main_collection.assessmentbefor.dry_weight}}</div>
78
+                <div v-if="org_id == 10188 || org_id == 10217">透前体重:{{main_collection.assessmentbefor.weight_before}}</div>
79
+                <div v-if="org_id == 10188 || org_id == 10217">体重增加:{{(main_collection.assessmentbefor.weight_before - main_collection.assessmentbefor.dry_weight).toFixed(2)}}</div>
80
                 <div>用法:静脉注射</div>
80
                 <div>用法:静脉注射</div>
81
                 <div>打印时间:{{currentDate}}</div>
81
                 <div>打印时间:{{currentDate}}</div>
82
               </div>
82
               </div>
294
       printAction: function() {
294
       printAction: function() {
295
         const style = '@media print {.signPrint{margin-left:30px;} .print_main_content { background-color: white; width:960px;  margin:0 auto; padding: 0 0 20px 0; } .order_title_panl { text-align: center; } .main_title { font-size: 18px; line-height: 40px; font-weight: 500; } .table_panel { } .table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } thead tr td { border: 1px solid; text-align: center; font-size: 20px; padding: 15px 5px; } tbody tr td { border: 1px solid; text-align: center; font-size: 18px; padding: 10px 5px; } .proj { padding: 5px 0; text-align: left; } .proj_title { font-size: 16px; font-weight: 500; line-height: 25px; } .proj_item { font-size: 15px; line-height: 20px; } .zone_name { font-weight: 500; } .printCell span{display: inline-block;width: 180px;} @page {margin-top:10px;}}'
295
         const style = '@media print {.signPrint{margin-left:30px;} .print_main_content { background-color: white; width:960px;  margin:0 auto; padding: 0 0 20px 0; } .order_title_panl { text-align: center; } .main_title { font-size: 18px; line-height: 40px; font-weight: 500; } .table_panel { } .table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } thead tr td { border: 1px solid; text-align: center; font-size: 20px; padding: 15px 5px; } tbody tr td { border: 1px solid; text-align: center; font-size: 18px; padding: 10px 5px; } .proj { padding: 5px 0; text-align: left; } .proj_title { font-size: 16px; font-weight: 500; line-height: 25px; } .proj_item { font-size: 15px; line-height: 20px; } .zone_name { font-weight: 500; } .printCell span{display: inline-block;width: 180px;} @page {margin-top:10px;}}'
296
         const style1 = '@media print { .print_main_content { background-color: white; width:960px;  margin:0 auto; padding: 0 0 20px 0; } .order_title_panl { text-align: center; } .main_title { font-size: 18px; line-height: 40px; font-weight: 500; } .table_panel { } .table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } thead tr td { border: 1px solid; text-align: center; font-size: 20px; padding: 15px 5px; } tbody tr td { border: 1px solid; text-align: center; font-size: 18px; padding: 10px 5px; } .proj { padding: 5px 0; text-align: left; } .proj_title { font-size: 16px; font-weight: 500; line-height: 25px; } .proj_item { font-size: 15px; line-height: 20px; } .zone_name { font-weight: 500; } .printCell span{display: inline-block;width: 170px;} @page {margin-top:10px;}}'
296
         const style1 = '@media print { .print_main_content { background-color: white; width:960px;  margin:0 auto; padding: 0 0 20px 0; } .order_title_panl { text-align: center; } .main_title { font-size: 18px; line-height: 40px; font-weight: 500; } .table_panel { } .table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } thead tr td { border: 1px solid; text-align: center; font-size: 20px; padding: 15px 5px; } tbody tr td { border: 1px solid; text-align: center; font-size: 18px; padding: 10px 5px; } .proj { padding: 5px 0; text-align: left; } .proj_title { font-size: 16px; font-weight: 500; line-height: 25px; } .proj_item { font-size: 15px; line-height: 20px; } .zone_name { font-weight: 500; } .printCell span{display: inline-block;width: 170px;} @page {margin-top:10px;}}'
297
-        if(this.org_id == 10188){
297
+        if(this.org_id == 10188 || this.org_id == 10217){
298
           printJS({
298
           printJS({
299
             printable: 'print_content',
299
             printable: 'print_content',
300
             type: 'html',
300
             type: 'html',