Przeglądaj źródła

Merge branch 'master' of http://git.shengws.com/csx/Pad_New

csx 4 lat temu
rodzic
commit
372e47e1a1
34 zmienionych plików z 7883 dodań i 2742 usunięć
  1. 1 1
      .gitignore
  2. 3 3
      .postcssrc.js
  3. 9 24
      src/api/login.js
  4. 70 0
      src/api/patient/patient.js
  5. BIN
      src/assets/images/myIcon9.png
  6. BIN
      src/assets/images/mydefault.png
  7. 2 1
      src/kya_pages/homeIndex/index.vue
  8. 6 2
      src/main.js
  9. 1 1
      src/pages/allCourseManagement/index.vue
  10. 76 11
      src/pages/allDoctorAdvice/index.vue
  11. 24 17
      src/pages/configureCenter/components/Bed.vue
  12. 18 6
      src/pages/configureCenter/components/Grouping.vue
  13. 17 6
      src/pages/configureCenter/components/Partition.vue
  14. 2 2
      src/pages/configureCenter/index.vue
  15. 1 1
      src/pages/configureCenter/newPartition.vue
  16. 10 5
      src/pages/console/managementConsole/staff_role/employeeList/index.vue
  17. 217 160
      src/pages/doctorAdvice/components/DoctorManagement.vue
  18. 1 3
      src/pages/doctorAdvice/index.vue
  19. 6 6
      src/pages/home/index.vue
  20. 51 33
      src/pages/home/login.vue
  21. 13 9
      src/pages/homeIndex/index.vue
  22. 4 1
      src/pages/main/RecordPage.vue
  23. 1 1
      src/pages/main/add_urgent_schedule.vue
  24. 476 471
      src/pages/main/dialog/MonitDialog.vue
  25. 1755 1492
      src/pages/main/dialog/PrescriptionDialog.vue
  26. 2 5
      src/pages/main/today/dialysisMonitoring.vue
  27. 313 270
      src/pages/main/today/dialysisPrescription.vue
  28. 52 28
      src/pages/my/index.vue
  29. 46 4
      src/pages/my/modifyingName.vue
  30. 23 13
      src/pages/my/myInfo.vue
  31. 12 1
      src/pages/my/organizationInfo.vue
  32. 4503 0
      src/pages/patientCenter/editOrg/index.vue
  33. 151 150
      src/router/index.js
  34. 17 15
      src/utils/request.js

+ 1 - 1
.gitignore Wyświetl plik

@@ -16,4 +16,4 @@ selenium-debug.log
16 16
 *.njsproj
17 17
 *.sln
18 18
 .svn
19
-.dist
19
+.dist

+ 3 - 3
.postcssrc.js Wyświetl plik

@@ -1,10 +1,10 @@
1 1
 // https://github.com/michael-ciniawsky/postcss-load-config
2 2
 
3 3
 module.exports = {
4
-  "plugins": {
4
+  plugins: {
5 5
     "postcss-import": {},
6 6
     "postcss-url": {},
7 7
     // to edit target browsers: use "browserslist" field in package.json
8
-    "autoprefixer": {}
8
+    autoprefixer: {}
9 9
   }
10
-}
10
+};

+ 9 - 24
src/api/login.js Wyświetl plik

@@ -15,53 +15,46 @@ export function loginByPwd(mobile, password) {
15 15
 export function isLogin() {
16 16
   return request({
17 17
     url: '/m/api/islogin',
18
-    method: 'get',
18
+    method: 'get'
19 19
   })
20 20
 }
21 21
 
22
-
23
-
24 22
 export function getCodeInit() {
25 23
   return request({
26 24
     url: '/m/api/code',
27
-    method: 'get',
25
+    method: 'get'
28 26
   })
29 27
 }
30 28
 
31
-
32 29
 export function getVerifyCode(params) {
33 30
   return request({
34 31
     url: '/m/api/getcode',
35 32
     method: 'get',
36
-    params:params,
33
+    params: params
37 34
   })
38 35
 }
39 36
 
40
-
41 37
 export function loginByCode(params) {
42 38
   return request({
43 39
     url: '/m/api/login/cs',
44 40
     method: 'post',
45
-    params:params,
41
+    params: params
46 42
   })
47 43
 }
48 44
 
49
-
50
-
51 45
 export function forgetPassWord(params) {
52 46
   return request({
53 47
     url: '/m/api/password/commit',
54 48
     method: 'post',
55
-    params:params,
49
+    params: params
56 50
   })
57 51
 }
58 52
 
59
-
60 53
 export function register(params) {
61 54
   return request({
62 55
     url: '/m/api/register/commit',
63 56
     method: 'post',
64
-    params:params,
57
+    params: params
65 58
   })
66 59
 }
67 60
 
@@ -69,29 +62,21 @@ export function setName(params) {
69 62
   return request({
70 63
     url: '/m/api/register/setname',
71 64
     method: 'post',
72
-    params:params,
65
+    params: params
73 66
   })
74 67
 }
75 68
 
76
-
77
-
78
-
79 69
 export function login() {
80 70
   return request({
81 71
     url: '/m/api/register/login',
82
-    method: 'post',
72
+    method: 'post'
83 73
   })
84 74
 }
85 75
 
86
-
87
-
88
-
89
-
90
-
91 76
 export function createOrg(params) {
92 77
   return request({
93 78
     url: '/m/api/org/create',
94 79
     method: 'post',
95
-    params:params,
80
+    params: params
96 81
   })
97 82
 }

+ 70 - 0
src/api/patient/patient.js Wyświetl plik

@@ -723,3 +723,73 @@ export function getBloodPatient(params) {
723 723
     params: params
724 724
   })
725 725
 }
726
+
727
+export function DeletePatient(id, params) {
728
+  console.log('医嘱id', id)
729
+  return request({
730
+    url: '/m/api/patient/deletePatient?id=' + id,
731
+    method: 'delete',
732
+    params: params
733
+  })
734
+}
735
+
736
+export function saveName(id, name) {
737
+  const params = {
738
+    id: id,
739
+    name: name
740
+  }
741
+  console.log('params', params)
742
+  return request({
743
+    url: '/m/api/patient/savename',
744
+    method: 'get',
745
+    params: params
746
+  })
747
+}
748
+
749
+export function getAllOrganization(id, params) {
750
+  return request({
751
+    url: '/m/api/patient/getallorganization?id=' + id,
752
+    method: 'get',
753
+    params: params
754
+  })
755
+}
756
+
757
+export function getMyOrganazition(id, params) {
758
+  return request({
759
+    url: '/m/api/patient/getmyorganazition?id=' + id,
760
+    method: 'get',
761
+    params: params
762
+  })
763
+}
764
+
765
+export function getOrgInformation(params) {
766
+  return request({
767
+    url: '/m/api/org/getorginformation',
768
+    method: 'get',
769
+    params: params
770
+  })
771
+}
772
+
773
+export function getAllOrgType(params) {
774
+  return request({
775
+    url: '/m/api/patient/getallorgtype',
776
+    method: 'get',
777
+    params: params
778
+  })
779
+}
780
+
781
+export function updateOrg(params, id) {
782
+  return request({
783
+    url: '/m/api/patient/editorg?id=' + id,
784
+    method: 'get',
785
+    params: params
786
+  })
787
+}
788
+
789
+export function getMyInforName(id, params) {
790
+  return request({
791
+    url: '/m/api/patient/getmyinforname?id=' + id,
792
+    method: 'get',
793
+    params: params
794
+  })
795
+}

BIN
src/assets/images/myIcon9.png Wyświetl plik


BIN
src/assets/images/mydefault.png Wyświetl plik


+ 2 - 1
src/kya_pages/homeIndex/index.vue Wyświetl plik

@@ -258,4 +258,5 @@ export default {
258 258
   }
259 259
 }
260 260
 </style>
261
-<style lang="scss"></style>
261
+<style lang="scss">
262
+</style>

+ 6 - 2
src/main.js Wyświetl plik

@@ -55,7 +55,9 @@ import {
55 55
   Switch,
56 56
   Uploader,
57 57
   Radio,
58
-  RadioGroup
58
+  RadioGroup,
59
+  Overlay,
60
+  Loading
59 61
   // eslint-disable-next-line no-irregular-whitespace,import/no-duplicates
60 62
 } from "vant";
61 63
 Vue.use(DropdownMenu)
@@ -90,7 +92,9 @@ Vue.use(DropdownMenu)
90 92
   .use(Switch)
91 93
   .use(Uploader)
92 94
   .use(RadioGroup)
93
-  .use(Radio);
95
+  .use(Radio)
96
+  .use(Overlay)
97
+  .use(Loading);
94 98
 // import "@/lib/flexible.js";
95 99
 
96 100
 // main.js

+ 1 - 1
src/pages/allCourseManagement/index.vue Wyświetl plik

@@ -2,7 +2,7 @@
2 2
   <div class="page_allCourse">
3 3
     <van-sticky>
4 4
       <div class="allCourseTitle">
5
-        <i class="iconfont icon-zuojiantou jiantou" @click="toReturn"></i>
5
+        <i class="iconfont icon-zuojiantou jiantou" @click="$router.go(-1)"></i>
6 6
         <span class="titleName">{{ couseDetail.name }}的病程记录</span>
7 7
       </div>
8 8
     </van-sticky>

+ 76 - 11
src/pages/allDoctorAdvice/index.vue Wyświetl plik

@@ -36,12 +36,12 @@
36 36
                    <van-icon
37 37
                   class="ellipsis"
38 38
                   name="ellipsis"
39
-                  @click="newShow = true"
39
+                  @click="toDelete(it.id,it.execution_state,i)"
40 40
                 />
41 41
                 </div>
42 42
                 <div v-for="(i, index) in childList" :key="index">
43
-                 <div style="display:flex;justify-content:space-between">
44
-                    <p v-if="i.parent_id == it.id">
43
+                 <div style="display:flex;justify-content:space-between" v-if="i.parent_id == it.id">
44
+                    <p>
45 45
                       ▲ {{ i.advice_name }} {{ i.advice_desc
46 46
                       }}{{ i.drug_spec_unit }} {{ i.prescribing_number
47 47
                       }}{{ i.prescribing_number_unit }} {{ i.single_dose
@@ -52,7 +52,7 @@
52 52
                        <van-icon
53 53
                         class="ellipsis"
54 54
                         name="ellipsis"
55
-                        @click="Delete(i.id,index)"
55
+                        @click="Delete(i.id,i.execution_state,index)"
56 56
                        />
57 57
                   </div>
58 58
                 </div>
@@ -158,7 +158,13 @@
158 158
 </template>
159 159
 <script>
160 160
 import { setRem, setHeight } from "@/libs/functionRem";
161
-import { GetDoctorAdviceDetail, getAllDoctor } from "@/api/patient/patient";
161
+import {
162
+  GetDoctorAdviceDetail,
163
+  getAllDoctor,
164
+  DeleteChild,
165
+  DeletePatient
166
+} from "@/api/patient/patient";
167
+import { Dialog } from "vant";
162 168
 import { uParseTime } from "@/utils/tools";
163 169
 export default {
164 170
   data() {
@@ -179,7 +185,8 @@ export default {
179 185
       newShowTwo: false,
180 186
       newShowThree: false,
181 187
       id: 0,
182
-      index: 0
188
+      index: 0,
189
+      state: 0
183 190
     };
184 191
   },
185 192
   methods: {
@@ -273,22 +280,80 @@ export default {
273 280
         }
274 281
       }
275 282
     },
276
-    Delete(id, index) {
283
+    toDelete(id, state, index) {
284
+      console.log("id", id);
285
+      console.log("state", state);
286
+      this.id = id;
287
+      this.state = state;
288
+      this.index = index;
289
+      this.newShow = true;
290
+    },
291
+    Delete(id, state, index) {
277 292
       console.log("id", id);
293
+      console.log("state", state);
278 294
       this.id = id;
295
+      this.state = state;
279 296
       this.index = index;
280 297
       this.newShowOne = true;
281 298
     },
282
-    onCancel() {},
283
-    onSelect() {},
299
+
300
+    onCancel() {
301
+      this.newShow = false;
302
+    },
303
+    onSelect(val) {
304
+      if (val.name === "删除") {
305
+        this.DeletePatient(this.id, this.state, this.index);
306
+      }
307
+    },
284 308
     onCancelOne() {
285 309
       this.newShowOne = false;
286 310
     },
287
-    onSelectOne() {},
311
+    onSelectOne(val) {
312
+      if (val.name === "删除") {
313
+        this.DeleteChild(this.id, this.index, this.state);
314
+      }
315
+    },
288 316
     onSelectTwo() {},
289 317
     onCancelTwo() {},
290 318
     onCancelThree() {},
291
-    onSelectThree() {}
319
+    onSelectThree() {},
320
+    DeletePatient(id, index, state) {
321
+      if (state == 1) {
322
+        this.$toast("医嘱已执行,无法删除");
323
+        return false;
324
+      }
325
+      Dialog.confirm({
326
+        title: "删除提示!",
327
+        message: "确认删除该条信息吗?,删除后将无法恢复!"
328
+      }).then(() => {
329
+        DeletePatient(id).then(response => {
330
+          if (response.data.state === 1) {
331
+            var msg = response.data.data.msg;
332
+            this.GetDoctorAdviceDetail(this.id);
333
+            this.newShow = false;
334
+          }
335
+        });
336
+      });
337
+    },
338
+    DeleteChild(id, index, state) {
339
+      if (state == 1) {
340
+        this.$toast("医嘱已执行,无法删除");
341
+        return false;
342
+      }
343
+      Dialog.confirm({
344
+        title: "删除提示!",
345
+        message: "确认删除该条信息吗?,删除后将无法恢复!"
346
+      }).then(() => {
347
+        DeleteChild(id).then(response => {
348
+          if (response.data.state === 1) {
349
+            var msg = response.data.data.msg;
350
+
351
+            this.childList.splice(index, 1);
352
+            this.newShowOne = false;
353
+          }
354
+        });
355
+      });
356
+    }
292 357
   },
293 358
   created() {
294 359
     this.active = parseInt(this.$route.query.active);

+ 24 - 17
src/pages/configureCenter/components/Bed.vue Wyświetl plik

@@ -2,11 +2,12 @@
2 2
   <div class="Bed">
3 3
     <van-list
4 4
       v-model="loading"
5
+      @load="onLoad"
5 6
       :finished="finished"
6 7
       finished-text="没有更多了"
7
-      @load="onLoad"
8
+      :immediate-check='show'
8 9
     >
9
-      <div class="BedOne" v-for="(item,index) in this.Number" :key="index">
10
+      <div class="BedOne" v-for="(item,index) in BedNumber" :key="index">
10 11
         <div class="BedLeft">
11 12
           <p>床位号:{{item.number}}</p>
12 13
           <p>分区类型:{{getZone(item.zone_id)}}</p>
@@ -42,11 +43,12 @@ export default {
42 43
       loading: false,
43 44
       finished: false,
44 45
       newShow: false,
46
+      show: false,
45 47
       actions: [{ name: "删除" }],
46 48
       page: 1,
47 49
       limit: 10,
48 50
       total: 0,
49
-      Number: [],
51
+      BedNumber: [],
50 52
       Zone: [],
51 53
       Group: [],
52 54
       id: 0,
@@ -54,7 +56,6 @@ export default {
54 56
     };
55 57
   },
56 58
   methods: {
57
-    onLoad() {},
58 59
     onCancel() {},
59 60
     addBed() {
60 61
       this.$router.push("/addbed?active=" + this.active);
@@ -63,8 +64,12 @@ export default {
63 64
       GetAllNumber(this.page, this.limit).then(response => {
64 65
         if (response.data.state === 1) {
65 66
           var number = response.data.data.number;
66
-          this.Number = number;
67
+          console.log("number", number);
68
+          let arr = this.BedNumber;
69
+          arr.push(...number);
70
+          this.BedNumber = arr;
67 71
           var total = response.data.data.total;
72
+          console.log("total", total);
68 73
           this.total = total;
69 74
           var zone = response.data.data.zone;
70 75
           this.Zone = zone;
@@ -74,6 +79,17 @@ export default {
74 79
         }
75 80
       });
76 81
     },
82
+    onLoad() {
83
+      setTimeout(() => {
84
+        this.page++;
85
+        if (this.page <= Math.ceil(this.total / 10)) {
86
+          this.GetAllNumber(this.page, this.limit);
87
+        } else {
88
+          this.loading = false;
89
+          this.finished = true;
90
+        }
91
+      }, 1000);
92
+    },
77 93
     getZone(id) {
78 94
       for (let i = 0; i < this.Zone.length; i++) {
79 95
         if (id === this.Zone[i].id) {
@@ -88,17 +104,7 @@ export default {
88 104
         }
89 105
       }
90 106
     },
91
-    onLoad() {
92
-      setTimeout(() => {
93
-        this.page++;
94
-        if (this.page <= Math.ceil(this.total / 10)) {
95
-          this.GetAllNumber(this.page, this.limit);
96
-        } else {
97
-          this.loading = false;
98
-          this.finished = true;
99
-        }
100
-      }, 1000);
101
-    },
107
+
102 108
     Delete(id, index) {
103 109
       this.newShow = true;
104 110
       this.id = id;
@@ -121,7 +127,7 @@ export default {
121 127
           if (response.data.state === 1) {
122 128
             var msg = response.data.data.msg;
123 129
             console.log("msg", msg);
124
-            this.Number.splice(index, 1);
130
+            this.BedNumber.splice(index, 1);
125 131
             this.newShow = false;
126 132
           }
127 133
         });
@@ -137,6 +143,7 @@ export default {
137 143
 
138 144
 <style lang="scss" scoped>
139 145
 .Bed {
146
+  margin-bottom: 3.125rem;
140 147
   .BedOne {
141 148
     padding: 1.375rem 1.125rem 0 1.5rem;
142 149
     display: flex;

+ 18 - 6
src/pages/configureCenter/components/Grouping.vue Wyświetl plik

@@ -10,7 +10,7 @@
10 10
         <div class="GroupingLeft">
11 11
           <p>分组名称:{{item.name}}</p>
12 12
         </div>
13
-        <van-icon class="ellipsis" name="ellipsis" @click="Delete(item.id,index)" />
13
+        <van-icon class="ellipsis" name="ellipsis" @click="Delete(item.id,item.number,index)" />
14 14
       </div>
15 15
     </van-list>
16 16
     <div class="add">
@@ -45,7 +45,9 @@ export default {
45 45
       limit: 10,
46 46
       group: [],
47 47
       id: 0,
48
-      index: 0
48
+      index: 0,
49
+      total: 0,
50
+      number: ""
49 51
     };
50 52
   },
51 53
   methods: {
@@ -57,10 +59,13 @@ export default {
57 59
       getAllGroup(this.page, this.limit).then(response => {
58 60
         if (response.data.state === 1) {
59 61
           var group = response.data.data.group;
60
-          this.group = group;
62
+          let arr = this.group;
63
+          arr.push(...group);
64
+          this.group = arr;
61 65
           console.log("group", group);
62 66
           var total = response.data.data.total;
63 67
           console.log("total", total);
68
+          this.total = total;
64 69
           this.loading = false;
65 70
         }
66 71
       });
@@ -79,17 +84,23 @@ export default {
79 84
     onCancel() {
80 85
       this.newShow = false;
81 86
     },
82
-    Delete(id, index) {
87
+    Delete(id, number, index) {
83 88
       this.newShow = true;
84 89
       this.id = id;
85 90
       this.index = index;
91
+      this.number = number;
86 92
     },
87 93
     OnSelect(val) {
88 94
       if (val.name === "删除") {
89
-        this.DeleteGroup(this.id, this.index);
95
+        this.DeleteGroup(this.id, this.number, this.index);
90 96
       }
91 97
     },
92
-    DeleteGroup(id, index) {
98
+    DeleteGroup(id, number, index) {
99
+      if (number !== "") {
100
+        this.$toast("该分组存在床位号,不能删除");
101
+        this.newShow = false;
102
+        return false;
103
+      }
93 104
       Dialog.confirm({
94 105
         title: "删除提示!",
95 106
         message: "确认删除该条信息吗?,删除后将无法恢复!"
@@ -113,6 +124,7 @@ export default {
113 124
 
114 125
 <style lang="scss" scoped>
115 126
 .Grouping {
127
+  margin-bottom: 3.125rem;
116 128
   .GroupingOne {
117 129
     padding: 1.375rem 1.125rem 1.125rem 1.5rem;
118 130
     display: flex;

+ 17 - 6
src/pages/configureCenter/components/Partition.vue Wyświetl plik

@@ -14,7 +14,7 @@
14 14
         <van-icon
15 15
           class="ellipsis"
16 16
           name="ellipsis"
17
-          @click="Delete(item.id, index)"
17
+          @click="Delete(item.id,item.number,index)"
18 18
         />
19 19
       </div>
20 20
     </van-list>
@@ -51,7 +51,8 @@ export default {
51 51
       zone: [],
52 52
       total: 0,
53 53
       id: 0,
54
-      index: 0
54
+      index: 0,
55
+      number: 0
55 56
     };
56 57
   },
57 58
   methods: {
@@ -64,6 +65,7 @@ export default {
64 65
       GetAllZone(this.page, this.limit).then(response => {
65 66
         if (response.data.state === 1) {
66 67
           var zone = response.data.data.zone;
68
+          console.log("分区", zone);
67 69
           for (let i = 0; i < zone.length; i++) {
68 70
             if (zone[i].type === 1) {
69 71
               zone[i].type = "普通";
@@ -84,7 +86,9 @@ export default {
84 86
               zone[i].type = "梅毒";
85 87
             }
86 88
           }
87
-          this.zone = zone;
89
+          let arr = this.zone;
90
+          arr.push(...zone);
91
+          this.zone = arr;
88 92
           var total = response.data.data.total;
89 93
           this.total = total;
90 94
           this.loading = false;
@@ -107,15 +111,21 @@ export default {
107 111
     },
108 112
     onSelect(val) {
109 113
       if (val.name === "删除") {
110
-        this.DeleteZone(this.id, this.index);
114
+        this.DeleteZone(this.id, this.number, this.index);
111 115
       }
112 116
     },
113
-    Delete(id, index) {
117
+    Delete(id, number, index) {
114 118
       this.id = id;
115 119
       this.index = index;
120
+      this.number = number;
116 121
       this.newShow = true;
117 122
     },
118
-    DeleteZone(id, index) {
123
+    DeleteZone(id, number, index) {
124
+      if (number !== "") {
125
+        this.$toast("该分区存在床位号,不能删除");
126
+        this.newShow = false;
127
+        return false;
128
+      }
119 129
       Dialog.confirm({
120 130
         title: "删除提示!",
121 131
         message: "确认删除该条信息吗?,删除后将无法恢复!"
@@ -139,6 +149,7 @@ export default {
139 149
 
140 150
 <style lang="scss" scoped>
141 151
 .partition {
152
+  margin-bottom: 3.125rem;
142 153
   .partitionOne {
143 154
     padding: 1.375rem 1.125rem 0 1.5rem;
144 155
     display: flex;

+ 2 - 2
src/pages/configureCenter/index.vue Wyświetl plik

@@ -1,11 +1,11 @@
1 1
 <template>
2 2
   <div class="page_configureCenter">
3 3
     <div class="configureCenterTitle">
4
-      <i class="iconfont icon-zuojiantou jiantou" @click="toReturn"></i>
4
+      <i class="iconfont icon-zuojiantou jiantou" @click="$router.go(-1)"></i>
5 5
       <span class="titleName">配置中心</span>
6 6
     </div>
7 7
     <div class="configureCenterMain">
8
-      <van-tabs v-model="active">
8
+      <van-tabs v-model="active" sticky>
9 9
         <van-tab title="分区">
10 10
           <partition :active="active"></partition>
11 11
         </van-tab>

+ 1 - 1
src/pages/configureCenter/newPartition.vue Wyświetl plik

@@ -42,7 +42,7 @@ export default {
42 42
       columns: ["普通", "乙肝", "丙肝", "艾滋病", "肺结核", "梅毒"],
43 43
       form: {
44 44
         name: "",
45
-        zoneType: 0
45
+        zoneType: ""
46 46
       },
47 47
       type: "",
48 48
       active: 0

+ 10 - 5
src/pages/console/managementConsole/staff_role/employeeList/index.vue Wyświetl plik

@@ -16,7 +16,7 @@
16 16
         @change="onChange"
17 17
       >
18 18
         <div class="checkOne" v-for="(item, index) in admin_user" :key="index">
19
-          <van-checkbox :name="item.id"></van-checkbox>
19
+          <van-checkbox :name="item.id" @change="onChange"></van-checkbox>
20 20
           <div class="checkUserBox">
21 21
             <img v-if="item.avatar.length > 0" :src="item.avatar" alt="" />
22 22
             <img
@@ -45,6 +45,13 @@ export default {
45 45
   },
46 46
   methods: {
47 47
     save() {
48
+      if(this.result.length == 0){
49
+        this.$toast({
50
+          message: "至少选择一个用户"
51
+        });
52
+        return
53
+      }
54
+
48 55
       let params = {
49 56
         id: this.$route.query.id,
50 57
         ids: this.result.join(",")
@@ -89,7 +96,7 @@ export default {
89 96
     checkAll() {
90 97
       if (this.allChecked == false) {
91 98
         for (let i = 0; i < this.admin_user.length; i++) {
92
-          this.result.push(this.admin_user[i].user_id);
99
+          this.result.push(this.admin_user[i].id);
93 100
         }
94 101
         this.allChecked = true;
95 102
       } else {
@@ -97,12 +104,10 @@ export default {
97 104
       }
98 105
     },
99 106
     onChange() {
100
-      if (this.result.length == this.list.length) {
107
+      if (this.result.length == this.admin_user.length) {
101 108
         this.allChecked = true;
102
-        this.$refs.checkboxes.toggle();
103 109
       } else {
104 110
         this.allChecked = false;
105
-        this.$refs.checkboxes.toggle();
106 111
       }
107 112
     }
108 113
   },

+ 217 - 160
src/pages/doctorAdvice/components/DoctorManagement.vue Wyświetl plik

@@ -22,124 +22,206 @@
22 22
         </div>
23 23
       </div>
24 24
 
25
-      <div class="adviceBox" v-show="showOne">
25
+      <div class="adviceBox">
26 26
         <van-list
27
-          v-model="loading"
28
-          :finished="finished"
29
-          finished-text="没有更多了"
30
-          @load="onLoad"
31
-        >
32
-          <div
33
-            class="adviceOne"
34
-            v-for="(item, index) in doctorAdvice"
35
-            :key="index"
36
-          >
37
-            <div v-for="(it, i) in item.child" :key="i">
38
-              <div class="adviceTitle" v-if="it.advice_date">
39
-                <p>{{ it.advice_date ? getTime(it.advice_date) : "" }}</p>
40
-                <van-icon
41
-                  class="ellipsis"
42
-                  name="ellipsis"
43
-                  @click="Delete(item.groupno, index, it.execution_staff)"
44
-                />
45
-              </div>
27
+         v-model="loading"
28
+         :finished="finished"
29
+         @load="onLoad"
30
+         finished-text="没有更多了"
31
+         >
46 32
 
47
-              <div
48
-                class="statOrder"
49
-                v-if="it.advice_type == 1 && it.parent_id == 0"
50
-              >
51
-                <div class="statOrderTitle" v-if="i < 3">
52
-                  <span>长期医嘱</span>
53
-                  <span style="margin-left:1rem">
54
-                    {{ getTimes(it.start_time) }}
55
-                  </span>
56
-                </div>
57
-                <div class="orderContent" v-if="i < 3">
58
-                  <p v-if="it.parent_id === 0">
59
-                    {{ it.advice_name }} {{ it.advice_desc
60
-                    }}{{ it.drug_spec_unit }} {{ it.prescribing_number
33
+          <div class="adviceOne" v-for="(item,index) in this.doctorAdvice" :key="index">
34
+            <div class="adviceTitle">
35
+              <p>{{getTime(item.child[0].start_time)}}</p>
36
+              <van-icon class="ellipsis" name="ellipsis" @click="newShow = true" />
37
+            </div>
38
+
39
+         <div v-for="(it,i) in item.child" :key="i">
40
+            <div class="statOrder"  v-if="it.advice_type == 1 && it.parent_id == 0" >
41
+              <div class="statOrderTitle">
42
+                <span v-if="i<1">长期医嘱</span>
43
+                <span  v-if="i<1" style="margin-left:1rem">{{getTimes(it.start_time)}}</span>
44
+              </div>
45
+              <div class="orderContent" v-if="i<4">
46
+                <p> {{ it.advice_name }} {{ it.advice_desc
47
+                     }}{{ it.drug_spec_unit }} {{ it.prescribing_number
61 48
                     }}{{ it.prescribing_number_unit }} {{ it.single_dose
62 49
                     }}{{ it.single_dose_unit }} {{ it.delivery_way }}
63
-                    {{ it.execution_frequency }}
64
-                  </p>
65
-                  <div v-for="(i, index) in childList" :key="index">
66
-                    <p v-if="i.parent_id == it.id">
67
-                   {{ i.advice_name }} {{ i.advice_desc
50
+                    {{ it.execution_frequency }}</p>
51
+
52
+                <div v-for="(i, index) in childList" :key="index">
53
+                 <p v-if="i.parent_id == it.id">
54
+                   {{ i.advice_name }} {{ i.advice_desc
68 55
                       }}{{ i.drug_spec_unit }} {{ i.prescribing_number
69 56
                       }}{{ i.prescribing_number_unit }} {{ i.single_dose
70 57
                       }}{{ i.single_dose_unit }}
71
-                      {{ i.delivery_way }}
72
-                      {{ i.execution_frequency }}
73
-                    </p>
74
-                  </div>
58
+                     {{ i.delivery_way }}
59
+                    {{ i.execution_frequency }}
60
+                 </p>
75 61
                 </div>
76
-                <div
77
-                  class="doctorBox"
78
-                  v-if="
79
-                    it.user_name ||
80
-                      it.execution_staff ||
81
-                      (it.checker && i == item.child.length)
82
-                  "
83
-                >
62
+                <div class="doctorBox">
84 63
                   <p>开嘱医生:{{ it.user_name }}</p>
85 64
                   <p>执行护士:{{ getDoctor(it.execution_staff) }}</p>
86 65
                   <p>核对护士:{{ getDoctor(it.checker) }}</p>
87 66
                 </div>
88 67
               </div>
68
+            </div>
89 69
 
90
-              <div
91
-                class="statOrder"
92
-                v-if="it.advice_type == 3 && it.parent_id == 0"
93
-              >
94
-                <div class="longOrderTitle" v-if="i < 3">
95
-                  <span>临时医嘱</span>
96
-                  <span style="margin-left:1rem">
97
-                    {{ getTimes(item.child[0].start_time) }}
98
-                  </span>
99
-                </div>
100
-                <div class="orderContent" v-if="i < 3">
101
-                  <p>
102
-                    {{ it.advice_name }} {{ it.advice_desc
103
-                    }}{{ it.drug_spec_unit }} {{ it.prescribing_number
70
+            <div class="statOrder" v-if="it.advice_type == 3 && it.parent_id == 0">
71
+              <div class="longOrderTitle">
72
+                <span v-if="i<1">临时医嘱</span>
73
+                <span v-if="i<1" style="margin-left:1rem">{{getTimes(it.start_time)}}</span>
74
+              </div>
75
+              <div class="orderContent" v-if="i<4">
76
+                <p v-if="it.parent_id == 0">{{ it.advice_name }} {{ it.advice_desc
77
+                  }}{{ it.drug_spec_unit }} {{ it.prescribing_number
104 78
                     }}{{ it.prescribing_number_unit }} {{ it.single_dose
105 79
                     }}{{ it.single_dose_unit }} {{ it.delivery_way }}
106
-                    {{ it.execution_frequency }}
107
-                  </p>
108
-                  <div v-for="(i, index) in childList" :key="index">
109
-                    <p v-if="i.parent_id == it.id">
110
-                      ▲ {{ i.advice_name }} {{ i.advice_desc
80
+                   {{ it.execution_frequency }}</p>
81
+                <div v-for="(i, index) in childList" :key="index">
82
+                  <p v-if="i.parent_id == it.id">▲ {{ i.advice_name }} {{ i.advice_desc
111 83
                       }}{{ i.drug_spec_unit }} {{ i.prescribing_number
112 84
                       }}{{ i.prescribing_number_unit }} {{ i.single_dose
113 85
                       }}{{ i.single_dose_unit }}
114
-                      {{ i.delivery_way }}
115
-                      {{ i.execution_frequency }}
116
-                    </p>
117
-                  </div>
86
+                     {{ i.delivery_way }}
87
+                    {{ i.execution_frequency }}</p>
118 88
                 </div>
119
-                <div
120
-                  class="doctorBox"
121
-                  v-if="
122
-                    it.user_name ||
123
-                      it.execution_staff ||
124
-                      (it.checker && i == item.child.length)
125
-                  "
126
-                >
89
+              </div>
90
+               <div class="doctorBox">
127 91
                   <p>开嘱医生:{{ it.user_name }}</p>
128 92
                   <p>执行护士:{{ getDoctor(it.execution_staff) }}</p>
129 93
                   <p>核对护士:{{ getDoctor(it.checker) }}</p>
130 94
                 </div>
131
-              </div>
132
-            </div>
133
-            <div
134
-              class="all"
135
-              @click="toDoctorAdviceDetail(item.child[0].groupno)"
136
-            >
137
-              全部
138 95
             </div>
96
+         </div>
97
+<!--             <div class="doctorBox">-->
98
+<!--                <p>开嘱医生:{{ item.child[0].user_name }}</p>-->
99
+<!--                <p>执行护士:{{ getDoctor(item.child[0].execution_staff) }}</p>-->
100
+<!--                <p>核对护士:{{ getDoctor(item.child[0].checker) }}</p>-->
101
+<!--              </div>-->
102
+            <div class="all" @click="toDoctorAdviceDetail(item.groupno)">全部</div>
139 103
           </div>
140 104
         </van-list>
141 105
       </div>
142 106
 
107
+<!--      <div class="adviceBox" v-show="showOne">-->
108
+<!--        <van-list-->
109
+<!--          v-model="loading"-->
110
+<!--          :finished="finished"-->
111
+<!--          finished-text="没有更多了"-->
112
+<!--          @load="onLoad"-->
113
+<!--        >-->
114
+<!--          <div-->
115
+<!--            class="adviceOne"-->
116
+<!--            v-for="(item, index) in doctorAdvice"-->
117
+<!--            :key="index"-->
118
+<!--          >-->
119
+<!--            <div v-for="(it, i) in item.child" :key="i">-->
120
+<!--              <div class="adviceTitle" v-if="it.advice_date">-->
121
+<!--                <p>{{ it.advice_date ? getTime(it.advice_date) : "" }}</p>-->
122
+<!--                <van-icon-->
123
+<!--                  class="ellipsis"-->
124
+<!--                  name="ellipsis"-->
125
+<!--                  @click="Delete(item.groupno, index, it.execution_staff)"-->
126
+<!--                />-->
127
+<!--              </div>-->
128
+
129
+<!--              <div-->
130
+<!--                class="statOrder"-->
131
+<!--                v-if="it.advice_type == 1 && it.parent_id == 0"-->
132
+<!--              >-->
133
+<!--                <div class="statOrderTitle" v-if="i < 3">-->
134
+<!--                  <span>长期医嘱</span>-->
135
+<!--                  <span style="margin-left:1rem">-->
136
+<!--                    {{ getTimes(it.start_time) }}-->
137
+<!--                  </span>-->
138
+<!--                </div>-->
139
+<!--                <div class="orderContent" v-if="i < 3">-->
140
+<!--                  <p v-if="it.parent_id === 0">-->
141
+<!--                    {{ it.advice_name }} {{ it.advice_desc-->
142
+<!--                    }}{{ it.drug_spec_unit }} {{ it.prescribing_number-->
143
+<!--                    }}{{ it.prescribing_number_unit }} {{ it.single_dose-->
144
+<!--                    }}{{ it.single_dose_unit }} {{ it.delivery_way }}-->
145
+<!--                    {{ it.execution_frequency }}-->
146
+<!--                  </p>-->
147
+<!--                  <div v-for="(i, index) in childList" :key="index">-->
148
+<!--                    <p v-if="i.parent_id == it.id">-->
149
+<!--                      ▲ {{ i.advice_name }} {{ i.advice_desc-->
150
+<!--                      }}{{ i.drug_spec_unit }} {{ i.prescribing_number-->
151
+<!--                      }}{{ i.prescribing_number_unit }} {{ i.single_dose-->
152
+<!--                      }}{{ i.single_dose_unit }}-->
153
+<!--                      {{ i.delivery_way }}-->
154
+<!--                      {{ i.execution_frequency }}-->
155
+<!--                    </p>-->
156
+<!--                  </div>-->
157
+<!--                </div>-->
158
+<!--                <div-->
159
+<!--                  class="doctorBox"-->
160
+<!--                  v-if="-->
161
+<!--                    it.user_name ||-->
162
+<!--                      it.execution_staff ||-->
163
+<!--                      (it.checker && i == item.child.length)-->
164
+<!--                  "-->
165
+<!--                >-->
166
+<!--                  <p>开嘱医生:{{ it.user_name }}</p>-->
167
+<!--                  <p>执行护士:{{ getDoctor(it.execution_staff) }}</p>-->
168
+<!--                  <p>核对护士:{{ getDoctor(it.checker) }}</p>-->
169
+<!--                </div>-->
170
+<!--              </div>-->
171
+
172
+<!--              <div-->
173
+<!--                class="statOrder"-->
174
+<!--                v-if="it.advice_type == 3 && it.parent_id == 0"-->
175
+<!--              >-->
176
+<!--                <div class="longOrderTitle" v-if="i < 3">-->
177
+<!--                  <span>临时医嘱</span>-->
178
+<!--                  <span style="margin-left:1rem">-->
179
+<!--                    {{ getTimes(item.child[0].start_time) }}-->
180
+<!--                  </span>-->
181
+<!--                </div>-->
182
+<!--                <div class="orderContent" v-if="i < 3">-->
183
+<!--                  <p>-->
184
+<!--                    {{ it.advice_name }} {{ it.advice_desc-->
185
+<!--                    }}{{ it.drug_spec_unit }} {{ it.prescribing_number-->
186
+<!--                    }}{{ it.prescribing_number_unit }} {{ it.single_dose-->
187
+<!--                    }}{{ it.single_dose_unit }} {{ it.delivery_way }}-->
188
+<!--                    {{ it.execution_frequency }}-->
189
+<!--                  </p>-->
190
+<!--                  <div v-for="(i, index) in childList" :key="index">-->
191
+<!--                    <p v-if="i.parent_id == it.id">-->
192
+<!--                      ▲ {{ i.advice_name }} {{ i.advice_desc-->
193
+<!--                      }}{{ i.drug_spec_unit }} {{ i.prescribing_number-->
194
+<!--                      }}{{ i.prescribing_number_unit }} {{ i.single_dose-->
195
+<!--                      }}{{ i.single_dose_unit }}-->
196
+<!--                      {{ i.delivery_way }}-->
197
+<!--                      {{ i.execution_frequency }}-->
198
+<!--                    </p>-->
199
+<!--                  </div>-->
200
+<!--                </div>-->
201
+<!--                <div-->
202
+<!--                  class="doctorBox"-->
203
+<!--                  v-if="-->
204
+<!--                    it.user_name ||-->
205
+<!--                      it.execution_staff ||-->
206
+<!--                      (it.checker && i == item.child.length)-->
207
+<!--                  "-->
208
+<!--                >-->
209
+<!--                  <p>开嘱医生:{{ it.user_name }}</p>-->
210
+<!--                  <p>执行护士:{{ getDoctor(it.execution_staff) }}</p>-->
211
+<!--                  <p>核对护士:{{ getDoctor(it.checker) }}</p>-->
212
+<!--                </div>-->
213
+<!--              </div>-->
214
+<!--            </div>-->
215
+<!--            <div-->
216
+<!--              class="all"-->
217
+<!--              @click="toDoctorAdviceDetail(item.child[0].groupno)"-->
218
+<!--            >-->
219
+<!--              全部-->
220
+<!--            </div>-->
221
+<!--          </div>-->
222
+<!--        </van-list>-->
223
+<!--      </div>-->
224
+
143 225
       <div class="noimgBox" v-show="showTwo">
144 226
         <img src="../../../assets/images/none.png" alt />
145 227
       </div>
@@ -218,8 +300,7 @@
218 300
 import {
219 301
   getDoctorAdvices,
220 302
   getPatientDetail,
221
-  DeleteManagement,
222
-  DeleteChild
303
+  DeleteManagement
223 304
 } from "@/api/patient/patient";
224 305
 import { uParseTime } from "@/utils/tools";
225 306
 import { Dialog } from "vant";
@@ -230,6 +311,7 @@ export default {
230 311
   },
231 312
   data() {
232 313
     return {
314
+      docShow: false,
233 315
       loading: false,
234 316
       finished: false,
235 317
       newShow: false,
@@ -241,7 +323,6 @@ export default {
241 323
       columns: ["全部", "长期医嘱", "临时医嘱"],
242 324
       startTime: "请选择",
243 325
       endTime: "请选择",
244
-      endTimes: "",
245 326
       minDate: new Date(1970, 0, 1),
246 327
       maxDate: new Date(2025, 10, 1),
247 328
       currentDate: new Date(),
@@ -249,8 +330,8 @@ export default {
249 330
       actions1: [{ name: "删除" }],
250 331
       actions2: [{ name: "删除" }],
251 332
       form: {
252
-        type: "",
253
-        limit: 10,
333
+        type: 0,
334
+        limit: 5,
254 335
         page: 1
255 336
       },
256 337
       total: "",
@@ -280,7 +361,7 @@ export default {
280 361
         this.patient_id,
281 362
         this.type,
282 363
         this.startTime,
283
-        this.endTimes,
364
+        this.endTime,
284 365
         this.form.limit,
285 366
         this.form.page
286 367
       );
@@ -355,18 +436,10 @@ export default {
355 436
       ).then(response => {
356 437
         if (response.data.state === 1) {
357 438
           var advice = response.data.data.advice;
358
-          // this.doctorAdvice = advice;
359
-          let objarr = [];
360
-          for (let i = 0; i < advice.length; i++) {
361
-            if (advice[i].parent_id != 0) {
362
-              objarr.push(advice[i]);
363
-            }
364
-          }
365
-          this.childList = objarr;
366
-          var total = response.data.data.total;
367
-          this.total = total;
439
+          console.log("advice", advice);
440
+          var one = response.data.data.one;
368 441
           let dataInfo = {};
369
-          advice.forEach((item, index) => {
442
+          one.forEach((item, index) => {
370 443
             let { groupno } = item;
371 444
             if (!dataInfo[groupno]) {
372 445
               dataInfo[groupno] = {
@@ -374,46 +447,31 @@ export default {
374 447
                 child: []
375 448
               };
376 449
             }
377
-            dataInfo[groupno].child.push(item);
378 450
           });
379
-          let list = Object.values(dataInfo); // list 转换成功的数据
380
-          let arr = [];
381
-
451
+          let list = Object.values(dataInfo);
382 452
           list.map(item => {
383
-            // console.log(item.child);
384
-            let arr2 = [];
385
-            if (item.child.length > 1) {
386
-              item.child.map((it, index) => {
387
-                // console.log(it);
388
-                if (arr.indexOf(it.advice_date) == -1) {
389
-                  arr.push(it.advice_date);
390
-                } else {
391
-                  delete it["advice_date"];
392
-                }
393
-              });
394
-              for (var i = item.child.length - 1; i != -1; i--) {
395
-                let obj = {};
396
-                obj.checker = item.child[i].checker;
397
-                obj.execution_staff = item.child[i].execution_staff;
398
-                obj.user_name = item.child[i].user_name;
399
-                if (
400
-                  JSON.stringify(arr2).includes(JSON.stringify(obj)) == false
401
-                ) {
402
-                  arr2.push(obj);
403
-                } else {
404
-                  delete item.child[i]["checker"];
405
-                  delete item.child[i]["execution_staff"];
406
-                  delete item.child[i]["user_name"];
407
-                }
453
+            for (let i = 0; i < advice.length; i++) {
454
+              if (item.groupno === advice[i].groupno) {
455
+                item.child.push(advice[i]);
408 456
               }
409 457
             }
410 458
           });
411
-
412
-          var doctor = response.data.data.doctor;
413
-          this.doctor = doctor;
414
-          this.doctorAdvice = list.reverse();
459
+          let objarr = [];
460
+          for (let i = 0; i < advice.length; i++) {
461
+            if (advice[i].parent_id != 0) {
462
+              objarr.push(advice[i]);
463
+            }
464
+          }
465
+          this.childList = objarr;
466
+          console.log("list", list);
467
+          let arr = this.doctorAdvice;
468
+          arr.push(...list.reverse());
469
+          this.doctorAdvice = arr;
470
+          console.log("listtwo", this.doctorAdvice);
471
+          var total = response.data.data.total;
472
+          this.total = total;
473
+          console.log("total", total);
415 474
           this.loading = false;
416
-          this.finished = true;
417 475
         }
418 476
       });
419 477
     },
@@ -440,25 +498,25 @@ export default {
440 498
     getTimes(time) {
441 499
       return uParseTime(time, "{h}:{i}");
442 500
     },
443
-    // onLoad() {
444
-    //   setTimeout(() => {
445
-    //     this.page++;
446
-    //     if (this.page <= Math.ceil(this.total / 10)) {
447
-    //       this.getDoctorAdvices(
448
-    //         this.patient_id,
449
-    //         this.form.type,
450
-    //         this.startTime,
451
-    //         this.endTimes,
452
-    //         this.form.limit,
453
-    //         this.form.page
454
-    //       );
455
-    //     } else {
456
-    //       this.loading = false;
457
-    //       this.finished = true;
458
-    //     }
459
-    //   }, 1000);
460
-    // },
461
-    onLoad() {},
501
+    onLoad() {
502
+      setTimeout(() => {
503
+        this.form.page++;
504
+        console.log("page", this.form.page);
505
+        if (this.form.page <= Math.ceil(this.total / 5)) {
506
+          this.getDoctorAdvices(
507
+            this.patient_id,
508
+            this.form.type,
509
+            this.startTime,
510
+            this.endTime,
511
+            this.form.limit,
512
+            this.form.page
513
+          );
514
+        } else {
515
+          this.loading = false;
516
+          this.finished = true;
517
+        }
518
+      }, 1000);
519
+    },
462 520
     toDoctorAdviceDetail(id) {
463 521
       var patientid = this.$route.query.patientid;
464 522
       this.$router.push(
@@ -503,7 +561,6 @@ export default {
503 561
       }
504 562
     },
505 563
     toChildDelete(val) {
506
-      console.log(val);
507 564
       if (val.name == "删除") {
508 565
         this.DeleteChild(this.id, this.index, this.state);
509 566
       }

+ 1 - 3
src/pages/doctorAdvice/index.vue Wyświetl plik

@@ -562,9 +562,7 @@ export default {
562 562
     this.patient_id = patientid;
563 563
     this.getPatientDetail(patientid);
564 564
     var seacherActive = this.$route.query.seacherActive;
565
-    // console.log("seacherActive是", seacherActive);
566
-
567
-    if (seacherActive === 0) {
565
+    if (seacherActive == 0) {
568 566
       this.getBloodDialysisPatientTwo();
569 567
     }
570 568
     if (seacherActive == 1) {

+ 6 - 6
src/pages/home/index.vue Wyświetl plik

@@ -94,12 +94,12 @@
94 94
             <!--<div>服务</div>-->
95 95
           <!--</van-tabbar-item>-->
96 96
         <!--</router-link>-->
97
-        <router-link to="/shop" replace>
98
-          <van-tabbar-item>
99
-            <i class="iconfont icon-shangcheng iconOne"></i>
100
-            <div>商城</div>
101
-          </van-tabbar-item>
102
-        </router-link>
97
+<!--        <router-link to="/shop" replace>-->
98
+<!--          <van-tabbar-item>-->
99
+<!--            <i class="iconfont icon-shangcheng iconOne"></i>-->
100
+<!--            <div>商城</div>-->
101
+<!--          </van-tabbar-item>-->
102
+<!--        </router-link>-->
103 103
         <router-link to="/newMy" replace>
104 104
           <van-tabbar-item>
105 105
             <i class="iconfont icon-wode iconOne"></i>

+ 51 - 33
src/pages/home/login.vue Wyświetl plik

@@ -42,6 +42,11 @@
42 42
       <span class="newColor" @click="agree()">《隐私服务协议》</span>
43 43
       <span class="newColor" @click="agree1()">《用户协议》</span>
44 44
     </div>
45
+    <van-overlay :show="show" @click="show = false">
46
+      <div class="wrapper">
47
+        <van-loading size="24px" vertical>正在登录...</van-loading>
48
+      </div>
49
+    </van-overlay>
45 50
   </div>
46 51
 </template>
47 52
 
@@ -64,6 +69,7 @@ export default {
64 69
       }
65 70
     };
66 71
     return {
72
+      show: false,
67 73
       checked: true,
68 74
       tel: "",
69 75
       psd: "",
@@ -129,43 +135,49 @@ export default {
129 135
     },
130 136
 
131 137
     submitForm() {
132
-      loginByPwd(this.LoginForm.tel, hex_md5(this.LoginForm.psd)).then(rs => {
133
-        var resp = rs.data;
134
-        if (this.checked != true) {
135
-          Toast("请同意隐私服务协议");
136
-          return;
137
-        }
138
+      this.show = true;
139
+      loginByPwd(this.LoginForm.tel, hex_md5(this.LoginForm.psd))
140
+        .then(rs => {
141
+          var resp = rs.data;
142
+          if (this.checked != true) {
143
+            Toast("请同意隐私服务协议");
144
+            return;
145
+          }
138 146
 
139
-        if (resp.state == 1 && this.checked == true) {
140
-          var user = resp.data.user;
141
-          var admin = resp.data.admin;
142
-          var org = resp.data.org;
143
-          var subscibe = resp.data.subscibe;
144
-          var config_list = resp.data.config_list;
145
-          var template_info = resp.data.template_info;
146
-          var filed_list = resp.data.filed_list;
147
+          if (resp.state == 1 && this.checked == true) {
148
+            this.show = false;
149
+            var user = resp.data.user;
150
+            var admin = resp.data.admin;
151
+            var org = resp.data.org;
152
+            var subscibe = resp.data.subscibe;
153
+            var config_list = resp.data.config_list;
154
+            var template_info = resp.data.template_info;
155
+            var filed_list = resp.data.filed_list;
147 156
 
148
-          this.$store.dispatch("InitUserInfo", {
149
-            admin: admin,
150
-            user: user,
151
-            org: org,
152
-            subscibe: subscibe,
153
-            template_info: template_info,
154
-            filed_list: filed_list
155
-          });
156
-          this.$store.dispatch("SetConfigList", config_list);
157
-          this.$router.replace({ path: "/homeIndex" });
158
-        } else {
159
-          if (this.errorNum >= 2) {
160
-            this.showForgetPwdDialog();
161
-          } else {
162
-            this.errorNum = this.errorNum + 1;
163
-            this.$toast({
164
-              message: resp.msg
157
+            this.$store.dispatch("InitUserInfo", {
158
+              admin: admin,
159
+              user: user,
160
+              org: org,
161
+              subscibe: subscibe,
162
+              template_info: template_info,
163
+              filed_list: filed_list
165 164
             });
165
+            this.$store.dispatch("SetConfigList", config_list);
166
+            this.$router.replace({ path: "/homeIndex" });
167
+          } else {
168
+            if (this.errorNum >= 2) {
169
+              this.showForgetPwdDialog();
170
+            } else {
171
+              this.errorNum = this.errorNum + 1;
172
+              this.$toast({
173
+                message: resp.msg
174
+              });
175
+            }
166 176
           }
167
-        }
168
-      });
177
+        })
178
+        .catch(error => {
179
+          console.log(error);
180
+        });
169 181
     },
170 182
     showForgetPwdDialog() {
171 183
       Dialog.confirm({
@@ -259,6 +271,12 @@ export default {
259 271
     color: #fff;
260 272
     text-align: center;
261 273
   }
274
+  .wrapper {
275
+    position: fixed;
276
+    left: 50%;
277
+    top: 50%;
278
+    transform: translate(-50%, -50%);
279
+  }
262 280
 }
263 281
 
264 282
 .el-form-item__error {

+ 13 - 9
src/pages/homeIndex/index.vue Wyświetl plik

@@ -4,18 +4,18 @@
4 4
       <div class="homeTitle">
5 5
         <div class="homeTitleLeft" style="visibility: hidden" v-if="isCreateOrg == false">
6 6
           <van-dropdown-menu>
7
-            <van-dropdown-item @change="changeOrg" v-model="value1" :options="org_arr"/>
7
+            <van-dropdown-item @change="changeOrg" v-model="value1" :options="org_arr" />
8 8
           </van-dropdown-menu>
9 9
         </div>
10
-        <div class="homeTitleLeft"  v-if="isCreateOrg == true">
10
+        <div class="homeTitleLeft" v-if="isCreateOrg == true">
11 11
           <van-dropdown-menu>
12
-            <van-dropdown-item @change="changeOrg" v-model="value1" :options="org_arr"/>
12
+            <van-dropdown-item @change="changeOrg" v-model="value1" :options="org_arr" />
13 13
           </van-dropdown-menu>
14 14
         </div>
15 15
         <div class="homeTitleRight">
16 16
           <i class="iconfont icon-sousuo search1" @click="toSearch"></i>
17 17
           <!--<van-icon class="iconOne" name="comment-o"/>-->
18
-          <van-icon class="iconOne" name="add-o" @click="toCreateOrg"/>
18
+          <van-icon name="plus" class="iconOne" @click="toCreateOrg" />
19 19
         </div>
20 20
       </div>
21 21
     </van-sticky>
@@ -26,6 +26,7 @@
26 26
         </van-swipe-item>
27 27
       </van-swipe>
28 28
     </div>
29
+    <van-overlay :show="show" @click="show = false" />
29 30
     <!--<div class="noticeBox">-->
30 31
     <!--<i class="iconfont icon-public-notice notice"></i>-->
31 32
     <!--<div class="noticeNews">-->
@@ -96,10 +97,6 @@
96 97
       </div>
97 98
     </div>
98 99
 
99
-
100
-
101
-
102
-
103 100
     <div class="application">
104 101
       <div class="applicationTitle">
105 102
         <div class="applicationName">应用工作台</div>
@@ -125,6 +122,7 @@
125 122
   export default {
126 123
     data() {
127 124
       return {
125
+        show: false,
128 126
         value1: 0,
129 127
         isCreateOrg: false,
130 128
         isSubSuperAdmin:false,
@@ -242,6 +240,7 @@
242 240
             this.$router.push({ path: "/main" });
243 241
             break
244 242
           case 8:
243
+            this.$router.push({ path: "/shop" });
245 244
 
246 245
             break
247 246
           case 9:
@@ -475,6 +474,11 @@
475 474
     opacity: 0.5;
476 475
     filter: alpha(opacity=40);
477 476
   }
477
+  .van-overlay {
478
+    top: 3.125rem;
479
+    z-index: 9;
480
+  }
478 481
 }
479 482
 </style>
480
-<style lang="scss"></style>
483
+<style lang="scss">
484
+</style>

+ 4 - 1
src/pages/main/RecordPage.vue Wyświetl plik

@@ -14,7 +14,10 @@
14 14
           </router-link>-->
15 15
           <i class="iconfont icon-zuojiantou jiantou" @click="$router.go(-1)"></i>
16 16
           <span class="titleName">透析记录</span>
17
-          <van-icon class="icons" name="ellipsis" @click="show = true" />
17
+          <router-link to="/add_urgent_schedule">
18
+            <p class="order">临时排班</p>
19
+          </router-link>
20
+          <!-- <van-icon class="icons" name="ellipsis" @click="show = true" /> -->
18 21
         </div>
19 22
         <van-popup v-model="show" closeable position="top" :style="{ height: '200px' }">
20 23
           <div class="popupContent">

+ 1 - 1
src/pages/main/add_urgent_schedule.vue Wyświetl plik

@@ -113,7 +113,7 @@
113 113
         </van-row>
114 114
       </div>
115 115
     </div>
116
-    <side-bar :active_index="0"></side-bar>
116
+    <!-- <side-bar :active_index="0"></side-bar> -->
117 117
     <van-popup v-model="show_patient_picker" position="bottom" class="popup">
118 118
       <van-picker :columns="patients" value-key="name" @change="didChangePatient"></van-picker>
119 119
     </van-popup>

Plik diff jest za duży
+ 476 - 471
src/pages/main/dialog/MonitDialog.vue


Plik diff jest za duży
+ 1755 - 1492
src/pages/main/dialog/PrescriptionDialog.vue


+ 2 - 5
src/pages/main/today/dialysisMonitoring.vue Wyświetl plik

@@ -29,8 +29,7 @@
29 29
           <th v-if="isShow('置换量')&& template_id == 6" width="50px">置换量(ml)</th>
30 30
           <th v-if="isShow('置换量')&& template_id != 6" width="50px">置换量(L)</th>
31 31
 
32
-
33
-          <th v-if="isShow('电导度')" width="92px">电导度(mS/m)</th>
32
+          <th v-if="isShow('电导度')" width="92px">电导度(mS/cm)</th>
34 33
           <th v-if="isShow('置换液流量')" width="92px">置换液流量(ml/h)</th>
35 34
           <th v-if="isShow('病情变化')" width="92px">病情变化</th>
36 35
           <th v-if="isShow('处理')" width="92px">处理</th>
@@ -54,8 +53,6 @@
54 53
             {{ item.pulse_frequency ? item.pulse_frequency : "" }}
55 54
           </td>
56 55
 
57
-
58
-
59 56
           <td v-if="isShow('呼吸频率')">
60 57
             {{ item.breathing_rate ? item.breathing_rate : "" }}
61 58
           </td>
@@ -195,7 +192,7 @@
195 192
       </span>
196 193
 
197 194
       <span v-if="isShow('电导度')">
198
-        <el-table-column prop="zip" label="电导度(mS/m)" width="200" align="center">
195
+        <el-table-column prop="zip" label="电导度(mS/cm)" width="200" align="center">
199 196
           <template slot-scope="scope">{{scope.row.conductivity?scope.row.conductivity:''}}</template>
200 197
         </el-table-column>
201 198
       </span>

+ 313 - 270
src/pages/main/today/dialysisPrescription.vue Wyświetl plik

@@ -117,20 +117,17 @@
117 117
           <span class="unit" v-if="this.prescription.anticoagulant == 5">{{anticoagulant_zongliang != '0'?"ml":""}}</span>
118 118
         </li>
119 119
 
120
-
121 120
         <li v-if="isShow('钙名称')&&this.prescription.anticoagulant == 5">
122 121
           <label>钙名称: </label>
123 122
           <span class="content">{{this.prescription.anticoagulant_gaimingcheng}}</span>
124 123
         </li>
125 124
 
126
-
127 125
         <li v-if="isShow('钙剂量')&&this.prescription.anticoagulant == 5">
128 126
           <label>钙剂量: </label>
129 127
           <span class="content">{{this.prescription.anticoagulant_gaijiliang}}</span>
130 128
           <span class="unit" v-if="this.prescription.anticoagulant == 5">{{'ml'}}</span>
131 129
         </li>
132 130
 
133
-
134 131
         <li v-if="isShow('钠')">
135 132
           <label>钠 : </label>
136 133
           <span class="content">{{sodium != '0'?sodium:""}}</span>
@@ -204,7 +201,7 @@
204 201
         <li v-if="isShow('电导度')">
205 202
           <label>电导度 : </label>
206 203
           <span class="content">{{conductivity != '0'?conductivity:""}}</span>
207
-          <span class="unit">{{conductivity != '0'?"mS/m":""}}</span>
204
+          <span class="unit">{{conductivity != '0'?"mS/cm":""}}</span>
208 205
         </li>
209 206
 
210 207
       </ul>
@@ -214,291 +211,337 @@
214 211
 </template>
215 212
 
216 213
 <script>
217
-  import {getDataConfig} from '@/utils/data'
218
-  export default {
219
-    name: 'DialysisPrescription',
220
-    data () {
221
-      return {
222
-        title: '透析处方',
223
-        perfusion_apparatus_map: {},
224
-        dialysateFormulationMap: {}
214
+import { getDataConfig } from "@/utils/data";
215
+export default {
216
+  name: "DialysisPrescription",
217
+  data() {
218
+    return {
219
+      title: "透析处方",
220
+      perfusion_apparatus_map: {},
221
+      dialysateFormulationMap: {}
222
+    };
223
+  },
224
+  props: {
225
+    prescription: {
226
+      type: Object
227
+    },
228
+    solution: {
229
+      type: Object
230
+    },
231
+    device_number_map: {
232
+      type: Object
233
+    }
234
+  },
235
+  computed: {
236
+    target_ultrafiltration: function() {
237
+      var v = this.getValueStr(
238
+        "target_ultrafiltration",
239
+        "target_ultrafiltration"
240
+      );
241
+      v = this.getFloat(v);
242
+      return v.length == 0 ? "0" : v;
243
+    },
244
+    dialysis_mode: function() {
245
+      var mode = this.getValueStr("mode_id", "mode_id");
246
+      if (mode.length == 0) {
247
+        return "";
225 248
       }
249
+      if (this.$store.getters.treatment_mode[mode] != undefined) {
250
+        return this.$store.getters.treatment_mode[mode].name;
251
+      }
252
+      return "";
226 253
     },
227
-    props: {
228
-      prescription: {
229
-        type: Object
230
-      },
231
-      solution: {
232
-        type: Object
233
-      },
234
-      device_number_map: {
235
-        type: Object
254
+    perfusion_apparatus: function() {
255
+      var v = this.getValueStr("perfusion_apparatus", "perfusion_apparatus");
256
+      if (v.length == 0) {
257
+        return "";
258
+      }
259
+      if (this.perfusion_apparatus_map[v] != undefined) {
260
+        return this.perfusion_apparatus_map[v].name;
236 261
       }
262
+      return "";
263
+    },
264
+    displace_liqui: function() {
265
+      var v = this.getValueStr("displace_liqui", "displace_liqui");
266
+      return v.length == 0 ? "0" : v;
267
+    },
268
+    anticoagulant_shouji: function() {
269
+      var v = this.getValueStr("anticoagulant_shouji", "anticoagulant_shouji");
270
+      return v.length == 0 ? "0" : v;
271
+    },
272
+    kalium: function() {
273
+      var v = this.getValueStr("kalium", "kalium");
274
+      v = this.getFloat(v);
275
+      return v == 0 ? "0" : v;
276
+    },
277
+    replacement_total: function() {
278
+      var v = this.getValueStr("replacement_total", "replacement_total");
279
+      return v.length == 0 ? "0" : v;
280
+    },
281
+    bicarbonate: function() {
282
+      var v = this.getValueStr("bicarbonate", "bicarbonate");
283
+      return v.length == 0 ? "0" : v;
284
+    },
285
+    dialysate_flow: function() {
286
+      var v = this.getValueStr("dialysate_flow", "dialysate_flow");
287
+      return v.length == 0 ? "0" : v;
288
+    },
289
+    dialysis_duration: function() {
290
+      var dialysis_duration_hour = this.getValueStr(
291
+        "dialysis_duration_hour",
292
+        "dialysis_duration_hour"
293
+      );
294
+      var dialysis_duration_minute = this.getValueStr(
295
+        "dialysis_duration_minute",
296
+        "dialysis_duration_minute"
297
+      );
298
+      if (
299
+        dialysis_duration_hour.length == 0 &&
300
+        dialysis_duration_minute.length == 0
301
+      ) {
302
+        return "0";
303
+      } else {
304
+        var time =
305
+          dialysis_duration_hour + "h" + dialysis_duration_minute + "min";
306
+        return time.length == 0 ? "0" : time;
307
+      }
308
+    },
309
+    blood_flow_volume: function() {
310
+      var v = this.getValueStr("blood_flow_volume", "blood_flow_volume");
311
+      return v.length == 0 ? "0" : v;
312
+    },
313
+    replacement_way: function() {
314
+      return this.getValueStr("replacement_way", "replacement_way");
315
+    },
316
+    anticoagulant_weichi: function() {
317
+      var v = this.getValueStr("anticoagulant_weichi", "anticoagulant_weichi");
318
+      return v.length == 0 ? "0" : v;
319
+    },
320
+    sodium: function() {
321
+      var v = this.getValueStr("sodium", "sodium");
322
+      console.log(v);
323
+      v = this.getFloat(v);
324
+      console.log(v);
325
+      return v == 0 ? "0" : v;
326
+    },
327
+    glucose: function() {
328
+      var v = this.getValueStr("glucose", "glucose");
329
+      return v.length == 0 ? "0" : v;
330
+    },
331
+    dialysate_temperature: function() {
332
+      var v = this.getValueStr(
333
+        "dialysate_temperature",
334
+        "dialysate_temperature"
335
+      );
336
+      return v.length == 0 ? "0" : v;
337
+    },
338
+    dialyzer: function() {
339
+      var v = this.getValueStr("dialyzer", "hemodialysis_machine");
340
+      if (v.length == 0) {
341
+        return "";
342
+      }
343
+      if (this.device_number_map[v] != undefined) {
344
+        return this.device_number_map[v].name;
345
+      }
346
+      return "";
347
+    },
348
+    dialysate_formulation: function() {
349
+      var v = this.getValueStr(
350
+        "dialysate_formulation",
351
+        "dialysate_formulation"
352
+      );
353
+      if (v.length == 0) {
354
+        return "";
355
+      }
356
+      if (v in this.dialysateFormulationMap) {
357
+        return this.dialysateFormulationMap[v].name;
358
+      }
359
+      return "";
360
+    },
361
+    prescription_dewatering: function() {
362
+      var v = this.getValueStr("prescription_dewatering", "dewater");
363
+      return v.length == 0 ? "0" : v;
364
+    },
365
+    anticoagulant: function() {
366
+      var v = this.getValueStr("anticoagulant", "anticoagulant");
367
+      if (v.length == 0) {
368
+        return "";
369
+      }
370
+      if (this.$store.getters.anticoagulants_confit[v] != undefined) {
371
+        return this.$store.getters.anticoagulants_confit[v].name;
372
+      }
373
+      return "";
374
+    },
375
+    anticoagulant_zongliang: function() {
376
+      var v = this.getValueStr(
377
+        "anticoagulant_zongliang",
378
+        "anticoagulant_zongliang"
379
+      );
380
+      return v.length == 0 ? "0" : v;
381
+    },
382
+    calcium: function() {
383
+      var v = this.getValueStr("calcium", "calcium");
384
+      v = this.getFloat(v);
385
+      return v == 0 ? "0" : v;
237 386
     },
238
-    computed: {
239
-      target_ultrafiltration: function () {
240
-        var v = this.getValueStr('target_ultrafiltration', 'target_ultrafiltration')
241
-        v = this.getFloat(v)
242
-        return v.length == 0 ? '0' : v
243
-      },
244
-      dialysis_mode: function () {
245
-        var mode = this.getValueStr('mode_id', 'mode_id')
246
-        if (mode.length == 0) {
247
-          return ''
248
-        }
249
-        if (this.$store.getters.treatment_mode[mode] != undefined) {
250
-          return this.$store.getters.treatment_mode[mode].name
251
-        }
252
-        return ''
253
-      },
254
-      perfusion_apparatus: function () {
255
-        var v = this.getValueStr('perfusion_apparatus', 'perfusion_apparatus')
256
-        if (v.length == 0) {
257
-          return ''
258
-        }
259
-        if (this.perfusion_apparatus_map[v] != undefined) {
260
-          return this.perfusion_apparatus_map[v].name
261
-        }
262
-        return ''
263
-      },
264
-      displace_liqui: function () {
265
-        var v = this.getValueStr('displace_liqui', 'displace_liqui')
266
-        return v.length == 0 ? '0' : v
267
-      },
268
-      anticoagulant_shouji: function () {
269
-        var v = this.getValueStr('anticoagulant_shouji', 'anticoagulant_shouji')
270
-        return v.length == 0 ? '0' : v
271
-      },
272
-      kalium: function () {
273
-        var v = this.getValueStr('kalium', 'kalium')
274
-        v = this.getFloat(v)
275
-        return v == 0 ? '0' : v
276
-      },
277
-      replacement_total: function () {
278
-        var v = this.getValueStr('replacement_total', 'replacement_total')
279
-        return v.length == 0 ? '0' : v
280
-      },
281
-      bicarbonate: function () {
282
-        var v = this.getValueStr('bicarbonate', 'bicarbonate')
283
-        return v.length == 0 ? '0' : v
284
-      },
285
-      dialysate_flow: function () {
286
-        var v = this.getValueStr('dialysate_flow', 'dialysate_flow')
287
-        return v.length == 0 ? '0' : v
288
-      },
289
-      dialysis_duration: function () {
290
-        var dialysis_duration_hour = (this.getValueStr('dialysis_duration_hour', 'dialysis_duration_hour'))
291
-        var dialysis_duration_minute = (this.getValueStr('dialysis_duration_minute', 'dialysis_duration_minute'))
292
-        if (dialysis_duration_hour.length == 0 && dialysis_duration_minute.length == 0) {
293
-          return '0'
294
-        } else {
295
-          var time = dialysis_duration_hour + 'h' + dialysis_duration_minute + 'min'
296
-          return time.length == 0 ? '0' : time
297
-        }
298
-      },
299
-      blood_flow_volume: function () {
300
-        var v = this.getValueStr('blood_flow_volume', 'blood_flow_volume')
301
-        return v.length == 0 ? '0' : v
302
-      },
303
-      replacement_way: function () {
304
-        return this.getValueStr('replacement_way', 'replacement_way')
305
-      },
306
-      anticoagulant_weichi: function () {
307
-        var v = this.getValueStr('anticoagulant_weichi', 'anticoagulant_weichi')
308
-        return v.length == 0 ? '0' : v
309
-      },
310
-      sodium: function () {
311
-        var v = this.getValueStr('sodium', 'sodium')
312
-        console.log(v)
313
-        v = this.getFloat(v)
314
-        console.log(v)
315
-        return v == 0 ? '0' : v
316
-      },
317
-      glucose: function () {
318
-        var v = this.getValueStr('glucose', 'glucose')
319
-        return v.length == 0 ? '0' : v
320
-      },
321
-      dialysate_temperature: function () {
322
-        var v = this.getValueStr('dialysate_temperature', 'dialysate_temperature')
323
-        return v.length == 0 ? '0' : v
324
-      },
325
-      dialyzer: function () {
326
-        var v = this.getValueStr('dialyzer', 'hemodialysis_machine')
327
-        if (v.length == 0) {
328
-          return ''
329
-        }
330
-        if (this.device_number_map[v] != undefined) {
331
-          return this.device_number_map[v].name
332
-        }
333
-        return ''
334
-      },
335
-      dialysate_formulation: function () {
336
-        var v = this.getValueStr('dialysate_formulation', 'dialysate_formulation')
337
-        if (v.length == 0) {
338
-          return ''
339
-        }
340
-        if (v in this.dialysateFormulationMap) {
341
-          return this.dialysateFormulationMap[v].name
342
-        }
343
-        return ''
344
-      },
345
-      prescription_dewatering: function () {
346
-        var v = this.getValueStr('prescription_dewatering', 'dewater')
347
-        return v.length == 0 ? '0' : v
348
-      },
349
-      anticoagulant: function () {
350
-        var v = this.getValueStr('anticoagulant', 'anticoagulant')
351
-        if (v.length == 0) {
352
-          return ''
353
-        }
354
-        if (this.$store.getters.anticoagulants_confit[v] != undefined) {
355
-          return this.$store.getters.anticoagulants_confit[v].name
356
-        }
357
-        return ''
358
-      },
359
-      anticoagulant_zongliang: function () {
360
-        var v = this.getValueStr('anticoagulant_zongliang', 'anticoagulant_zongliang')
361
-        return v.length == 0 ? '0' : v
362
-      },
363
-      calcium: function () {
364
-        var v = this.getValueStr('calcium', 'calcium')
365
-        v = this.getFloat(v)
366
-        return v == 0 ? '0' : v
367
-      },
368 387
 
369
-      conductivity: function () {
370
-        var v = this.getValueStr('conductivity', 'conductivity')
371
-        return v.length == 0 ? '0' : v
372
-      },
373
-      dialyzer_perfusion_apparatus: function () {
374
-        return this.getValueStr('dialyzer_perfusion_apparatus', 'dialyzer_perfusion_apparatus')
375
-      },
376
-      note: function () {
377
-        return this.getValueStr('remark', 'remark')
378
-      },
379
-      body_fluid: function () {
380
-        var id = this.getValueStr('body_fluid', 'body_fluid')
381
-        if (id == 0) {
382
-          return ''
383
-        }
384
-        var bodyFluidOptions = this.$store.getters.body_fluid
385
-        for (let i = 0; i < bodyFluidOptions.length; i++) {
386
-          if (bodyFluidOptions[i].id == id) {
387
-            return bodyFluidOptions[i].name
388
-          }
389
-        }
390
-      },
391
-      special_medicine: function () {
392
-        var id = this.getValueStr('special_medicine', 'special_medicine')
393
-        if (id == 0) {
394
-          return ''
395
-        }
396
-        var special_medicine = this.$store.getters.special_medicine
397
-        for (let i = 0; i < special_medicine.length; i++) {
398
-          if (special_medicine[i].id == id) {
399
-            return special_medicine[i].name
400
-          }
401
-        }
402
-      },
403
-      special_medicine_other: function () {
404
-        return this.getValueStr('special_medicine_other', 'special_medicine_other')
405
-      },
406
-      blood_access: function () {
407
-        var id = this.getValueStr('blood_access', 'blood_access')
408
-        if (id == 0) {
409
-          return ''
388
+    conductivity: function() {
389
+      var v = this.getValueStr("conductivity", "conductivity");
390
+      return v.length == 0 ? "0" : v;
391
+    },
392
+    dialyzer_perfusion_apparatus: function() {
393
+      return this.getValueStr(
394
+        "dialyzer_perfusion_apparatus",
395
+        "dialyzer_perfusion_apparatus"
396
+      );
397
+    },
398
+    note: function() {
399
+      return this.getValueStr("remark", "remark");
400
+    },
401
+    body_fluid: function() {
402
+      var id = this.getValueStr("body_fluid", "body_fluid");
403
+      if (id == 0) {
404
+        return "";
405
+      }
406
+      var bodyFluidOptions = this.$store.getters.body_fluid;
407
+      for (let i = 0; i < bodyFluidOptions.length; i++) {
408
+        if (bodyFluidOptions[i].id == id) {
409
+          return bodyFluidOptions[i].name;
410 410
         }
411
-        var blood_access = this.$store.getters.blood_access
412
-        console.log('blood_access', blood_access)
413
-        for (let i = 0; i < blood_access.length; i++) {
414
-          if (blood_access[i].id == id) {
415
-            return blood_access[i].name
416
-          }
411
+      }
412
+    },
413
+    special_medicine: function() {
414
+      var id = this.getValueStr("special_medicine", "special_medicine");
415
+      if (id == 0) {
416
+        return "";
417
+      }
418
+      var special_medicine = this.$store.getters.special_medicine;
419
+      for (let i = 0; i < special_medicine.length; i++) {
420
+        if (special_medicine[i].id == id) {
421
+          return special_medicine[i].name;
417 422
         }
418
-      },
419
-      displace_liqui: function () {
420
-        var id = this.getValueStr('displace_liqui_part', 'displace_liqui_part')
421
-        var displace_liqui_value = this.getValueStr('displace_liqui_value', 'displace_liqui_value')
422
-        var displace_liqui_part = ''
423
-        var displace_liqui = this.$store.getters.displace_liqui
424
-        for (let i = 0; i < displace_liqui.length; i++) {
425
-          if (displace_liqui[i].id == id) {
426
-            displace_liqui_part = displace_liqui[i].name
427
-          }
423
+      }
424
+    },
425
+    special_medicine_other: function() {
426
+      return this.getValueStr(
427
+        "special_medicine_other",
428
+        "special_medicine_other"
429
+      );
430
+    },
431
+    blood_access: function() {
432
+      var id = this.getValueStr("blood_access", "blood_access");
433
+      if (id == 0) {
434
+        return "";
435
+      }
436
+      var blood_access = this.$store.getters.blood_access;
437
+      console.log("blood_access", blood_access);
438
+      for (let i = 0; i < blood_access.length; i++) {
439
+        if (blood_access[i].id == id) {
440
+          return blood_access[i].name;
428 441
         }
429
-        return displace_liqui_part
430
-      },
431
-      ultrafiltration: function () {
432
-        var v = this.getValueStr('ultrafiltration', 'ultrafiltration')
433
-        v = this.getFloat(v)
434
-        return v.length == 0 ? '0' : v
435
-      },
436
-      target_ktv: function () {
437
-        var v = this.getValueStr('target_ktv', 'target_ktv')
438
-        return v.length == 0 ? '0' : v
439 442
       }
440 443
     },
441
-    created () {
442
-      var perfusion_apparatus = this.$store.getters.perfusion_apparatus
443
-      var map = {}
444
-      for (let index = 0; index < perfusion_apparatus.length; index++) {
445
-        const p = perfusion_apparatus[index]
446
-        map[p.id] = p
444
+    displace_liqui: function() {
445
+      var id = this.getValueStr("displace_liqui_part", "displace_liqui_part");
446
+      var displace_liqui_value = this.getValueStr(
447
+        "displace_liqui_value",
448
+        "displace_liqui_value"
449
+      );
450
+      var displace_liqui_part = "";
451
+      var displace_liqui = this.$store.getters.displace_liqui;
452
+      for (let i = 0; i < displace_liqui.length; i++) {
453
+        if (displace_liqui[i].id == id) {
454
+          displace_liqui_part = displace_liqui[i].name;
455
+        }
447 456
       }
448
-      this.perfusion_apparatus_map = map
457
+      return displace_liqui_part;
458
+    },
459
+    ultrafiltration: function() {
460
+      var v = this.getValueStr("ultrafiltration", "ultrafiltration");
461
+      v = this.getFloat(v);
462
+      return v.length == 0 ? "0" : v;
463
+    },
464
+    target_ktv: function() {
465
+      var v = this.getValueStr("target_ktv", "target_ktv");
466
+      return v.length == 0 ? "0" : v;
467
+    }
468
+  },
469
+  created() {
470
+    var perfusion_apparatus = this.$store.getters.perfusion_apparatus;
471
+    var map = {};
472
+    for (let index = 0; index < perfusion_apparatus.length; index++) {
473
+      const p = perfusion_apparatus[index];
474
+      map[p.id] = p;
475
+    }
476
+    this.perfusion_apparatus_map = map;
449 477
 
450
-      var dialysateFormulationOptions = getDataConfig('hemodialysis', 'dialysate_formulation')
451
-      for (var index in dialysateFormulationOptions) {
452
-        this.dialysateFormulationMap[dialysateFormulationOptions[index].id] = dialysateFormulationOptions[index]
478
+    var dialysateFormulationOptions = getDataConfig(
479
+      "hemodialysis",
480
+      "dialysate_formulation"
481
+    );
482
+    for (var index in dialysateFormulationOptions) {
483
+      this.dialysateFormulationMap[dialysateFormulationOptions[index].id] =
484
+        dialysateFormulationOptions[index];
485
+    }
486
+  },
487
+  methods: {
488
+    getDisplaceLiquiValue: function() {
489
+      return this.getValueStr("displace_liqui_value", "displace_liqui_value");
490
+    },
491
+    isShow(name) {
492
+      var filedList = this.$store.getters.user.fileds;
493
+      for (let i = 0; i < filedList.length; i++) {
494
+        if (
495
+          filedList[i].module == 1 &&
496
+          filedList[i].filed_name_cn == name &&
497
+          filedList[i].is_show == 1
498
+        ) {
499
+          return true;
500
+        }
453 501
       }
502
+      return false;
454 503
     },
455
-    methods: {
456
-      getDisplaceLiquiValue:function(){
457
-        return this.getValueStr('displace_liqui_value', 'displace_liqui_value')
458
-      },
459
-      isShow (name) {
460
-        var filedList = this.$store.getters.user.fileds
461
-        for (let i = 0; i < filedList.length; i++) {
462
-          if (filedList[i].module == 1 && filedList[i].filed_name_cn == name && filedList[i].is_show == 1) {
463
-            return true
464
-          }
504
+    getValueStr(pkey, skey) {
505
+      if (
506
+        (this.prescription == null || this.prescription.id == "") &&
507
+        (this.solution == null || this.solution.id == "")
508
+      ) {
509
+        return "";
510
+      } else if (this.prescription != null && this.prescription.id != "") {
511
+        if (
512
+          this.prescription[pkey] == null ||
513
+          this.prescription[pkey] == undefined
514
+        ) {
515
+          return "";
516
+        }
517
+        return this.prescription[pkey] + "";
518
+      } else {
519
+        if (this.solution[skey] == null || this.solution[skey] == undefined) {
520
+          return "";
465 521
         }
466
-        return false
467
-      },
468
-      getValueStr (pkey, skey) {
469
-        if ((this.prescription == null || this.prescription.id == '') && (this.solution == null || this.solution.id == '')) {
470
-          return ''
471
-        } else if (this.prescription != null && this.prescription.id != '') {
472
-          if (this.prescription[pkey] == null || this.prescription[pkey] == undefined) {
473
-            return ''
474
-          }
475
-          return this.prescription[pkey] + ''
476
-        } else {
477
-          if (this.solution[skey] == null || this.solution[skey] == undefined) {
478
-            return ''
479
-          }
480
-          return this.solution[skey] + ''
522
+        return this.solution[skey] + "";
523
+      }
524
+    },
525
+    getFloat: function(x) {
526
+      if (x != ".") {
527
+        var f = Math.round(x * 100) / 100;
528
+        var s = f.toString();
529
+        var rs = s.indexOf(".");
530
+        if (rs <= 0) {
531
+          rs = s.length;
532
+          s += ".";
481 533
         }
482
-      },
483
-      getFloat: function (x) {
484
-        if (x != '.') {
485
-          var f = Math.round(x * 100) / 100
486
-          var s = f.toString()
487
-          var rs = s.indexOf('.')
488
-          if (rs <= 0) {
489
-            rs = s.length
490
-            s += '.'
491
-          }
492
-          while (s.length <= rs + 1) {
493
-            s += '0'
494
-          }
495
-          return s
496
-        } else {
497
-          return '0.0'
534
+        while (s.length <= rs + 1) {
535
+          s += "0";
498 536
         }
537
+        return s;
538
+      } else {
539
+        return "0.0";
499 540
       }
500 541
     }
501 542
   }
543
+};
502 544
 </script>
503 545
 
504
-<style rel="stylesheet/scss" lang="scss" scoped></style>
546
+<style rel="stylesheet/scss" lang="scss" scoped>
547
+</style>

+ 52 - 28
src/pages/my/index.vue Wyświetl plik

@@ -2,25 +2,24 @@
2 2
   <div class="page_my">
3 3
     <div class="myTop">
4 4
       <img src="../../assets/images/myBanner.png" alt />
5
-      <router-link to="/myInfo">
6 5
         <div class="avatar">
7 6
           <img v-if="roleInfo.avatar != ''" :src="roleInfo.avatar" alt />
8 7
           <img
9 8
             v-if="roleInfo.avatar == ''"
10
-            src="../../assets/images/default_avatar.jpg"
9
+            src="../../assets/images/mydefault.png"
11 10
             alt
12 11
           />
13 12
         </div>
14
-        <div class="userMain">
13
+        <div class="userMain" @click="toMyIndex">
15 14
           <div class="userBox">
16 15
             <div class="userTxt">
17
-              <p class="userName">{{ roleInfo.user_name }}</p>
16
+              <span v-if="roleInfo.user_name!=''"><p class="userName">{{ roleInfo.user_name }}</p></span>
17
+                <span v-if="roleInfo.user_name==''"><p class="userName">{{ userName.name }}</p></span>
18 18
               <p class="signature">{{ roleInfo.message }}</p>
19 19
             </div>
20 20
             <van-icon name="arrow" />
21 21
           </div>
22 22
         </div>
23
-      </router-link>
24 23
       <div class="invitebox">
25 24
         <img src="../../assets/images/invite.png" alt />
26 25
       </div>
@@ -35,15 +34,15 @@
35 34
       <router-link to="/ElectronicSignature">
36 35
         <div class="myInfo1">
37 36
           <div class="myInfoLeft">
38
-            <img src="../../assets/images/myIcon1.png" alt />
37
+            <img src="../../assets/images/myIcon9.png" alt />
39 38
             <p>电子签名</p>
40 39
           </div>
41 40
           <van-icon class="arrow" name="arrow" />
42 41
         </div>
43 42
       </router-link>
44 43
     </div>
44
+
45 45
     <div class="myBox">
46
-      <router-link to="/organizationInfo">
47 46
         <div class="myBoxOne">
48 47
           <div class="myInfoLeft">
49 48
             <img src="../../assets/images/myIcon2.png" alt />
@@ -51,24 +50,15 @@
51 50
           </div>
52 51
           <van-icon class="arrow" name="arrow" />
53 52
         </div>
54
-      </router-link>
55
-      <div class="myBoxTwo">
56
-        <div class="myInfoLeft">
57
-          <img src="../../assets/images/m01.png" alt />
58
-          <p>我的医院/组织/团队</p>
59
-        </div>
60
-        <div class="myInfoRight">
61
-          <van-icon class="arrow" name="arrow" />
62
-        </div>
63
-      </div>
64
-      <div class="myBoxTwo noBorder">
53
+      <div class="myBoxTwo noBorder" v-for="(item,index) in organaziton" :key="index">
65 54
         <div class="myInfoLeft">
66
-          <img src="../../assets/images/m01.png" alt />
67
-          <p>我的医院/组织/团队</p>
55
+          <span v-if="item.org_logo == ''"><img src="../../assets/images/m01.png" alt /></span>
56
+          <span v-if="item.org_logo !==''"><img :src="item.org_logo"></span>
57
+          <p>{{item.org_name}}</p>
68 58
         </div>
69
-        <div class="myInfoRight" @click="toManage">
70
-          <div class="myInfoRightBtn">管理</div>
71
-          <van-icon class="arrow" name="arrow" />
59
+        <div class="myInfoRight" v-if="item.is_super_admin == 1">
60
+          <div class="myInfoRightBtn" @click="toEditOrg()">管理</div>
61
+          <van-icon class="arrow" name="arrow"  @click="toManage"/>
72 62
         </div>
73 63
       </div>
74 64
     </div>
@@ -133,13 +123,21 @@
133 123
   </div>
134 124
 </template>
135 125
 <script>
136
-import { getMyInformation, LoginOut } from "@/api/patient/patient";
126
+import {
127
+  getMyInformation,
128
+  LoginOut,
129
+  getMyOrganazition,
130
+  getMyInforName
131
+} from "@/api/patient/patient";
137 132
 import { uParseTime } from "@/utils/tools";
138 133
 export default {
139 134
   data() {
140 135
     return {
141 136
       roleInfo: {},
142
-      admin_user_id: 0
137
+      admin_user_id: 0,
138
+      adminid: 0,
139
+      organaziton: [],
140
+      userName: {}
143 141
     };
144 142
   },
145 143
   methods: {
@@ -160,11 +158,30 @@ export default {
160 158
       getMyInformation(id).then(response => {
161 159
         if (response.data.state === 1) {
162 160
           var roleInfo = response.data.data.roleInfo;
161
+          console.log("roleInfo", roleInfo);
163 162
           this.admin_user_id = roleInfo.id;
163
+          this.adminid = roleInfo.admin_user_id;
164 164
           this.roleInfo = roleInfo;
165 165
         }
166 166
       });
167 167
     },
168
+    getMyOrganazition(id) {
169
+      getMyOrganazition(id).then(response => {
170
+        if (response.data.state === 1) {
171
+          var organaziton = response.data.data.organaziton;
172
+          this.organaziton = organaziton;
173
+        }
174
+      });
175
+    },
176
+    getMyInforName(id) {
177
+      getMyInforName(id).then(response => {
178
+        if (response.data.state === 1) {
179
+          var Rolename = response.data.data.Rolename;
180
+          var username = response.data.data.Username;
181
+          this.userName = username;
182
+        }
183
+      });
184
+    },
168 185
     getTime(time) {
169 186
       // return uParseTime(time, "{y}-{m}-{d} {h}:{i}:{s}");
170 187
       return uParseTime(time, "{y}-{m}-{d}");
@@ -176,13 +193,20 @@ export default {
176 193
       this.$router.push("/myInfo?id=" + this.admin_user_id);
177 194
     },
178 195
     toManage() {
179
-      this.$router.push("/organizationinfo?id=" + this.admin_user_id);
196
+      this.$router.push("/organizationinfo?id=" + this.adminid);
197
+    },
198
+    toEditOrg() {
199
+      this.$router.push("/newMy");
200
+    },
201
+    toMyIndex() {
202
+      this.$router.push("/myInfo?id=" + this.admin_user_id);
180 203
     }
181 204
   },
182 205
   created() {
183 206
     var adminid = this.$store.getters.user.user.id;
184
-    console.log("adminid", adminid);
185 207
     this.getMyInformation(adminid);
208
+    this.getMyOrganazition(adminid);
209
+    this.getMyInforName(adminid);
186 210
   }
187 211
 };
188 212
 </script>
@@ -206,7 +230,7 @@ export default {
206 230
       width: 4.375rem;
207 231
       height: 4.375rem;
208 232
       background: rgba(50, 50, 50, 1);
209
-      border: 2px solid rgba(255, 255, 255, 1);
233
+      // border: 2px solid rgba(255, 255, 255, 1);
210 234
       border-radius: 50%;
211 235
       img {
212 236
         border-radius: 50%;

+ 46 - 4
src/pages/my/modifyingName.vue Wyświetl plik

@@ -3,15 +3,57 @@
3 3
     <div class="modifyingNameTitle">
4 4
       <i class="iconfont icon-zuojiantou jiantou" @click="$router.go(-1)"></i>
5 5
       <span class="titleName">修改姓名</span>
6
-      <span>保存</span>
6
+      <span @click="saveName">保存</span>
7 7
     </div>
8 8
     <div class="nameBox">
9
-      <van-field v-model="value" placeholder="请填写姓名" />
9
+      <van-field v-model="name" placeholder="请填写姓名" />
10 10
     </div>
11 11
   </div>
12 12
 </template>
13
-
14
-
13
+<script>
14
+import { saveName, getMyInforName } from "@/api/patient/patient";
15
+export default {
16
+  data() {
17
+    return {
18
+      name: "",
19
+      admin_user_id: 0
20
+    };
21
+  },
22
+  methods: {
23
+    getMyInforName(id) {
24
+      getMyInforName(id).then(response => {
25
+        if (response.data.state === 1) {
26
+          var Rolename = response.data.data.Rolename;
27
+          var username = response.data.data.Username;
28
+          if (Rolename.user_name != "") {
29
+            this.name = Rolename.user_name;
30
+          }
31
+          if (Rolename.user_name == "") {
32
+            this.name = username.name;
33
+          }
34
+        }
35
+      });
36
+    },
37
+    saveName() {
38
+      if (this.name === "") {
39
+        this.$toast("姓名不能为空");
40
+        return false;
41
+      }
42
+      saveName(this.admin_user_id, this.name).then(response => {
43
+        if (response.data.state === 1) {
44
+          var role = response.data.data.role;
45
+          this.$router.push("/myInfo?id=" + this.admin_user_id);
46
+        }
47
+      });
48
+    }
49
+  },
50
+  created() {
51
+    var id = this.$route.query.id;
52
+    this.getMyInforName(id);
53
+    this.admin_user_id = id;
54
+  }
55
+};
56
+</script>
15 57
 <style lang="scss" scoped>
16 58
 .page_modifyingName {
17 59
   height: 100%;

+ 23 - 13
src/pages/my/myInfo.vue Wyświetl plik

@@ -11,21 +11,19 @@
11 11
           <img v-if="roleInfo.avatar != ''" :src="roleInfo.avatar" alt />
12 12
           <img
13 13
             v-if="roleInfo.avatar == ''"
14
-            src="../../assets/images/default_avatar.jpg"
14
+            src="../../assets/images/mydefault.png"
15 15
             alt
16 16
           />
17 17
           <van-icon class="arrow" name="arrow" />
18 18
         </div>
19 19
       </div>
20
-      <router-link to="/editname">
21
-        <div class="infoBoxTwo">
20
+        <div class="infoBoxTwo" @click="editName">
22 21
           <p>姓名</p>
23 22
           <div class="infoBoxOneRight">
24 23
             <p>{{ roleInfo.user_name }}</p>
25 24
             <van-icon class="arrow" name="arrow" />
26 25
           </div>
27 26
         </div>
28
-      </router-link>
29 27
       <div class="infoBoxTwo" @click="show = true">
30 28
         <p>性别</p>
31 29
         <div class="infoBoxOneRight">
@@ -73,7 +71,7 @@
73 71
 </template>
74 72
 
75 73
 <script>
76
-import { getMyInformation, SaveSex, SaveBirthday } from "@/api/patient/patient";
74
+import { getMyInforName, SaveSex, SaveBirthday } from "@/api/patient/patient";
77 75
 import { uParseTime } from "@/utils/tools";
78 76
 export default {
79 77
   data() {
@@ -86,7 +84,11 @@ export default {
86 84
       minDate: new Date(1900, 0, 1),
87 85
       maxDate: new Date(2025, 10, 1),
88 86
       currentDate: new Date(),
89
-      roleInfo: {},
87
+      roleInfo: {
88
+        avatar: "",
89
+        user_name: "",
90
+        message: ""
91
+      },
90 92
       admin_user_id: "",
91 93
       form: {
92 94
         sex: ""
@@ -94,11 +96,11 @@ export default {
94 96
     };
95 97
   },
96 98
   methods: {
97
-    getMyInformation(id) {
98
-      getMyInformation(id).then(response => {
99
+    getMyInforName(id) {
100
+      getMyInforName(id).then(response => {
99 101
         if (response.data.state === 1) {
100
-          var roleInfo = response.data.data.roleInfo;
101
-          console.log("roleInfo", roleInfo);
102
+          var roleInfo = response.data.data.Rolename;
103
+          var username = response.data.data.Username;
102 104
           if (roleInfo.sex === 1) {
103 105
             this.sex = "男";
104 106
           }
@@ -106,14 +108,22 @@ export default {
106 108
             this.sex = "女";
107 109
           }
108 110
           this.birthday = this.getTime(roleInfo.birthday);
109
-
110
-          this.roleInfo = roleInfo;
111
+          this.roleInfo.user_name = roleInfo.user_name;
112
+          this.roleInfo.avatar = roleInfo.avatar;
113
+          this.roleInfo.message = roleInfo.message;
114
+          if (roleInfo.user_name == "") {
115
+            this.roleInfo.user_name = username.name;
116
+          }
117
+          this.userName = username;
111 118
         }
112 119
       });
113 120
     },
114 121
     toMyPersonalsign() {
115 122
       this.$router.push("/personalsign?id=" + this.admin_user_id);
116 123
     },
124
+    editName() {
125
+      this.$router.push("/editname?id=" + this.admin_user_id);
126
+    },
117 127
     onConfirm(value) {
118 128
       if (value === "男") {
119 129
         this.form.sex = 1;
@@ -172,8 +182,8 @@ export default {
172 182
   },
173 183
   created() {
174 184
     var id = this.$route.query.id;
175
-    this.getMyInformation(id);
176 185
     this.admin_user_id = id;
186
+    this.getMyInforName(id);
177 187
   }
178 188
 };
179 189
 </script>

+ 12 - 1
src/pages/my/organizationInfo.vue Wyświetl plik

@@ -39,7 +39,11 @@
39 39
   </div>
40 40
 </template>
41 41
 <script>
42
-import { getOrgName, getRoleName } from "@/api/patient/patient";
42
+import {
43
+  getOrgName,
44
+  getRoleName,
45
+  getAllOrganization
46
+} from "@/api/patient/patient";
43 47
 export default {
44 48
   data() {
45 49
     return {
@@ -110,6 +114,12 @@ export default {
110 114
           this.positionName = positionName.user_type;
111 115
         }
112 116
       });
117
+    },
118
+    getAllOrganization(id) {
119
+      getAllOrganization(id).then(response => {
120
+        if (response.data.state == 1) {
121
+        }
122
+      });
113 123
     }
114 124
   },
115 125
   created() {
@@ -119,6 +129,7 @@ export default {
119 129
     console.log("id", id);
120 130
     this.getOrgName();
121 131
     this.getRoleName(id);
132
+    this.getAllOrganization(id);
122 133
   }
123 134
 };
124 135
 </script>

Plik diff jest za duży
+ 4503 - 0
src/pages/patientCenter/editOrg/index.vue


+ 151 - 150
src/router/index.js Wyświetl plik

@@ -1,143 +1,140 @@
1
-import Vue from "vue";
2
-import Router from "vue-router";
1
+import Vue from 'vue'
2
+import Router from 'vue-router'
3 3
 
4
-Vue.use(Router);
4
+Vue.use(Router)
5 5
 
6 6
 export default new Router({
7
-  routes: [
8
-    {
9
-      path: "/",
10
-      name: "Home",
11
-      component: () => import("@/pages/home/verifyToken")
7
+  routes: [{
8
+      path: '/',
9
+      name: 'Home',
10
+      component: () => import('@/pages/home/verifyToken')
12 11
     },
13 12
     {
14
-      path: "/login",
15
-      name: "Home",
16
-      component: () => import("@/pages/home/login")
13
+      path: '/login',
14
+      name: 'Home',
15
+      component: () => import('@/pages/home/login')
17 16
     },
18 17
     {
19
-      path: "/nopassword",
20
-      name: "Home",
21
-      component: () => import("@/pages/home/noPassword")
18
+      path: '/nopassword',
19
+      name: 'Home',
20
+      component: () => import('@/pages/home/noPassword')
22 21
     },
23 22
     {
24
-      path: "/setname",
25
-      name: "Home",
26
-      component: () => import("@/pages/home/register/name")
23
+      path: '/setname',
24
+      name: 'Home',
25
+      component: () => import('@/pages/home/register/name')
27 26
     },
28 27
     {
29
-      path: "/register",
30
-      name: "Home",
31
-      component: () => import("@/pages/home/register/register")
28
+      path: '/register',
29
+      name: 'Home',
30
+      component: () => import('@/pages/home/register/register')
32 31
     },
33 32
     {
34
-      path: "/join",
35
-      name: "Home",
36
-      component: () => import("@/pages/home/noJoinedGroup")
33
+      path: '/join',
34
+      name: 'Home',
35
+      component: () => import('@/pages/home/noJoinedGroup')
37 36
     },
38 37
     {
39
-      path: "/forget",
40
-      name: "Home",
41
-      component: () => import("@/pages/home/forgetPassword")
38
+      path: '/forget',
39
+      name: 'Home',
40
+      component: () => import('@/pages/home/forgetPassword')
42 41
     },
43 42
     {
44
-      path: "/createorg",
45
-      name: "Home",
46
-      component: () => import("@/pages/home/createOrg")
43
+      path: '/createorg',
44
+      name: 'Home',
45
+      component: () => import('@/pages/home/createOrg')
47 46
     },
48 47
     // 首页
49 48
     {
50
-      path: "/myIndex",
51
-      name: "myIndex",
52
-      component: () => import("@/pages/home/index"),
53
-      children: [
54
-        {
55
-          path: "/homeIndex",
56
-          component: () => import("@/pages/homeIndex/index.vue"),
49
+      path: '/myIndex',
50
+      name: 'myIndex',
51
+      component: () => import('@/pages/home/index'),
52
+      children: [{
53
+          path: '/homeIndex',
54
+          component: () => import('@/pages/homeIndex/index.vue'),
57 55
           meta: {
58 56
             noCache: true // 不会被 <keep-alive> 缓存
59 57
           }
60 58
         },
61 59
         // 我的
62 60
         {
63
-          path: "/newMy",
64
-          name: "newMy",
65
-          component: () => import("@/pages/my/index")
61
+          path: '/newMy',
62
+          name: 'newMy',
63
+          component: () => import('@/pages/my/index')
66 64
         },
67 65
         // 商城
68 66
         {
69
-          path: "/shop",
70
-          name: "shop",
71
-          component: () => import("@/pages/shop/index")
67
+          path: '/shop',
68
+          name: 'shop',
69
+          component: () => import('@/pages/shop/index')
72 70
         }
73 71
       ]
74 72
     },
75 73
 
76 74
     {
77
-      path: "/perfectOrg",
78
-      component: () => import("@/pages/org"),
75
+      path: '/perfectOrg',
76
+      component: () => import('@/pages/org'),
79 77
       meta: {
80 78
         noCache: true // 不会被 <keep-alive> 缓存
81 79
       }
82 80
     },
83 81
     {
84
-      path: "/manageconsole",
85
-      name: "console",
86
-      component: () => import("@/pages/console/managementConsole")
82
+      path: '/manageconsole',
83
+      name: 'console',
84
+      component: () => import('@/pages/console/managementConsole')
87 85
     },
88 86
     {
89
-      path: "/manageconsole/staff",
90
-      name: "staff",
87
+      path: '/manageconsole/staff',
88
+      name: 'staff',
91 89
       component: () =>
92
-        import("@/pages/console/managementConsole/staff_role/staffManagement")
90
+        import('@/pages/console/managementConsole/staff_role/staffManagement')
93 91
     },
94 92
     {
95
-      path: "/staff/editstaff",
96
-      name: "editstaff",
93
+      path: '/staff/editstaff',
94
+      name: 'editstaff',
97 95
       component: () =>
98
-        import("@/pages/console/managementConsole/staff_role/editStaff")
96
+        import('@/pages/console/managementConsole/staff_role/editStaff')
99 97
     }, {
100
-      path: "/staff/addstaff",
101
-      name: "addstaff",
98
+      path: '/staff/addstaff',
99
+      name: 'addstaff',
102 100
       component: () =>
103
-        import("@/pages/console/managementConsole/staff_role/addStaff")
101
+        import('@/pages/console/managementConsole/staff_role/addStaff')
104 102
     },
105 103
 
106 104
     {
107
-      path: "/manageconsole/role",
108
-      name: "role",
105
+      path: '/manageconsole/role',
106
+      name: 'role',
109 107
       component: () =>
110
-        import("@/pages/console/managementConsole/staff_role/privilegeManagement")
108
+        import('@/pages/console/managementConsole/staff_role/privilegeManagement')
111 109
     },
112 110
 
113
-
114 111
     {
115
-      path: "/role/user",
116
-      name: "user",
112
+      path: '/role/user',
113
+      name: 'user',
117 114
       component: () =>
118
-        import("@/pages/console/managementConsole/staff_role/newUser")
115
+        import('@/pages/console/managementConsole/staff_role/newUser')
119 116
     },
120 117
 
121 118
     {
122
-      path: "/role/addnewuser",
123
-      name: "user",
119
+      path: '/role/addnewuser',
120
+      name: 'user',
124 121
       component: () =>
125
-        import("@/pages/console/managementConsole/staff_role/newAddStaff")
122
+        import('@/pages/console/managementConsole/staff_role/newAddStaff')
126 123
     }, {
127
-      path: "/role/stafflist",
128
-      name: "user",
124
+      path: '/role/stafflist',
125
+      name: 'user',
129 126
       component: () =>
130
-        import("@/pages/console/managementConsole/staff_role/employeeList")
131
-    },{
132
-      path: "/role/usermanage",
133
-      name: "user",
127
+        import('@/pages/console/managementConsole/staff_role/employeeList')
128
+    }, {
129
+      path: '/role/usermanage',
130
+      name: 'user',
134 131
       component: () =>
135
-        import("@/pages/console/managementConsole/staff_role/userManage")
136
-    },{
137
-      path: "/role/addrole",
138
-      name: "add_role",
132
+        import('@/pages/console/managementConsole/staff_role/userManage')
133
+    }, {
134
+      path: '/role/addrole',
135
+      name: 'add_role',
139 136
       component: () =>
140
-        import("@/pages/console/managementConsole/staff_role/newAddRole")
137
+        import('@/pages/console/managementConsole/staff_role/newAddRole')
141 138
     },
142 139
 
143 140
     //
@@ -148,134 +145,132 @@ export default new Router({
148 145
     //     import("@/pages/console/managementConsole/staff_role/privilegeManagement")
149 146
     // },
150 147
 
151
-
152
-
153 148
     {
154
-      path: "/role/editrole",
155
-      name: "editrole",
149
+      path: '/role/editrole',
150
+      name: 'editrole',
156 151
       component: () =>
157
-        import("@/pages/console/managementConsole/staff_role/editRole")
152
+        import('@/pages/console/managementConsole/staff_role/editRole')
158 153
     },
159 154
     {
160
-      path: "/role/subpurview",
161
-      name: "purview",
155
+      path: '/role/subpurview',
156
+      name: 'purview',
162 157
       component: () =>
163
-        import("@/pages/console/managementConsole/staff_role/subPurview")
158
+        import('@/pages/console/managementConsole/staff_role/subPurview')
164 159
     },
165 160
     {
166
-      path: "/role/otherpurview",
167
-      name: "purview",
161
+      path: '/role/otherpurview',
162
+      name: 'purview',
168 163
       component: () =>
169
-        import("@/pages/console/managementConsole/staff_role/otherPurview")
164
+        import('@/pages/console/managementConsole/staff_role/otherPurview')
170 165
     }, {
171
-      path: "/role/functionpurview",
172
-      name: "purview",
166
+      path: '/role/functionpurview',
167
+      name: 'purview',
173 168
       component: () =>
174
-        import("@/pages/console/managementConsole/staff_role/functionPurview")
169
+        import('@/pages/console/managementConsole/staff_role/functionPurview')
175 170
     },
176 171
     // 患者中心
177 172
     {
178
-      path: "/patients",
179
-      name: "patients",
180
-      component: () => import("@/pages/patientManagement/patientManagement")
173
+      path: '/patients',
174
+      name: 'patients',
175
+      component: () => import('@/pages/patientManagement/patientManagement')
181 176
     },
182 177
     // 新增病人
183 178
     {
184
-      path: "/addPatints",
185
-      name: "addpatients",
186
-      component: () => import("@/pages/patients/addPatient")
179
+      path: '/addPatints',
180
+      name: 'addpatients',
181
+      component: () => import('@/pages/patients/addPatient')
187 182
     },
188 183
     // 全部病程
189 184
     {
190
-      path: "/coursedetail",
191
-      name: "coursedetail",
192
-      component: () => import("@/pages/allCourseManagement/index")
185
+      path: '/coursedetail',
186
+      name: 'coursedetail',
187
+      component: () => import('@/pages/allCourseManagement/index')
193 188
     },
194 189
     // 全部干体重
195 190
     {
196
-      path: "/dryweight",
197
-      name: "dryweight",
198
-      component: () => import("@/pages/allDryWeight/index")
191
+      path: '/dryweight',
192
+      name: 'dryweight',
193
+      component: () => import('@/pages/allDryWeight/index')
199 194
     },
200 195
     // 基本信息
201 196
     {
202
-      path: "/editPatient",
203
-      name: "editPatient",
204
-      component: () => import("@/pages/patients/editPatient")
197
+      path: '/editPatient',
198
+      name: 'editPatient',
199
+      component: () => import('@/pages/patients/editPatient')
205 200
     },
206 201
     // 全部排班
207 202
     {
208
-      path: "/editScheduling",
209
-      name: "editscheduling",
210
-      component: () => import("@/pages/allScheduling/index")
203
+      path: '/editScheduling',
204
+      name: 'editscheduling',
205
+      component: () => import('@/pages/allScheduling/index')
211 206
     },
212 207
     // 全部透后宣教
213 208
     {
214
-      path: "/editEducation",
215
-      name: "editeducation",
216
-      component: () => import("@/pages/allEducation/index")
209
+      path: '/editEducation',
210
+      name: 'editeducation',
211
+      component: () => import('@/pages/allEducation/index')
217 212
     },
218 213
     // 全部抢救记录
219 214
     {
220
-      path: "/rescuerecord",
221
-      name: "rescuerecord",
222
-      component: () => import("@/pages/allRescue/index")
215
+      path: '/rescuerecord',
216
+      name: 'rescuerecord',
217
+      component: () => import('@/pages/allRescue/index')
223 218
     },
224 219
     //
225 220
     {
226
-      path: "/patientdetail",
227
-      name: "patientdetail",
228
-      component: () => import("@/pages/doctorAdvice/index")
221
+      path: '/patientdetail',
222
+      name: 'patientdetail',
223
+      component: () => import('@/pages/doctorAdvice/index')
229 224
     },
230 225
     // 搜索
231 226
     {
232
-      path: "/search",
233
-      name: "search",
234
-      component: () => import("@/pages/search/index")
227
+      path: '/search',
228
+      name: 'search',
229
+      component: () => import('@/pages/search/index')
235 230
     },
236 231
     // 我的信息
237 232
     {
238
-      path: "/myInfo",
239
-      name: "myInfo",
240
-      component: () => import("@/pages/my/myInfo")
233
+      path: '/myInfo',
234
+      name: 'myInfo',
235
+      component: () => import('@/pages/my/myInfo')
241 236
     },
242 237
     // 意见反馈
243 238
     {
244
-      path: "/feedBack",
245
-      name: "feedBack",
246
-      component: () => import("@/pages/my/feedBack")
239
+      path: '/feedBack',
240
+      name: 'feedBack',
241
+      component: () => import('@/pages/my/feedBack')
247 242
     },
248 243
     // 关于我们
249 244
     {
250
-      path: "/about",
251
-      name: "about",
252
-      component: () => import("@/pages/my/aboutUs")
245
+      path: '/about',
246
+      name: 'about',
247
+      component: () => import('@/pages/my/aboutUs')
253 248
     },
254 249
     // 公司介绍
255 250
     {
256
-      path: "/introduce",
257
-      name: "introduce",
258
-      component: () => import("@/pages/my/companyIntroduction")
251
+      path: '/introduce',
252
+      name: 'introduce',
253
+      component: () => import('@/pages/my/companyIntroduction')
259 254
     },
260 255
     // 更改名字
261 256
     {
262
-      path: "/editname",
263
-      name: "editname",
264
-      component: () => import("@/pages/my/modifyingName")
257
+      path: '/editname',
258
+      name: 'editname',
259
+      component: () => import('@/pages/my/modifyingName')
265 260
     },
266 261
     // 更改名字
267 262
     {
268
-      path: "/personalsign",
269
-      name: "personalsign",
270
-      component: () => import("@/pages/my/personalSign")
263
+      path: '/personalsign',
264
+      name: 'personalsign',
265
+      component: () => import('@/pages/my/personalSign')
271 266
     },
272 267
 
273 268
     // 全部长期透析记录
274 269
 
275 270
     {
276
-      path: "/alllongdialysis",
277
-      name: "longdialysis",
278
-      component: () => import("@/pages/allLongDialysis/index")
271
+      path: '/alllongdialysis',
272
+      name: 'longdialysis',
273
+      component: () => import('@/pages/allLongDialysis/index')
279 274
     },
280 275
     //,
281 276
     {
@@ -301,21 +296,27 @@ export default new Router({
301 296
       name: '/addgroup',
302 297
       component: () => import('@/pages/configureCenter/newGrouping')
303 298
     },
304
-    // 新增位号
299
+    // 新增位号
305 300
     {
306 301
       path: '/addbed',
307 302
       name: '/addbed',
308 303
       component: () => import('@/pages/configureCenter/newBed')
309 304
     },
305
+    // 我的页面管理
306
+    {
307
+      path: '/editorg',
308
+      name: '/editorg',
309
+      component: () => import('@/pages/patientCenter/editOrg/index')
310
+    },
310 311
     {
311 312
       path: '/organizationinfo',
312 313
       name: '/organizationinfo',
313 314
       component: () => import('@/pages/my/organizationInfo')
314 315
     },
315 316
     {
316
-      path: "/main",
317
-      name: "main",
318
-      component: () => import("@/pages/main/index"),
317
+      path: '/main',
318
+      name: 'main',
319
+      component: () => import('@/pages/main/index'),
319 320
       meta: {
320 321
         noCache: true // 不会被 <keep-alive> 缓存
321 322
       }
@@ -326,9 +327,9 @@ export default new Router({
326 327
       component: () => import('@/pages/product/index')
327 328
     },
328 329
     {
329
-      path: "/monitoring",
330
-      name: "monitorPage",
331
-      component: () => import("@/pages/monitoring/index")
330
+      path: '/monitoring',
331
+      name: 'monitorPage',
332
+      component: () => import('@/pages/monitoring/index')
332 333
     },
333 334
     {
334 335
       path: '/details',
@@ -398,6 +399,6 @@ export default new Router({
398 399
       path: '/modifypsw',
399 400
       name: 'modifyPassword',
400 401
       component: () => import('@/pages/my/modifyPassword')
401
-    },
402
+    }
402 403
   ]
403 404
 })

+ 17 - 15
src/utils/request.js Wyświetl plik

@@ -1,4 +1,4 @@
1
-import axios from 'axios'
1
+import axios from "axios";
2 2
 // import { Toast } from 'mint-ui'
3 3
 import { Toast } from "vant";
4 4
 
@@ -6,16 +6,14 @@ import { Toast } from "vant";
6 6
 const service = axios.create({
7 7
   baseURL: process.env.BASE_API, // api的base_url
8 8
   timeout: 30000, // request timeout
9
-  withCredentials: true,
10
-
11
-
12
-})
9
+  withCredentials: true
10
+});
13 11
 
14 12
 // respone interceptor
15 13
 service.interceptors.response.use(
16 14
   // response => response,
17 15
   response => {
18
-    const res = response.data
16
+    const res = response.data;
19 17
     if (res.state !== 1) {
20 18
       if (res.code === 6002) {
21 19
         // MessageBox.confirm('你已被登出,可以取消继续留在该页面,或者重新登录', '确定登出', {
@@ -27,21 +25,25 @@ service.interceptors.response.use(
27 25
         //     location.reload() // 为了重新实例化vue-router对象 避免bug
28 26
         //   })
29 27
         // })
30
-        Toast("登录超时")
31
-        location.reload()
32
-        return Promise.reject('error')
28
+        Toast("登录超时");
29
+        location.reload();
30
+        return Promise.reject("error");
33 31
       } else {
34
-        return response
32
+        return response;
35 33
       }
36 34
     } else {
37
-      return response
35
+      return response;
38 36
     }
39 37
   },
40 38
   error => {
41
-    if(error.message.includes('timeout')){   // 判断请求异常信息中是否含有超时timeout字符串
42
-      return Promise.reject(error);          // reject这个错误信息
39
+    console.log(error);
40
+    Toast(error);
41
+    if (error.message.includes("timeout")) {
42
+      // 判断请求异常信息中是否含有超时timeout字符串
43
+      return Promise.reject(error); // reject这个错误信息
43 44
     }
44 45
     return Promise.reject(error);
45
-  })
46
+  }
47
+);
46 48
 
47
-export default service
49
+export default service;