|
|
@@ -15,25 +15,25 @@
|
|
15
|
15
|
<el-card class="box-card">
|
|
16
|
16
|
<template #header>
|
|
17
|
17
|
<div class="card-header">
|
|
18
|
|
- <span class="card-title">{{ workBasicData.source === '电话' ? '问卷配置' : '短信配置' }}</span>
|
|
|
18
|
+ <span class="card-title">{{ workBasicData.way === '1' ? '问卷配置' : '短信配置' }}</span>
|
|
19
|
19
|
</div>
|
|
20
|
20
|
</template>
|
|
21
|
21
|
<el-row>
|
|
22
|
22
|
<el-col :span="12">
|
|
23
|
|
- <el-form-item label="选择模版" label-width="200px" v-if="workBasicData.source === '电话'">
|
|
24
|
|
- <el-select v-model="selectValue" placeholder="请选择模版" style="width: 240px">
|
|
25
|
|
- <el-option v-for="item in selectOptions" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
23
|
+ <el-form-item label="选择模版" label-width="200px" v-if="workBasicData.way === '1'">
|
|
|
24
|
+ <el-select v-model="questionnaire" placeholder="请选择模版" style="width: 240px">
|
|
|
25
|
+ <el-option v-for="item in questionnaireData" :key="item.value" :label="item.title" :value="item.value" />
|
|
26
|
26
|
</el-select>
|
|
27
|
27
|
</el-form-item>
|
|
28
|
|
- <el-form-item label="选择模版" label-width="200px" v-if="workBasicData.source === '短信'">
|
|
29
|
|
- <el-select v-model="selectValue" placeholder="请选择模版" style="width: 240px">
|
|
30
|
|
- <el-option v-for="item in selectOptions11" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
28
|
+ <el-form-item label="选择模版" label-width="200px" v-if="workBasicData.way === '2'">
|
|
|
29
|
+ <el-select v-model="smsValue" placeholder="请选择模版" style="width: 240px">
|
|
|
30
|
+ <el-option v-for="item in smsData" :key="item.value" :label="item.title" :value="item.value" />
|
|
31
|
31
|
</el-select>
|
|
32
|
32
|
</el-form-item>
|
|
33
|
33
|
</el-col>
|
|
34
|
34
|
<el-col :span="12">
|
|
35
|
|
- <div class="templateBox">
|
|
36
|
|
- <div class="template-title">{{ workBasicData.source === '电话' ? '问卷模版' : '短信模版' }}</div>
|
|
|
35
|
+ <div class="templateBox" v-if="workBasicData.way === '2'">
|
|
|
36
|
+ <div class="template-title">短信模版</div>
|
|
37
|
37
|
<div>
|
|
38
|
38
|
<el-tag type="primary">患者姓名</el-tag>
|
|
39
|
39
|
您好!我是开封市医院回访专员<el-tag type="primary">坐席昵称</el-tag>。
|
|
|
@@ -53,16 +53,44 @@
|
|
53
|
53
|
</template>
|
|
54
|
54
|
<el-row>
|
|
55
|
55
|
<el-col :span="12">
|
|
56
|
|
- <el-form-item label="选择模版" label-width="200px">
|
|
57
|
|
- <el-select v-model="selectValue" placeholder="请选择模版" style="width: 240px">
|
|
58
|
|
- <el-option label="均分" value="均分" />
|
|
59
|
|
- <el-option label="比例" value="比例" />
|
|
|
56
|
+ <el-form-item label="分配方式" label-width="200px">
|
|
|
57
|
+ <el-select v-model="allocation" placeholder="请选择分配方式" style="width: 240px">
|
|
|
58
|
+ <el-option v-for="item in allotMode" :key="item.value" :label="item.title" :value="item.value" />
|
|
60
|
59
|
</el-select>
|
|
61
|
60
|
</el-form-item>
|
|
62
|
61
|
</el-col>
|
|
63
|
62
|
<el-col :span="12">
|
|
64
|
63
|
<div class="questionBox">
|
|
65
|
|
- <seat-list></seat-list>
|
|
|
64
|
+ <div class="questionBox">
|
|
|
65
|
+ <el-table :data="seatListData" border style="margin-bottom: 15px;">
|
|
|
66
|
+ <el-table-column prop="usercode" label="成员"></el-table-column>
|
|
|
67
|
+ <el-table-column prop="username" label="工号"></el-table-column>
|
|
|
68
|
+ <el-table-column prop="userdept" label="部门"></el-table-column>
|
|
|
69
|
+ <el-table-column label="比例" v-if="allocation==='2'">
|
|
|
70
|
+ <template #default="scope">
|
|
|
71
|
+ <span v-show="scope.$index !== editIndex">{{ scope.row.proportion }}</span>
|
|
|
72
|
+ <el-input
|
|
|
73
|
+ v-show="scope.$index === editIndex"
|
|
|
74
|
+ v-model="scope.row.proportion"
|
|
|
75
|
+ ></el-input>
|
|
|
76
|
+ </template>
|
|
|
77
|
+ </el-table-column>
|
|
|
78
|
+ <el-table-column label="操作">
|
|
|
79
|
+ <template #default="{ row }">
|
|
|
80
|
+ <div style="display: flex;">
|
|
|
81
|
+ <el-button link @click="handleEdit(row)" v-if="allocation==='2'">编辑</el-button>
|
|
|
82
|
+ <el-button type="primary" link @click="handleSave" v-if="allocation==='2'">保存</el-button>
|
|
|
83
|
+ <el-button type="danger" link @click="handleDelete(row)"
|
|
|
84
|
+ >删除</el-button
|
|
|
85
|
+ >
|
|
|
86
|
+ </div>
|
|
|
87
|
+ </template>
|
|
|
88
|
+ </el-table-column>
|
|
|
89
|
+ </el-table>
|
|
|
90
|
+ <el-button class="mt-4" style="width: 100%" @click="onAddItem">
|
|
|
91
|
+ 新增坐席
|
|
|
92
|
+ </el-button>
|
|
|
93
|
+ </div>
|
|
66
|
94
|
</div>
|
|
67
|
95
|
</el-col>
|
|
68
|
96
|
</el-row>
|
|
|
@@ -72,275 +100,159 @@
|
|
72
|
100
|
<template #header>
|
|
73
|
101
|
<div class="card-header">
|
|
74
|
102
|
<span class="card-title">患者匹配规则</span>
|
|
75
|
|
- <a class="card-titleFr">下载导入模版</a>
|
|
|
103
|
+ <a class="card-titleFr" v-if="matchingMethod === '1'">下载导入模版</a>
|
|
76
|
104
|
</div>
|
|
77
|
105
|
|
|
78
|
106
|
</template>
|
|
79
|
107
|
<el-row>
|
|
80
|
108
|
<el-col :span="12">
|
|
81
|
109
|
<el-form-item label="去重方式" label-width="200px">
|
|
82
|
|
- <el-select v-model="selectValue2" placeholder="请选择去重方式" style="width: 240px">
|
|
83
|
|
- <el-option v-for="item in selectOptions2" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
110
|
+ <el-select v-model="deduplication" placeholder="请选择去重方式" style="width: 240px">
|
|
|
111
|
+ <el-option v-for="item in repetitionMode" :key="item.value" :label="item.title" :value="item.value" />
|
|
84
|
112
|
</el-select>
|
|
85
|
113
|
</el-form-item>
|
|
86
|
114
|
<el-form-item label="匹配方式" label-width="200px">
|
|
87
|
|
- <el-select v-model="selectValue3" placeholder="请选择匹配方式" @change="changeSelect3" style="width: 240px">
|
|
88
|
|
- <el-option v-for="item in selectOptions3" :key="item.value" :label="item.label" :value="item.value" />
|
|
|
115
|
+ <el-select v-model="matchingMethod" placeholder="请选择匹配方式" @change="changeSelect3" style="width: 240px">
|
|
|
116
|
+ <el-option v-for="item in matchMode" :key="item.value" :label="item.title" :value="item.value" :disabled="item.value=='1'" />
|
|
89
|
117
|
</el-select>
|
|
90
|
118
|
</el-form-item>
|
|
91
|
|
- <el-form-item label="周期" label-width="200px" v-if="selectValue3 === '筛选'">
|
|
92
|
|
- <el-select v-model="selectValue4" placeholder="请选择周期" style="width: 240px">
|
|
93
|
|
- <el-option label="一次" value="一次" />
|
|
94
|
|
- <el-option label="每天" value="每天" />
|
|
|
119
|
+ <el-form-item label="周期" label-width="200px" v-if="matchingMethod === '2'">
|
|
|
120
|
+ <el-select v-model="cycle" placeholder="请选择周期" style="width: 240px">
|
|
|
121
|
+ <el-option v-for="item in periodData" :key="item.value" :label="item.title" :value="item.value" />
|
|
95
|
122
|
</el-select>
|
|
96
|
123
|
</el-form-item>
|
|
97
|
|
- <el-form-item label="时间" label-width="200px" v-if="selectValue3 === '筛选'">
|
|
98
|
|
- <el-time-picker style="width: 240px" v-model="dataValue1" placeholder="请选择时间" />
|
|
|
124
|
+ <el-form-item label="时间" label-width="200px" v-if="matchingMethod === '2'">
|
|
|
125
|
+ <el-time-picker style="width: 240px" v-model="executionTime" placeholder="请选择时间" />
|
|
99
|
126
|
</el-form-item>
|
|
100
|
|
- <el-form-item label="患者数量" label-width="200px" v-if="selectValue3 === '筛选'">
|
|
101
|
|
- <el-radio-group v-model="dataRadio1">
|
|
102
|
|
- <el-radio label="1">无</el-radio>
|
|
103
|
|
- <el-radio label="2">固定</el-radio>
|
|
104
|
|
- <el-radio label="3">每日</el-radio>
|
|
|
127
|
+ <el-form-item label="患者数量" label-width="200px" v-if="matchingMethod === '2'">
|
|
|
128
|
+ <el-radio-group v-model="patientsNumRule">
|
|
|
129
|
+ <el-radio v-for="item in patientsData" :label="item.value" >{{item.title}}</el-radio>
|
|
105
|
130
|
</el-radio-group>
|
|
106
|
|
- <el-input-number style="margin-left: 30px;" v-model="dataNum1" :min="1" :max="10" />
|
|
|
131
|
+
|
|
|
132
|
+ </el-form-item>
|
|
|
133
|
+ <el-form-item label="" label-width="200px" v-if="patientsNumRule!=='1'">
|
|
|
134
|
+ <el-input-number v-model="patientsNum" :min="1" :max="9999" />
|
|
107
|
135
|
</el-form-item>
|
|
|
136
|
+
|
|
108
|
137
|
</el-col>
|
|
109
|
138
|
<el-col :span="12">
|
|
110
|
139
|
<div class="questionBox">
|
|
111
|
|
- <patient-list v-if="selectValue3 === '导入'"></patient-list>
|
|
112
|
|
- <div v-if="selectValue3 === '筛选'">
|
|
|
140
|
+
|
|
|
141
|
+ <patient-list v-if="matchingMethod === '1'"></patient-list>
|
|
|
142
|
+ <div v-if="matchingMethod === '2'" style="position: relative;">
|
|
113
|
143
|
<div>筛选条件</div>
|
|
114
|
|
- <div v-for="item in filterData" style="display: flex;">
|
|
115
|
|
- <div v-for="itemChild in item" style="margin: 15px 15px 0px 0px;">
|
|
116
|
|
- <el-select v-if="itemChild.type === 'select'" v-model="itemChild.value" placeholder="请选择"
|
|
|
144
|
+ <div v-for="( item , index ) in filterData" style="display: flex; margin-top: 15px;" >
|
|
|
145
|
+ <el-select class="formItem" v-model="item.officeItem.value" @change="officeItemChange($event,index)" placeholder="请选择" style="width: 120px">
|
|
|
146
|
+ <el-option
|
|
|
147
|
+ v-for="itemSon in item.officeItem.data"
|
|
|
148
|
+ :key="itemSon.value"
|
|
|
149
|
+ :label="itemSon.label"
|
|
|
150
|
+ :value="itemSon.value"
|
|
|
151
|
+ />
|
|
|
152
|
+ </el-select>
|
|
|
153
|
+ <el-select class="formItem" v-model="item.relationItem.value" placeholder="请选择"
|
|
117
|
154
|
style="width: 120px">
|
|
118
|
|
- <el-option v-for="itemSon in itemChild.data" :key="itemSon.value" :label="itemSon.label"
|
|
|
155
|
+ <el-option v-for="itemSon in item.relationItem.data" :key="itemSon.value" :label="itemSon.label"
|
|
119
|
156
|
:value="itemSon.value" />
|
|
120
|
157
|
</el-select>
|
|
121
|
|
- <el-input v-if="itemChild.type === 'input'" v-model="itemChild.value" style="width: 120px"
|
|
|
158
|
+ <el-select class="formItem" v-model="item.numberItem.value" v-if="item.numberItem.type ==='select'" placeholder="请选择" style="width: 120px">
|
|
|
159
|
+ <el-option v-for="itemSon in item.numberItem.data" :key="itemSon.value"
|
|
|
160
|
+ :label="itemSon.name"
|
|
|
161
|
+ :value="itemSon.value" />
|
|
|
162
|
+ </el-select>
|
|
|
163
|
+ <el-input class="formItem" v-model="item.numberItem.value" v-if="item.numberItem.type ==='input'" style="width: 120px"
|
|
122
|
164
|
placeholder="请输入" />
|
|
123
|
|
-
|
|
124
|
|
- </div>
|
|
|
165
|
+
|
|
|
166
|
+ </div>
|
|
|
167
|
+ <div class="filterIcon">
|
|
|
168
|
+ <el-button :icon="Plus" circle @click="filterAddItem" />
|
|
|
169
|
+ <el-button :icon="Minus" circle @click="filterMinuItem" v-if="filterData.length > 1"/>
|
|
125
|
170
|
</div>
|
|
|
171
|
+
|
|
126
|
172
|
</div>
|
|
127
|
173
|
</div>
|
|
128
|
174
|
</el-col>
|
|
129
|
175
|
</el-row>
|
|
130
|
176
|
</el-card>
|
|
131
|
177
|
<div style="width: 100%; height: 50px;"></div>
|
|
132
|
|
- <div class="box-btns" v-if="planId">
|
|
|
178
|
+ <div class="box-btns" v-if="!planId">
|
|
133
|
179
|
<el-button style="margin-right: 30px;" type="primary" @click="handleConfirmClick">确 定</el-button>
|
|
134
|
180
|
</div>
|
|
135
|
181
|
|
|
136
|
182
|
</div>
|
|
137
|
183
|
<el-dialog v-model="centerDialogVisibleQues" title="问卷信息" align-center width="30%" :modal="true" :show-close="true">
|
|
138
|
184
|
<el-form-item label="链接:" label-width="150px">
|
|
139
|
|
- <el-radio-group v-model="quesRadio1">
|
|
140
|
|
- <el-radio label="1">无</el-radio>
|
|
141
|
|
- <el-radio label="2">固定</el-radio>
|
|
142
|
|
- <el-radio label="3">每日</el-radio>
|
|
|
185
|
+ <el-radio-group v-model="messageType">
|
|
|
186
|
+ <el-radio label="1">问卷</el-radio>
|
|
|
187
|
+ <el-radio label="2">远程链接</el-radio>
|
|
143
|
188
|
</el-radio-group>
|
|
144
|
189
|
</el-form-item>
|
|
145
|
|
- <el-form-item label="" label-width="150px">
|
|
|
190
|
+ <el-form-item label-width="150px" v-if="messageType === '1'">
|
|
|
191
|
+ <el-select v-model="questionnaire" placeholder="请选择模版" style="width: 240px">
|
|
|
192
|
+ <el-option v-for="item in questionnaireData" :key="item.value" :label="item.title" :value="item.value" />
|
|
|
193
|
+ </el-select>
|
|
|
194
|
+ </el-form-item>
|
|
|
195
|
+ <el-form-item label-width="150px" v-if="messageType === '2'">
|
|
146
|
196
|
<el-input v-model="quesIput" placeholder="请输入链接"></el-input>
|
|
147
|
197
|
</el-form-item>
|
|
148
|
198
|
<div style="text-align: center; margin: 0 auto;">
|
|
149
|
|
- <el-button type="primary">确定</el-button>
|
|
|
199
|
+ <el-button type="primary" @click= "centerDialogVisibleQues = false">确定</el-button>
|
|
150
|
200
|
</div>
|
|
151
|
201
|
</el-dialog>
|
|
|
202
|
+ <el-dialog
|
|
|
203
|
+ v-model="centerDialogVisibleAddWorkorder"
|
|
|
204
|
+ title="新增坐席"
|
|
|
205
|
+ center
|
|
|
206
|
+ width="50%"
|
|
|
207
|
+ :modal="true"
|
|
|
208
|
+ :show-close="true"
|
|
|
209
|
+ >
|
|
|
210
|
+ <el-form-item label="请选择坐席" label-width="200px">
|
|
|
211
|
+ <el-select
|
|
|
212
|
+ v-model="seatSelectvalue"
|
|
|
213
|
+ multiple
|
|
|
214
|
+ filterable
|
|
|
215
|
+ remote
|
|
|
216
|
+ reserve-keyword
|
|
|
217
|
+ placeholder="Please enter a keyword"
|
|
|
218
|
+ :remote-method="remoteMethod"
|
|
|
219
|
+ :loading="loading"
|
|
|
220
|
+ style="width: 240px"
|
|
|
221
|
+ >
|
|
|
222
|
+ <el-option
|
|
|
223
|
+ v-for="item in rangeSeatData"
|
|
|
224
|
+ :key="item.value"
|
|
|
225
|
+ :label="item.title"
|
|
|
226
|
+ :value="item.value"
|
|
|
227
|
+ />
|
|
|
228
|
+ </el-select>
|
|
|
229
|
+ </el-form-item>
|
|
|
230
|
+ <div style="text-align: center;">
|
|
|
231
|
+ <el-button style="margin-right: 30px;" type="primary" @click="handleSeatTrue">确 定</el-button>
|
|
|
232
|
+ </div>
|
|
|
233
|
+ </el-dialog>
|
|
152
|
234
|
</div>
|
|
153
|
235
|
</template>
|
|
154
|
236
|
|
|
155
|
237
|
<script setup>
|
|
|
238
|
+ import {
|
|
|
239
|
+ Plus,
|
|
|
240
|
+ Minus
|
|
|
241
|
+} from '@element-plus/icons-vue'
|
|
|
242
|
+import moment from 'moment';
|
|
156
|
243
|
import PageAdd from '@/components/page-add';
|
|
157
|
244
|
import seatList from './cpns/seatList/seatList';
|
|
158
|
245
|
import patientList from './cpns/patientList/patientList';
|
|
159
|
246
|
import { modalConfig } from './config/modal.config';
|
|
160
|
247
|
import { usePageModal } from '@/hooks/use-page-add';
|
|
161
|
248
|
import useSelectStore from '@/store/commonSelect/common';
|
|
162
|
|
-import { createPageData, editPageData } from '@/api/main/system/system';
|
|
163
|
|
-import { onMounted, ref, watch } from 'vue';
|
|
|
249
|
+import { createPageData, editPageData,getPageListData } from '@/api/main/system/system';
|
|
164
|
250
|
|
|
|
251
|
+import {
|
|
|
252
|
+ followType,followWay,followExecution,allotMode,repetitionMode,
|
|
|
253
|
+ matchMode,periodData,patientsData } from "@/utils/commonDic.js";
|
|
165
|
254
|
|
|
166
|
|
-const { proxy } = getCurrentInstance();
|
|
167
|
|
-
|
|
168
|
|
-const formData = ref({});
|
|
169
|
|
-const workBasicData = ref({});
|
|
170
|
|
-const callId = ref({});
|
|
171
|
|
-const planId = ref('')
|
|
172
|
|
-const selectValue = ref('')
|
|
173
|
|
-const selectValue2 = ref('')
|
|
174
|
|
-const selectValue3 = ref('筛选')
|
|
175
|
|
-const selectValue4 = ref('')
|
|
176
|
|
-const dataValue1 = ref('')
|
|
177
|
|
-const dataRadio1 = ref('1')
|
|
178
|
|
-const dataNum1 = ref(1)
|
|
179
|
|
-
|
|
180
|
|
-const filterData = ref([
|
|
181
|
|
- [{
|
|
182
|
|
- type: 'select',
|
|
183
|
|
- data: [{
|
|
184
|
|
- value: '1',
|
|
185
|
|
- label: '1',
|
|
186
|
|
- },
|
|
187
|
|
- {
|
|
188
|
|
- value: '2',
|
|
189
|
|
- label: '2',
|
|
190
|
|
- }
|
|
191
|
|
- ],
|
|
192
|
|
- value: '1'
|
|
193
|
|
- }, {
|
|
194
|
|
- type: 'input',
|
|
195
|
|
- data: [{
|
|
196
|
|
- value: '1',
|
|
197
|
|
- label: '1',
|
|
198
|
|
- },
|
|
199
|
|
- {
|
|
200
|
|
- value: '2',
|
|
201
|
|
- label: '2',
|
|
202
|
|
- }
|
|
203
|
|
- ],
|
|
204
|
|
- value: '2'
|
|
205
|
|
- }, {
|
|
206
|
|
- type: 'select',
|
|
207
|
|
- data: [{
|
|
208
|
|
- value: '1',
|
|
209
|
|
- label: '1',
|
|
210
|
|
- },
|
|
211
|
|
- {
|
|
212
|
|
- value: '2',
|
|
213
|
|
- label: '2',
|
|
214
|
|
- }
|
|
215
|
|
- ],
|
|
216
|
|
- value: '2'
|
|
217
|
|
- }],
|
|
218
|
|
- [{
|
|
219
|
|
- type: 'select',
|
|
220
|
|
- data: [{
|
|
221
|
|
- value: '1',
|
|
222
|
|
- label: '1',
|
|
223
|
|
- },
|
|
224
|
|
- {
|
|
225
|
|
- value: '2',
|
|
226
|
|
- label: '2',
|
|
227
|
|
- }
|
|
228
|
|
- ],
|
|
229
|
|
- value: '2'
|
|
230
|
|
- }, {
|
|
231
|
|
- type: 'select',
|
|
232
|
|
- data: [{
|
|
233
|
|
- value: '1',
|
|
234
|
|
- label: '1',
|
|
235
|
|
- },
|
|
236
|
|
- {
|
|
237
|
|
- value: '2',
|
|
238
|
|
- label: '2',
|
|
239
|
|
- }
|
|
240
|
|
- ],
|
|
241
|
|
- value: '2'
|
|
242
|
|
- }, {
|
|
243
|
|
- type: 'input',
|
|
244
|
|
- value: '2'
|
|
245
|
|
- }]
|
|
246
|
|
-])
|
|
247
|
|
-const selectOptions = [
|
|
248
|
|
- {
|
|
249
|
|
- value: '问卷模版1',
|
|
250
|
|
- label: '问卷模版1',
|
|
251
|
|
- },
|
|
252
|
|
- {
|
|
253
|
|
- value: '问卷模版2',
|
|
254
|
|
- label: '问卷模版2',
|
|
255
|
|
- },
|
|
256
|
|
- {
|
|
257
|
|
- value: '问卷模版3',
|
|
258
|
|
- label: '问卷模版3',
|
|
259
|
|
- }
|
|
260
|
|
-]
|
|
261
|
|
-const selectOptions11 = [
|
|
262
|
|
- {
|
|
263
|
|
- value: '短信模版1',
|
|
264
|
|
- label: '短信模版1',
|
|
265
|
|
- },
|
|
266
|
|
- {
|
|
267
|
|
- value: '短信模版2',
|
|
268
|
|
- label: '短信模版2',
|
|
269
|
|
- },
|
|
270
|
|
- {
|
|
271
|
|
- value: '短信模版2',
|
|
272
|
|
- label: '短信模版2',
|
|
273
|
|
- }
|
|
274
|
|
-]
|
|
275
|
|
-const selectOptions2 = [
|
|
276
|
|
- {
|
|
277
|
|
- value: '不去重',
|
|
278
|
|
- label: '不去重',
|
|
279
|
|
- },
|
|
280
|
|
- {
|
|
281
|
|
- value: '全部不重复',
|
|
282
|
|
- label: '全部不重复',
|
|
283
|
|
- },
|
|
284
|
|
- {
|
|
285
|
|
- value: '计划不重复',
|
|
286
|
|
- label: '计划不重复',
|
|
287
|
|
- }
|
|
288
|
|
-]
|
|
289
|
|
-
|
|
290
|
|
-const centerDialogVisibleQues = ref(false)
|
|
291
|
|
-const quesIput = ref('1')
|
|
292
|
|
-const quesRadio1 = ref('1')
|
|
293
|
|
-function changeSelect3(data) {
|
|
294
|
|
- console.log(data)
|
|
295
|
|
-}
|
|
296
|
|
-const selectOptions3 = [
|
|
297
|
|
- {
|
|
298
|
|
- value: '导入',
|
|
299
|
|
- label: '导入',
|
|
300
|
|
- },
|
|
301
|
|
- {
|
|
302
|
|
- value: '筛选',
|
|
303
|
|
- label: '筛选',
|
|
304
|
|
- }
|
|
305
|
|
-]
|
|
306
|
|
-const tableData = [
|
|
307
|
|
- {
|
|
308
|
|
- date: '2016-05-03',
|
|
309
|
|
- name: 'Tom',
|
|
310
|
|
- state: 'California',
|
|
311
|
|
- city: 'Los Angeles',
|
|
312
|
|
- address: 'No. 189, Grove St, Los Angeles',
|
|
313
|
|
- zip: 'CA 90036',
|
|
314
|
|
- tag: 'Home',
|
|
315
|
|
- },
|
|
316
|
|
- {
|
|
317
|
|
- date: '2016-05-02',
|
|
318
|
|
- name: 'Tom',
|
|
319
|
|
- state: 'California',
|
|
320
|
|
- city: 'Los Angeles',
|
|
321
|
|
- address: 'No. 189, Grove St, Los Angeles',
|
|
322
|
|
- zip: 'CA 90036',
|
|
323
|
|
- tag: 'Office',
|
|
324
|
|
- },
|
|
325
|
|
- {
|
|
326
|
|
- date: '2016-05-04',
|
|
327
|
|
- name: 'Tom',
|
|
328
|
|
- state: 'California',
|
|
329
|
|
- city: 'Los Angeles',
|
|
330
|
|
- address: 'No. 189, Grove St, Los Angeles',
|
|
331
|
|
- zip: 'CA 90036',
|
|
332
|
|
- tag: 'Home',
|
|
333
|
|
- },
|
|
334
|
|
- {
|
|
335
|
|
- date: '2016-05-01',
|
|
336
|
|
- name: 'Tom',
|
|
337
|
|
- state: 'California',
|
|
338
|
|
- city: 'Los Angeles',
|
|
339
|
|
- address: 'No. 189, Grove St, Los Angeles',
|
|
340
|
|
- zip: 'CA 90036',
|
|
341
|
|
- tag: 'Office',
|
|
342
|
|
- },
|
|
343
|
|
-]
|
|
|
255
|
+import { onMounted, ref, watch } from 'vue';
|
|
344
|
256
|
const props = defineProps({
|
|
345
|
257
|
getDefaultInfo: {
|
|
346
|
258
|
type: Object,
|
|
|
@@ -355,30 +267,128 @@ watch(props, (nweProps) => {
|
|
355
|
267
|
planId.value = nweProps.planId
|
|
356
|
268
|
initMethod(nweProps);
|
|
357
|
269
|
});
|
|
|
270
|
+
|
|
|
271
|
+const { proxy } = getCurrentInstance();
|
|
|
272
|
+const planId = ref('')
|
|
|
273
|
+const loading = ref(false)
|
|
|
274
|
+const seatSelectvalue = ref()
|
|
|
275
|
+const rangeSeatData = ref([])
|
|
|
276
|
+const seatData = ref([])
|
|
|
277
|
+const seatDataList = ref([])
|
|
|
278
|
+const seatValue = ref()
|
|
|
279
|
+const seatListData = ref([])
|
|
|
280
|
+const seatResultData = ref([])
|
|
|
281
|
+const filterOfficeData = ref([])
|
|
|
282
|
+const filterObjData = ref({
|
|
|
283
|
+ officeItem:{
|
|
|
284
|
+ type: 'select',
|
|
|
285
|
+ data: [],
|
|
|
286
|
+ value: ''
|
|
|
287
|
+ },
|
|
|
288
|
+ relationItem:{
|
|
|
289
|
+ type: 'select',
|
|
|
290
|
+ data: [],
|
|
|
291
|
+ value: ''
|
|
|
292
|
+ },
|
|
|
293
|
+ numberItem: {
|
|
|
294
|
+ type: 'input',
|
|
|
295
|
+ value: ''
|
|
|
296
|
+ }
|
|
|
297
|
+})
|
|
|
298
|
+const filterLongData = ref([])
|
|
|
299
|
+const filterData = ref([])
|
|
|
300
|
+
|
|
|
301
|
+
|
|
|
302
|
+const formData = ref({});
|
|
|
303
|
+const workBasicData = ref({});
|
|
|
304
|
+const questionnaire = ref('') // 问卷模版id
|
|
|
305
|
+const message = ref('') // 短信模版id
|
|
|
306
|
+const quesIput = ref('1') // 链接
|
|
|
307
|
+const messageType = ref('1') // 短信模版问卷id
|
|
|
308
|
+const allocation = ref('') // 分配方式
|
|
|
309
|
+
|
|
|
310
|
+const deduplication = ref('') // 去重方式
|
|
|
311
|
+const matchingMethod = ref('2') // 匹配方式
|
|
|
312
|
+const cycle = ref('') // 周期
|
|
|
313
|
+const executionTime = ref('') // 时间
|
|
|
314
|
+const patientsNumRule = ref('1') // 患者规则
|
|
|
315
|
+const patientsNum = ref(1) // 患者数量
|
|
|
316
|
+const filterResultData = ref([])
|
|
|
317
|
+
|
|
|
318
|
+const questionnaireData = useSelectStore().questionnaireData
|
|
|
319
|
+const smsData = useSelectStore().templateNameListData
|
|
|
320
|
+
|
|
|
321
|
+const centerDialogVisibleQues = ref(false)
|
|
|
322
|
+function changeSelect3(data) {
|
|
|
323
|
+ console.log(data)
|
|
|
324
|
+}
|
|
358
|
325
|
onMounted(() => {
|
|
359
|
|
- workBasicData.value.source = '电话'
|
|
|
326
|
+ workBasicData.value.way = '1'
|
|
360
|
327
|
initMethod(props);
|
|
361
|
328
|
});
|
|
362
|
|
-
|
|
363
|
329
|
function initMethod(data) {
|
|
364
|
|
- console.log(data)
|
|
|
330
|
+ getFilterList()
|
|
|
331
|
+ getSeatList()
|
|
|
332
|
+ seatData.value = useSelectStore().userListData
|
|
|
333
|
+}
|
|
|
334
|
+const centerDialogVisibleAddWorkorder = ref(false);
|
|
|
335
|
+const onAddItem = () => {
|
|
|
336
|
+ seatSelectvalue.value = []
|
|
|
337
|
+ centerDialogVisibleAddWorkorder.value = true;
|
|
|
338
|
+}
|
|
|
339
|
+function handleSeatTrue() {
|
|
|
340
|
+ centerDialogVisibleAddWorkorder.value = false;
|
|
|
341
|
+ console.log(seatSelectvalue.value)
|
|
|
342
|
+ console.log(seatDataList.value);
|
|
|
343
|
+ seatDataList.value.forEach(element => {
|
|
|
344
|
+ const obj = {}
|
|
|
345
|
+ obj.username = element.nickName
|
|
|
346
|
+ obj.usercode = element.userName
|
|
|
347
|
+ // obj.userdept = element.dept ?element.dept.deptName:''
|
|
|
348
|
+ obj.proportion = ''
|
|
|
349
|
+ if (seatSelectvalue.value.indexOf(obj.usercode)!=-1) {
|
|
|
350
|
+ seatResultData.value.push(obj)
|
|
|
351
|
+ // obj.userdept = element.dept ?element.dept.deptName:''
|
|
|
352
|
+ seatListData.value.push(obj)
|
|
|
353
|
+
|
|
|
354
|
+ }
|
|
|
355
|
+
|
|
|
356
|
+ });
|
|
|
357
|
+ console.log(seatListData.value)
|
|
|
358
|
+
|
|
|
359
|
+}
|
|
|
360
|
+const remoteMethod = (query) => {
|
|
|
361
|
+ if (query) {
|
|
|
362
|
+ loading.value = true
|
|
|
363
|
+ setTimeout(() => {
|
|
|
364
|
+ loading.value = false
|
|
|
365
|
+ rangeSeatData.value = seatData.value.filter((item) => {
|
|
|
366
|
+ return item.title.toLowerCase().includes(query.toLowerCase())
|
|
|
367
|
+ })
|
|
|
368
|
+ }, 200)
|
|
|
369
|
+ } else {
|
|
|
370
|
+ rangeSeatData.value = []
|
|
|
371
|
+ }
|
|
365
|
372
|
}
|
|
366
|
373
|
function questionHandle() {
|
|
367
|
|
- console.log("问卷")
|
|
368
|
374
|
centerDialogVisibleQues.value = true
|
|
369
|
375
|
}
|
|
370
|
376
|
const modalConfigRef = computed(() => {
|
|
371
|
|
- // 来源
|
|
372
|
|
- const processorSourceItem = modalConfig.formItems.find((item) => item.field === 'source');
|
|
373
|
|
- processorSourceItem.options = useSelectStore().dictSourceList;
|
|
374
|
|
-
|
|
375
|
|
-
|
|
|
377
|
+ // 随访类型
|
|
|
378
|
+ const processorTypeItem = modalConfig.formItems.find((item) => item.field === 'type');
|
|
|
379
|
+ processorTypeItem.options = followType;
|
|
|
380
|
+ // 随访方式
|
|
|
381
|
+ const processorwayItem = modalConfig.formItems.find((item) => item.field === 'way');
|
|
|
382
|
+ processorwayItem.options = followWay;
|
|
|
383
|
+ // 随访方式
|
|
|
384
|
+ const processorExecutionItem = modalConfig.formItems.find((item) => item.field === 'executionMethod');
|
|
|
385
|
+ processorExecutionItem.options = followExecution;
|
|
|
386
|
+
|
|
376
|
387
|
return modalConfig;
|
|
377
|
388
|
});
|
|
378
|
389
|
|
|
379
|
390
|
// 工单基础信息
|
|
380
|
391
|
const getWorkBasicData = (item) => {
|
|
381
|
|
-
|
|
382
|
392
|
workBasicData.value = item;
|
|
383
|
393
|
console.log(workBasicData.value)
|
|
384
|
394
|
};
|
|
|
@@ -388,22 +398,122 @@ defineExpose({
|
|
388
|
398
|
const handleConfirmClick = () => {
|
|
389
|
399
|
pageModalRef.value.formRef.ruleFormRef.validate((bool) => {
|
|
390
|
400
|
if (bool) {
|
|
391
|
|
- if (JSON.stringify(props.getDefaultInfo) !== '{}') {
|
|
392
|
|
- formData.value.workorderId = props.getDefaultInfo.workorderId;
|
|
393
|
|
- editPageData('/order/workorder', formData.value).then((data) => {
|
|
394
|
|
- proxy.$modal.msgSuccess('编辑成功!');
|
|
395
|
|
- });
|
|
396
|
|
- } else {
|
|
397
|
|
- let creatUrl = '/order/workorder';
|
|
398
|
|
- creatUrl = '/order/workorder?callid=' + callId.value;
|
|
399
|
|
- createPageData(creatUrl, formData.value).then((data) => {
|
|
400
|
|
- proxy.$modal.msgSuccess('新增成功!');
|
|
401
|
|
- });
|
|
402
|
|
- }
|
|
|
401
|
+ handleFilter()
|
|
|
402
|
+ formData.value = workBasicData.value
|
|
|
403
|
+ formData.value.beginEffective = moment(workBasicData.value.indate[0]).format('YYYY-MM-DD HH:mm:ss')
|
|
|
404
|
+ formData.value.endEffective = moment(workBasicData.value.indate[1]).format('YYYY-MM-DD HH:mm:ss')
|
|
|
405
|
+ delete formData.value.indate
|
|
|
406
|
+ formData.value.questionnaire = questionnaire.value
|
|
|
407
|
+ formData.value.message = message.value
|
|
|
408
|
+ formData.value.messageType = messageType.value
|
|
|
409
|
+ formData.value.messageParameter = messageType.value==='1' ? questionnaire.value : quesIput.value
|
|
|
410
|
+ formData.value.allocation = allocation.value
|
|
|
411
|
+ formData.value.seats = seatResultData.value //seatResultData.value
|
|
|
412
|
+ formData.value.deduplication = deduplication.value
|
|
|
413
|
+ formData.value.matchingMethod = matchingMethod.value
|
|
|
414
|
+ formData.value.cycle = cycle.value
|
|
|
415
|
+ formData.value.executionTime = moment(executionTime.value).format('HH:mm:ss')
|
|
|
416
|
+ formData.value.patientsNumRule =patientsNumRule.value
|
|
|
417
|
+ formData.value.patientsNum = patientsNum.value
|
|
|
418
|
+ formData.value.screen = JSON.stringify(filterResultData.value)
|
|
|
419
|
+ console.log(formData.value)
|
|
|
420
|
+ createPageData('/SfPlan/sfPlan', formData.value).then((data) => {
|
|
|
421
|
+ proxy.$modal.msgSuccess('新增成功!');
|
|
|
422
|
+ })
|
|
|
423
|
+ // editPageData('/order/workorder', formData.value).then((data) => {})
|
|
403
|
424
|
}
|
|
404
|
425
|
});
|
|
405
|
426
|
};
|
|
406
|
427
|
|
|
|
428
|
+
|
|
|
429
|
+const editIndex = ref(-1)
|
|
|
430
|
+const handleEdit = (row) => {
|
|
|
431
|
+ editIndex.value = seatListData.value.indexOf(row)
|
|
|
432
|
+}
|
|
|
433
|
+const handleSave = () => {
|
|
|
434
|
+ editIndex.value = -1
|
|
|
435
|
+ console.log(seatListData.value)
|
|
|
436
|
+}
|
|
|
437
|
+const handleDelete = (row) => {
|
|
|
438
|
+ seatListData.value.splice(seatListData.value.indexOf(row), 1)
|
|
|
439
|
+}
|
|
|
440
|
+const props2 = {
|
|
|
441
|
+ multiple: true,
|
|
|
442
|
+ checkStrictly: true,
|
|
|
443
|
+}
|
|
|
444
|
+function getSeatList() {
|
|
|
445
|
+ getPageListData('/system/user').then((res)=>{
|
|
|
446
|
+ seatDataList.value = res.data
|
|
|
447
|
+ })
|
|
|
448
|
+}
|
|
|
449
|
+function filterAddItem() {
|
|
|
450
|
+
|
|
|
451
|
+ const newObj = {
|
|
|
452
|
+ officeItem:{
|
|
|
453
|
+ type: 'select',
|
|
|
454
|
+ data: filterOfficeData.value,
|
|
|
455
|
+ value: ''
|
|
|
456
|
+ },
|
|
|
457
|
+ relationItem:{
|
|
|
458
|
+ type: 'select',
|
|
|
459
|
+ data: [],
|
|
|
460
|
+ value: ''
|
|
|
461
|
+ },
|
|
|
462
|
+ numberItem: {
|
|
|
463
|
+ type: 'input',
|
|
|
464
|
+ value: ''
|
|
|
465
|
+ }
|
|
|
466
|
+ }
|
|
|
467
|
+ filterData.value.push(newObj)
|
|
|
468
|
+}
|
|
|
469
|
+function filterMinuItem() {
|
|
|
470
|
+ filterData.value.pop()
|
|
|
471
|
+}
|
|
|
472
|
+function handleFilter() {
|
|
|
473
|
+ console.log(filterData.value);
|
|
|
474
|
+ filterResultData.value = []
|
|
|
475
|
+ filterData.value.forEach(ele => {
|
|
|
476
|
+ const obj = {}
|
|
|
477
|
+ obj.field = ele.officeItem.value
|
|
|
478
|
+ obj.operate = ele.relationItem.value
|
|
|
479
|
+ obj.value = ele.numberItem.value
|
|
|
480
|
+ filterResultData.value.push(obj)
|
|
|
481
|
+ });
|
|
|
482
|
+ console.log(JSON.stringify(filterResultData.value));
|
|
|
483
|
+}
|
|
|
484
|
+function officeItemChange(value,index) {
|
|
|
485
|
+ console.log(value,index);
|
|
|
486
|
+ filterLongData.value.forEach(ele => {
|
|
|
487
|
+ if (ele.field.value === value) {
|
|
|
488
|
+ filterData.value[index].relationItem.data = ele.operate
|
|
|
489
|
+ if (ele.value) {
|
|
|
490
|
+ filterData.value[index].numberItem.type = 'select'
|
|
|
491
|
+ filterData.value[index].numberItem.data = ele.value
|
|
|
492
|
+ } else{
|
|
|
493
|
+ filterData.value[index].numberItem.type = 'input'
|
|
|
494
|
+ }
|
|
|
495
|
+ }
|
|
|
496
|
+ });
|
|
|
497
|
+}
|
|
|
498
|
+function getFilterList() {
|
|
|
499
|
+ getPageListData('/SfPlan/sfPlan/option').then((res)=>{
|
|
|
500
|
+ console.log(res);
|
|
|
501
|
+ if (res.data.length>0) {
|
|
|
502
|
+ filterLongData.value = res.data
|
|
|
503
|
+ res.data.forEach(ele => {
|
|
|
504
|
+ const obj = {
|
|
|
505
|
+ value:ele.field.value,
|
|
|
506
|
+ label:ele.field.name,
|
|
|
507
|
+ }
|
|
|
508
|
+ filterObjData.value.officeItem.data.push(obj)
|
|
|
509
|
+ filterOfficeData.value.push(obj)
|
|
|
510
|
+ });
|
|
|
511
|
+ filterData.value.push(filterObjData.value)
|
|
|
512
|
+ }
|
|
|
513
|
+ console.log(filterData.value);
|
|
|
514
|
+ })
|
|
|
515
|
+}
|
|
|
516
|
+
|
|
407
|
517
|
// 1.处理逻辑
|
|
408
|
518
|
const newCallback = () => { };
|
|
409
|
519
|
const editCallback = () => { };
|
|
|
@@ -463,6 +573,14 @@ const [pageModalRef, defaultInfo] = usePageModal(newCallback, editCallback);
|
|
463
|
573
|
}
|
|
464
|
574
|
|
|
465
|
575
|
.questionBox {
|
|
466
|
|
- width: 100%;
|
|
|
576
|
+ width: 400px;
|
|
|
577
|
+ .filterIcon{
|
|
|
578
|
+ position: absolute;
|
|
|
579
|
+ right: -70px;
|
|
|
580
|
+ bottom: 0px;
|
|
|
581
|
+ }
|
|
|
582
|
+ .formItem{
|
|
|
583
|
+ margin-right: 8px;
|
|
|
584
|
+ }
|
|
467
|
585
|
}
|
|
468
|
586
|
</style>
|