浏览代码

打印单抗凝剂问题修改

XMLWAN 5 年前
父节点
当前提交
2260ba58d1

+ 8 - 7
src/xt_pages/dialysis/batch_print/batch_print_order_seven.vue 查看文件

1424
             }
1424
             }
1425
 
1425
 
1426
             this.adminUser = resp.data.users
1426
             this.adminUser = resp.data.users
1427
+            //console.log("使用者",this.adminUser)
1427
             this.loading = false
1428
             this.loading = false
1428
           } else {
1429
           } else {
1429
             this.loading = false
1430
             this.loading = false
1454
       QueryPartById: function(val) {
1455
       QueryPartById: function(val) {
1455
         let vascular_access_part_name = '/'
1456
         let vascular_access_part_name = '/'
1456
         const vascular_access = getDataConfig('hemodialysis', 'vascular_access_desc')
1457
         const vascular_access = getDataConfig('hemodialysis', 'vascular_access_desc')
1457
-         console.log("血管通路",vascular_access)
1458
+        // console.log("血管通路",vascular_access)
1458
         for (let i = 0; i < vascular_access.length; i++) {
1459
         for (let i = 0; i < vascular_access.length; i++) {
1459
           if (vascular_access[i].id == val) {
1460
           if (vascular_access[i].id == val) {
1460
             vascular_access_part_name = vascular_access[i].name
1461
             vascular_access_part_name = vascular_access[i].name
1582
         }
1583
         }
1583
       },
1584
       },
1584
       getAdminUser(key, id) {
1585
       getAdminUser(key, id) {
1585
-        // console.log('key', key)
1586
-        // console.log('id', id)
1586
+       // console.log('key', key)
1587
+       // console.log('id', id)
1587
         if (
1588
         if (
1588
           typeof key === 'undefined' ||
1589
           typeof key === 'undefined' ||
1589
           key == null ||
1590
           key == null ||
1671
         )
1672
         )
1672
       },
1673
       },
1673
       getNumber: function(record) {
1674
       getNumber: function(record) {
1674
-        console.log(record)
1675
+        //console.log(record)
1675
       },
1676
       },
1676
       getLastAfterWeight(id, assessmentDate) {
1677
       getLastAfterWeight(id, assessmentDate) {
1677
         getLastAfterWeight(id, assessmentDate).then(response => {
1678
         getLastAfterWeight(id, assessmentDate).then(response => {
1679
             var weight = response.data.data.weight
1680
             var weight = response.data.data.weight
1680
 
1681
 
1681
             this.lastAfterWeight = weight.weight_after.toFixed(1)
1682
             this.lastAfterWeight = weight.weight_after.toFixed(1)
1682
-            console.log('weight', weight)
1683
+           // console.log('weight', weight)
1683
           }
1684
           }
1684
         })
1685
         })
1685
       },
1686
       },
1686
       getDisplaceLiquiPart: function(val) {
1687
       getDisplaceLiquiPart: function(val) {
1687
-        console.log(val)
1688
+       // console.log(val)
1688
         let displace_liqui_part_name = "/";
1689
         let displace_liqui_part_name = "/";
1689
         const displace_liqui_part = this.displaceLiquiPartOptions;
1690
         const displace_liqui_part = this.displaceLiquiPartOptions;
1690
-        console.log("置换方式",displace_liqui_part)
1691
+       // console.log("置换方式",displace_liqui_part)
1691
         for (let i = 0; i < displace_liqui_part.length; i++) {
1692
         for (let i = 0; i < displace_liqui_part.length; i++) {
1692
            if (displace_liqui_part[i].id == val) {
1693
            if (displace_liqui_part[i].id == val) {
1693
            displace_liqui_part_name = displace_liqui_part[i].name;
1694
            displace_liqui_part_name = displace_liqui_part[i].name;

+ 186 - 438
src/xt_pages/dialysis/batch_print/batch_print_order_six.vue 查看文件

14
     <div class="app-container">
14
     <div class="app-container">
15
       <div id="print_content">
15
       <div id="print_content">
16
         <div
16
         <div
17
-          v-for="(record, index) in records"
18
-          :key="index"
17
+          v-for="(record, t) in records"
18
+          :key="t"
19
           class="print_page_main_content"
19
           class="print_page_main_content"
20
         >
20
         >
21
           <div style="display:inline-block;width:100%;text-align:center;">
21
           <div style="display:inline-block;width:100%;text-align:center;">
98
           <div class="row">
98
           <div class="row">
99
             <div class="inline_block">
99
             <div class="inline_block">
100
               入科方式:
100
               入科方式:
101
-              <!--<check-box-->
102
-              <!--v-for="(item, index) in way_arr"-->
103
-              <!--:key="index"-->
104
-              <!--:text="item.name"-->
105
-              <!--:checked="-->
106
-              <!--isCheckBoxChecked(-->
107
-              <!--record.receive_assessment,-->
108
-              <!--'way',-->
109
-              <!--item.id-->
110
-              <!--)-->
111
-              <!--"-->
112
-              <!--&gt;</check-box>-->
113
-              <!--<div-->
114
-              <!--class="under_line"-->
115
-              <!--v-if="record.receive_assessment.way == 0"-->
116
-              <!--style="width: 180px;text-align: left"-->
117
-              <!--&gt;</div>-->
118
-
119
               <div
101
               <div
120
-                v-for="(item, index) in way_arr"
102
+                v-for="(item, i) in way_arr"
121
                 class="under_line"
103
                 class="under_line"
122
                 v-if="record.receive_assessment.way == item.id"
104
                 v-if="record.receive_assessment.way == item.id"
123
                 style="width: 180px;text-align: left"
105
                 style="width: 180px;text-align: left"
124
               >
106
               >
125
                 {{ item.name }}
107
                 {{ item.name }}
126
               </div>
108
               </div>
127
-              <!--<div-->
128
-              <!--class="under_line"-->
129
-              <!--v-if="C.receive_assessment.way == 1"-->
130
-              <!--style="width: 180px;text-align: left"-->
131
-              <!--&gt;-->
132
-              <!--步行-->
133
-              <!--</div>-->
134
-              <!--<div-->
135
-              <!--class="under_line"-->
136
-              <!--v-if="record.receive_assessment.way == 2"-->
137
-              <!--style="width: 180px;text-align: left"-->
138
-              <!--&gt;-->
139
-              <!--扶行-->
140
-              <!--</div>-->
141
-              <!--<div-->
142
-              <!--class="under_line"-->
143
-              <!--v-if="record.receive_assessment.way == 3"-->
144
-              <!--style="width: 180px;text-align: left"-->
145
-              <!--&gt;-->
146
-              <!--轮椅-->
147
-              <!--</div>-->
148
-              <!--<div-->
149
-              <!--class="under_line"-->
150
-              <!--v-if="record.receive_assessment.way == 4"-->
151
-              <!--style="width: 180px;text-align: left"-->
152
-              <!--&gt;-->
153
-              <!--平车-->
154
-              <!--</div>-->
155
             </div>
109
             </div>
156
             <div class="inline_block" style="margin-left: 10px;">
110
             <div class="inline_block" style="margin-left: 10px;">
157
               诊断:
111
               诊断:
866
                           <td width="60">透析液温度(°C)</td>
820
                           <td width="60">透析液温度(°C)</td>
867
                           <td width="50">电导度<br />(ms/cm)</td>
821
                           <td width="50">电导度<br />(ms/cm)</td>
868
                           <td width="50">超滤量<br />(ml)</td>
822
                           <td width="50">超滤量<br />(ml)</td>
823
+                          <td
824
+                            v-if="
825
+                              record.prescription.mode_id == 2 ||
826
+                                record.prescription.mode_id == 5 ||
827
+                                record.prescription.mode_id == 12
828
+                            "
829
+                            width="50"
830
+                          >
831
+                            置换量<br />(ml)
832
+                          </td>
869
                           <td width="200">病情变化及处理</td>
833
                           <td width="200">病情变化及处理</td>
870
                         </tr>
834
                         </tr>
871
                         <tr
835
                         <tr
872
-                          v-for="(monitor_record,
873
-                          index) in record.monitor_records"
874
-                          :key="index"
836
+                          v-for="(monitor_record, j) in record.monitor_records"
837
+                          :key="j"
875
                         >
838
                         >
876
                           <td>
839
                           <td>
877
                             {{
840
                             {{
945
                                 : 0
908
                                 : 0
946
                             }}
909
                             }}
947
                           </td>
910
                           </td>
948
-
911
+                          <td
912
+                            v-if="
913
+                              record.prescription.mode_id == 2 ||
914
+                                record.prescription.mode_id == 5 ||
915
+                                (record.prescription.mode_id == 12 &&
916
+                                  monitor_record.operate_time >
917
+                                    record.dialysis_order.end_time)
918
+                            "
919
+                            style="width:50px"
920
+                          >
921
+                            {{
922
+                              monitor_record.displacement_quantity
923
+                                ? monitor_record.displacement_quantity
924
+                                : ""
925
+                            }}
926
+                          </td>
949
                           <td style="line-height:16px;padding:0px;">
927
                           <td style="line-height:16px;padding:0px;">
950
                             <div
928
                             <div
951
                               style="min-height:40px;line-height:20px; overflow:hidden;"
929
                               style="min-height:40px;line-height:20px; overflow:hidden;"
966
                           </td>
944
                           </td>
967
                         </tr>
945
                         </tr>
968
                         <tr
946
                         <tr
969
-                          v-for="(monitor_record,
970
-                          index) in record.monitor_records2"
971
-                          :key="index"
947
+                          v-for="(monitor_record, s) in record.monitor_records2"
948
+                          :key="s"
972
                         >
949
                         >
973
                           <td></td>
950
                           <td></td>
974
                           <td></td>
951
                           <td></td>
1029
                           :key="advice_index"
1006
                           :key="advice_index"
1030
                         >
1007
                         >
1031
                           <td height="35px">
1008
                           <td height="35px">
1032
-                            <span v-if="advice.start_time">
1033
-                              {{ getTime(advice.start_time, "{h}:{i}") }}
1009
+                            <span v-if="advice[0].start_time">
1010
+                              {{ getTime(advice[0].start_time, "{h}:{i}") }}
1034
                             </span>
1011
                             </span>
1035
                             <!-- <span v-else>&nbsp;<br/>&nbsp;</span> -->
1012
                             <!-- <span v-else>&nbsp;<br/>&nbsp;</span> -->
1036
                           </td>
1013
                           </td>
1040
                             class="advice-name"
1017
                             class="advice-name"
1041
                             style="padding-left:7px;"
1018
                             style="padding-left:7px;"
1042
                           >
1019
                           >
1043
-                            <span v-if="advice.parent_id > 0">---></span>
1044
-                            <span>{{ advice.advice_name }}</span>
1045
-                            <span v-if="advice.advice_desc != ''"
1046
-                              >{{ advice.advice_desc
1047
-                              }}{{ advice.drug_spec_unit }}</span
1020
+                            <span v-if="advice[0].parent_id > 0">---></span>
1021
+                            <span>{{ advice[0].advice_name }}</span>
1022
+                            <span v-if="advice[0].advice_desc != ''"
1023
+                              >{{ advice[0].advice_desc
1024
+                              }}{{ advice[0].drug_spec_unit }}</span
1048
                             >
1025
                             >
1049
-                            <span v-if="advice.prescribing_number"
1050
-                              >&nbsp;&nbsp; {{ advice.prescribing_number
1051
-                              }}{{ advice.prescribing_number_unit }}</span
1026
+                            <span v-if="advice[0].prescribing_number"
1027
+                              >&nbsp;&nbsp; {{ advice[0].prescribing_number
1028
+                              }}{{ advice[0].prescribing_number_unit }}</span
1052
                             >
1029
                             >
1053
-                            <span v-if="advice.single_dose != 0">
1054
-                              {{ advice.single_dose
1055
-                              }}{{ advice.single_dose_unit }}</span
1030
+                            <span v-if="advice[0].single_dose != 0">
1031
+                              {{ advice[0].single_dose
1032
+                              }}{{ advice[0].single_dose_unit }}</span
1056
                             >
1033
                             >
1057
                             <span
1034
                             <span
1058
                               v-if="
1035
                               v-if="
1059
-                                advice.parent_id == 0 &&
1060
-                                  advice.children.length == 0
1036
+                                advice[0].parent_id == 0 &&
1037
+                                  advice[0].children.length == 0
1061
                               "
1038
                               "
1062
-                              >{{ advice.delivery_way }}</span
1039
+                              >{{ advice[0].delivery_way }}</span
1063
                             >
1040
                             >
1064
                             <span
1041
                             <span
1065
                               v-if="
1042
                               v-if="
1066
-                                advice.parent_id == 0 &&
1067
-                                  advice.children.length == 0
1043
+                                advice[0].parent_id == 0 &&
1044
+                                  advice[0].children.length == 0
1068
                               "
1045
                               "
1069
-                              >{{ advice.execution_frequency }}</span
1046
+                              >{{ advice[0].execution_frequency }}</span
1070
                             >
1047
                             >
1071
                             <span
1048
                             <span
1072
                               v-if="
1049
                               v-if="
1073
-                                advice.parent_id == 0 &&
1074
-                                  advice.children &&
1075
-                                  advice.children.length == 0 &&
1076
-                                  advice.remark.length > 0
1050
+                                advice[0].parent_id == 0 &&
1051
+                                  advice[0].children &&
1052
+                                  advice[0].children.length == 0 &&
1053
+                                  advice[0].remark.length > 0
1077
                               "
1054
                               "
1078
-                              >({{ advice.remark }})</span
1055
+                              >({{ advice[0].remark }})</span
1079
                             >
1056
                             >
1080
                           </td>
1057
                           </td>
1081
-                          <!-- <td colspan="2" height="60px" style="text-align: center" v-else >
1082
-                                            <span>{{advice.delivery_way}}</span>
1083
-                                            <span>{{advice.execution_frequency}}</span>
1084
-                                            <span v-if="advice.remark.length > 0">({{advice.remark}})</span>
1085
-                                        </td> -->
1086
-                          <!-- <td width="10%" v-if="(advice.children && advice.children.length > 0 || advice.parent_id > 0) && advice.isShow == 2" ></td> -->
1087
                           <td height="35px">
1058
                           <td height="35px">
1088
                             <span
1059
                             <span
1089
-                              v-if="setAdminUserES(advice.advice_doctor) == ''"
1090
-                              >{{ getAdminUser(advice.advice_doctor) }}</span
1060
+                              v-if="
1061
+                                setAdminUserES(advice[0], 'advice_doctor') == ''
1062
+                              "
1063
+                              >{{
1064
+                                getAdminUser(advice[0], "advice_doctor")
1065
+                              }}</span
1091
                             >
1066
                             >
1092
                             <img
1067
                             <img
1093
-                              style="height:20px;"
1094
-                              :src="setAdminUserES(advice.advice_doctor)"
1068
+                              class="es-img"
1069
+                              :src="setAdminUserES(advice[0], 'advice_doctor')"
1095
                               alt=""
1070
                               alt=""
1096
                               srcset=""
1071
                               srcset=""
1097
                               v-else
1072
                               v-else
1073
+                              style="height: 40px;"
1098
                             />
1074
                             />
1099
                           </td>
1075
                           </td>
1100
                           <!-- <td height="35px">
1076
                           <!-- <td height="35px">
1104
                           <td height="35px">
1080
                           <td height="35px">
1105
                             <span
1081
                             <span
1106
                               v-if="
1082
                               v-if="
1107
-                                setAdminUserES(advice.execution_staff) == ''
1083
+                                setAdminUserES(advice[0].execution_staff) == ''
1108
                               "
1084
                               "
1109
-                              >{{ getAdminUser(advice.execution_staff) }}</span
1085
+                              >{{
1086
+                                getAdminUser(advice[0].execution_staff)
1087
+                              }}</span
1110
                             >
1088
                             >
1111
                             <img
1089
                             <img
1112
                               style="height:20px;"
1090
                               style="height:20px;"
1113
-                              :src="setAdminUserES(advice.execution_staff)"
1091
+                              :src="setAdminUserES(advice[0].execution_staff)"
1114
                               alt=""
1092
                               alt=""
1115
                               srcset=""
1093
                               srcset=""
1116
                               v-else
1094
                               v-else
1117
                             />
1095
                             />
1118
                           </td>
1096
                           </td>
1119
                           <td height="35px">
1097
                           <td height="35px">
1120
-                            <span v-if="advice.execution_time">{{
1098
+                            <span v-if="advice[0].execution_time">{{
1121
                               getTime(
1099
                               getTime(
1122
-                                advice.execution_time,
1100
+                                advice[0].execution_time,
1123
                                 "{y}-{m}-{d} {h}:{i}"
1101
                                 "{y}-{m}-{d} {h}:{i}"
1124
                               )
1102
                               )
1125
                             }}</span>
1103
                             }}</span>
1221
                 >
1199
                 >
1222
                   {{ item.name }}
1200
                   {{ item.name }}
1223
                 </div>
1201
                 </div>
1224
-                <!--<div-->
1225
-                <!--class="under_line"-->
1226
-                <!--v-if="record.receive_assessment.way == 0"-->
1227
-                <!--style="width: 180px;text-align: left"-->
1228
-                <!--&gt;</div>-->
1229
-                <!--<div-->
1230
-                <!--class="under_line"-->
1231
-                <!--v-if="record.receive_assessment == 1"-->
1232
-                <!--style="width: 180px;text-align: left"-->
1233
-                <!--&gt;-->
1234
-                <!--步行-->
1235
-                <!--</div>-->
1236
-                <!--<div-->
1237
-                <!--class="under_line"-->
1238
-                <!--v-if="record.receive_assessment == 2"-->
1239
-                <!--style="width: 180px;text-align: left"-->
1240
-                <!--&gt;-->
1241
-                <!--扶行-->
1242
-                <!--</div>-->
1243
-                <!--<div-->
1244
-                <!--class="under_line"-->
1245
-                <!--v-if="record.receive_assessment == 3"-->
1246
-                <!--style="width: 180px;text-align: left"-->
1247
-                <!--&gt;-->
1248
-                <!--轮椅-->
1249
-                <!--</div>-->
1250
-                <!--<div-->
1251
-                <!--class="under_line"-->
1252
-                <!--v-if="record.receive_assessment == 4"-->
1253
-                <!--style="width: 180px;text-align: left"-->
1254
-                <!--&gt;-->
1255
-                <!--平车-->
1256
-                <!--</div>-->
1257
               </div>
1202
               </div>
1258
               <div class="inline_block" style="margin-left: 10px;">
1203
               <div class="inline_block" style="margin-left: 10px;">
1259
                 诊断:
1204
                 诊断:
1560
                           <span
1505
                           <span
1561
                             v-if="
1506
                             v-if="
1562
                               setAdminUserES(
1507
                               setAdminUserES(
1563
-                                record.dialysis_order == null
1564
-                                  ? 0
1565
-                                  : record.dialysis_order.puncture_nurse
1508
+                                record.dialysis_order,
1509
+                                'puncture_nurse'
1566
                               ) == ''
1510
                               ) == ''
1567
                             "
1511
                             "
1568
                             >{{
1512
                             >{{
1569
                               getAdminUser(
1513
                               getAdminUser(
1570
-                                record.dialysis_order == null
1571
-                                  ? 0
1572
-                                  : record.dialysis_order.puncture_nurse
1514
+                                record.dialysis_order,
1515
+                                "puncture_nurse"
1573
                               )
1516
                               )
1517
+                                ? getAdminUser(
1518
+                                    record.dialysis_order,
1519
+                                    "puncture_nurse"
1520
+                                  )
1521
+                                : "/"
1574
                             }}</span
1522
                             }}</span
1575
                           >
1523
                           >
1576
                           <img
1524
                           <img
1577
-                            style="height:20px;"
1525
+                            class="es-img"
1578
                             :src="
1526
                             :src="
1579
                               setAdminUserES(
1527
                               setAdminUserES(
1580
-                                record.dialysis_order == null
1581
-                                  ? 0
1582
-                                  : record.dialysis_order.puncture_nurse
1528
+                                record.dialysis_order,
1529
+                                'puncture_nurse'
1583
                               )
1530
                               )
1584
                             "
1531
                             "
1585
                             alt=""
1532
                             alt=""
1586
                             srcset=""
1533
                             srcset=""
1587
                             v-else
1534
                             v-else
1535
+                            style="height: 40px;"
1588
                           />
1536
                           />
1589
                         </div>
1537
                         </div>
1590
                       </div>
1538
                       </div>
1597
                           <span
1545
                           <span
1598
                             v-if="
1546
                             v-if="
1599
                               setAdminUserES(
1547
                               setAdminUserES(
1600
-                                record.dialysis_order == null
1601
-                                  ? 0
1602
-                                  : record.dialysis_order.start_nurse
1548
+                                record.dialysis_order,
1549
+                                'start_nurse'
1603
                               ) == ''
1550
                               ) == ''
1604
                             "
1551
                             "
1605
                             >{{
1552
                             >{{
1606
-                              getAdminUser(
1607
-                                record.dialysis_order == null
1608
-                                  ? 0
1609
-                                  : record.dialysis_order.start_nurse
1610
-                              )
1553
+                              getAdminUser(record.dialysis_order, "start_nurse")
1554
+                                ? getAdminUser(
1555
+                                    record.dialysis_order,
1556
+                                    "start_nurse"
1557
+                                  )
1558
+                                : "/"
1611
                             }}</span
1559
                             }}</span
1612
                           >
1560
                           >
1613
                           <img
1561
                           <img
1614
-                            style="height:20px;"
1562
+                            class="es-img"
1615
                             :src="
1563
                             :src="
1616
                               setAdminUserES(
1564
                               setAdminUserES(
1617
-                                record.dialysis_order == null
1618
-                                  ? 0
1619
-                                  : record.dialysis_order.start_nurse
1565
+                                record.dialysis_order,
1566
+                                'start_nurse'
1620
                               )
1567
                               )
1621
                             "
1568
                             "
1622
                             alt=""
1569
                             alt=""
1623
                             srcset=""
1570
                             srcset=""
1624
                             v-else
1571
                             v-else
1572
+                            style="height: 40px;"
1625
                           />
1573
                           />
1626
                         </div>
1574
                         </div>
1627
                       </div>
1575
                       </div>
1644
                           >
1592
                           >
1645
                             <span
1593
                             <span
1646
                               v-if="
1594
                               v-if="
1647
-                                setAdminUserES(record.check, 'modifier') == ''
1595
+                                setAdminUserES(record.check, 'creater') == ''
1648
                               "
1596
                               "
1649
                               >{{
1597
                               >{{
1650
-                                getAdminUser(record.check, "modifier")
1598
+                                getAdminUser(record.check, "creater")
1599
+                                  ? getAdminUser(record.check, "creater")
1600
+                                  : "/"
1651
                               }}</span
1601
                               }}</span
1652
                             >
1602
                             >
1653
                             <img
1603
                             <img
1654
                               class="es-img"
1604
                               class="es-img"
1655
-                              :src="setAdminUserES(record.check, 'modifier')"
1605
+                              :src="setAdminUserES(record.check, 'creater')"
1656
                               alt=""
1606
                               alt=""
1657
                               srcset=""
1607
                               srcset=""
1658
                               v-else
1608
                               v-else
1609
+                              style="height: 40px;"
1659
                             />
1610
                             />
1660
                           </div>
1611
                           </div>
1661
                           <div
1612
                           <div
1722
                           <span
1673
                           <span
1723
                             v-if="
1674
                             v-if="
1724
                               setAdminUserES(
1675
                               setAdminUserES(
1725
-                                record.dialysis_order == null
1726
-                                  ? 0
1727
-                                  : record.dialysis_order.finish_nurse
1676
+                                record.dialysis_order,
1677
+                                'finish_nurse'
1728
                               ) == ''
1678
                               ) == ''
1729
                             "
1679
                             "
1730
                             >{{
1680
                             >{{
1731
                               getAdminUser(
1681
                               getAdminUser(
1732
-                                record.dialysis_order == null
1733
-                                  ? 0
1734
-                                  : record.dialysis_order.finish_nurse
1682
+                                record.dialysis_order,
1683
+                                "finish_nurse"
1735
                               )
1684
                               )
1685
+                                ? getAdminUser(
1686
+                                    record.dialysis_order,
1687
+                                    "finish_nurse"
1688
+                                  )
1689
+                                : "/"
1736
                             }}</span
1690
                             }}</span
1737
                           >
1691
                           >
1738
                           <img
1692
                           <img
1739
-                            style="height:20px;"
1693
+                            class="es-img"
1740
                             :src="
1694
                             :src="
1741
                               setAdminUserES(
1695
                               setAdminUserES(
1742
-                                record.dialysis_order == null
1743
-                                  ? 0
1744
-                                  : record.dialysis_order.finish_nurse
1696
+                                record.dialysis_order,
1697
+                                'finish_nurse'
1745
                               )
1698
                               )
1746
                             "
1699
                             "
1747
                             alt=""
1700
                             alt=""
1748
                             srcset=""
1701
                             srcset=""
1749
                             v-else
1702
                             v-else
1703
+                            style="height: 40px;"
1750
                           />
1704
                           />
1751
                         </div>
1705
                         </div>
1752
                       </div>
1706
                       </div>
1765
                             <span
1719
                             <span
1766
                               v-if="
1720
                               v-if="
1767
                                 setAdminUserES(
1721
                                 setAdminUserES(
1768
-                                  record.prescription.prescription_doctor
1722
+                                  record.prescription,
1723
+                                  'prescription_doctor'
1769
                                 ) == ''
1724
                                 ) == ''
1770
                               "
1725
                               "
1771
                               >{{
1726
                               >{{
1772
                                 getAdminUser(
1727
                                 getAdminUser(
1773
-                                  record.prescription.prescription_doctor
1728
+                                  record.prescription,
1729
+                                  "prescription_doctor"
1774
                                 )
1730
                                 )
1775
                               }}</span
1731
                               }}</span
1776
                             >
1732
                             >
1777
                             <img
1733
                             <img
1778
-                              style="height:20px;"
1734
+                              class="es-img"
1779
                               :src="
1735
                               :src="
1780
                                 setAdminUserES(
1736
                                 setAdminUserES(
1781
-                                  record.prescription.prescription_doctor
1737
+                                  record.prescription,
1738
+                                  'prescription_doctor'
1782
                                 )
1739
                                 )
1783
                               "
1740
                               "
1784
                               alt=""
1741
                               alt=""
1785
                               srcset=""
1742
                               srcset=""
1786
                               v-else
1743
                               v-else
1744
+                              style="height: 40px;"
1787
                             />
1745
                             />
1788
                           </template>
1746
                           </template>
1789
                         </div>
1747
                         </div>
1876
     this.precaution_arr = getDataConfig("hemodialysis", "precaution");
1834
     this.precaution_arr = getDataConfig("hemodialysis", "precaution");
1877
     this.intake_arr = getDataConfig("hemodialysis", "intake");
1835
     this.intake_arr = getDataConfig("hemodialysis", "intake");
1878
     this.nutrition_arr = getDataConfig("hemodialysis", "nutrition");
1836
     this.nutrition_arr = getDataConfig("hemodialysis", "nutrition");
1879
-
1880
-    console.log("触发模板6");
1881
     var xtuser = this.$store.getters.xt_user;
1837
     var xtuser = this.$store.getters.xt_user;
1882
-    console.log("xtuser", xtuser);
1883
     this.orgname = xtuser.org.org_name;
1838
     this.orgname = xtuser.org.org_name;
1884
     //   this.orgname = "遂溪方济医院";
1839
     //   this.orgname = "遂溪方济医院";
1885
     this.modeOptions = this.$store.getters.treatment_mode;
1840
     this.modeOptions = this.$store.getters.treatment_mode;
1930
         var resp = rs.data;
1885
         var resp = rs.data;
1931
         if (resp.state == 1) {
1886
         if (resp.state == 1) {
1932
           this.records = this.records.concat(resp.data.schedules);
1887
           this.records = this.records.concat(resp.data.schedules);
1933
-          console.log("this", this.records);
1888
+          console.log("记录", this.records);
1889
+
1934
           for (const recordIndex in this.records) {
1890
           for (const recordIndex in this.records) {
1935
-            this.advice_groups = [];
1936
-            this.advice_groups_2 = [];
1937
             var dlegh = 0;
1891
             var dlegh = 0;
1938
-            if (
1939
-              (this.records[recordIndex].assessment_before_dislysis &&
1940
-                this.records[recordIndex].assessment_before_dislysis
1941
-                  .systolic_blood_pressure != 0 &&
1942
-                this.records[recordIndex].assessment_before_dislysis
1943
-                  .diastolic_blood_pressure != 0) ||
1944
-              (this.records[recordIndex].assessment_before_dislysis &&
1945
-                this.records[recordIndex].assessment_before_dislysis.remark
1946
-                  .length > 0) ||
1947
-              (this.records[recordIndex].assessment_before_dislysis &&
1948
-                this.records[recordIndex].assessment_before_dislysis
1949
-                  .pulse_frequency != 0) ||
1950
-              (this.records[recordIndex].assessment_before_dislysis &&
1951
-                this.records[recordIndex].assessment_before_dislysis
1952
-                  .breathing_rate != 0) ||
1953
-              (this.records[recordIndex].assessment_before_dislysis &&
1954
-                this.records[recordIndex].assessment_before_dislysis
1955
-                  .temperature != 0)
1956
-            ) {
1957
-              var nl = 6;
1958
-              this.records[recordIndex].print_length = 8;
1959
-              if (this.records[recordIndex].length > 8) {
1960
-                this.records[recordIndex].classname = "margin-bottom-900";
1961
-              } else {
1962
-                this.records[recordIndex].classname = "margin-bottom-300";
1963
-              }
1964
-            } else {
1965
-              var nl = 6;
1966
-              this.records[recordIndex].print_length = 9;
1967
-              if (this.records[recordIndex].length > 9) {
1968
-                this.records[recordIndex].classname = "margin-bottom-900";
1969
-              } else {
1970
-                this.records[recordIndex].classname = "margin-bottom-300";
1971
-              }
1972
-            }
1973
-            if (
1974
-              this.records[recordIndex].assessment_before_dislysis &&
1975
-              this.records[recordIndex].assessment_before_dislysis
1976
-                .blood_access_part_opera_id
1977
-            ) {
1978
-              this.records[
1979
-                recordIndex
1980
-              ].assessment_before_dislysis.blood_access_part_opera_name = this.bloodAccessParOperaName(
1981
-                this.records[recordIndex].assessment_before_dislysis
1982
-                  .blood_access_part_opera_id
1983
-              );
1984
-            }
1985
-
1986
-            if (recordIndex == this.records.length - 1) {
1987
-              this.records[recordIndex].classname = " ";
1988
-            }
1989
-
1990
-            this.records[recordIndex].monitor_records2 = [];
1991
             if (
1892
             if (
1992
               this.records[recordIndex].monitor_records &&
1893
               this.records[recordIndex].monitor_records &&
1993
-              this.records[recordIndex].monitor_records.length < 7
1894
+              this.records[recordIndex].monitor_records.length < 8
1994
             ) {
1895
             ) {
1995
-              dlegh = nl - this.records[recordIndex].monitor_records.length;
1996
-            }
1997
-            if (this.records[recordIndex].monitor_records.length <= 0) {
1998
-              dlegh = nl;
1896
+              dlegh = 8 - this.records[recordIndex].monitor_records.length;
1897
+            } else {
1898
+              dlegh = 0;
1999
             }
1899
             }
2000
             if (dlegh > 0) {
1900
             if (dlegh > 0) {
2001
               if (
1901
               if (
2006
                 this.records[recordIndex].monitor_records = [];
1906
                 this.records[recordIndex].monitor_records = [];
2007
               }
1907
               }
2008
               for (let index = 0; index < dlegh; index++) {
1908
               for (let index = 0; index < dlegh; index++) {
2009
-                this.records[recordIndex].monitor_records2.push([]);
1909
+                this.records[recordIndex].monitor_records.push([]);
2010
               }
1910
               }
2011
             }
1911
             }
2012
 
1912
 
2013
-            var tempmonitorflag = true;
2014
-            for (
2015
-              let index = 0;
2016
-              index < this.records[recordIndex].monitor_records.length;
2017
-              index++
2018
-            ) {
2019
-              const monitor = this.records[recordIndex].monitor_records[index];
2020
-              this.records[recordIndex].monitor_records[index].end = "";
2021
-              if (Object.keys(monitor).length > 0 && index > 1) {
2022
-                if (
2023
-                  monitor.operate_time ==
2024
-                  this.records[recordIndex].dialysis_order.end_time
2025
-                ) {
2026
-                  this.records[recordIndex].monitor_records[index].end =
2027
-                    "【结束透析】";
2028
-                  tempmonitorflag = false;
2029
-                }
2030
-                if (
2031
-                  tempmonitorflag &&
2032
-                  index == this.records[recordIndex].monitor_records.length - 1
2033
-                ) {
2034
-                  this.records[recordIndex].monitor_records[index].end =
2035
-                    "【结束透析】";
2036
-                }
2037
-              }
1913
+            this.records[recordIndex].isShowZero = false;
1914
+            if (this.records[recordIndex].patient.user_org_id == 9535) {
1915
+              this.records[recordIndex].isShowZero = true;
2038
             }
1916
             }
2039
 
1917
 
2040
-            this.monitor_records = this.records[recordIndex].monitor_records;
2041
-
2042
-            // this.records[recordIndex].monitor_records2 = []
2043
-            // if (this.records[recordIndex].monitor_records.length > 13){
2044
-            //   const tempMonitors = []
2045
-            //   const tempMonitors2 = []
1918
+            var delghTwo = 0;
1919
+            if (
1920
+              this.records[recordIndex].advices &&
1921
+              this.records[recordIndex].advices.length < 14
1922
+            ) {
1923
+              delghTwo = 14 - this.records[recordIndex].advices.length;
1924
+            } else {
1925
+              delghTwo = 0;
1926
+            }
2046
 
1927
 
2047
-            //   for (let index = 0; index < this.records[recordIndex].monitor_records.length; index++) {
2048
-            //     if (index < 13) {
2049
-            //       tempMonitors.push(this.records[recordIndex].monitor_records[index])
2050
-            //     } else {
2051
-            //       tempMonitors2.push(this.records[recordIndex].monitor_records[index])
2052
-            //     }
2053
-            //   }
2054
-            // this.records[recordIndex].monitor_records = tempMonitors
2055
-            // this.records[recordIndex].monitor_records2 = tempMonitors2
2056
-            // }
1928
+            if (delghTwo > 0) {
1929
+              if (
1930
+                typeof this.records[recordIndex].advices === "undefined" ||
1931
+                this.records[recordIndex].advices == null
1932
+              ) {
1933
+                this.records[recordIndex].advices = [];
1934
+              }
1935
+              for (let index = 0; index < delghTwo; index++) {
1936
+                this.records[recordIndex].advices.push([]);
1937
+              }
1938
+            }
2057
 
1939
 
2058
             var childMap = {};
1940
             var childMap = {};
2059
             for (const index in this.records[recordIndex].advices) {
1941
             for (const index in this.records[recordIndex].advices) {
2088
               advices.push(item);
1970
               advices.push(item);
2089
             }
1971
             }
2090
 
1972
 
2091
-            this.doctor_advices =
2092
-              this.records[recordIndex].advices == null
2093
-                ? []
2094
-                : this.records[recordIndex].advices;
2095
-            for (let index = 0; index < this.doctor_advices.length; index++) {
2096
-              this.doctor_advices[index]["isShow"] = 2;
2097
-            }
2098
-
2099
-            // if (this.doctor_advices.length > 0) {
2100
-            //   var group = this.newAdviceGroupObject()
2101
-            //   var initGroupBlock = function(group, advice) {
2102
-            //     group.group_no = advice.groupno
2103
-            //   }
2104
-            //   for (let index = this.doctor_advices.length - 1; index >= 0; index--) {
2105
-            //     var new_advice_index = 0
2106
-            //     if ('children' in this.doctor_advices[index] && this.doctor_advices[index].children.length > 0) {
2107
-            //       new_advice_index = index + this.doctor_advices[index].children.length + 1
2108
-
2109
-            //       var doctor_advice = {
2110
-            //         delivery_way: this.doctor_advices[index].delivery_way,
2111
-            //         execution_frequency: this.doctor_advices[index].execution_frequency,
2112
-            //         groupno: this.doctor_advices[index].groupno,
2113
-            //         id: this.doctor_advices[index].id,
2114
-            //         parent_id: this.doctor_advices[index].parent_id,
2115
-            //         children: this.doctor_advices[index].children,
2116
-            //         remark: this.doctor_advices[index].remark,
2117
-            //         execution_staff: this.doctor_advices[index].execution_staff,
2118
-            //         checker: this.doctor_advices[index].checker,
2119
-            //         advice_doctor: this.doctor_advices[index].advice_doctor,
2120
-            //         execution_time: this.doctor_advices[index].execution_time,
2121
-
2122
-            //       }
2123
-            //       doctor_advice['isShow'] = 1
2124
-            //       this.doctor_advices.splice(new_advice_index, 0, doctor_advice)
2125
-            //     }
2126
-            //   }
2127
-
2128
-            //   var templength = 0
2129
-            //   if (this.doctor_advices.length > 12) {
2130
-            //     templength = 12
2131
-            //   } else {
2132
-            //     templength = this.doctor_advices.length
2133
-            //   }
2134
-
2135
-            //   for (let index = 0; index < templength; index++) {
2136
-            //     const advice = this.doctor_advices[index]
2137
-            //     if (advice.groupno == 0) {
2138
-            //       // 老版本的医嘱没有分组的概念,所以这一个 if 是解决这个问题的,将每个无分组的医嘱各自归为一组
2139
-            //       if (advice.parent_id > 0) {
2140
-            //         if (this.advice_groups.length > 0) {
2141
-            //           var parent_group = this.advice_groups[
2142
-            //             this.advice_groups.length - 1
2143
-            //           ]
2144
-            //           if (parent_group.advices.length > 0) {
2145
-            //             if (parent_group.advices[0].id == advice.parent_id) {
2146
-            //               parent_group.advices.push(advice)
2147
-            //             }
2148
-            //           }
2149
-            //         }
2150
-            //         continue
2151
-            //       } else {
2152
-            //         if (group.group_no > 0) {
2153
-            //           this.advice_groups.push(group)
2154
-            //           group = this.newAdviceGroupObject()
2155
-            //         }
2156
-
2157
-            //         initGroupBlock(group, advice)
2158
-            //         group.advices.push(advice)
2159
-            //         this.advice_groups.push(group)
2160
-            //         group = this.newAdviceGroupObject()
2161
-            //         continue
2162
-            //       }
2163
-            //     }
2164
-
2165
-            //     if (group.group_no > 0 && group.group_no != advice.groupno) {
2166
-            //       this.advice_groups.push(group)
2167
-            //       group = this.newAdviceGroupObject()
2168
-            //     }
2169
-            //     if (group.group_no == 0) {
2170
-            //       initGroupBlock(group, advice)
2171
-            //     }
2172
-            //     if (group.group_no == advice.groupno) {
2173
-            //       group.advices.push(advice)
2174
-            //     }
2175
-            //     if (index == 11) {
2176
-            //       this.advice_groups.push(group)
2177
-            //       group = this.newAdviceGroupObject()
2178
-            //     }
2179
-            //   }
2180
-
2181
-            //   if (this.doctor_advices.length > 12) {
2182
-            //     for (let index = 12; index < this.doctor_advices.length; index++) {
2183
-            //       const advice = this.doctor_advices[index]
2184
-            //       if (advice.groupno == 0) {
2185
-            //         // 老版本的医嘱没有分组的概念,所以这一个 if 是解决这个问题的,将每个无分组的医嘱各自归为一组
2186
-            //         if (advice.parent_id > 0) {
2187
-            //           if (this.advice_groups_2.length > 0) {
2188
-            //             var parent_group = this.advice_groups_2[
2189
-            //               this.advice_groups_2.length - 1
2190
-            //             ]
2191
-            //             if (parent_group.advices.length > 0) {
2192
-            //               if (parent_group.advices[0].id == advice.parent_id) {
2193
-            //                 parent_group.advices.push(advice)
2194
-            //               }
2195
-            //             }
2196
-            //           }
2197
-            //           continue
2198
-            //         } else {
2199
-            //           if (group.group_no > 0) {
2200
-            //             this.advice_groups_2.push(group)
2201
-            //             group = this.newAdviceGroupObject()
2202
-            //           }
2203
-
2204
-            //           initGroupBlock(group, advice)
2205
-            //           group.advices.push(advice)
2206
-            //           this.advice_groups_2.push(group)
2207
-            //           group = this.newAdviceGroupObject()
2208
-            //           continue
2209
-            //         }
2210
-            //       }
2211
-
2212
-            //       if (group.group_no > 0 && group.group_no != advice.groupno) {
2213
-            //         this.advice_groups_2.push(group)
2214
-            //         group = this.newAdviceGroupObject()
2215
-            //       }
2216
-            //       if (group.group_no == 0) {
2217
-            //         initGroupBlock(group, advice)
2218
-            //       }
2219
-            //       if (group.group_no == advice.groupno) {
2220
-            //         group.advices.push(advice)
2221
-            //       }
2222
-            //     }
2223
-            //   }
2224
-
2225
-            //   if (group.group_no > 0) {
2226
-            //     // 上述的算法会导致最后一组没有加到advice_groups,这里要手动加上
2227
-            //     if (this.doctor_advices.length > 12) {
2228
-            //       this.advice_groups_2.push(group)
2229
-            //     } else {
2230
-            //       this.advice_groups.push(group)
2231
-            //     }
2232
-            //   }
2233
-            // }
2234
-
2235
-            if (this.doctor_advices.length <= 6) {
2236
-              var nl = 6;
2237
-              this.print_length = 6;
1973
+            var leftAdvice = [];
1974
+            var rightAdvice = [];
1975
+            var adlen = advices.length;
2238
 
1976
 
1977
+            var halfLen = adlen % 2 == 0 ? adlen / 2 : (adlen + 1) / 2;
1978
+            for (var i = 0; i < halfLen; i++) {
1979
+              leftAdvice.push(advices[i]);
1980
+              var rightIndex = i + halfLen;
1981
+              rightAdvice.push(
1982
+                rightIndex in advices ? advices[i + halfLen] : []
1983
+              );
1984
+            }
1985
+            if (halfLen < 5) {
1986
+              var nl = 5 - leftAdvice.length;
1987
+              for (let index = 0; index < nl; index++) {
1988
+                leftAdvice.push([]);
1989
+              }
1990
+              var nl = 5 - rightAdvice.length;
2239
               for (let index = 0; index < nl; index++) {
1991
               for (let index = 0; index < nl; index++) {
2240
-                if (
2241
-                  this.doctor_advices[index] == undefined ||
2242
-                  this.doctor_advices[index].length <= 0
2243
-                ) {
2244
-                  this.doctor_advices.push([]);
2245
-                } else {
2246
-                  continue;
2247
-                }
1992
+                rightAdvice.push([]);
2248
               }
1993
               }
2249
             }
1994
             }
2250
-            this.records[recordIndex].advices = [];
2251
-            this.records[recordIndex].advices2 = [];
2252
-            this.records[recordIndex].advices = this.doctor_advices;
2253
-            this.records[recordIndex].advices2 = this.advice_groups_2;
2254
 
1995
 
2255
-            this.records[recordIndex].totallength =
2256
-              this.doctor_advices.length + this.monitor_records.length;
1996
+            this.records[recordIndex].advices = [];
1997
+            for (var i = 0; i < halfLen; i++) {
1998
+              var item = [];
1999
+              item.push(leftAdvice[i]);
2000
+              item.push(rightAdvice[i]);
2001
+              this.records[recordIndex].advices.push(item);
2002
+            }
2257
           }
2003
           }
2258
 
2004
 
2005
+          console.log(" this.records[recordIndex].advices", this.records);
2259
           this.operators = resp.data.medical_staffs;
2006
           this.operators = resp.data.medical_staffs;
2260
           if (this.operators.length > 0) {
2007
           if (this.operators.length > 0) {
2261
             var operatorsLen = this.operators.length;
2008
             var operatorsLen = this.operators.length;
2267
               );
2014
               );
2268
             }
2015
             }
2269
           }
2016
           }
2270
-
2271
           this.adminUser = resp.data.users;
2017
           this.adminUser = resp.data.users;
2272
           console.log("使用者", this.adminUser);
2018
           console.log("使用者", this.adminUser);
2273
           this.loading = false;
2019
           this.loading = false;
2422
       }
2168
       }
2423
     },
2169
     },
2424
     getAdminUser(key, id) {
2170
     getAdminUser(key, id) {
2171
+      console.log("key", key);
2172
+      console.log("id", id);
2425
       if (
2173
       if (
2426
         typeof key === "undefined" ||
2174
         typeof key === "undefined" ||
2427
         key == null ||
2175
         key == null ||
2429
       ) {
2177
       ) {
2430
         return "";
2178
         return "";
2431
       }
2179
       }
2432
-      if (key[id] == 0) {
2180
+      if (key[id] === 0) {
2433
         return "";
2181
         return "";
2434
       }
2182
       }
2435
-      if (key[id] == undefined) {
2183
+      if (key[id] === undefined) {
2436
         return "";
2184
         return "";
2437
       }
2185
       }
2438
       for (let i = 0; i < this.adminUser.length; i++) {
2186
       for (let i = 0; i < this.adminUser.length; i++) {
2439
-        if (this.adminUser[i].id == key[id]) {
2187
+        if (this.adminUser[i].id === key[id]) {
2440
           return this.adminUser[i].name;
2188
           return this.adminUser[i].name;
2441
         }
2189
         }
2442
       }
2190
       }

+ 3 - 18
src/xt_pages/dialysis/template/DialysisPrintOrderSix.vue 查看文件

988
                             : 0
988
                             : 0
989
                         }}
989
                         }}
990
                       </td>
990
                       </td>
991
-                      <td
992
-                        v-if="
993
-                          (prescription.mode_id == 2 ||
994
-                            prescription.mode_id == 5 ||
995
-                            prescription.mode_id == 12) &&
996
-                            monitor.operate_time > dialysisOrder.end_time
997
-                        "
998
-                        width="50"
999
-                      >
1000
-                        {{
1001
-                          monitor.displacement_quantity
1002
-                            ? monitor.displacement_quantity
1003
-                            : ""
1004
-                        }}
1005
-                      </td>
1006
                       <td
991
                       <td
1007
                         v-if="
992
                         v-if="
1008
                           prescription.mode_id == 2 ||
993
                           prescription.mode_id == 2 ||
1009
                             prescription.mode_id == 5 ||
994
                             prescription.mode_id == 5 ||
1010
                             (prescription.mode_id == 12 &&
995
                             (prescription.mode_id == 12 &&
1011
-                              monitor.operate_time <= dialysisOrder.end_time)
996
+                              monitor.operate_time > dialysisOrder.end_time)
1012
                         "
997
                         "
1013
-                        width="50"
998
+                        style="width:50px"
1014
                       >
999
                       >
1015
                         {{
1000
                         {{
1016
                           monitor.displacement_quantity
1001
                           monitor.displacement_quantity
1017
                             ? monitor.displacement_quantity
1002
                             ? monitor.displacement_quantity
1018
-                            : 0
1003
+                            : ""
1019
                         }}
1004
                         }}
1020
                       </td>
1005
                       </td>
1021
                       <td style="line-height:16px;padding:0px;">
1006
                       <td style="line-height:16px;padding:0px;">