浏览代码

Merge branch '20201109_pc_vue_new_branch' of http://git.shengws.com/csx/Vue_New into 20201109_pc_vue_new_branch

XMLWAN 3 年前
父节点
当前提交
f3ce4450ef

+ 42 - 2
src/xt_pages/dialysis/batch_print/batch_print_order_fortyThree.vue 查看文件

454
                             <span v-if="advice.execution_time">{{ getTime(advice.execution_time, "{h}:{i}") }}</span>
454
                             <span v-if="advice.execution_time">{{ getTime(advice.execution_time, "{h}:{i}") }}</span>
455
                         </td>
455
                         </td>
456
                     </tr>
456
                     </tr>
457
+                    <tr v-for="(advice, advice_index) in record.his_project" :key="advice_index">
458
+                        <td height="32px;padding:1px 1px">
459
+                            <span v-if="advice.start_time">
460
+                                {{ getTime(advice.start_time, "{h}:{i}") }}
461
+                            </span>
462
+                        </td>
463
+                        <td height="32px" colspan="2" class="advice-name" style="padding-left:7px;">
464
+                            <span style="padding-left:5px;display:inline-block;">
465
+                              <span>{{ advice.project.project_name }}</span>
466
+                            </span>
467
+                        </td>
468
+
469
+                        <td height="32px">
470
+                            <span v-if="setAdminUserES(advice, 'doctor') == ''">
471
+                                {{getAdminUser(advice, 'doctor')}}
472
+                            </span>
473
+                            <span v-else style="display:flex;align-items:center;justify-content:space-around;height:36px;">
474
+                                <img style="height:30px;" :src="setAdminUserES(advice, 'doctor')" alt srcset />
475
+                            </span>
476
+                        </td>
477
+                        <td height="32px">
478
+                            <span v-if="setAdminUserES(advice, 'execution_staff') == ''">
479
+                                {{getAdminUser(advice, 'execution_staff')}}
480
+                            </span>
481
+                            <span v-else>
482
+                                <img style="height:30px;" :src="setAdminUserES(advice, 'execution_staff')" alt srcset />
483
+                            </span>
484
+                        </td>
485
+                        <td height="32px">
486
+                            <span v-if="advice.execution_time">{{ getTime(advice.execution_time, "{h}:{i}") }}</span>
487
+                        </td>
488
+                    </tr>
457
                     <!-- </template> -->
489
                     <!-- </template> -->
458
                     </tbody>
490
                     </tbody>
459
                 </table>
491
                 </table>
503
                         </div>
535
                         </div>
504
                     </div>
536
                     </div>
505
                 </div>
537
                 </div>
506
-                <div class="row" style="border-bottom:1px solid #000;display:flex;margin-top:150px;">
538
+                <div class="row" style="border-bottom:1px solid #000;display:flex;margin-top:50px;">
507
                     <div class="inline_block" style="width:33%">
539
                     <div class="inline_block" style="width:33%">
508
                         医生签名:
540
                         医生签名:
509
                         <div class="under_line" style="width: 70px;text-align: center;">
541
                         <div class="under_line" style="width: 70px;text-align: center;">
711
             if (this.records[recordIndex].patient.user_org_id == 9535) {
743
             if (this.records[recordIndex].patient.user_org_id == 9535) {
712
               this.records[recordIndex].isShowZero = true
744
               this.records[recordIndex].isShowZero = true
713
             }
745
             }
746
+
747
+            let his_project = []
748
+            this.records[recordIndex].his_project.map(item => {
749
+              if(item.type == 2){
750
+                his_project.push(item)
751
+              }
752
+            })
753
+            this.records[recordIndex].his_project = his_project
714
             
754
             
715
             var delghThree = 0
755
             var delghThree = 0
716
             if (
756
             if (
717
               this.records[recordIndex].his_advices &&
757
               this.records[recordIndex].his_advices &&
718
-              this.records[recordIndex].his_advices.length < 6
758
+              this.records[recordIndex].his_advices.length + this.records[recordIndex].his_project.length < 6
719
             ) {
759
             ) {
720
               delghThree = 6 - this.records[recordIndex].his_advices.length
760
               delghThree = 6 - this.records[recordIndex].his_advices.length
721
             } else {
761
             } else {

+ 77 - 24
src/xt_pages/dialysis/template/DialysisPrintOrderFortyThree.vue 查看文件

424
                   <span v-if="advice.execution_time">{{ getTime(advice.execution_time, "{h}:{i}") }}</span>
424
                   <span v-if="advice.execution_time">{{ getTime(advice.execution_time, "{h}:{i}") }}</span>
425
                   </td>
425
                   </td>
426
               </tr>
426
               </tr>
427
-              <!-- </template> -->
427
+              <tr v-for="(advice, advice_index) in projects" :key="advice_index">
428
+                  <td height="32px;padding:1px 1px">
429
+                  <span v-if="advice.start_time">
430
+                      {{ getTime(advice.start_time, "{h}:{i}") }}
431
+                  </span>
432
+                  </td>
433
+                  <td height="32px" colspan="2" class="advice-name" style="padding-left:7px;">
434
+                    <span>{{ advice.project.project_name }}</span>
435
+                  </td>
436
+                  <td height="32px">
437
+                      <span v-if="setAdminUserES(advice.doctor) == ''">{{ getAdminUser(advice.doctor) }}</span>
438
+                      <img style="height:30px" :src="setAdminUserES(advice.doctor)" alt="" srcset="" v-else />
439
+                  </td>
440
+                  <td height="32px">
441
+                      <span v-if="setAdminUserES(advice.execution_staff) == ''">{{ getAdminUser(advice.execution_staff) }}</span>
442
+                      <img style="height:30px" :src="setAdminUserES(advice.execution_staff)" alt="" srcset="" v-else />
443
+                  </td>
444
+                  <td height="32px">
445
+                  <span v-if="advice.execution_time">{{ getTime(advice.execution_time, "{h}:{i}") }}</span>
446
+                  </td>
447
+              </tr>
428
               </tbody>
448
               </tbody>
429
           </table>
449
           </table>
430
           <div style="border:1px solid #000;margin-top:5px;padding:0 10px;">
450
           <div style="border:1px solid #000;margin-top:5px;padding:0 10px;">
473
                   </div>
493
                   </div>
474
               </div>
494
               </div>
475
           </div>
495
           </div>
476
-          <div class="row" style="border-bottom:1px solid #000;display:flex;margin-top:150px;">
496
+          <div class="row" style="border-bottom:1px solid #000;display:flex;margin-top:50px;">
477
             <div class="inline_block" style="width:33%">
497
             <div class="inline_block" style="width:33%">
478
                   医生签名:
498
                   医生签名:
479
                   <div class="under_line" style="width: 70px;text-align: center;">
499
                   <div class="under_line" style="width: 70px;text-align: center;">
656
         gaijiliang_unit: ''
676
         gaijiliang_unit: ''
657
       },
677
       },
658
       org_id:0,
678
       org_id:0,
679
+      projects:[]
659
     }
680
     }
660
   },
681
   },
661
   methods: {
682
   methods: {
702
         this.$message.error('血流速未填')
723
         this.$message.error('血流速未填')
703
       }else if(this.predialysis.symptom_before_dialysis == ""){
724
       }else if(this.predialysis.symptom_before_dialysis == ""){
704
         this.$message.error('透前病情未填')
725
         this.$message.error('透前病情未填')
705
-      }else if(this.dialysisOrder.washpipe_nurse == 0){
726
+      }else if(this.dialysisOrder == null || this.dialysisOrder.washpipe_nurse == 0){
706
         this.$message.error('预冲者未填')
727
         this.$message.error('预冲者未填')
707
-      }else if(this.dialysisOrder.puncture_nurse == 0){
728
+      }else if(this.dialysisOrder == null || this.dialysisOrder.puncture_nurse == 0){
708
         this.$message.error('穿刺者未填')
729
         this.$message.error('穿刺者未填')
709
-      }else if(this.dialysisOrder.start_nurse == 0){
730
+      }else if(this.dialysisOrder == null || this.dialysisOrder.start_nurse == 0){
710
         this.$message.error('上机者未填')
731
         this.$message.error('上机者未填')
711
-      }else if(this.dialysisOrder.finish_nurse == 0){
732
+      }else if(this.dialysisOrder == null || this.dialysisOrder.finish_nurse == 0){
712
         this.$message.error('下机者未填')
733
         this.$message.error('下机者未填')
713
       }else if(this.afterdialysis.weight_after == 0){
734
       }else if(this.afterdialysis.weight_after == 0){
714
         this.$message.error('透后体重未填')
735
         this.$message.error('透后体重未填')
733
       }else if(this.dialysisOrder != null && this.dialysisOrder.start_nurse != this.check.creater && this.dialysisOrder.start_nurse != this.check.modifier && this.check.creater == 0){
754
       }else if(this.dialysisOrder != null && this.dialysisOrder.start_nurse != this.check.creater && this.dialysisOrder.start_nurse != this.check.modifier && this.check.creater == 0){
734
         this.$message.error('查对护士未填')
755
         this.$message.error('查对护士未填')
735
       }else if(this.tableAdvice.length > 0){
756
       }else if(this.tableAdvice.length > 0){
736
-        this.tableAdvice.map(item => {
737
-          if(item.id > 0 && item.created_time){
738
-            this.users.map(it => {
739
-              if(it.id == item.advice_doctor){
740
-                if(it.type != 2){
741
-                  this.$message.error('存在不是医生保存的医嘱')
757
+        let num = 0
758
+        if(this.tableAdvice.length > 0){
759
+          this.tableAdvice.map(item => {
760
+            if(item.id > 0 && (item.created_time || item.start_time)){
761
+              this.users.map(it => {
762
+                if(it.id == item.advice_doctor){
763
+                  if(it.user_type == 3){
764
+                    num++
765
+                    this.$message.error('存在不是医生保存的医嘱')
766
+                  }else if(it.id == item.execution_staff && item.execution_staff > 0){
767
+                    if(it.user_type == 2){
768
+                      num++
769
+                      this.$message.error('存在不是护士执行的医嘱')
770
+                    }
771
+                  }else if(it.id == item.checker && item.checker > 0){
772
+                    if(it.user_type == 2){
773
+                      num++
774
+                      this.$message.error('存在不是护士核对的医嘱')
775
+                    }
776
+                  }
777
+                }else if(it.id == item.execution_staff && item.execution_staff > 0){
778
+                  if(it.user_type == 2){
779
+                    num++
780
+                    this.$message.error('存在不是护士执行的医嘱')
781
+                  }
782
+                }else if(it.id == item.checker && item.checker > 0){
783
+                  if(it.user_type == 2){
784
+                    num++
785
+                    this.$message.error('存在不是护士核对的医嘱')
786
+                  }
742
                 }
787
                 }
743
-              }else if(it.id == item.execution_staff && item.execution_staff > 0){
744
-                if(it.type != 3){
745
-                  this.$message.error('存在不是护士执行的医嘱')
746
-                }
747
-              }else if(it.id == item.checker && item.checker > 0){
748
-                if(it.type != 3){
749
-                  this.$message.error('存在不是护士核对的医嘱')
750
-                }
751
-              }
752
-            })
753
-          }
788
+              })
789
+            }
754
         })
790
         })
791
+        }
792
+        
793
+        if(num == 0){
794
+          this.$message.success('核对完成')
795
+        }
796
+      }else{
797
+        this.$message.success('核对完成')
755
       }
798
       }
756
     },
799
     },
757
     getDisplaceLiquiPart: function(val) {
800
     getDisplaceLiquiPart: function(val) {
1209
         //    this.advice_groups.push(group)
1252
         //    this.advice_groups.push(group)
1210
         //   }
1253
         //   }
1211
         // }
1254
         // }
1212
-        if (this.doctor_advices.length <= 6) {
1255
+
1256
+        let projects = []
1257
+        response.data.data.projects.map(item => {
1258
+          if(item.type == 2){
1259
+            projects.push(item)
1260
+          }
1261
+        })
1262
+        this.projects = projects
1263
+        if (this.doctor_advices.length + this.projects.length <= 6) {
1213
           var nl = 6
1264
           var nl = 6
1214
           this.print_length = 6
1265
           this.print_length = 6
1215
 
1266
 
1224
             }
1275
             }
1225
           }
1276
           }
1226
         }
1277
         }
1278
+        
1279
+        console.log('this.projects',this.projects)
1227
 
1280
 
1228
         // this.totollength = this.doctor_advices.length + this.monitors.length
1281
         // this.totollength = this.doctor_advices.length + this.monitors.length
1229
         // if (this.totollength > 18) {
1282
         // if (this.totollength > 18) {