XMLWAN 5 years ago
parent
commit
4308079b25

+ 35 - 0
src/api/patient/patient.js View File

321
     params: params
321
     params: params
322
   })
322
   })
323
 }
323
 }
324
+
325
+export function DeleteEducationOne(id, params) {
326
+  return request({
327
+    url: '/m/api/patient/deleteeductionone?id=' + id,
328
+    method: 'delete',
329
+    params: params
330
+  })
331
+}
332
+
333
+export function getRescueRecordDetail(id, params) {
334
+  return request({
335
+    url: '/m/api/patient/getrescuerecorddetail?id=' + id,
336
+    method: 'get',
337
+    params: params
338
+  })
339
+}
340
+
341
+export function DeleteRescueRecord(id, params) {
342
+  return request({
343
+    url: '/m/api/patient/deleterescuerecord?id=' + id,
344
+    method: 'delete',
345
+    params: params
346
+  })
347
+}
348
+
349
+export function toSearchPatient(keyword) {
350
+  const params = {
351
+    keyword: keyword
352
+  }
353
+  return request({
354
+    url: '/m/api/patient/tosearchepatient',
355
+    method: 'get',
356
+    params: params
357
+  })
358
+}

+ 68 - 27
src/pages/allRescue/index.vue View File

2
   <div class="page_allRescue">
2
   <div class="page_allRescue">
3
     <van-sticky>
3
     <van-sticky>
4
       <div class="allRescueTitle">
4
       <div class="allRescueTitle">
5
-        <i class="iconfont icon-zuojiantou jiantou"></i>
5
+        <i class="iconfont icon-zuojiantou jiantou" @click="toReturn"></i>
6
         <span class="titleName">张三的抢救记录</span>
6
         <span class="titleName">张三的抢救记录</span>
7
       </div>
7
       </div>
8
     </van-sticky>
8
     </van-sticky>
9
     <div class="courseBox">
9
     <div class="courseBox">
10
       <div class="courseOne">
10
       <div class="courseOne">
11
         <div class="statOrder">
11
         <div class="statOrder">
12
-          <p class="time">2019.01.01</p>
13
-          <div class="statOrderTitle">
14
-            <span>抢救记录</span>
15
-          </div>
12
+          <p class="time">{{ getTime(recorddetail.record_time) }}</p>
16
           <div class="orderContent">
13
           <div class="orderContent">
17
             <p>
14
             <p>
18
-              病历书写基本规范2010》第二十二条规定:“病程记录
19
-              是指继入院记录之后,对患者病情和诊疗过程所进行的
20
-              连续性记录。内容包括患病历书写基本规范2010》第二十二条规定:“病程记录
21
-              是指继入院记录之后,对患者病情和诊疗过程所进行的
22
-              连续性记录。内容包括患
15
+              {{ recorddetail.content }}
23
             </p>
16
             </p>
24
           </div>
17
           </div>
25
           <div class="doctorBox">
18
           <div class="doctorBox">
26
-            <p>记录医生:钱蛮子</p>
19
+            <p>记录医生:{{ recorddetail.user_name }}</p>
27
           </div>
20
           </div>
28
         </div>
21
         </div>
29
       </div>
22
       </div>
30
     </div>
23
     </div>
31
   </div>
24
   </div>
32
 </template>
25
 </template>
33
-
26
+<script>
27
+import { getRescueRecordDetail } from "@/api/patient/patient";
28
+import { uParseTime } from "@/utils/tools";
29
+import { setRem, setHeight } from "@/libs/functionRem";
30
+import "../../styles/resetStyle.scss";
31
+export default {
32
+  props: {
33
+    active: Number
34
+  },
35
+  data() {
36
+    return {
37
+      patientid: 0,
38
+      active: 0,
39
+      recorddetail: {}
40
+    };
41
+  },
42
+  methods: {
43
+    getRescueRecordDetail(id) {
44
+      getRescueRecordDetail(id).then(response => {
45
+        if (response.data.state === 1) {
46
+          var recorddetail = response.data.data.recordDetail;
47
+          this.recorddetail = recorddetail;
48
+          console.log("记录详情", recorddetail);
49
+        }
50
+      });
51
+    },
52
+    toReturn() {
53
+      this.$router.push(
54
+        "/patientdetail?patientid=" + this.patientid + "&active=" + this.active
55
+      );
56
+    },
57
+    getTime(time) {
58
+      // return uParseTime(time, "{y}-{m}-{d} {h}:{i}:{s}");
59
+      return uParseTime(time, "{y}-{m}-{d}");
60
+    }
61
+  },
62
+  created() {
63
+    this.active = parseInt(this.$route.query.active);
64
+    setRem();
65
+    setHeight();
66
+    var id = this.$route.query.id;
67
+    console.log("id", id);
68
+    var patientid = this.$route.query.patientid;
69
+    this.patientid = patientid;
70
+    console.log("patientid", patientid);
71
+    this.getRescueRecordDetail(id);
72
+  }
73
+};
74
+</script>
34
 <style lang="scss" scoped>
75
 <style lang="scss" scoped>
35
-  .page_allRescue {
36
-    height: 100%;
37
-    overflow-y: auto;
76
+.page_allRescue {
77
+  height: 100%;
78
+  overflow-y: auto;
38
   .allRescueTitle {
79
   .allRescueTitle {
39
     background: #fff;
80
     background: #fff;
40
     padding: 0 1.125rem;
81
     padding: 0 1.125rem;
58
   .courseOne {
99
   .courseOne {
59
     box-shadow: 0px 1px 0px 0px rgba(0, 0, 0, 0.1);
100
     box-shadow: 0px 1px 0px 0px rgba(0, 0, 0, 0.1);
60
     padding-bottom: 1.25rem;
101
     padding-bottom: 1.25rem;
61
-  .time {
62
-    font-size: 1.125rem;
63
-    margin-top: 0.625rem;
64
-    font-weight: bold;
65
-  }
102
+    .time {
103
+      font-size: 1.125rem;
104
+      margin-top: 0.625rem;
105
+      font-weight: bold;
106
+    }
66
   }
107
   }
67
   .statOrderTitle {
108
   .statOrderTitle {
68
     color: #5b98ff;
109
     color: #5b98ff;
73
   .orderContent {
114
   .orderContent {
74
     font-size: 0.875rem;
115
     font-size: 0.875rem;
75
     color: rgba(49, 50, 52, 1);
116
     color: rgba(49, 50, 52, 1);
76
-  p {
77
-    line-height: 1.125rem;
78
-  }
117
+    p {
118
+      line-height: 1.125rem;
119
+    }
79
   }
120
   }
80
   .doctorBox {
121
   .doctorBox {
81
     font-size: 0.75rem;
122
     font-size: 0.75rem;
86
     justify-content: space-between;
127
     justify-content: space-between;
87
     margin-top: 0.625rem;
128
     margin-top: 0.625rem;
88
   }
129
   }
89
-  }
90
-  ::-webkit-scrollbar {
91
-    width: 0;
92
-  }
130
+}
131
+::-webkit-scrollbar {
132
+  width: 0;
133
+}
93
 </style>
134
 </style>

+ 36 - 4
src/pages/doctorAdvice/components/Education.vue View File

32
               <van-icon
32
               <van-icon
33
                 class="ellipsis"
33
                 class="ellipsis"
34
                 name="ellipsis"
34
                 name="ellipsis"
35
-                @click="newShow = true"
35
+                @click="toDeleteEducation(item.id, item.index)"
36
               />
36
               />
37
             </div>
37
             </div>
38
             <div class="statOrder">
38
             <div class="statOrder">
87
         v-model="newShow"
87
         v-model="newShow"
88
         :actions="actions"
88
         :actions="actions"
89
         cancel-text="取消"
89
         cancel-text="取消"
90
-        @cancel="onCancel"
90
+        @select="DeleteEducation"
91
       />
91
       />
92
     </div>
92
     </div>
93
   </div>
93
   </div>
94
 </template>
94
 </template>
95
 
95
 
96
 <script>
96
 <script>
97
-import { getPatientDetail, getEducation } from "@/api/patient/patient";
97
+import {
98
+  getPatientDetail,
99
+  getEducation,
100
+  DeleteEducationOne
101
+} from "@/api/patient/patient";
98
 import { uParseTime } from "@/utils/tools";
102
 import { uParseTime } from "@/utils/tools";
99
 import Vue from "vue";
103
 import Vue from "vue";
100
 import { Dialog } from "vant";
104
 import { Dialog } from "vant";
125
       finished: false,
129
       finished: false,
126
       list: [],
130
       list: [],
127
       Education: [],
131
       Education: [],
128
-      patient_id: ""
132
+      patient_id: "",
133
+      id: 0,
134
+      index: 0
129
     };
135
     };
130
   },
136
   },
131
   methods: {
137
   methods: {
242
           "&active=" +
248
           "&active=" +
243
           this.active
249
           this.active
244
       );
250
       );
251
+    },
252
+    toDeleteEducation(id, index) {
253
+      this.id = id;
254
+      this.index = index;
255
+      this.newShow = true;
256
+    },
257
+    DeleteEducation(value) {
258
+      console.log("value", value);
259
+      if (value.name == "删除") {
260
+        this.DeleteEducationOne(this.id, this.index);
261
+      }
262
+    },
263
+    DeleteEducationOne(id, index) {
264
+      Dialog.confirm({
265
+        title: "删除提示!",
266
+        message: "确认删除该条信息吗?,删除后将无法恢复!"
267
+      }).then(() => {
268
+        DeleteEducationOne(id).then(response => {
269
+          if (response.data.state === 1) {
270
+            var msg = response.data.data.msg;
271
+            console.log("msg", msg);
272
+            this.Education.splice(index, 1);
273
+            this.newShow = false;
274
+          }
275
+        });
276
+      });
245
     }
277
     }
246
   },
278
   },
247
   created() {
279
   created() {

+ 51 - 10
src/pages/doctorAdvice/components/RescueRecord.vue View File

28
             :key="index"
28
             :key="index"
29
           >
29
           >
30
             <div class="adviceTitle">
30
             <div class="adviceTitle">
31
-              <p>2019.09.01</p>
31
+              <p>{{ getTime(item.record_time) }}</p>
32
               <van-icon
32
               <van-icon
33
                 class="ellipsis"
33
                 class="ellipsis"
34
                 name="ellipsis"
34
                 name="ellipsis"
35
-                @click="newShow = true"
35
+                @click="toDeleteRescueRecord(item.id, item.index)"
36
               />
36
               />
37
             </div>
37
             </div>
38
             <div class="statOrder">
38
             <div class="statOrder">
39
-              <div class="statOrderTitle">
40
-                <span>日常抢救</span>
41
-              </div>
42
-
43
               <div class="orderContent">
39
               <div class="orderContent">
44
                 <p>
40
                 <p>
45
                   <span v-html="item.content"></span>
41
                   <span v-html="item.content"></span>
49
                 <p>记录医生:{{ item.user_name }}</p>
45
                 <p>记录医生:{{ item.user_name }}</p>
50
               </div>
46
               </div>
51
             </div>
47
             </div>
52
-            <div class="all">全部</div>
48
+            <div class="all" @click="toRescueRecord(item.id)">全部</div>
53
           </div>
49
           </div>
54
         </van-list>
50
         </van-list>
55
       </div>
51
       </div>
93
         v-model="newShow"
89
         v-model="newShow"
94
         :actions="actions"
90
         :actions="actions"
95
         cancel-text="取消"
91
         cancel-text="取消"
96
-        @cancel="onCancel"
92
+        @select="Delete"
97
       />
93
       />
98
     </div>
94
     </div>
99
   </div>
95
   </div>
100
 </template>
96
 </template>
101
 
97
 
102
 <script>
98
 <script>
103
-import { getPatientDetail, getRescueRecord } from "@/api/patient/patient";
99
+import {
100
+  getPatientDetail,
101
+  getRescueRecord,
102
+  DeleteRescueRecord
103
+} from "@/api/patient/patient";
104
 import { uParseTime } from "@/utils/tools";
104
 import { uParseTime } from "@/utils/tools";
105
 import Vue from "vue";
105
 import Vue from "vue";
106
 import { Dialog } from "vant";
106
 import { Dialog } from "vant";
107
 const moment = require("moment");
107
 const moment = require("moment");
108
 export default {
108
 export default {
109
+  props: {
110
+    active: Number
111
+  },
109
   data() {
112
   data() {
110
     return {
113
     return {
111
       newShow: false,
114
       newShow: false,
128
       finished: false,
131
       finished: false,
129
       rescueRecords: [],
132
       rescueRecords: [],
130
       patient_id: 0,
133
       patient_id: 0,
131
-      list: []
134
+      list: [],
135
+      id: 0,
136
+      index: 0
132
     };
137
     };
133
   },
138
   },
134
   methods: {
139
   methods: {
233
     getTime(time) {
238
     getTime(time) {
234
       // return uParseTime(time, "{y}-{m}-{d} {h}:{i}:{s}");
239
       // return uParseTime(time, "{y}-{m}-{d} {h}:{i}:{s}");
235
       return uParseTime(time, "{y}-{m}-{d}");
240
       return uParseTime(time, "{y}-{m}-{d}");
241
+    },
242
+    toRescueRecord(id) {
243
+      var patientid = this.$route.query.patientid;
244
+      this.$router.push(
245
+        "/rescuerecord?id=" +
246
+          id +
247
+          "&patientid=" +
248
+          patientid +
249
+          "&active=" +
250
+          this.active
251
+      );
252
+    },
253
+    toDeleteRescueRecord(id, index) {
254
+      this.id = id;
255
+      this.index = index;
256
+      this.newShow = true;
257
+    },
258
+    Delete(value) {
259
+      if (value.name == "删除") {
260
+        this.DeleteRescueRecord(this.id, this.index);
261
+      }
262
+    },
263
+    DeleteRescueRecord(id, index) {
264
+      Dialog.confirm({
265
+        title: "删除提示!",
266
+        message: "确认删除该条信息吗?,删除后将无法恢复!"
267
+      }).then(() => {
268
+        DeleteRescueRecord(id).then(response => {
269
+          if (response.data.state === 1) {
270
+            var msg = response.data.data.msg;
271
+            console.log("msg", msg);
272
+            this.rescueRecords.splice(index, 1);
273
+            this.newShow = false;
274
+          }
275
+        });
276
+      });
236
     }
277
     }
237
   },
278
   },
238
   created() {
279
   created() {

+ 1 - 1
src/pages/doctorAdvice/index.vue View File

24
           v-if="active == 5"
24
           v-if="active == 5"
25
           :active="active"
25
           :active="active"
26
         ></course-management>
26
         ></course-management>
27
-        <rescue-record v-if="active == 6"></rescue-record>
27
+        <rescue-record v-if="active == 6" :active="active"></rescue-record>
28
         <scheduling v-if="active == 7" :active="active"></scheduling>
28
         <scheduling v-if="active == 7" :active="active"></scheduling>
29
         <education v-if="active == 8" :active="active"></education>
29
         <education v-if="active == 8" :active="active"></education>
30
         <signs-record v-if="active == 9" :active="active"></signs-record>
30
         <signs-record v-if="active == 9" :active="active"></signs-record>

+ 1 - 1
src/pages/patientManagement/patientManagement.vue View File

129
         if (this.list.length >= this.total) {
129
         if (this.list.length >= this.total) {
130
           this.finished = true;
130
           this.finished = true;
131
         }
131
         }
132
-      }, 100);
132
+      }, 1000);
133
     },
133
     },
134
     getBloodDialysisPatient() {
134
     getBloodDialysisPatient() {
135
       getBloodDialysisPatient(this.page, this.limit).then(response => {
135
       getBloodDialysisPatient(this.page, this.limit).then(response => {

+ 19 - 4
src/pages/search/index.vue View File

2
   <div class="page_search">
2
   <div class="page_search">
3
     <div class="header">
3
     <div class="header">
4
       <i class="iconfont icon-zuojiantou" @click="toHomeIndex"></i>
4
       <i class="iconfont icon-zuojiantou" @click="toHomeIndex"></i>
5
-      <van-search v-model="value" placeholder=" 姓名 / 首拼 / 透析号" />
5
+      <van-search
6
+        v-model="value"
7
+        placeholder=" 姓名 / 首拼 / 透析号"
8
+        @search="toSearchPatient"
9
+      />
6
     </div>
10
     </div>
7
     <div class="searchList">
11
     <div class="searchList">
8
       <div class="patientOne">
12
       <div class="patientOne">
54
 </template>
58
 </template>
55
 
59
 
56
 <script>
60
 <script>
57
-// import { SaveSearch } from "@/api/login/login";
61
+import { toSearchPatient } from "@/api/patient/patient";
58
 export default {
62
 export default {
59
   data() {
63
   data() {
60
     return {
64
     return {
61
       searchVal: "",
65
       searchVal: "",
62
-      active: 0
66
+      active: 0,
67
+      keyword: "",
68
+      value: ""
63
     };
69
     };
64
   },
70
   },
65
   methods: {
71
   methods: {
71
     },
77
     },
72
     toHomeIndex() {
78
     toHomeIndex() {
73
       this.$router.push({ path: "/homeIndex" });
79
       this.$router.push({ path: "/homeIndex" });
80
+    },
81
+    toSearchPatient(val) {
82
+      toSearchPatient(val).then(response => {
83
+        if (response.data.state === 1) {
84
+          var patient = response.data.data.patient;
85
+          console.log("patient", patient);
86
+        }
87
+      });
74
     }
88
     }
75
-  }
89
+  },
90
+  created() {}
76
 };
91
 };
77
 </script>
92
 </script>
78
 
93
 

+ 7 - 0
src/router/index.js View File

104
       name: 'editeducation',
104
       name: 'editeducation',
105
       component: () => import('@/pages/allEducation/index')
105
       component: () => import('@/pages/allEducation/index')
106
 
106
 
107
+    },
108
+    // 全部抢救记录
109
+    {
110
+      path: '/rescuerecord',
111
+      name: 'rescuerecord',
112
+      component: () => import('@/pages/allRescue/index')
113
+
107
     },
114
     },
108
     //
115
     //
109
     {
116
     {