@liuqiongqiong/vue-pages 1.0.3 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,74 +1,35 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="app-container">
|
|
3
3
|
<div class="filter-container">
|
|
4
|
-
<el-form
|
|
5
|
-
ref="listQuery"
|
|
6
|
-
:inline="true"
|
|
7
|
-
:model="listQuery"
|
|
8
|
-
class="demo-form-inline"
|
|
9
|
-
>
|
|
4
|
+
<el-form ref="listQuery" :inline="true" :model="listQuery" class="demo-form-inline">
|
|
10
5
|
<el-form-item label="护理项目名称" prop="title">
|
|
11
|
-
<el-input
|
|
12
|
-
v-model="listQuery.title"
|
|
13
|
-
size="small"
|
|
14
|
-
placeholder="请输入护理项目名称"
|
|
15
|
-
/>
|
|
6
|
+
<el-input v-model="listQuery.title" size="small" placeholder="请输入护理项目名称" />
|
|
16
7
|
</el-form-item>
|
|
17
8
|
<el-form-item label="状态" prop="status">
|
|
18
|
-
<el-select
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
class="filter-item"
|
|
25
|
-
placeholder="请选择状态"
|
|
26
|
-
>
|
|
27
|
-
<el-option
|
|
28
|
-
v-for="(item, index) in [
|
|
29
|
-
{ label: '启用', value: '1' },
|
|
30
|
-
{ label: '下架', value: '2' },
|
|
31
|
-
]"
|
|
32
|
-
:key="index"
|
|
33
|
-
:label="item.label"
|
|
34
|
-
:value="item.value"
|
|
35
|
-
/>
|
|
9
|
+
<el-select v-model="listQuery.status" style="width: 100%" clearable filterable size="small"
|
|
10
|
+
class="filter-item" placeholder="请选择状态">
|
|
11
|
+
<el-option v-for="(item, index) in [
|
|
12
|
+
{ label: '启用', value: '1' },
|
|
13
|
+
{ label: '下架', value: '2' },
|
|
14
|
+
]" :key="index" :label="item.label" :value="item.value" />
|
|
36
15
|
</el-select>
|
|
37
16
|
</el-form-item>
|
|
38
17
|
<el-form-item>
|
|
39
|
-
<el-button
|
|
40
|
-
size="small"
|
|
41
|
-
type="primary"
|
|
42
|
-
@click="onSubmit"
|
|
43
|
-
>查询</el-button>
|
|
18
|
+
<el-button size="small" type="primary" @click="onSubmit">查询</el-button>
|
|
44
19
|
</el-form-item>
|
|
45
20
|
<el-form-item>
|
|
46
|
-
<el-button
|
|
47
|
-
size="small"
|
|
48
|
-
type="warning"
|
|
49
|
-
@click="resetting('listQuery')"
|
|
50
|
-
>重置</el-button>
|
|
21
|
+
<el-button size="small" type="warning" @click="resetting('listQuery')">重置</el-button>
|
|
51
22
|
</el-form-item>
|
|
52
23
|
<el-form-item>
|
|
53
|
-
<el-button size="small" type="success" @click="synchronization"
|
|
24
|
+
<!-- <el-button size="small" type="success" @click="synchronization">同步护理项</el-button> -->
|
|
54
25
|
<!-- <el-button size="small" type="success" @click="add">新增</el-button> -->
|
|
55
26
|
</el-form-item>
|
|
56
27
|
<el-form-item>
|
|
57
|
-
<el-button
|
|
58
|
-
size="small"
|
|
59
|
-
type="primary"
|
|
60
|
-
@click="dialogVisibleExp = true"
|
|
61
|
-
>导出</el-button>
|
|
28
|
+
<el-button size="small" type="primary" @click="dialogVisibleExp = true">导出</el-button>
|
|
62
29
|
</el-form-item>
|
|
63
30
|
</el-form>
|
|
64
31
|
</div>
|
|
65
|
-
<el-table
|
|
66
|
-
border
|
|
67
|
-
height="65vh"
|
|
68
|
-
|
|
69
|
-
:data="list"
|
|
70
|
-
style="width: 100%"
|
|
71
|
-
>
|
|
32
|
+
<el-table border height="65vh" :data="list" style="width: 100%">
|
|
72
33
|
<!-- @sort-change="sortChange" -->
|
|
73
34
|
<el-table-column :label="'护理项目编号'" align="center">
|
|
74
35
|
<template slot-scope="{ row }">
|
|
@@ -115,24 +76,16 @@
|
|
|
115
76
|
</el-table-column>
|
|
116
77
|
<el-table-column :label="'状态'" align="center">
|
|
117
78
|
<template slot-scope="{ row }">
|
|
118
|
-
<el-tag
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
"
|
|
123
|
-
>{{
|
|
124
|
-
row.status == "1" ? "启用" : row.status == "2" ? "下架" : "-"
|
|
125
|
-
}}</el-tag>
|
|
79
|
+
<el-tag size="medium" :type="row.status == '1' ? 'success' : row.status == '2' ? 'warning' : ''
|
|
80
|
+
">{{
|
|
81
|
+
row.status == "1" ? "启用" : row.status == "2" ? "下架" : "-"
|
|
82
|
+
}}</el-tag>
|
|
126
83
|
</template>
|
|
127
84
|
</el-table-column>
|
|
128
85
|
<el-table-column :label="'海报'" align="center">
|
|
129
86
|
<template slot-scope="{ row }">
|
|
130
|
-
<el-image
|
|
131
|
-
|
|
132
|
-
style="width: 50px; height: 50px"
|
|
133
|
-
:src="`http://192.168.1.21/img/${row.picUrl}`"
|
|
134
|
-
:preview-src-list="[`http://192.168.1.21/img/${row.picUrl}`]"
|
|
135
|
-
/>
|
|
87
|
+
<el-image v-if="row.picUrl" style="width: 50px; height: 50px" :src="`http://192.168.1.21/img/${row.picUrl}`"
|
|
88
|
+
:preview-src-list="[`http://192.168.1.21/img/${row.picUrl}`]" />
|
|
136
89
|
<span v-else> - </span>
|
|
137
90
|
</template>
|
|
138
91
|
</el-table-column>
|
|
@@ -146,219 +99,102 @@
|
|
|
146
99
|
<span>{{ row.description }}</span>
|
|
147
100
|
</template>
|
|
148
101
|
</el-table-column>
|
|
149
|
-
<el-table-column
|
|
150
|
-
:label="'操作'"
|
|
151
|
-
align="center"
|
|
152
|
-
width="150"
|
|
153
|
-
class-name="small-padding fixed-width"
|
|
154
|
-
>
|
|
102
|
+
<el-table-column :label="'操作'" align="center" width="150" class-name="small-padding fixed-width">
|
|
155
103
|
<template slot-scope="{ row, $index }">
|
|
156
104
|
<el-button size="mini" type="primary" @click="edit(row, $index)">
|
|
157
105
|
修改
|
|
158
106
|
</el-button>
|
|
159
|
-
<el-button
|
|
160
|
-
size="mini"
|
|
161
|
-
type="danger"
|
|
162
|
-
@click="handleDelete(row, $index)"
|
|
163
|
-
>
|
|
107
|
+
<el-button size="mini" type="danger" @click="handleDelete(row, $index)">
|
|
164
108
|
删除
|
|
165
109
|
</el-button>
|
|
166
110
|
</template>
|
|
167
111
|
</el-table-column>
|
|
168
112
|
</el-table>
|
|
169
|
-
<pagination
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
:
|
|
173
|
-
:
|
|
174
|
-
@pagination="getList"
|
|
175
|
-
/>
|
|
176
|
-
<el-dialog
|
|
177
|
-
:close-on-click-modal="false"
|
|
178
|
-
:close-on-press-escape="false"
|
|
179
|
-
|
|
180
|
-
:title="textMap[dialogStatus]"
|
|
181
|
-
:visible.sync="dialogFormVisible"
|
|
182
|
-
width="50%"
|
|
183
|
-
>
|
|
184
|
-
<el-form
|
|
185
|
-
ref="dataForm"
|
|
186
|
-
:rules="rules"
|
|
187
|
-
:model="temp"
|
|
188
|
-
label-position="right"
|
|
189
|
-
label-width="150px"
|
|
190
|
-
>
|
|
113
|
+
<pagination v-show="total > 0" :total="total" :page.sync="listQuery.pageNo" :limit.sync="listQuery.size"
|
|
114
|
+
@pagination="getList" />
|
|
115
|
+
<el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :title="textMap[dialogStatus]"
|
|
116
|
+
:visible.sync="dialogFormVisible" width="50%">
|
|
117
|
+
<el-form ref="dataForm" :rules="rules" :model="temp" label-position="right" label-width="150px">
|
|
191
118
|
<el-row :gutter="20">
|
|
192
119
|
<el-col :span="12">
|
|
193
120
|
<el-form-item label="护理项目名称" prop="title">
|
|
194
|
-
<el-input
|
|
195
|
-
v-model="temp.title"
|
|
196
|
-
clearable
|
|
197
|
-
placeholder="请输入护理项目名称"
|
|
198
|
-
size="small"
|
|
199
|
-
/>
|
|
121
|
+
<el-input v-model="temp.title" clearable placeholder="请输入护理项目名称" size="small" />
|
|
200
122
|
</el-form-item>
|
|
201
123
|
</el-col>
|
|
202
124
|
<el-col :span="12">
|
|
203
125
|
<el-form-item label="护理类型" prop="type">
|
|
204
|
-
<el-select
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
class="filter-item"
|
|
211
|
-
placeholder="请选择护理类型"
|
|
212
|
-
>
|
|
213
|
-
<el-option
|
|
214
|
-
v-for="(item, index) in [
|
|
215
|
-
{ label: '生活服务', value: '1' },
|
|
216
|
-
{ label: '医疗护理', value: '2' },
|
|
217
|
-
]"
|
|
218
|
-
:key="index"
|
|
219
|
-
:label="item.label"
|
|
220
|
-
:value="item.value"
|
|
221
|
-
/>
|
|
126
|
+
<el-select v-model="temp.type" style="width: 100%" clearable filterable size="small" class="filter-item"
|
|
127
|
+
placeholder="请选择护理类型">
|
|
128
|
+
<el-option v-for="(item, index) in [
|
|
129
|
+
{ label: '生活服务', value: '1' },
|
|
130
|
+
{ label: '医疗护理', value: '2' },
|
|
131
|
+
]" :key="index" :label="item.label" :value="item.value" />
|
|
222
132
|
</el-select>
|
|
223
133
|
</el-form-item>
|
|
224
134
|
</el-col>
|
|
225
135
|
<el-col :span="12">
|
|
226
136
|
<el-form-item label="机构上门护理价格" prop="price1">
|
|
227
|
-
<el-input
|
|
228
|
-
v-model="temp.price1"
|
|
229
|
-
clearable
|
|
230
|
-
placeholder="请输入机构上门护理价格"
|
|
231
|
-
size="small"
|
|
232
|
-
/>
|
|
137
|
+
<el-input v-model="temp.price1" clearable placeholder="请输入机构上门护理价格" size="small" />
|
|
233
138
|
</el-form-item>
|
|
234
139
|
</el-col>
|
|
235
140
|
<el-col :span="12">
|
|
236
141
|
<el-form-item label="亲情护理价格" prop="price2">
|
|
237
|
-
<el-input
|
|
238
|
-
v-model="temp.price2"
|
|
239
|
-
clearable
|
|
240
|
-
placeholder="请输入亲情护理价格"
|
|
241
|
-
size="small"
|
|
242
|
-
/>
|
|
142
|
+
<el-input v-model="temp.price2" clearable placeholder="请输入亲情护理价格" size="small" />
|
|
243
143
|
</el-form-item>
|
|
244
144
|
</el-col>
|
|
245
145
|
<el-col :span="12">
|
|
246
146
|
<el-form-item label="机构护理价格" prop="price3">
|
|
247
|
-
<el-input
|
|
248
|
-
v-model="temp.price3"
|
|
249
|
-
placeholder="请输入机构护理价格"
|
|
250
|
-
clearable
|
|
251
|
-
size="small"
|
|
252
|
-
/>
|
|
147
|
+
<el-input v-model="temp.price3" placeholder="请输入机构护理价格" clearable size="small" />
|
|
253
148
|
</el-form-item>
|
|
254
149
|
</el-col>
|
|
255
150
|
<el-col :span="12">
|
|
256
151
|
<el-form-item label="参考护理时间(小时)" prop="hourNum">
|
|
257
|
-
<el-input
|
|
258
|
-
v-model="temp.hourNum"
|
|
259
|
-
placeholder="请输入参考护理时间(小时)"
|
|
260
|
-
clearable
|
|
261
|
-
size="small"
|
|
262
|
-
/>
|
|
152
|
+
<el-input v-model="temp.hourNum" placeholder="请输入参考护理时间(小时)" clearable size="small" />
|
|
263
153
|
</el-form-item>
|
|
264
154
|
</el-col>
|
|
265
155
|
<el-col :span="12">
|
|
266
156
|
<el-form-item label="有效开始时间">
|
|
267
|
-
<el-date-picker
|
|
268
|
-
|
|
269
|
-
size="small"
|
|
270
|
-
format="yyyy 年 MM 月 dd 日"
|
|
271
|
-
value-format="yyyy-MM-dd"
|
|
272
|
-
style="width: 100%"
|
|
273
|
-
type="date"
|
|
274
|
-
placeholder="请选择有效开始时间"
|
|
275
|
-
/>
|
|
157
|
+
<el-date-picker v-model="temp.startTime" size="small" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd"
|
|
158
|
+
style="width: 100%" type="date" placeholder="请选择有效开始时间" />
|
|
276
159
|
</el-form-item>
|
|
277
160
|
</el-col>
|
|
278
161
|
<el-col :span="12">
|
|
279
162
|
<el-form-item label="有效结束时间">
|
|
280
|
-
<el-date-picker
|
|
281
|
-
|
|
282
|
-
size="small"
|
|
283
|
-
format="yyyy 年 MM 月 dd 日"
|
|
284
|
-
value-format="yyyy-MM-dd"
|
|
285
|
-
style="width: 100%"
|
|
286
|
-
type="date"
|
|
287
|
-
placeholder="请输入有效结束时间"
|
|
288
|
-
/>
|
|
163
|
+
<el-date-picker v-model="temp.endTime" size="small" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd"
|
|
164
|
+
style="width: 100%" type="date" placeholder="请输入有效结束时间" />
|
|
289
165
|
</el-form-item>
|
|
290
166
|
</el-col>
|
|
291
167
|
<el-col :span="12">
|
|
292
168
|
<el-form-item label="状态">
|
|
293
|
-
<el-select
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
class="filter-item"
|
|
300
|
-
placeholder="请选择状态"
|
|
301
|
-
>
|
|
302
|
-
<el-option
|
|
303
|
-
v-for="(item, index) in [
|
|
304
|
-
{ label: '启用', value: '1' },
|
|
305
|
-
{ label: '下架', value: '2' },
|
|
306
|
-
]"
|
|
307
|
-
:key="index"
|
|
308
|
-
:label="item.label"
|
|
309
|
-
:value="item.value"
|
|
310
|
-
/>
|
|
169
|
+
<el-select v-model="temp.status" style="width: 100%" clearable filterable size="small" class="filter-item"
|
|
170
|
+
placeholder="请选择状态">
|
|
171
|
+
<el-option v-for="(item, index) in [
|
|
172
|
+
{ label: '启用', value: '1' },
|
|
173
|
+
{ label: '下架', value: '2' },
|
|
174
|
+
]" :key="index" :label="item.label" :value="item.value" />
|
|
311
175
|
</el-select>
|
|
312
176
|
</el-form-item>
|
|
313
177
|
</el-col>
|
|
314
178
|
<el-col :span="12">
|
|
315
179
|
<el-form-item label="所属机构" prop="unitId">
|
|
316
|
-
<el-select
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
filterable
|
|
321
|
-
size="small"
|
|
322
|
-
class="filter-item"
|
|
323
|
-
placeholder="请选择所属机构"
|
|
324
|
-
>
|
|
325
|
-
<el-option
|
|
326
|
-
v-for="(item, index) in institutionData"
|
|
327
|
-
:key="index"
|
|
328
|
-
:label="item.label"
|
|
329
|
-
:value="item.value"
|
|
330
|
-
/>
|
|
180
|
+
<el-select v-model="temp.unitId" style="width: 100%" clearable filterable size="small" class="filter-item"
|
|
181
|
+
placeholder="请选择所属机构">
|
|
182
|
+
<el-option v-for="(item, index) in institutionData" :key="index" :label="item.label"
|
|
183
|
+
:value="item.value" />
|
|
331
184
|
</el-select>
|
|
332
185
|
</el-form-item>
|
|
333
186
|
</el-col>
|
|
334
187
|
<el-col :span="12">
|
|
335
188
|
<el-form-item label="项目海报" prop="picUrl">
|
|
336
|
-
<el-upload
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
:data="FormData"
|
|
340
|
-
:before-upload="beforeAvatarUploada"
|
|
341
|
-
:http-request="handleFileUpload"
|
|
342
|
-
:file-list="fileList"
|
|
343
|
-
:on-preview="onPreview"
|
|
344
|
-
>
|
|
345
|
-
<el-button
|
|
346
|
-
slot="trigger"
|
|
347
|
-
size="small"
|
|
348
|
-
type="primary"
|
|
349
|
-
>选取文件</el-button>
|
|
189
|
+
<el-upload action="#" :limit="1" :data="FormData" :before-upload="beforeAvatarUploada"
|
|
190
|
+
:http-request="handleFileUpload" :file-list="fileList" :on-preview="onPreview">
|
|
191
|
+
<el-button slot="trigger" size="small" type="primary">选取文件</el-button>
|
|
350
192
|
</el-upload>
|
|
351
193
|
</el-form-item>
|
|
352
194
|
</el-col>
|
|
353
195
|
<el-col :span="12">
|
|
354
196
|
<el-form-item label="详情" prop="description">
|
|
355
|
-
<el-input
|
|
356
|
-
v-model="temp.description"
|
|
357
|
-
clearable
|
|
358
|
-
placeholder="请输入详情"
|
|
359
|
-
type="textarea"
|
|
360
|
-
size="small"
|
|
361
|
-
/>
|
|
197
|
+
<el-input v-model="temp.description" clearable placeholder="请输入详情" type="textarea" size="small" />
|
|
362
198
|
</el-form-item>
|
|
363
199
|
</el-col>
|
|
364
200
|
</el-row>
|
|
@@ -367,38 +203,21 @@
|
|
|
367
203
|
<el-button size="small" @click="dialogFormVisible = false">
|
|
368
204
|
取 消
|
|
369
205
|
</el-button>
|
|
370
|
-
<el-button
|
|
371
|
-
type="primary"
|
|
372
|
-
size="small"
|
|
373
|
-
@click="dialogStatus === 'create' ? createData() : updateData()"
|
|
374
|
-
>
|
|
206
|
+
<el-button type="primary" size="small" @click="dialogStatus === 'create' ? createData() : updateData()">
|
|
375
207
|
确 认
|
|
376
208
|
</el-button>
|
|
377
209
|
</div>
|
|
378
210
|
</el-dialog>
|
|
379
211
|
<preview-file :file="file" />
|
|
380
|
-
<el-dialog
|
|
381
|
-
:close
|
|
382
|
-
:close-on-press-escape="false"
|
|
383
|
-
|
|
384
|
-
title="导出"
|
|
385
|
-
:visible.sync="dialogVisibleExp"
|
|
386
|
-
width="600px"
|
|
387
|
-
:before-close="handleClose"
|
|
388
|
-
>
|
|
212
|
+
<el-dialog :close-on-click-modal="false" :close-on-press-escape="false" title="导出" :visible.sync="dialogVisibleExp"
|
|
213
|
+
width="600px" :before-close="handleClose">
|
|
389
214
|
<el-form :inline="true" class="demo-form-inline">
|
|
390
215
|
<el-form-item label="提示:">
|
|
391
216
|
<el-link :underline="false" type="primary">选择的开始日期和结束日期请将数据的入录时间包含起来,结束日期选后一天</el-link>
|
|
392
217
|
</el-form-item>
|
|
393
218
|
<el-form-item label="时间">
|
|
394
|
-
<el-date-picker
|
|
395
|
-
|
|
396
|
-
type="daterange"
|
|
397
|
-
value-format="yyyy-MM-dd"
|
|
398
|
-
range-separator="至"
|
|
399
|
-
start-placeholder="开始日期"
|
|
400
|
-
end-placeholder="结束日期"
|
|
401
|
-
/>
|
|
219
|
+
<el-date-picker v-model="startDate" type="daterange" value-format="yyyy-MM-dd" range-separator="至"
|
|
220
|
+
start-placeholder="开始日期" end-placeholder="结束日期" />
|
|
402
221
|
</el-form-item>
|
|
403
222
|
</el-form>
|
|
404
223
|
<span slot="footer" class="dialog-footer">
|