|
@@ -23,16 +23,32 @@
|
23
|
23
|
</div>
|
24
|
24
|
|
25
|
25
|
<div class="adviceBox" v-show="showOne">
|
26
|
|
- <van-list v-model="loading" :finished="finished" finished-text="没有更多了">
|
27
|
|
- <div class="adviceOne" v-for="(item, index) in Inspection" :key="index">
|
|
26
|
+ <van-list
|
|
27
|
+ v-model="loading"
|
|
28
|
+ :finished="finished"
|
|
29
|
+ finished-text="没有更多了"
|
|
30
|
+ >
|
|
31
|
+ <div
|
|
32
|
+ class="adviceOne"
|
|
33
|
+ v-for="(item, index) in Inspection"
|
|
34
|
+ :key="index"
|
|
35
|
+ >
|
28
|
36
|
<div class="adviceTitle">
|
29
|
37
|
<p>{{ getTime(item.inspect_date) }}</p>
|
30
|
|
- <van-icon class="ellipsis" name="ellipsis" @click="newShow = true" />
|
|
38
|
+ <van-icon
|
|
39
|
+ class="ellipsis"
|
|
40
|
+ name="ellipsis"
|
|
41
|
+ @click="Delete(item.inspect_date, index)"
|
|
42
|
+ />
|
31
|
43
|
</div>
|
32
|
44
|
<div class="orderContent">
|
33
|
45
|
<div class="flexBox" v-for="(it, i) in item.child" :key="i">
|
34
|
46
|
<p>{{ it }}</p>
|
35
|
|
- <van-icon class="ellipsis" name="ellipsis" @click="newShow = true" />
|
|
47
|
+ <van-icon
|
|
48
|
+ class="ellipsis"
|
|
49
|
+ name="ellipsis"
|
|
50
|
+ @click="DeleteOne(it, item.inspect_date, i)"
|
|
51
|
+ />
|
36
|
52
|
</div>
|
37
|
53
|
</div>
|
38
|
54
|
<div class="all" @click="toInspection(item.inspect_date)">全部</div>
|
|
@@ -52,10 +68,23 @@
|
52
|
68
|
|
53
|
69
|
<!-- 弹出层 -->
|
54
|
70
|
<div>
|
55
|
|
- <van-popup v-model="typeShow" position="bottom" :style="{ height: '40%' }">
|
56
|
|
- <van-picker show-toolbar :columns="columns" @cancel="onCancel" @confirm="onConfirm" />
|
|
71
|
+ <van-popup
|
|
72
|
+ v-model="typeShow"
|
|
73
|
+ position="bottom"
|
|
74
|
+ :style="{ height: '40%' }"
|
|
75
|
+ >
|
|
76
|
+ <van-picker
|
|
77
|
+ show-toolbar
|
|
78
|
+ :columns="columns"
|
|
79
|
+ @cancel="onCancel"
|
|
80
|
+ @confirm="onConfirm"
|
|
81
|
+ />
|
57
|
82
|
</van-popup>
|
58
|
|
- <van-popup v-model="startShow" position="bottom" :style="{ height: '40%' }">
|
|
83
|
+ <van-popup
|
|
84
|
+ v-model="startShow"
|
|
85
|
+ position="bottom"
|
|
86
|
+ :style="{ height: '40%' }"
|
|
87
|
+ >
|
59
|
88
|
<van-datetime-picker
|
60
|
89
|
v-model="currentDate"
|
61
|
90
|
type="date"
|
|
@@ -75,7 +104,18 @@
|
75
|
104
|
@cancel="endShow = false"
|
76
|
105
|
/>
|
77
|
106
|
</van-popup>
|
78
|
|
- <van-action-sheet v-model="newShow" :actions="actions" cancel-text="取消" @cancel="onCancel" />
|
|
107
|
+ <van-action-sheet
|
|
108
|
+ v-model="newShow"
|
|
109
|
+ :actions="actions"
|
|
110
|
+ cancel-text="取消"
|
|
111
|
+ @select="toDelete"
|
|
112
|
+ />
|
|
113
|
+ <van-action-sheet
|
|
114
|
+ v-model="newShowOne"
|
|
115
|
+ :actions="actions1"
|
|
116
|
+ cancel-text="取消"
|
|
117
|
+ @select="DeleteInspection"
|
|
118
|
+ />
|
79
|
119
|
</div>
|
80
|
120
|
</div>
|
81
|
121
|
</template>
|
|
@@ -84,7 +124,8 @@
|
84
|
124
|
import {
|
85
|
125
|
getPatientDetail,
|
86
|
126
|
getAllInspection,
|
87
|
|
- getInspection
|
|
127
|
+ getInspection,
|
|
128
|
+ DeleteInspection
|
88
|
129
|
} from "@/api/patient/patient";
|
89
|
130
|
import { uParseTime } from "@/utils/tools";
|
90
|
131
|
import { Dialog } from "vant";
|
|
@@ -98,6 +139,7 @@ export default {
|
98
|
139
|
loading: false,
|
99
|
140
|
finished: false,
|
100
|
141
|
newShow: false,
|
|
142
|
+ newShowOne: false,
|
101
|
143
|
typeShow: false,
|
102
|
144
|
startShow: false,
|
103
|
145
|
endShow: false,
|
|
@@ -108,7 +150,8 @@ export default {
|
108
|
150
|
minDate: new Date(1970, 0, 1),
|
109
|
151
|
maxDate: new Date(2025, 10, 1),
|
110
|
152
|
currentDate: new Date(),
|
111
|
|
- actions: [{ name: "删除" }],
|
|
153
|
+ actions: [{ name: "全部删除" }],
|
|
154
|
+ actions1: [{ name: "删除" }],
|
112
|
155
|
showOne: true,
|
113
|
156
|
showTwo: false,
|
114
|
157
|
list: [],
|
|
@@ -118,7 +161,12 @@ export default {
|
118
|
161
|
Inspection: [],
|
119
|
162
|
project_id: 0,
|
120
|
163
|
patientid: 0,
|
121
|
|
- checkdata: []
|
|
164
|
+ checkdata: [],
|
|
165
|
+ date: 0,
|
|
166
|
+ index: 0,
|
|
167
|
+ name: "",
|
|
168
|
+ date: "",
|
|
169
|
+ index: ""
|
122
|
170
|
};
|
123
|
171
|
},
|
124
|
172
|
methods: {
|
|
@@ -255,6 +303,7 @@ export default {
|
255
|
303
|
arr.push(it.project_name);
|
256
|
304
|
}
|
257
|
305
|
});
|
|
306
|
+ console.log("arr", arr);
|
258
|
307
|
item.child = arr;
|
259
|
308
|
});
|
260
|
309
|
this.Inspection = list.reverse();
|
|
@@ -277,6 +326,59 @@ export default {
|
277
|
326
|
"&active=" +
|
278
|
327
|
this.active
|
279
|
328
|
);
|
|
329
|
+ },
|
|
330
|
+ Delete(date, index) {
|
|
331
|
+ this.newShow = true;
|
|
332
|
+ this.date = date;
|
|
333
|
+ this.index = index;
|
|
334
|
+ },
|
|
335
|
+ toDelete(val) {
|
|
336
|
+ console.log("val", val);
|
|
337
|
+ if (val.name === "全部删除") {
|
|
338
|
+ this.DeleteInspection(this.date, this.index);
|
|
339
|
+ }
|
|
340
|
+ },
|
|
341
|
+ DeleteInspection(id, index) {
|
|
342
|
+ Dialog.confirm({
|
|
343
|
+ title: "删除提示!",
|
|
344
|
+ message: "确认删除该条信息吗?,删除后将无法恢复!"
|
|
345
|
+ }).then(() => {
|
|
346
|
+ DeleteInspection(id).then(response => {
|
|
347
|
+ if (response.data.state === 1) {
|
|
348
|
+ var msg = response.data.data.msg;
|
|
349
|
+
|
|
350
|
+ this.Inspection.splice(index, 1);
|
|
351
|
+ this.newShow = false;
|
|
352
|
+ }
|
|
353
|
+ });
|
|
354
|
+ });
|
|
355
|
+ },
|
|
356
|
+ DeleteOne(name, date, index) {
|
|
357
|
+ this.newShowOne = true;
|
|
358
|
+ this.name = name;
|
|
359
|
+ this.date = date;
|
|
360
|
+ this.index = index;
|
|
361
|
+ },
|
|
362
|
+ DeleteInspection(val) {
|
|
363
|
+ if (val.name == "删除") {
|
|
364
|
+ this.DeleteChildInspection(this.name, this.date, this.index);
|
|
365
|
+ }
|
|
366
|
+ },
|
|
367
|
+ // 删除整组医嘱
|
|
368
|
+ DeleteInspection(name, index, staff) {
|
|
369
|
+ Dialog.confirm({
|
|
370
|
+ title: "删除提示!",
|
|
371
|
+ message: "确认删除该条信息吗?,删除后将无法恢复!"
|
|
372
|
+ }).then(() => {
|
|
373
|
+ DeleteInspection(id).then(response => {
|
|
374
|
+ if (response.data.state === 1) {
|
|
375
|
+ var msg = response.data.data.msg;
|
|
376
|
+
|
|
377
|
+ this.doctorAdvice.splice(index, 1);
|
|
378
|
+ this.newShow = false;
|
|
379
|
+ }
|
|
380
|
+ });
|
|
381
|
+ });
|
280
|
382
|
}
|
281
|
383
|
},
|
282
|
384
|
created() {
|