Browse Source

hah阿凡达

28169 3 weeks ago
parent
commit
3a47c2c421

+ 7 - 0
src/api/doctor.js View File

@@ -13,3 +13,10 @@ export function fetchAllAdminUsers() {
13 13
   })
14 14
 }
15 15
 
16
+
17
+export function fetchMoibleAllDoctorAndNurse(){
18
+  return request({
19
+    url:"/api/mobilealldoctors",
20
+    method:"Get",
21
+  })
22
+}

+ 2 - 4
src/xt_pages/stock/drugs/components/purchaseNewDrugQuery.vue View File

@@ -373,12 +373,10 @@ export default {
373 373
      if(totalthree == ""){
374 374
       totalthree =0
375 375
      }
376
-    //  console.log("totalone=========",totalone)
377
-    //  console.log("totalone=========",totaltwo)
378
-    //  console.log("totalone=========",totalthree)
376
+   
379 377
      var total = 0
380 378
       total = (parseFloat(totalone)  + parseFloat(totaltwo)  - parseFloat(totalthree))
381
-      console.log("total-=---------------",total)
379
+     
382 380
       if(total >0){
383 381
         return total.toFixed(2)
384 382
       }else{

+ 17 - 16
src/xt_pages/stock/drugs/components/purchaseNewDrugQueryPrint.vue View File

@@ -1622,23 +1622,24 @@ export default {
1622 1622
     
1623 1623
    },
1624 1624
    GetDrugOverOnePrice(totalone,totaltwo,totalthree,min_number,min_unit,max_unit){
1625
-      if(totalone == ""){
1626
-          totalone =0
1627
-      }
1628
-      if(totaltwo == ""){
1629
-        totaltwo =0
1630
-      }
1631
-      if(totalone == ""){
1632
-          totalone =0
1633
-      }
1634
-      if(totalthree == ""){
1635
-        totalthree =0
1636
-      }
1637 1625
      
1638
-      var total = 0
1639
-      total = totalone  + totaltwo  - totalthree
1640
-      if(total >0 || total!="NaN"){
1641
-       
1626
+    if(totalone == ""){
1627
+        totalone =0
1628
+     }
1629
+     if(totaltwo == ""){
1630
+       totaltwo =0
1631
+     }
1632
+     if(totalone == ""){
1633
+        totalone =0
1634
+     }
1635
+     if(totalthree == ""){
1636
+      totalthree =0
1637
+     }
1638
+   
1639
+     var total = 0
1640
+      total = (parseFloat(totalone)  + parseFloat(totaltwo)  - parseFloat(totalthree))
1641
+     
1642
+      if(total >0){
1642 1643
         return total.toFixed(2)
1643 1644
       }else{
1644 1645
         return ""

+ 3 - 3
src/xt_pages/stock/query/purchaseNewStockQuery.vue View File

@@ -754,7 +754,7 @@ export default {
754 754
     }
755 755
     if(val2!=null && val2.length > 0){
756 756
      for(let i=0;i<val2.length;i++){
757
-      count_one_price +=val2[i].count * val[i].price
757
+      count_one_price +=val2[i].count * val2[i].price
758 758
      }
759 759
     }
760 760
     all_count_price = count_price + count_one_price
@@ -957,12 +957,12 @@ export default {
957 957
      }
958 958
      if(val2!=null && val2.length > 0){
959 959
       for(let i=0;i<val2.length;i++){
960
-        count_one_price +=val2[i].count  * val[i].price
960
+        count_one_price +=val2[i].count  * val2[i].price
961 961
       }
962 962
      }
963 963
      if(val3!=null && val3.length > 0){
964 964
       for(let i=0;i<val3.length;i++){
965
-        count_two_price +=val3[i].count  * val[i].price
965
+        count_two_price +=val3[i].count  * val3[i].price
966 966
       }
967 967
      }
968 968
      console.log("本期减少",count_price)

+ 3 - 3
src/xt_pages/stock/query/purchaseNewStockQueryPrint.vue View File

@@ -904,7 +904,7 @@ export default {
904 904
       }
905 905
       if(val2!=null && val2.length > 0){
906 906
       for(let i=0;i<val2.length;i++){
907
-        count_one_price +=val2[i].count * val[i].price
907
+        count_one_price +=val2[i].count * val2[i].price
908 908
       }
909 909
       }
910 910
       all_count_price = count_price + count_one_price
@@ -927,12 +927,12 @@ export default {
927 927
      }
928 928
      if(val2!=null && val2.length > 0){
929 929
       for(let i=0;i<val2.length;i++){
930
-        count_one_price +=val2[i].count  * val[i].price
930
+        count_one_price +=val2[i].count  * val2[i].price
931 931
       }
932 932
      }
933 933
      if(val3!=null && val3.length > 0){
934 934
       for(let i=0;i<val3.length;i++){
935
-        count_two_price +=val3[i].count  * val[i].price
935
+        count_two_price +=val3[i].count  * val3[i].price
936 936
       }
937 937
      }
938 938
      console.log("本期减少",count_price)

+ 20 - 8
src/xt_pages/user/courseOfDisease_new.vue View File

@@ -73,9 +73,9 @@
73 73
                 <el-select v-model="admin_user_id" placeholder="请选择" :disabled="disabled">
74 74
                   <el-option
75 75
                     v-for="item in doctorOptions"
76
-                    :key="item.id"
77
-                    :label="item.name"
78
-                    :value="item.id">
76
+                    :key="item.admin_user_id"
77
+                    :label="item.user_name"
78
+                    :value="item.admin_user_id">
79 79
                   </el-option>
80 80
                 </el-select>
81 81
               </div>
@@ -284,7 +284,7 @@
284 284
     deleteCourseTempalte,
285 285
     getAutoPatientContent
286 286
   } from '@/api/patient'
287
-  import { fetchAllDoctorAndNurse } from "@/api/doctor";
287
+  import { fetchMoibleAllDoctorAndNurse } from "@/api/doctor";
288 288
   import { parseTime } from '@/utils'
289 289
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
290 290
   import { uParseTime } from '@/utils/tools'
@@ -335,7 +335,7 @@
335 335
         end_date:'',
336 336
         quzhi_options:[{value:1,label:'本周'},{value:2,label:'上周'},{value:3,label:'本月'},{value:4,label:'上周'},],
337 337
         tableData:[],
338
-        admin_user_id:0,
338
+        admin_user_id:"",
339 339
         record_date:moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
340 340
         template_name:"",
341 341
         id:0,
@@ -381,6 +381,9 @@
381 381
     },
382 382
     created() {
383 383
       this.admin_user_id = this.$store.getters.xt_user.user.id
384
+      if(this.admin_user_id == 0){
385
+         this.admin_user_id = ""
386
+      }
384 387
 
385 388
       this.patient_id = parseInt(this.$route.query.id)
386 389
       this.org_id = this.$store.getters.xt_user.template_info.org_id;
@@ -426,8 +429,13 @@
426 429
         this.library_dialog = false
427 430
       },
428 431
       getCurrentChangeOne(val){
432
+        console.log("val================",val)
429 433
         this.$refs.editor.contents = val.content
430 434
         this.record_date = this.getTime(val.record_time)
435
+        this.admin_user_id = val.recorder
436
+        if(this.admin_user_id == 0){
437
+           this.admin_user_id = ""
438
+        }
431 439
         this.id = val.id
432 440
       },
433 441
       getCurrentChangeTwo(val){
@@ -487,8 +495,8 @@
487 495
       getDocName(admin_user_id){
488 496
         var user_name = ""
489 497
         for(let i=0;i<this.doctorOptions.length;i++){
490
-          if(admin_user_id == this.doctorOptions[i].id){
491
-              user_name = this.doctorOptions[i].name
498
+          if(admin_user_id == this.doctorOptions[i].admin_user_id){
499
+              user_name = this.doctorOptions[i].user_name
492 500
           }
493 501
         }
494 502
        return user_name
@@ -507,7 +515,7 @@
507 515
         })
508 516
      },
509 517
      fetchAllDoctorAndNurse() {
510
-       fetchAllDoctorAndNurse().then(response => {
518
+      fetchMoibleAllDoctorAndNurse().then(response => {
511 519
         if (response.data.state == 1) {
512 520
           this.doctorOptions= []
513 521
           this.doctorOptions = response.data.data.doctors;
@@ -541,6 +549,10 @@
541 549
           this.$message.error('请填写病程内容')
542 550
           return
543 551
         }
552
+
553
+        if(this.admin_user_id == ""){
554
+           this.admin_user_id = 0
555
+        }
544 556
        
545 557
         var params = {
546 558
           id:this.id,

+ 33 - 17
src/xt_pages/user/sickHistory_new.vue View File

@@ -99,9 +99,9 @@
99 99
                 <el-select v-model="admin_user_id" placeholder="请选择" style="width: 120px;" :disabled="disabled">
100 100
                   <el-option
101 101
                     v-for="item in doctorOptions"
102
-                    :key="item.id"
103
-                    :label="item.name"
104
-                    :value="item.id">
102
+                    :key="item.admin_user_id"
103
+                    :label="item.user_name"
104
+                    :value="item.admin_user_id">
105 105
                   </el-option>
106 106
                 </el-select>
107 107
               </div>
@@ -208,7 +208,7 @@ import PatientSidebar from './components/PatientSidebar'
208 208
 import PatientSidebar_new from './components/PatientSidebar_new'
209 209
 import Editor from '@/components/Editor'
210 210
 import ueditor from '@/components/Uedtior'
211
-import { fetchAllDoctorAndNurse } from "@/api/doctor";
211
+import { fetchMoibleAllDoctorAndNurse } from "@/api/doctor";
212 212
  import print from 'print-js'
213 213
 import {
214 214
   createNewSickHistoryRecord,
@@ -299,10 +299,16 @@ export default {
299 299
     }
300 300
   },
301 301
   created() {
302
+
303
+   
304
+    this.fetchAllDoctorAndNurse()
302 305
     this.wayOptions = getDataConfig("patient", "reimbursement_ways");
303
-    console.log('this.wayOptions',this.wayOptions);
304
-    
306
+
305 307
     this.admin_user_id = this.$store.getters.xt_user.user.id
308
+   
309
+    if(this.admin_user_id == 0){
310
+        this.admin_user_id = ""
311
+    }
306 312
     this.patient_id = parseInt(this.$route.query.id)
307 313
     
308 314
     if (isNaN(this.patient_id) || this.patient_id <= 0) {
@@ -336,10 +342,9 @@ export default {
336 342
       (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
337 343
       '-' +
338 344
       (nowDay < 10 ? '0' + nowDay : nowDay)
339
-
340
-    this.getlist()
341
-    this.fetchAllDoctorAndNurse()
342
-    this.fetchPatient(this.patient_id)
345
+      this.getlist()
346
+      this.fetchPatient(this.patient_id)
347
+  
343 348
   },
344 349
   methods: {
345 350
     template_dele(){
@@ -603,7 +608,7 @@ export default {
603 608
     },
604 609
 
605 610
     fetchAllDoctorAndNurse() {
606
-      fetchAllDoctorAndNurse().then(response => {
611
+      fetchMoibleAllDoctorAndNurse().then(response => {
607 612
         if (response.data.state == 1) {
608 613
           this.doctorOptions= []
609 614
           this.doctorOptions = response.data.data.doctors;
@@ -628,7 +633,7 @@ export default {
628 633
         this.$message.error('请选择医生')
629 634
         return
630 635
       }
631
-      if(this.sick_history_time.length  == 0){
636
+      if(this.start_time==""){
632 637
         this.$message.error('请选择时间')
633 638
         return
634 639
       }
@@ -642,6 +647,10 @@ export default {
642 647
       if(this.shen_guomi == ""){
643 648
         this.shen_guomi = 0
644 649
       }
650
+
651
+      if(this.admin_user_id == ""){
652
+         this.admin_user_id = 0
653
+      }
645 654
     
646 655
       let params = {
647 656
         id:this.id,
@@ -687,7 +696,6 @@ export default {
687 696
 
688 697
     createAction: function() {
689 698
 
690
-      console.log("hhhhhhhhhhhhhhhhhh",this.$refs)
691 699
       this.new_content = this.$refs.editor.contents
692 700
       if (this.new_content.length == 0) {
693 701
         this.$message.error('请填写病程内容')
@@ -697,7 +705,7 @@ export default {
697 705
         this.$message.error('请选择医生')
698 706
         return
699 707
       }
700
-      if(this.sick_history_time.length  == 0){
708
+      if(this.start_time == ""){
701 709
         this.$message.error('请选择时间')
702 710
         return
703 711
       }
@@ -710,6 +718,9 @@ export default {
710 718
       if(this.shen_guomi == ""){
711 719
         this.shen_guomi = 0
712 720
       }
721
+      if(this.admin_user_id == ""){
722
+         this.admin_user_id = 0
723
+      }
713 724
     
714 725
       let params = {
715 726
         id:this.id,
@@ -811,8 +822,8 @@ export default {
811 822
     getDocName(admin_user_id){
812 823
       var user_name = ""
813 824
       for(let i=0;i<this.doctorOptions.length;i++){
814
-        if(admin_user_id == this.doctorOptions[i].id){
815
-             user_name = this.doctorOptions[i].name
825
+        if(admin_user_id == this.doctorOptions[i].admin_user_id){
826
+             user_name = this.doctorOptions[i].user_name
816 827
         }
817 828
       }
818 829
       return user_name
@@ -848,7 +859,12 @@ export default {
848 859
       }
849 860
 
850 861
       this.patient_id = val.patient_id
851
-      this.admin_user_id = val.recorder?val.doctor_id:"0"
862
+      this.admin_user_id = val.doctor_id
863
+      if(this.admin_user_id == 0){
864
+         this.admin_user_id = ""
865
+      }
866
+
867
+      this.start_time  = this.getTime(val.record_date)
852 868
 
853 869
     },
854 870
     getCurrentChangeOne(val){

+ 13 - 13
src/xt_permission.js View File

@@ -12,19 +12,19 @@ const permissionWhiteList = loginWhiteList.concat(['/']) // 权限验证白名
12 12
 
13 13
 router.beforeEach((to, from, next) => {
14 14
   // 线上注释
15
-  if (!store.getters.configlist || store.getters.configlist === undefined || store.getters.configlist.length <= 0) {
16
-    store.dispatch('VerifyConfigList', []).then(() => {
17
-      next()
18
-    })
19
-  }
20
-  if (store.getters.permission_routers === undefined) {
21
-    store.dispatch('xt_GenerateRoutes', []).then(() => {
22
-      next()
23
-    })
24
-  } else {
25
-    next()
26
-  }
27
-  return
15
+  // if (!store.getters.configlist || store.getters.configlist === undefined || store.getters.configlist.length <= 0) {
16
+  //   store.dispatch('VerifyConfigList', []).then(() => {
17
+  //     next()
18
+  //   })
19
+  // }
20
+  // if (store.getters.permission_routers === undefined) {
21
+  //   store.dispatch('xt_GenerateRoutes', []).then(() => {
22
+  //     next()
23
+  //   })
24
+  // } else {
25
+  //   next()
26
+  // }
27
+  // return
28 28
  // 线上注释
29 29
   NProgress.start()
30 30
   // console.log(store.getters.current_role_urls.indexOf(to.path))