mainqaq 2 年之前
父節點
當前提交
87b31f718c

+ 4 - 4
src/xt_pages/hospitalStation/components/prescriptionTable.vue 查看文件

@@ -471,14 +471,14 @@
471 471
               this.$message.error(scope.row.drug_name + '库存不足')
472 472
             }
473 473
           }
474
-         
474
+
475 475
         } else {
476 476
           if(scope.row.drug.is_user!=1){
477 477
             if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count) {
478 478
               this.$message.error(scope.row.drug_name + '库存不足')
479 479
             }
480 480
           }
481
-        
481
+
482 482
           // scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
483 483
         }
484 484
 
@@ -521,14 +521,14 @@
521 521
               this.$message.error(scope.row.drug_name + '库存不足')
522 522
            }
523 523
           }
524
-        
524
+
525 525
         } else {
526 526
           if(scope.row.drug.is_user!=1){
527 527
             if ((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.sum_count) {
528 528
               this.$message.error(scope.row.drug_name + '库存不足')
529 529
             }
530 530
           }
531
-         
531
+
532 532
         }
533 533
       },
534 534
       getProjectSingleDose(scope) {

+ 19 - 14
src/xt_pages/management/components/RepairForm.vue 查看文件

@@ -35,7 +35,7 @@
35 35
         ></el-date-picker>
36 36
       </el-col>
37 37
       <el-col :span="2">
38
-        <el-button @click="queryRepair()">查询</el-button>
38
+        <el-button style="background-color:#409eff;color: #DCDFE6" @click="queryRepair()">查询</el-button>
39 39
       </el-col>
40 40
     </el-row>
41 41
     <el-row style="display: flex;align-items: center;">
@@ -406,6 +406,7 @@
406 406
         </el-row>
407 407
       </el-form>
408 408
       <span slot="footer" class="dialog-footer">
409
+<!--        <button @click="lili">调试</button>-->
409 410
         <el-button @click="dialogVisible = false">取 消</el-button>
410 411
         <el-button type="primary" @click="UpdateRepair('guaForm')"
411 412
           >保存</el-button
@@ -482,10 +483,12 @@ export default {
482 483
       limit: 10,
483 484
       page: 1,
484 485
       total: 0,
485
-      filename: ""
486 486
     };
487 487
   },
488 488
   methods: {
489
+    lili(){
490
+      console.log("this.guaForm",this.guaForm)
491
+    },
489 492
     changeCheck() {
490 493
       this.$refs.multipleTable.clearSelection();
491 494
       if (this.checkAllStatus) {
@@ -655,19 +658,21 @@ export default {
655 658
       window.location.href = this.guaForm.images;
656 659
     },
657 660
     UpdateRepair(formName) {
661
+      console.log("formName",formName)
662
+      console.log("this.guaForm",this.guaForm)
658 663
       this.$refs[formName].validate(valid => {
659
-        this.guaForm.start_time = uParseTime(
660
-          this.guaForm.start_time,
661
-          "{y}-{m}-{d} {h}:{i}"
662
-        );
663
-        this.guaForm.arrive_time = uParseTime(
664
-          this.guaForm.arrive_time,
665
-          "{y}-{m}-{d} {h}:{i}"
666
-        );
667
-        this.guaForm.finish_time = uParseTime(
668
-          this.guaForm.finish_time,
669
-          "{y}-{m}-{d} {h}:{i}"
670
-        );
664
+        // this.guaForm.start_time = uParseTime(
665
+        //   this.guaForm.start_time,
666
+        //   "{y}-{m}-{d} {h}:{i}"
667
+        // );
668
+        // this.guaForm.arrive_time = uParseTime(
669
+        //   this.guaForm.arrive_time,
670
+        //   "{y}-{m}-{d} {h}:{i}"
671
+        // );
672
+        // this.guaForm.finish_time = uParseTime(
673
+        //   this.guaForm.finish_time,
674
+        //   "{y}-{m}-{d} {h}:{i}"
675
+        // );
671 676
 
672 677
         if (this.guaForm.failure_stage === "") {
673 678
           this.guaForm.failure_stage = 0;

+ 25 - 7
src/xt_pages/outpatientDoctorStation/batch_delete.vue 查看文件

@@ -34,6 +34,7 @@
34 34
           <div v-if="new_type == 1">
35 35
             请输入需要删除的药品:
36 36
             <el-select
37
+              filterable
37 38
               v-model="id"
38 39
               placeholder="请选择"
39 40
               @change="getUsername"
@@ -50,6 +51,7 @@
50 51
           <div v-if="new_type == 2">
51 52
             请输入需要删除的项目:
52 53
             <el-select
54
+              filterable
53 55
               v-model="id"
54 56
               placeholder="请选择"
55 57
               @change="getUsername"
@@ -274,12 +276,12 @@ export default {
274 276
       tableDatas:[{
275 277
         id: "",
276 278
         drug_name: "",
277
-        single_dose: 0,
279
+        single_dose: "",
278 280
         single_dose_unit: "",
279 281
         delivery_way: "",
280 282
         execution_frequency: "",
281
-        day: 0,
282
-        prescribing_number: 0,
283
+        day: "",
284
+        prescribing_number: "",
283 285
         prescribing_number_unit: "",
284 286
         price: "",
285 287
         remark: "",
@@ -288,12 +290,12 @@ export default {
288 290
         id: "",
289 291
         drug_name: "",
290 292
         translate:"",
291
-        single_dose: 0,
293
+        single_dose: "",
292 294
         unit: "",
293 295
         delivery_way: "",
294 296
         execution_frequency: "",
295
-        day: 0,
296
-        prescribing_number: 0,
297
+        day: "",
298
+        prescribing_number: "",
297 299
         price: "",
298 300
         remark: "",
299 301
         frequency_type:1,
@@ -340,8 +342,24 @@ export default {
340 342
   },
341 343
   methods: {
342 344
     save() {
345
+      var tmp = this.modeOptions[this.modeOptions_value].name
346
+      var tmp2 = ""
347
+      if (this.druglist != null){
348
+        for(let i = 0;i < this.druglist.length;i++){
349
+          if (this.id == this.druglist[i].id){
350
+            tmp2 = this.druglist[i].name
351
+          }
352
+        }
353
+      }
354
+      if(this.projectlist != null){
355
+        for (let j = 0;j < this.projectlist.length;j++){
356
+          if (this.id == this.projectlist[j].id){
357
+            tmp2 = this.projectlist[j].name
358
+          }
359
+        }
360
+      }
343 361
       this.$confirm(
344
-        "注:该操作将会把选中的药品或项目从所选患者处方模板中移除,请确定是否删除?",
362
+        "注:该操作将会把所选患者的"+tmp+"透析模式中的"+tmp2+"进行删除,请确定是否删除?",
345 363
         "",
346 364
         {
347 365
           confirmButtonText: "确 定",

+ 84 - 33
src/xt_pages/outpatientDoctorStation/batch_mode_template.vue 查看文件

@@ -50,7 +50,7 @@
50 50
           </div>
51 51
         </div>
52 52
 
53
-<!--        <button @click="lili">调试</button>-->
53
+        <button @click="lili">调试</button>
54 54
         <el-button @click="save">保存</el-button>
55 55
       </div>
56 56
 
@@ -121,6 +121,7 @@
121 121
                 <el-table-column fixed label="新增药品名称" width="230">
122 122
                   <template slot-scope="scope">
123 123
                     <el-select
124
+                      filterable
124 125
                       v-model="scope.row.drug_name"
125 126
                       placeholder="请选择"
126 127
                       @focus="clicktmp(item.patient_value, scope.row)"
@@ -280,6 +281,7 @@
280 281
                 <el-table-column fixed label="新增项目名称" width="230">
281 282
                   <template slot-scope="scope">
282 283
                     <el-select
284
+                      filterable
283 285
                       v-model="scope.row.drug_name"
284 286
                       placeholder="请选择"
285 287
                       @focus="clicktmp(item.patient_value, scope.row)"
@@ -581,7 +583,7 @@
581 583
       </div>
582 584
 
583 585
       <span slot="footer" class="dialog-footer">
584
-        <button @click="lili">调试</button>
586
+<!--        <button @click="lili">调试</button>-->
585 587
     <el-button @click="dialogVisible = false">取 消</el-button>
586 588
     <el-button type="primary" @click="baocun">确 定</el-button>
587 589
   </span>
@@ -615,12 +617,12 @@ export default {
615 617
             {
616 618
               id: "",
617 619
               drug_name: "",
618
-              single_dose: 0,
620
+              single_dose: "",
619 621
               single_dose_unit: "",
620 622
               delivery_way: "",
621 623
               execution_frequency: "",
622
-              day: 0,
623
-              prescribing_number: 0,
624
+              day: "",
625
+              prescribing_number: "",
624 626
               prescribing_number_unit: "",
625 627
               price: "",
626 628
               remark: "",
@@ -631,12 +633,12 @@ export default {
631 633
               id: "",
632 634
               drug_name: "",
633 635
               translate:"",
634
-              single_dose: 0,
636
+              single_dose: "",
635 637
               unit: "",
636 638
               delivery_way: "",
637 639
               execution_frequency: "",
638
-              day: 0,
639
-              prescribing_number: 0,
640
+              day: "",
641
+              prescribing_number: "",
640 642
               price: "",
641 643
               remark: "",
642 644
               frequency_type:1,
@@ -685,8 +687,54 @@ export default {
685 687
   },
686 688
   methods: {
687 689
     save() {
690
+      var tmp = this.modeOptions[this.modeOptions_value].name
691
+      var tmp2 = ""
692
+      for(let i =0;i < this.editableTabs.length;i++){
693
+        console.log("for")
694
+          for (let j = 0;j < this.editableTabs[i].project.length;j++){
695
+            if (this.editableTabs[i].project[j].id != ""){
696
+              if (this.projectlist != null){
697
+                for(let p1 = 0;p1 < this.projectlist.length;p1++){
698
+                  if(this.editableTabs[i].project[j].id == this.projectlist[p1].id){
699
+                    tmp2 = tmp2 + this.projectlist[p1].name+","
700
+                  }
701
+                }
702
+              }
703
+              if(this.projectlist2 != null){
704
+                for(let p2 = 0;p2 < this.projectlist2.length;p2++){
705
+                  if(this.editableTabs[i].project[j].id == this.projectlist2[p2].id){
706
+                    tmp2 = tmp2 + this.projectlist2[p2].name+","
707
+                  }
708
+                }
709
+              }
710
+            }
711
+          }
712
+          for (let x = 0;x < this.editableTabs[i].tableDatas.length;x++){
713
+            if(this.editableTabs[i].tableDatas[x].id != ""){
714
+              if(this.druglist != null){
715
+                console.log("for"+i+"",this.editableTabs[i].tableDatas[x].id)
716
+                for(let d1 = 0;d1 < this.druglist.length;d1++){
717
+                  console.log("循环"+d1+"",this.druglist[d1].id)
718
+                  if(this.editableTabs[i].tableDatas[x].id == this.druglist[d1].id){
719
+                    tmp2 = tmp2 + this.druglist[d1].name+","
720
+                  }
721
+                }
722
+              }
723
+              if(this.druglist2 != null){
724
+                console.log("for"+i+"",this.editableTabs[i].tableDatas[x].id)
725
+                for(let d2 = 0;d2 < this.druglist2.length;d2++){
726
+                  console.log("循环"+d2+"",this.druglist2[d2].id)
727
+                  if(this.editableTabs[i].tableDatas[x].id == this.druglist2[d2].id){
728
+                    tmp2 = tmp2 + this.druglist2[d2].name+","
729
+                  }
730
+                }
731
+              }
732
+            }
733
+          }
734
+      }
735
+      console.log("tmp2",tmp2)
688 736
       this.$confirm(
689
-        "注:该操作将会把所选患者的XX透析模式中的新增XXX,请确定是否保存?",
737
+        "注:该操作将会把所选患者的"+tmp+"透析模式中的新增"+tmp2+",请确定是否保存?",
690 738
         "",
691 739
         {
692 740
           confirmButtonText: "确 定",
@@ -702,7 +750,6 @@ export default {
702 750
         for (let i = 0;i < this.multipleSelection.length;i++){
703 751
           st = st + this.multipleSelection[i].id + ","
704 752
         }
705
-        console.log("string",st)
706 753
         let params = {
707 754
           mode_id:this.modeOptions_value,
708 755
           patient_id: st,
@@ -723,8 +770,8 @@ export default {
723 770
 
724 771
     lili() {
725 772
       console.log("this.editableTabs",this.editableTabs);
726
-      // console.log("this.week_days",this.week_days)
727
-      // console.log("this.editableTabs",this.editableTabs)
773
+      // console.log("this.druglist2",this.druglist2)
774
+      // console.log("this.projectlist",this.projectlist)
728 775
       // console.log("this.projectlist2",this.projectlist2)
729 776
       // console.log("patient_value",this.patient_value)
730 777
     },
@@ -746,12 +793,12 @@ export default {
746 793
           {
747 794
             id: "",
748 795
             drug_name: "",
749
-            single_dose: 0,
796
+            single_dose: "",
750 797
             single_dose_unit: "",
751 798
             delivery_way: "",
752 799
             execution_frequency: "",
753
-            day: 0,
754
-            prescribing_number: 0,
800
+            day: "",
801
+            prescribing_number: "",
755 802
             prescribing_number_unit: "",
756 803
             price: "",
757 804
             remark: "",
@@ -762,12 +809,12 @@ export default {
762 809
             id: "",
763 810
             drug_name: "",
764 811
             translate:"",
765
-            single_dose: 0,
812
+            single_dose: "",
766 813
             unit: "",
767 814
             delivery_way: "",
768 815
             execution_frequency: "",
769
-            day: 0,
770
-            prescribing_number: 0,
816
+            day: "",
817
+            prescribing_number: "",
771 818
             price: "",
772 819
             remark: "",
773 820
             frequency_type:1,
@@ -793,7 +840,7 @@ export default {
793 840
       this.tabhang = tab.index
794 841
     },
795 842
     changeid(item,index){
796
-      console.log("this.tabhang",this.tabhang)
843
+      console.log("this.tabhang1",this.tabhang)
797 844
       console.log("this.hang",this.hang)
798 845
       this.hang = index
799 846
       item.id = item.drug_name
@@ -816,7 +863,7 @@ export default {
816 863
       })
817 864
     },
818 865
     changeid2(item,index){
819
-      console.log("this.tabhang",this.tabhang)
866
+      console.log("this.tabhang2",this.tabhang)
820 867
       console.log("this.hang???",this.hang)
821 868
       this.hang = index
822 869
       item.id = item.drug_name
@@ -879,12 +926,12 @@ export default {
879 926
       rows.splice(index+1,0,{
880 927
         id:"",
881 928
         drug_name: '',
882
-        single_dose:0,
929
+        single_dose:"",
883 930
         single_dose_unit: '',
884 931
         delivery_way: '',
885 932
         execution_frequency: '',
886
-        day: 0,
887
-        prescribing_number:0,
933
+        day: "",
934
+        prescribing_number:"",
888 935
         prescribing_number_unit:"",
889 936
         price:"",
890 937
         remark:"",
@@ -894,12 +941,12 @@ export default {
894 941
       rows.splice(index+1,0,{
895 942
         id: "",
896 943
         drug_name: "",
897
-        single_dose: 0,
944
+        single_dose: "",
898 945
         unit: "",
899 946
         delivery_way: "",
900 947
         execution_frequency: "",
901
-        day: 0,
902
-        prescribing_number: 0,
948
+        day: "",
949
+        prescribing_number: "",
903 950
         price: "",
904 951
         remark: "",
905 952
         frequency_type:"",
@@ -952,7 +999,11 @@ export default {
952 999
     },
953 1000
     handleTabsEdit(targetName, action,tab) {
954 1001
       this.tabhang = this.editableTabs.length
955
-      console.log("this.tabhang",this.tabhang)
1002
+      if(this.editableTabs.length == 1){
1003
+        this.$message.error("最后一条处方,不能删除")
1004
+        return
1005
+      }
1006
+      console.log("this.tabhang3",this.tabhang)
956 1007
       if (action === "add") {
957 1008
         let newTabName = ++this.tabIndex + "";
958 1009
         let tmp = this.editableTabs.length + 1;
@@ -964,12 +1015,12 @@ export default {
964 1015
             {
965 1016
               id: "",
966 1017
               drug_name: "",
967
-              single_dose: 0,
1018
+              single_dose: "",
968 1019
               single_dose_unit: "",
969 1020
               delivery_way: "",
970 1021
               execution_frequency: "",
971
-              day: 0,
972
-              prescribing_number: 0,
1022
+              day: "",
1023
+              prescribing_number: "",
973 1024
               prescribing_number_unit: "",
974 1025
               price: "",
975 1026
               remark: "",
@@ -979,12 +1030,12 @@ export default {
979 1030
             {
980 1031
               id: "",
981 1032
               drug_name: "",
982
-              single_dose: 0,
1033
+              single_dose: "",
983 1034
               unit: "",
984 1035
               delivery_way: "",
985 1036
               execution_frequency: "",
986
-              day: 0,
987
-              prescribing_number: 0,
1037
+              day: "",
1038
+              prescribing_number: "",
988 1039
               price: "",
989 1040
               remark: "",
990 1041
               frequency_type:"",

+ 81 - 20
src/xt_pages/outpatientDoctorStation/batch_replacement.vue 查看文件

@@ -34,6 +34,7 @@
34 34
           <div v-if="new_type == 1">
35 35
             请输入需要替换的药品:
36 36
             <el-select
37
+              filterable
37 38
               v-model="id"
38 39
               placeholder="请选择"
39 40
               @change="getUsername"
@@ -50,6 +51,7 @@
50 51
           <div v-if="new_type == 2">
51 52
             请输入需要替换的项目:
52 53
             <el-select
54
+              filterable
53 55
               v-model="id"
54 56
               placeholder="请选择"
55 57
               @change="getUsername"
@@ -65,7 +67,7 @@
65 67
           </div>
66 68
         </div>
67 69
 
68
-<!--        <button @click="lili">调试</button>-->
70
+        <button @click="lili">调试</button>
69 71
         <el-button @click="save">保存</el-button>
70 72
       </div>
71 73
 
@@ -106,6 +108,7 @@
106 108
           <el-table-column fixed label="替换药品名称" width="230">
107 109
             <template slot-scope="scope">
108 110
               <el-select
111
+                filterable
109 112
                 v-model="scope.row.drug_name"
110 113
                 placeholder="请选择"
111 114
                 @change="changeid(scope.row,scope.$index)"
@@ -240,6 +243,7 @@
240 243
           <el-table-column fixed label="替换项目名称" width="230">
241 244
             <template slot-scope="scope">
242 245
               <el-select
246
+                filterable
243 247
                 v-model="scope.row.drug_name"
244 248
                 placeholder="请选择"
245 249
                 @change="changeid2(scope.row,scope.$index)"
@@ -343,16 +347,16 @@
343 347
               <div v-if="scope.row.frequency_type == 3">{{scope.row.week_days}}</div>
344 348
             </template>
345 349
           </el-table-column>
346
-          <el-table-column fixed="right" label="操作" width="102">
347
-            <template slot-scope="scope">
348
-              <el-button
349
-                @click.native.prevent="addopen(scope.$index)"
350
-                type="text"
351
-                size="small">
352
-                推送
353
-              </el-button>
354
-            </template>
355
-          </el-table-column>
350
+<!--          <el-table-column fixed="right" label="操作" width="102">-->
351
+<!--            <template slot-scope="scope">-->
352
+<!--              <el-button-->
353
+<!--                @click.native.prevent="addopen(scope.$index)"-->
354
+<!--                type="text"-->
355
+<!--                size="small">-->
356
+<!--                推送-->
357
+<!--              </el-button>-->
358
+<!--            </template>-->
359
+<!--          </el-table-column>-->
356 360
         </el-table>
357 361
       </el-container>
358 362
     </div>
@@ -412,12 +416,12 @@ export default {
412 416
       tableDatas:[{
413 417
         id: "",
414 418
         drug_name: "",
415
-        single_dose: 0,
419
+        single_dose: "",
416 420
         single_dose_unit: "",
417 421
         delivery_way: "",
418 422
         execution_frequency: "",
419
-        day: 0,
420
-        prescribing_number: 0,
423
+        day: "",
424
+        prescribing_number: "",
421 425
         prescribing_number_unit: "",
422 426
         price: "",
423 427
         remark: "",
@@ -426,12 +430,12 @@ export default {
426 430
         id: "",
427 431
         drug_name: "",
428 432
         translate:"",
429
-        single_dose: 0,
433
+        single_dose: "",
430 434
         unit: "",
431 435
         delivery_way: "",
432 436
         execution_frequency: "",
433
-        day: 0,
434
-        prescribing_number: 0,
437
+        day: "",
438
+        prescribing_number: "",
435 439
         price: "",
436 440
         remark: "",
437 441
         frequency_type:1,
@@ -473,8 +477,64 @@ export default {
473 477
   },
474 478
   methods: {
475 479
     save() {
480
+      var tmp = this.modeOptions[this.modeOptions_value].name
481
+      var tmp2 = ""
482
+      var tmp3 = ""
483
+      if (this.new_type == 2){
484
+        if (this.projectlist != null){
485
+          for(let p1 = 0;p1 < this.projectlist.length;p1++){
486
+            if(this.id == this.projectlist[p1].id){
487
+              tmp2 =  this.projectlist[p1].name
488
+            }
489
+            if(this.project != null){
490
+              if(this.project[0].id == this.projectlist[p1].id){
491
+                tmp3 = this.projectlist[p1].name
492
+              }
493
+            }
494
+          }
495
+        }
496
+        if(this.projectlist2 != null){
497
+          for(let p2 = 0;p2 < this.projectlist2.length;p2++){
498
+            if(this.id == this.projectlist2[p2].id){
499
+              tmp2 = this.projectlist2[p2].name
500
+            }
501
+            if(this.project != null){
502
+              if(this.project[0].id == this.projectlist2[p2].id){
503
+                tmp3 = this.projectlist2[p2].name
504
+              }
505
+            }
506
+          }
507
+        }
508
+      }
509
+      if (this.new_type == 1){
510
+        if(this.druglist != null){
511
+          for(let d1 = 0;d1 < this.druglist.length;d1++){
512
+            if(this.id == this.druglist[d1].id){
513
+              tmp2 = this.druglist[d1].name
514
+            }
515
+            if(this.tableDatas != null){
516
+              if(this.tableDatas[0].id == this.druglist[d1].id){
517
+                tmp3 = this.druglist[d1].name
518
+              }
519
+            }
520
+          }
521
+        }
522
+        if(this.druglist2 != null){
523
+          for(let d2 = 0;d2 < this.druglist2.length;d2++){
524
+            if(this.id == this.druglist2[d2].id){
525
+              tmp2 = tmp2 + this.druglist2[d2].name
526
+            }
527
+            if(this.tableDatas != null){
528
+              if(this.tableDatas[0].id == this.druglist2[d2].id){
529
+                tmp3 = this.druglist2[d2].name
530
+              }
531
+            }
532
+          }
533
+        }
534
+      }
535
+
476 536
       this.$confirm(
477
-        "注:该操作将会把所选患者的XX透析模式中的新增XXX,请确定是否保存?",
537
+        "注:该操作将会把所选患者的"+tmp+"透析模式中的"+tmp2+"替换为"+tmp3+",请确定是否保存?",
478 538
         "",
479 539
         {
480 540
           confirmButtonText: "确 定",
@@ -530,8 +590,8 @@ export default {
530 590
     },
531 591
 
532 592
     lili() {
533
-      console.log("this.multipleSelection",this.multipleSelection);
534
-      console.log("this.tableData",this.tableData)
593
+      // console.log("this.multipleSelection",this.multipleSelection);
594
+      console.log("this.tableDatas",this.tableDatas)
535 595
       // console.log("this.mode",this.modeOptions_value)
536 596
       // console.log("this.projectlist2",this.projectlist2)
537 597
       // console.log("patient_value",this.patient_value)
@@ -550,6 +610,7 @@ export default {
550 610
       this.tableData = []
551 611
     },
552 612
     changeid(item,index){
613
+      console.log("")
553 614
       item.id = item.drug_name
554 615
       var params = {
555 616
         id:item.id