|
@@ -126,10 +126,9 @@
|
126
|
126
|
|
127
|
127
|
<van-tabs v-model="active">
|
128
|
128
|
<van-tab title="我的病人">
|
129
|
|
- <van-index-bar class="indexBar" sticky highlight-color="#fb6463">
|
130
|
|
- <div v-for="(subItem, index) in mypatients" :key="index" :index="index">
|
|
129
|
+ <van-index-bar class="indexBar" sticky highlight-color="#fb6463" >
|
|
130
|
+ <div v-for="(subItem, index) in mypatients" :key="index" :index="index" v-if="$store.getters.user.template_info.org_id!=10721">
|
131
|
131
|
<van-index-anchor :index="index">
|
132
|
|
- <!-- <span class="indexWord">{{ index }}</span> -->
|
133
|
132
|
</van-index-anchor>
|
134
|
133
|
<van-cell
|
135
|
134
|
@click="choosePatient(item)"
|
|
@@ -138,13 +137,20 @@
|
138
|
137
|
:title="item.patient.name"
|
139
|
138
|
/>
|
140
|
139
|
</div>
|
|
140
|
+ <div :key="index" :index="index" v-if="$store.getters.user.template_info.org_id==10721">
|
|
141
|
+ <van-cell
|
|
142
|
+ @click="choosePatient(item)"
|
|
143
|
+ v-for="(item, subIndex) in myPatientsOne"
|
|
144
|
+ :key="subIndex"
|
|
145
|
+ :title="item.patient.name+ '' +'('+ item.device_number.number+')'"
|
|
146
|
+ />
|
|
147
|
+ </div>
|
141
|
148
|
</van-index-bar>
|
142
|
149
|
</van-tab>
|
143
|
150
|
<van-tab title="全部病人">
|
144
|
151
|
<van-index-bar class="indexBar" sticky highlight-color="#fb6463">
|
145
|
|
- <div v-for="(subItem, index) in patients" :key="index" :index="index">
|
|
152
|
+ <div v-for="(subItem, index) in patients" :key="index" :index="index" v-if="$store.getters.user.template_info.org_id!=10721">
|
146
|
153
|
<van-index-anchor :index="index">
|
147
|
|
- <!-- <span class="indexWord">{{ index }}</span> -->
|
148
|
154
|
</van-index-anchor>
|
149
|
155
|
<van-cell
|
150
|
156
|
@click="choosePatient(item)"
|
|
@@ -153,6 +159,16 @@
|
153
|
159
|
:title="item.patient.name"
|
154
|
160
|
/>
|
155
|
161
|
</div>
|
|
162
|
+
|
|
163
|
+ <div v-if="$store.getters.user.template_info.org_id==10721">
|
|
164
|
+
|
|
165
|
+ <van-cell
|
|
166
|
+ @click="choosePatient(item)"
|
|
167
|
+ v-for="(item, subIndex) in newPatient"
|
|
168
|
+ :key="subIndex"
|
|
169
|
+ :title="item.patient.name+ '' +'('+ item.device_number.number+')'"
|
|
170
|
+ />
|
|
171
|
+ </div>
|
156
|
172
|
</van-index-bar>
|
157
|
173
|
</van-tab>
|
158
|
174
|
</van-tabs>
|
|
@@ -272,7 +288,8 @@ export default {
|
272
|
288
|
zoneValue: 0,
|
273
|
289
|
zoneShow: false,
|
274
|
290
|
zoneColumns: [],
|
275
|
|
-
|
|
291
|
+ myPatientsOne:[],
|
|
292
|
+ newPatient:[],
|
276
|
293
|
//
|
277
|
294
|
users: {
|
278
|
295
|
name: '',
|
|
@@ -738,10 +755,10 @@ export default {
|
738
|
755
|
getScheduals (patient) {
|
739
|
756
|
// console.log('222222', this.$store.getters.adminUserArr.adminUserArr)
|
740
|
757
|
if (this.$store.getters.adminUserArr.adminUserArr) {
|
741
|
|
- // console.log('上面')
|
|
758
|
+ console.log('上面')
|
742
|
759
|
this.getAdminUser(patient)
|
743
|
760
|
} else {
|
744
|
|
- // console.log('下面')
|
|
761
|
+ console.log('下面')
|
745
|
762
|
this.dialysisGlobalConfig(patient)
|
746
|
763
|
}
|
747
|
764
|
|
|
@@ -768,10 +785,36 @@ export default {
|
768
|
785
|
}
|
769
|
786
|
})
|
770
|
787
|
}
|
|
788
|
+
|
|
789
|
+
|
|
790
|
+
|
|
791
|
+
|
|
792
|
+
|
|
793
|
+
|
771
|
794
|
let cityNameList = []
|
772
|
795
|
for (let p in zoneNewPatients) {
|
773
|
796
|
cityNameList.push(zoneNewPatients[p])
|
774
|
797
|
}
|
|
798
|
+
|
|
799
|
+ console.log("全部患者-------------------------",cityNameList)
|
|
800
|
+
|
|
801
|
+
|
|
802
|
+ // //解决溪康排序问题
|
|
803
|
+ if(cityNameList!=null && cityNameList.length>0){
|
|
804
|
+ for(let i=0;i<cityNameList.length;i++){
|
|
805
|
+ cityNameList[i].sort = 0
|
|
806
|
+ cityNameList[i].sort = cityNameList[i].device_number.sort
|
|
807
|
+ }
|
|
808
|
+ }
|
|
809
|
+
|
|
810
|
+ this.newPatient = []
|
|
811
|
+ this.newPatient = cityNameList.sort(function (a, b) {
|
|
812
|
+ return a.sort > b.sort
|
|
813
|
+ })
|
|
814
|
+
|
|
815
|
+
|
|
816
|
+
|
|
817
|
+
|
775
|
818
|
let firstName = {}
|
776
|
819
|
this.FirstPin.forEach(item => {
|
777
|
820
|
firstName[item] = []
|
|
@@ -782,6 +825,12 @@ export default {
|
782
|
825
|
}
|
783
|
826
|
})
|
784
|
827
|
this.patients = firstName
|
|
828
|
+
|
|
829
|
+
|
|
830
|
+
|
|
831
|
+
|
|
832
|
+
|
|
833
|
+
|
785
|
834
|
// 判断非空
|
786
|
835
|
let newObj = {}
|
787
|
836
|
Object.keys(this.patients).map((item, index) => {
|
|
@@ -790,6 +839,10 @@ export default {
|
790
|
839
|
}
|
791
|
840
|
})
|
792
|
841
|
this.patients = newObj
|
|
842
|
+
|
|
843
|
+
|
|
844
|
+
|
|
845
|
+
|
793
|
846
|
// console.log('所有的病人', this.patients)
|
794
|
847
|
})
|
795
|
848
|
},
|
|
@@ -856,7 +909,19 @@ export default {
|
856
|
909
|
this.show = false
|
857
|
910
|
},
|
858
|
911
|
getAdminUser (patient) {
|
859
|
|
- // console.log('user---', this.users.user_type)
|
|
912
|
+ // console.log("病人列表-----------------------------------",patient)
|
|
913
|
+
|
|
914
|
+ // if(patient!=null && patient.length>0){
|
|
915
|
+ // for(let i=0;i<patient.length;i++){
|
|
916
|
+ // patient[i].sort= 0
|
|
917
|
+ // patient[i].sort = patient[i].device_number.sort
|
|
918
|
+ // }
|
|
919
|
+ // this.newPatient = patient.sort(function (a, b) {
|
|
920
|
+ // return a.sort > b.sort
|
|
921
|
+ // })
|
|
922
|
+ // }
|
|
923
|
+
|
|
924
|
+ console.log('user---', this.users.user_type)
|
860
|
925
|
if (this.users.user_type == 1 || this.users.user_type == 2) {
|
861
|
926
|
// console.log('触发了吗')
|
862
|
927
|
let arr = []
|
|
@@ -877,7 +942,25 @@ export default {
|
877
|
942
|
zoneArr.push(item)
|
878
|
943
|
}
|
879
|
944
|
})
|
|
945
|
+
|
|
946
|
+ if(zoneArr!=null && zoneArr.length>0){
|
|
947
|
+ for(let i=0;i<zoneArr.length;i++){
|
|
948
|
+ zoneArr[i].sort = 0
|
|
949
|
+ zoneArr[i].sort = zoneArr[i].device_number.sort
|
|
950
|
+ }
|
|
951
|
+ }
|
|
952
|
+
|
|
953
|
+ this.myPatientsOne = []
|
|
954
|
+ this.myPatientsOne = zoneArr.sort(function (a, b) {
|
|
955
|
+ return a.sort > b.sort
|
|
956
|
+ })
|
|
957
|
+
|
|
958
|
+
|
|
959
|
+
|
880
|
960
|
this.searchArr = zoneArr
|
|
961
|
+
|
|
962
|
+
|
|
963
|
+
|
881
|
964
|
let cityNameList = []
|
882
|
965
|
for (let p in zoneArr) {
|
883
|
966
|
cityNameList.push(zoneArr[p])
|
|
@@ -891,6 +974,8 @@ export default {
|
891
|
974
|
firstName[item].push(el)
|
892
|
975
|
}
|
893
|
976
|
})
|
|
977
|
+
|
|
978
|
+
|
894
|
979
|
this.mypatients = firstName
|
895
|
980
|
// 判断非空
|
896
|
981
|
let newObj = {}
|
|
@@ -905,8 +990,7 @@ export default {
|
905
|
990
|
} else if (this.users.user_type == 3) {
|
906
|
991
|
let arr = []
|
907
|
992
|
let zoneArr = []
|
908
|
|
- console.log('武警机构ID', this.$store.getters.user.template_info.org_id)
|
909
|
|
- console.log('9999999', patient)
|
|
993
|
+
|
910
|
994
|
|
911
|
995
|
if (this.$store.getters.user.template_info.org_id == 10340) {
|
912
|
996
|
patient.map((item, index) => {
|
|
@@ -924,7 +1008,7 @@ export default {
|
924
|
1008
|
}
|
925
|
1009
|
}
|
926
|
1010
|
})
|
927
|
|
- console.log('arr0------------------', arr)
|
|
1011
|
+
|
928
|
1012
|
} else {
|
929
|
1013
|
patient.map((item, index) => {
|
930
|
1014
|
if (item.dialysis_order != null && item.dialysis_order.start_nurse == this.users.id) {
|
|
@@ -937,6 +1021,8 @@ export default {
|
937
|
1021
|
})
|
938
|
1022
|
}
|
939
|
1023
|
|
|
1024
|
+
|
|
1025
|
+
|
940
|
1026
|
arr.map(item => {
|
941
|
1027
|
if (item.device_number.zone_id == this.zoneValue) {
|
942
|
1028
|
zoneArr.push(item)
|
|
@@ -944,11 +1030,32 @@ export default {
|
944
|
1030
|
zoneArr.push(item)
|
945
|
1031
|
}
|
946
|
1032
|
})
|
947
|
|
- // console.log('arr', arr)
|
|
1033
|
+
|
|
1034
|
+ console.log("zoneArr---------------------",zoneArr)
|
|
1035
|
+
|
|
1036
|
+
|
|
1037
|
+ // //解决溪康排序问题 我的病人列表
|
|
1038
|
+ if(zoneArr!=null && zoneArr.length>0){
|
|
1039
|
+ for(let i=0;i<zoneArr.length;i++){
|
|
1040
|
+ zoneArr[i].sort = 0
|
|
1041
|
+ zoneArr[i].sort = zoneArr[i].device_number.sort
|
|
1042
|
+ }
|
|
1043
|
+ }
|
|
1044
|
+
|
|
1045
|
+ this.myPatientsOne = []
|
|
1046
|
+ this.myPatientsOne = zoneArr.sort(function (a, b) {
|
|
1047
|
+ return a.sort > b.sort
|
|
1048
|
+ })
|
|
1049
|
+
|
|
1050
|
+
|
|
1051
|
+
|
948
|
1052
|
let cityNameList = []
|
949
|
1053
|
for (let p in zoneArr) {
|
950
|
1054
|
cityNameList.push(zoneArr[p])
|
951
|
1055
|
}
|
|
1056
|
+
|
|
1057
|
+
|
|
1058
|
+
|
952
|
1059
|
let firstName = {}
|
953
|
1060
|
this.FirstPin.forEach(item => {
|
954
|
1061
|
firstName[item] = []
|
|
@@ -958,6 +1065,7 @@ export default {
|
958
|
1065
|
firstName[item].push(el)
|
959
|
1066
|
}
|
960
|
1067
|
})
|
|
1068
|
+
|
961
|
1069
|
this.mypatients = firstName
|
962
|
1070
|
// 判断非空
|
963
|
1071
|
let newObj = {}
|
|
@@ -969,6 +1077,8 @@ export default {
|
969
|
1077
|
this.mypatients = newObj
|
970
|
1078
|
})
|
971
|
1079
|
console.log('我的病人', this.mypatients)
|
|
1080
|
+
|
|
1081
|
+
|
972
|
1082
|
}
|
973
|
1083
|
},
|
974
|
1084
|
dialysisGlobalConfig (patient) {
|
|
@@ -996,11 +1106,40 @@ export default {
|
996
|
1106
|
zoneArr.push(item)
|
997
|
1107
|
}
|
998
|
1108
|
})
|
|
1109
|
+ // //解决溪康排序问题 我的病人列表
|
|
1110
|
+ if(zoneArr!=null && zoneArr.length>0){
|
|
1111
|
+ for(let i=0;i<zoneArr.length;i++){
|
|
1112
|
+ zoneArr[i].sort = 0
|
|
1113
|
+ zoneArr[i].sort = zoneArr[i].device_number.sort
|
|
1114
|
+ }
|
|
1115
|
+ }
|
|
1116
|
+
|
|
1117
|
+ this.myPatientsOne = []
|
|
1118
|
+ this.myPatientsOne = zoneArr.sort(function (a, b) {
|
|
1119
|
+ return a.sort > b.sort
|
|
1120
|
+ })
|
|
1121
|
+
|
999
|
1122
|
this.searchArr = zoneArr
|
|
1123
|
+
|
1000
|
1124
|
let cityNameList = []
|
1001
|
1125
|
for (let p in zoneArr) {
|
1002
|
1126
|
cityNameList.push(zoneArr[p])
|
1003
|
1127
|
}
|
|
1128
|
+
|
|
1129
|
+
|
|
1130
|
+ if(cityNameList!=null && cityNameList.length>0){
|
|
1131
|
+ for(let i=0;i<cityNameList.length;i++){
|
|
1132
|
+ cityNameList[i].sort = 0
|
|
1133
|
+ cityNameList[i].sort = cityNameList[i].device_number.sort
|
|
1134
|
+ }
|
|
1135
|
+ }
|
|
1136
|
+
|
|
1137
|
+ this.newPatient = []
|
|
1138
|
+ this.newPatient = cityNameList.sort(function (a, b) {
|
|
1139
|
+ return a.sort > b.sort
|
|
1140
|
+ })
|
|
1141
|
+
|
|
1142
|
+
|
1004
|
1143
|
let firstName = {}
|
1005
|
1144
|
this.FirstPin.forEach(item => {
|
1006
|
1145
|
firstName[item] = []
|
|
@@ -1040,11 +1179,46 @@ export default {
|
1040
|
1179
|
zoneArr.push(item)
|
1041
|
1180
|
}
|
1042
|
1181
|
})
|
|
1182
|
+
|
|
1183
|
+
|
|
1184
|
+ // //解决溪康排序问题 我的病人列表
|
|
1185
|
+ if(zoneArr!=null && zoneArr.length>0){
|
|
1186
|
+ for(let i=0;i<zoneArr.length;i++){
|
|
1187
|
+ zoneArr[i].sort = 0
|
|
1188
|
+ zoneArr[i].sort = zoneArr[i].device_number.sort
|
|
1189
|
+ }
|
|
1190
|
+ }
|
|
1191
|
+
|
|
1192
|
+ this.myPatientsOne = []
|
|
1193
|
+ this.myPatientsOne = zoneArr.sort(function (a, b) {
|
|
1194
|
+ return a.sort > b.sort
|
|
1195
|
+ })
|
|
1196
|
+
|
|
1197
|
+
|
|
1198
|
+
|
1043
|
1199
|
// console.log('arr', arr)
|
1044
|
1200
|
let cityNameList = []
|
1045
|
1201
|
for (let p in zoneArr) {
|
1046
|
1202
|
cityNameList.push(zoneArr[p])
|
1047
|
1203
|
}
|
|
1204
|
+
|
|
1205
|
+
|
|
1206
|
+ if(cityNameList!=null && cityNameList.length>0){
|
|
1207
|
+ for(let i=0;i<cityNameList.length;i++){
|
|
1208
|
+ cityNameList[i].sort = 0
|
|
1209
|
+ cityNameList[i].sort = cityNameList[i].device_number.sort
|
|
1210
|
+ }
|
|
1211
|
+ }
|
|
1212
|
+
|
|
1213
|
+ this.newPatient = []
|
|
1214
|
+ this.newPatient = cityNameList.sort(function (a, b) {
|
|
1215
|
+ return a.sort > b.sort
|
|
1216
|
+ })
|
|
1217
|
+
|
|
1218
|
+
|
|
1219
|
+
|
|
1220
|
+
|
|
1221
|
+
|
1048
|
1222
|
let firstName = {}
|
1049
|
1223
|
this.FirstPin.forEach(item => {
|
1050
|
1224
|
firstName[item] = []
|