陈少旭 před 1 rokem
rodič
revize
935655e752

+ 1 - 1
src/xt_pages/outpatientCharges/summary.vue Zobrazit soubor

@@ -1334,7 +1334,7 @@ export default {
1334 1334
                 name: order.patient.name,
1335 1335
                 id_card_no: order.patient.id_card_no,
1336 1336
                 year: "2023",
1337
-                month: "09",
1337
+                month: order.setl_time.split(" ")[0].split("-")[1],
1338 1338
                 code: data[b].code,
1339 1339
                 pric: data[b].total ,
1340 1340
                 item_name: data[b].name,

+ 52 - 2
src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue Zobrazit soubor

@@ -2641,6 +2641,9 @@ export default {
2641 2641
 
2642 2642
                       }
2643 2643
                     }
2644
+
2645
+
2646
+
2644 2647
                     console.log("newArr",newArr )
2645 2648
                   }
2646 2649
                 }
@@ -2994,6 +2997,8 @@ export default {
2994 2997
 
2995 2998
       if(this.org_id != 10206 && this.org_id != 0) {
2996 2999
         obj.med_type = 14
3000
+      }else{
3001
+        obj.med_type = 12
2997 3002
       }
2998 3003
 
2999 3004
       this.prescriptions.push(obj)
@@ -3251,11 +3256,32 @@ export default {
3251 3256
         return
3252 3257
        }
3253 3258
       }
3259
+
3260
+      if(this.org_id == 10206){
3261
+        if (row.zuobiao_stock_num <= 0) {
3262
+          if (selection) {
3263
+            selection.forEach(row => {
3264
+              if (row.zuobiao_stock_num <= 0) {
3265
+                this.$refs.multipleTable.toggleRowSelection(row)
3266
+              }
3267
+            })
3268
+          } else {
3269
+            this.$refs.multipleTable.clearSelection()
3270
+          }
3271
+          this.$message.error(row.drug_name + '库存不足')
3272
+          return
3273
+        }
3274
+      }
3275
+
3276
+
3277
+
3278
+
3254 3279
       this.curDrugs = selection
3255 3280
     },
3256 3281
 
3257 3282
     comfirm() {
3258 3283
 
3284
+
3259 3285
       if (this.curDrugs.length > 0) {
3260 3286
         for (let i = 0; i < this.curDrugs.length; i++) {
3261 3287
           if(this.org_id != 10206 && this.org_id != 0) {
@@ -3560,6 +3586,22 @@ export default {
3560 3586
             return
3561 3587
         }
3562 3588
        }
3589
+
3590
+      if ( this.org_id == 10206) {
3591
+        if (row.type == 3) {
3592
+          if (selection) {
3593
+            selection.forEach(row => {
3594
+              if (row.zuobiao_stock_num <= 0) {
3595
+                this.$refs.tables.toggleRowSelection(row)
3596
+              }
3597
+            })
3598
+          } else {
3599
+            this.$refs.tables.clearSelection()
3600
+          }
3601
+          this.$message.error(row.project_name + '库存不足')
3602
+          return
3603
+        }
3604
+      }
3563 3605
       this.teamList = selection
3564 3606
     },
3565 3607
     getlist() {
@@ -3729,12 +3771,20 @@ export default {
3729 3771
                 }
3730 3772
 
3731 3773
                 teamList.push(obj)
3732
-              } else if (project[i].type == 3 && project[i].status == 1 && this.org_id != 10206 && this.org_id != 0) {
3733
-                if (project[i].good_info.sum_count <= 0) {
3774
+              } else if (project[i].type == 3 && project[i].status == 1 ) {
3775
+
3776
+                if (project[i].good_info.sum_count <= 0 && this.org_id != 10206) {
3734 3777
                   num++
3735 3778
                   this.$refs.tabProjectTeam.toggleRowSelection(row)
3736 3779
                   this.$message.error(project[i].good_info.good_name + '库存不足')
3737 3780
                 }
3781
+
3782
+                if (project[i].good_info.zuobiao_stock_num <= 0 && this.org_id == 10206) {
3783
+                  num++
3784
+                  this.$refs.tabProjectTeam.toggleRowSelection(row)
3785
+                  this.$message.error(project[i].good_info.good_name + '库存不足')
3786
+                }
3787
+
3738 3788
                 if (num > 0) {
3739 3789
                   this.$refs.tabProjectTeam.clearSelection()
3740 3790
                 }

+ 72 - 67
src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue Zobrazit soubor

@@ -468,36 +468,38 @@
468 468
         //   this.$message.error('该处方已经结算或记账,无法删除')
469 469
         //
470 470
         // }
471
-        if (scope.row.drug.min_unit == scope.row.single_dose_unit) {
472
-          if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
473
-            console.log(1)
474
-            scope.row.prescribing_number = scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)
475
-          } else {
476
-            console.log(12)
477
-            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1)) * (scope.row.day ? scope.row.day : 1) / scope.row.drug.min_number)
478
-          }
479
-        } else {
480
-          if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
481
-            console.log(123)
482
-            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose)
471
+        if(this.$store.getters.xt_user.org_id != 10206) {
472
+          if (scope.row.drug.min_unit == scope.row.single_dose_unit) {
473
+            if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
474
+              console.log(1)
475
+              scope.row.prescribing_number = scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)
476
+            } else {
477
+              console.log(12)
478
+              scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1)) * (scope.row.day ? scope.row.day : 1) / scope.row.drug.min_number)
479
+            }
483 480
           } else {
484
-            console.log(1234)
485
-            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose / scope.row.drug.min_number)
481
+            if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
482
+              console.log(123)
483
+              scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose)
484
+            } else {
485
+              console.log(1234)
486
+              scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose / scope.row.drug.min_number)
487
+            }
486 488
           }
487
-        }
488
-        if (scope.row.prescribing_number == 0) {
489
-          scope.row.prescribing_number = 1
490
-        }
491
-        if (scope.row.prescribing_number_unit == scope.row.drug.min_unit && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
492
-          // scope.row.retail_price = scope.row.drug.min_number / scope.row.retail_price
493
-          if (scope.row.prescribing_number > scope.row.drug.sum_count) {
494
-            this.$message.error(scope.row.drug_name + '库存不足')
489
+          if (scope.row.prescribing_number == 0) {
490
+            scope.row.prescribing_number = 1
495 491
           }
496
-        } else {
497
-          if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count) {
498
-            this.$message.error(scope.row.drug_name + '库存不足')
492
+          if (scope.row.prescribing_number_unit == scope.row.drug.min_unit && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
493
+            // scope.row.retail_price = scope.row.drug.min_number / scope.row.retail_price
494
+            if (scope.row.prescribing_number > scope.row.drug.sum_count) {
495
+              this.$message.error(scope.row.drug_name + '库存不足')
496
+            }
497
+          } else {
498
+            if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count) {
499
+              this.$message.error(scope.row.drug_name + '库存不足')
500
+            }
501
+            // scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
499 502
           }
500
-          // scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
501 503
         }
502 504
 
503 505
       },
@@ -506,42 +508,44 @@
506 508
           this.$message.error('该处方包含已发药的药品,无法修改')
507 509
           return
508 510
         }
509
-        if (scope.row.drug.min_unit == scope.row.single_dose_unit) {
510
-          if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
511
-            console.log(1)
512
-            scope.row.prescribing_number = scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)
511
+        if(this.$store.getters.xt_user.org_id != 10206) {
512
+          if (scope.row.drug.min_unit == scope.row.single_dose_unit) {
513
+            if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
514
+              console.log(1)
515
+              scope.row.prescribing_number = scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)
516
+            } else {
517
+              console.log(12)
518
+              scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1)) * (scope.row.day ? scope.row.day : 1) / scope.row.drug.min_number)
519
+            }
513 520
           } else {
514
-            console.log(12)
515
-            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1)) * (scope.row.day ? scope.row.day : 1) / scope.row.drug.min_number)
521
+            if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
522
+              console.log(123)
523
+              scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose)
524
+            } else {
525
+              console.log(1234)
526
+              scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose / scope.row.drug.min_number)
527
+            }
528
+          }
529
+          if (scope.row.prescribing_number == 0) {
530
+            scope.row.prescribing_number = 1
516 531
           }
517
-        } else {
518 532
           if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
519
-            console.log(123)
520
-            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose)
533
+            // scope.row.retail_price = scope.row.drug.min_number / scope.row.retail_price
534
+            if (scope.row.drug.is_user != 1) {
535
+              if (scope.row.prescribing_number > scope.row.drug.sum_count && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
536
+                this.$message.error(scope.row.drug_name + '库存不足')
537
+              }
538
+            }
539
+
521 540
           } else {
522
-            console.log(1234)
523
-            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * (scope.row.execution_frequency ? this.getNum(scope.row.execution_frequency) : 1) * (scope.row.day ? scope.row.day : 1)) / scope.row.drug.dose / scope.row.drug.min_number)
524
-          }
525
-        }
526
-        if (scope.row.prescribing_number == 0) {
527
-          scope.row.prescribing_number = 1
528
-        }
529
-        if (scope.row.prescribing_number_unit == scope.row.drug.min_unit) {
530
-          // scope.row.retail_price = scope.row.drug.min_number / scope.row.retail_price
531
-          if(scope.row.drug.is_user!=1){
532
-           if (scope.row.prescribing_number > scope.row.drug.sum_count  && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
533
-            this.$message.error(scope.row.drug_name + '库存不足')
534
-           }
535
-          }
541
+            if (scope.row.drug.is_user != 1) {
542
+              if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
543
+                this.$message.error(scope.row.drug_name + '库存不足')
544
+              }
545
+            }
536 546
 
537
-        } else {
538
-          if(scope.row.drug.is_user!=1){
539
-           if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count  && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
540
-            this.$message.error(scope.row.drug_name + '库存不足')
541
-           }
547
+            // scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
542 548
           }
543
-
544
-          // scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
545 549
         }
546 550
 
547 551
       },
@@ -633,22 +637,23 @@
633 637
         //     this.$message.error(scope.row.drug_name + '库存不足')
634 638
         //    }
635 639
         // }
640
+        if(this.$store.getters.xt_user.org_id != 10206) {
636 641
 
637
-
638
-        if (scope.row.prescribing_number_unit == scope.row.drug.min_unit  && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
639
-          if(scope.row.drug.is_user!=1){
640
-            if (parseInt(scope.row.prescribing_number) > scope.row.drug.sum_count) {
641
-              this.$message.error(scope.row.drug_name + '库存不足')
642
+          if (scope.row.prescribing_number_unit == scope.row.drug.min_unit && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
643
+            if (scope.row.drug.is_user != 1) {
644
+              if (parseInt(scope.row.prescribing_number) > scope.row.drug.sum_count) {
645
+                this.$message.error(scope.row.drug_name + '库存不足')
646
+              }
642 647
             }
643
-          }
644 648
 
645
-        } else {
646
-          if(scope.row.drug.is_user!=1  && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0){
647
-            if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count) {
648
-              this.$message.error(scope.row.drug_name + '库存不足')
649
+          } else {
650
+            if (scope.row.drug.is_user != 1 && this.$store.getters.xt_user.org_id != 10206 && this.$store.getters.xt_user.org_id != 0) {
651
+              if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count) {
652
+                this.$message.error(scope.row.drug_name + '库存不足')
653
+              }
649 654
             }
650
-          }
651 655
 
656
+          }
652 657
         }
653 658
       },
654 659
       getProjectSingleDose(scope) {

+ 14 - 14
src/xt_pages/outpatientDoctorStation/doctorDesk.vue Zobrazit soubor

@@ -1498,7 +1498,7 @@ export default {
1498 1498
           this.additions = response.data.data.additions
1499 1499
 
1500 1500
           //针对普爱医院获取药品和耗材相关库存数据
1501
-          if(this.org_id == 10206 || this.org_id == 0){
1501
+          if(this.org_id == 10206){
1502 1502
             var that = this
1503 1503
             axios.get("http://127.0.0.1:9532" + '/nmg/coordinate/querystock', {
1504 1504
 
@@ -2052,7 +2052,7 @@ export default {
2052 2052
                   med_type: '',
2053 2053
                   is_medicine_status:false,
2054 2054
                 }
2055
-                if(this.org_id != 10206 || this.org_id != 0) {
2055
+                if(this.org_id != 10206) {
2056 2056
                   if (prescription.med_type == 0 || prescription.med_type == '') {
2057 2057
 
2058 2058
                     obj.med_type = ''
@@ -2062,7 +2062,7 @@ export default {
2062 2062
                     obj.med_type = parseInt(prescription.med_type)
2063 2063
                   }
2064 2064
                   if (obj.med_type == 0 || obj.med_type == '') {
2065
-                    if (this.org_id != 10206 || this.org_id != 0) {
2065
+                    if (this.org_id != 10206 ) {
2066 2066
                       obj.med_type = 14
2067 2067
                     } else {
2068 2068
 
@@ -2085,7 +2085,7 @@ export default {
2085 2085
                 med_type: '',
2086 2086
                 is_medicine_status:false,
2087 2087
               }
2088
-              if(this.org_id != 10206 || this.org_id != 0){
2088
+              if(this.org_id != 10206 ){
2089 2089
                 obj.med_type = 14
2090 2090
               }
2091 2091
               this.prescriptions.push(obj)
@@ -2544,7 +2544,7 @@ export default {
2544 2544
                         med_type: ''
2545 2545
 
2546 2546
                       }
2547
-                      if(this.org_id != 10206 || this.org_id != 0) {
2547
+                      if(this.org_id != 10206) {
2548 2548
                         if (prescription.med_type == 0 || prescription.med_type == '') {
2549 2549
 
2550 2550
                           obj.med_type = ''
@@ -2575,7 +2575,7 @@ export default {
2575 2575
 
2576 2576
                     }
2577 2577
 
2578
-                    if (this.org_id != 10206 || this.org_id != 0) {
2578
+                    if (this.org_id != 10206 ) {
2579 2579
                       obj.med_type = 14
2580 2580
                     }
2581 2581
 
@@ -3077,7 +3077,7 @@ export default {
3077 3077
                         med_type: ''
3078 3078
 
3079 3079
                       }
3080
-                      if(this.org_id != 10206 || this.org_id != 0) {
3080
+                      if(this.org_id != 10206 ) {
3081 3081
                         if (prescription.med_type == 0 || prescription.med_type == '') {
3082 3082
 
3083 3083
                           obj.med_type = ''
@@ -3105,7 +3105,7 @@ export default {
3105 3105
                       med_type: ''
3106 3106
 
3107 3107
                     }
3108
-                    if(this.org_id != 10206 || this.org_id != 0) {
3108
+                    if(this.org_id != 10206 ) {
3109 3109
                       obj.med_type = 14
3110 3110
                     }
3111 3111
 
@@ -3596,7 +3596,7 @@ export default {
3596 3596
                       med_type: ''
3597 3597
 
3598 3598
                     }
3599
-                    if(this.org_id != 10206 || this.org_id != 0) {
3599
+                    if(this.org_id != 10206 ) {
3600 3600
                       if (prescription.med_type == 0 || prescription.med_type == '') {
3601 3601
 
3602 3602
                         obj.med_type = ''
@@ -3626,7 +3626,7 @@ export default {
3626 3626
 
3627 3627
                   }
3628 3628
 
3629
-                  if(this.org_id != 10206 || this.org_id != 0) {
3629
+                  if(this.org_id != 10206 ) {
3630 3630
                     obj.med_type = 14
3631 3631
                   }
3632 3632
 
@@ -4235,7 +4235,7 @@ export default {
4235 4235
                         med_type: ''
4236 4236
 
4237 4237
                       }
4238
-                      if(this.org_id != 10206 || this.org_id != 0) {
4238
+                      if(this.org_id != 10206 ) {
4239 4239
                         if (prescription.med_type == 0 || prescription.med_type == '') {
4240 4240
 
4241 4241
                           obj.med_type = ''
@@ -4265,7 +4265,7 @@ export default {
4265 4265
                       med_type: ''
4266 4266
 
4267 4267
                     }
4268
-                    if(this.org_id != 10206 || this.org_id != 0 ) {
4268
+                    if(this.org_id != 10206  ) {
4269 4269
                       obj.med_type = 14
4270 4270
                     }
4271 4271
 
@@ -4892,7 +4892,7 @@ export default {
4892 4892
                         med_type: ''
4893 4893
 
4894 4894
                       }
4895
-                      if(this.org_id != 10206 || this.org_id != 0) {
4895
+                      if(this.org_id != 10206 ) {
4896 4896
                         if (prescription.med_type == 0 || prescription.med_type == '') {
4897 4897
 
4898 4898
                           obj.med_type = ''
@@ -4921,7 +4921,7 @@ export default {
4921 4921
                       med_type: ''
4922 4922
 
4923 4923
                     }
4924
-                    if(this.org_id != 10206 || this.org_id != 0) {
4924
+                    if(this.org_id != 10206 ) {
4925 4925
 
4926 4926
                       obj.med_type = 14
4927 4927
                     }