telephone-clients 4.0.0-1-5 → 4.0.0-1-6

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "telephone-clients",
3
- "version": "4.0.0-1-5",
3
+ "version": "4.0.0-1-6",
4
4
  "description": "呼叫模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "directories": {
@@ -47,26 +47,6 @@
47
47
  v-if="!show" :disabled="issee"></textarea>
48
48
  </div>
49
49
  </div>
50
- <div class="row auto" v-if="imgtpe">
51
- <div class="col-xs-12 col-sm-12 col-md-12 form-input-group" v-for="row in imgstype">
52
- <label class="text-justify lb-left">{{ row.title }}</label>
53
- <img-area :model="model.imgs" :sutitle="getsutitle(row.title)" :isxiangce="isxiangce"></img-area>
54
- </div>
55
- </div>
56
- <!-- <div v-if="pdfurl">-->
57
- <!-- <iframe class="prism-player" :src="pdfurl" width="100%" height="100%"></iframe>-->
58
- <!-- </div>-->
59
- <img-area :model="model.imgs" :sutitle="'总体照片'" v-if="!imgtpe" :isxiangce="isxiangce"></img-area>
60
- <p style="font-size: 15px;font-weight: bold" v-if="model.f_sign_imgid">客户签名:</p>
61
- <div v-if="!show && signType">
62
- <Sign :signname="model.f_signname" @input="getSignValue"></Sign>
63
- </div>
64
- <div v-if="!show && !signType">
65
- <new-sign :value="model.f_signname" @input="getSignValue"></new-sign>
66
- </div>
67
- <div v-if="show && model.f_sign_imgid">
68
- <img :src="'rs/file/getfile/' + model.f_sign_imgid" :width="150" :height="200">
69
- </div>
70
50
  <div class="form-group col-md-12 col-sm-12 col-xs-12">
71
51
  <div class="row">
72
52
  <label class="text-left">请对我们的服务做出评价:</label>
@@ -89,7 +69,32 @@
89
69
  @click="delAudioFile('f_recording_path', model.f_recording_path)"></img>
90
70
  </div>
91
71
  </div>
92
-
72
+ <div class="row auto">
73
+ <div class="col-xs-12 col-sm-12 col-md-12 form-input-group">
74
+ <label class="text-justify lb-left">处理前照片</label>
75
+ <img-area :model="model.imgs" :sutitle="处理前照片"></img-area>
76
+ </div>
77
+ </div>
78
+ <div class="row auto" v-if="imgtpe">
79
+ <div class="col-xs-12 col-sm-12 col-md-12 form-input-group" v-for="row in imgstype">
80
+ <label class="text-justify lb-left">{{ row.title }}</label>
81
+ <img-area :model="model.imgs" :sutitle="getsutitle(row.title)" :isxiangce="isxiangce"></img-area>
82
+ </div>
83
+ </div>
84
+ <!-- <div v-if="pdfurl">-->
85
+ <!-- <iframe class="prism-player" :src="pdfurl" width="100%" height="100%"></iframe>-->
86
+ <!-- </div>-->
87
+ <img-area :model="model.imgs" :sutitle="'总体照片'" v-if="!imgtpe" :isxiangce="isxiangce"></img-area>
88
+ <p style="font-size: 15px;font-weight: bold" v-if="model.f_sign_imgid">客户签名:</p>
89
+ <div v-if="!show && signType">
90
+ <Sign :signname="model.f_signname" @input="getSignValue"></Sign>
91
+ </div>
92
+ <div v-if="!show && !signType">
93
+ <new-sign :value="model.f_signname" @input="getSignValue"></new-sign>
94
+ </div>
95
+ <div v-if="show && model.f_sign_imgid">
96
+ <img :src="'rs/file/getfile/' + model.f_sign_imgid" :width="150" :height="200">
97
+ </div>
93
98
  </div>
94
99
  <material-sum v-if="!materialsumshow" v-on:sumchange="sumchange"
95
100
  v-on:back="showchenge" :material="model.material" :f_cost_material="model.f_cost_material"
@@ -115,12 +115,12 @@
115
115
  <div class="row" style="margin-top: 6px">
116
116
  <label class="col-xs-4 col-md-4 control-label font text-left">派单方式</label>
117
117
  <div class="col-xs-8">
118
- <v-select :value="f_handlingtype" :value-single="true" v-model="f_handlingtype"
118
+ <v-select :value-single="true" :value.sync="f_handlingtype" v-model="f_handlingtype"
119
119
  :options='repairerType' placeholder='请选择派单方式'
120
120
  close-on-select></v-select>
121
121
  </div>
122
122
  </div>
123
- <div class="row" style="margin-top: 6px" v-if=" f_handlingtype == '转维修员' ">
123
+ <div class="row" style="margin-top: 6px" v-if="f_handlingtype == '转维修员'">
124
124
  <label class="col-xs-4 col-md-4 control-label font text-left">维修员</label>
125
125
  <div class="col-xs-8">
126
126
  <v-select :value="sendselected.serviceacitivity[0].f_reciever" :value-single="true"
@@ -128,7 +128,7 @@
128
128
  close-on-select v-on:change="repiarmancg"></v-select>
129
129
  </div>
130
130
  </div>
131
- <div class="row" style="margin-top: 6px" v-if=" f_handlingtype == '转站点' ">
131
+ <div class="row" style="margin-top: 6px" v-if="f_handlingtype == '转站点'">
132
132
  <label class="col-xs-4 col-md-4 control-label font text-left">站点</label>
133
133
  <input style="width: 60%" type="text" v-show="false" v-model="sendselected.serviceacitivity[0].f_reciever">
134
134
  <right-tree islist :userid="userid" :source="source" v-on:re-res="reres" :textContent="选择站点管理员">
@@ -217,12 +217,12 @@ export default{
217
217
  if(val.res == undefined || val.res[0] == undefined || val.res[0] == ''){
218
218
  return
219
219
  }
220
- this.model.serviceacitivity[0].f_meetunit = val.res[0]
221
- this.model.f_meetunit = val.res[0]
222
- this.model.f_filiale_id = val.orgobj[0].parentid
223
- this.model.f_filiale = val.orgobj[0].parentname
224
- this.model.f_outlets = val.res[0]
225
- this.model.serviceacitivity[0].f_reciever = val.resids[0]
220
+ this.sendselected.serviceacitivity[0].f_meetunit = val.res[0]
221
+ this.sendselected.f_meetunit = val.res[0]
222
+ this.sendselected.f_filiale_id = val.orgobj[0].parentid
223
+ this.sendselected.f_filiale = val.orgobj[0].parentname
224
+ this.sendselected.f_outlets = val.res[0]
225
+ this.sendselected.serviceacitivity[0].f_reciever = val.resids[0]
226
226
  },
227
227
  caseend(val){
228
228
  this.selectone = val
@@ -0,0 +1,336 @@
1
+ <style scoped>
2
+ .bg {
3
+ background-color: blue;
4
+ height: 1px;
5
+ border: 0;
6
+ }
7
+ .app-row {
8
+ background-color: white;
9
+ padding: 10px 10px 0 10px;
10
+ border-bottom: 1px solid rgba(235, 235, 235, 0.5);
11
+ }
12
+ .search_input {
13
+ border: 0;
14
+ outline: none;
15
+ }
16
+ .font{
17
+ font: 15px PingFang-SC-Medium;
18
+ color: #666666;
19
+ }
20
+ .input-font{
21
+ font: 15px PingFang-SC-Medium;
22
+ color: #333333;
23
+ }
24
+ .btn-font{
25
+ font:600 16px PingFang-SC-Bold;
26
+ color: #499EDF;
27
+ }
28
+ .btn-color{
29
+ background-color: #FFFFFF;
30
+ border-radius: 10px ;
31
+ border: 1px solid #499EDF;
32
+ }
33
+ .app-text {
34
+ font-size: 12px;
35
+ }
36
+ .panel-self{
37
+ border-radius: 10px;
38
+ border:1px solid #499EDF;
39
+ background-color: #F8F8F8;
40
+ }
41
+ .yybtn-color{
42
+ background-color:#499edf;
43
+ border-radius: 4px ;
44
+ border: 1px solid #499EDF;
45
+ color: #FFFFFF;
46
+ font: 14px PingFang-SC-Bold;
47
+ }
48
+ .qxbtn-color{
49
+ background-color: #FFFFFF;
50
+ border-radius: 4px ;
51
+ color: #499edf;
52
+ font: 14px PingFang-SC-Bold;
53
+ border: 1px solid #499EDF;
54
+ }
55
+
56
+ .button_shrink_top {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_top.png")}
57
+ .button_shrink_bottom {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_bottom.png")}
58
+ .button_shrink_left {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_left.png")}
59
+ .button_shrink_right {width: 35px; height: 35px; background-size:100%;background-image: url("../../../../static/newStyle/stretch_right.png")}
60
+ </style>
61
+
62
+ <template>
63
+ <div style="height: auto;width: 100%">
64
+ <criteria-paged :model="model" v-ref:paged>
65
+ <criteria partial='criteria' @condition-changed='$parent.search' v-ref:cri>
66
+ <div partial>
67
+ <form>
68
+ <div class="row app-row">
69
+ <div class="col-xs-4">
70
+ <img src="../../../assets/用户姓名.png" style="width: 20px;margin-bottom: 5px" alt="">
71
+ <label for="user-name-id" class="font text-left">用户姓名:</label>
72
+ </div>
73
+ <div class="col-xs-8" >
74
+ <input class="search_input input-font" id="user-name-id"
75
+ v-model=model.f_user_name condition="f_user_name like '%{}%'" />
76
+ </div>
77
+ </div>
78
+
79
+ <div class="row app-row" >
80
+ <div class="col-xs-4">
81
+ <img src="../../../assets/用户ID.png" style="width: 20px;margin-bottom: 5px" alt="">
82
+ <label for="user-info-id" class="font text-left">工单编号:</label>
83
+ </div>
84
+ <input id="user-info-id" class="search_input input-font" v-model="model.f_service_id"
85
+ condition="f_service_id like '%{}%'">
86
+ </div>
87
+
88
+ <div class="row app-row">
89
+ <div class="col-xs-4">
90
+ <img src="../../../assets/用户类型.png" style="width: 20px;margin-bottom: 5px" alt="">
91
+ <label for="f_f_address" class="font text-left">用户地址:</label>
92
+ </div>
93
+ <div class="col-xs-8" >
94
+ <input id="f_f_address" class="search_input input-font"
95
+ v-model=model.f_address condition="f_address like '%{}%'" />
96
+ </div>
97
+ </div>
98
+
99
+ <div class="row app-row">
100
+ <div class="col-xs-4">
101
+ <img src="../../../assets/用户类型.png" style="width: 20px;margin-bottom: 5px" alt="">
102
+ <label for="f_f_address" class="font text-left">报修类型:</label>
103
+ </div>
104
+ <div class="col-xs-8" >
105
+ <v-select
106
+ :value.sync="model.f_repairtype"
107
+ v-model="model.f_repairtype"
108
+ :options='$parent.$parent.repairTypeOptions'
109
+ placeholder='请选择'
110
+ :multiple="true"
111
+ condition="f_repairtype in {}"
112
+ ></v-select>
113
+ </div>
114
+ </div>
115
+
116
+ <div class="row text-center" style="margin-top: 20px;">
117
+ <button type="button" class="btn btn-lg btn-font btn-color" style="width: 25%;" @click="search()">查询</button>
118
+ </div>
119
+ <div style="height:30px;"></div>
120
+ <table style="margin-left: 15px;text-align: center;font-size: 16px" border="1">
121
+ <tr style="background-color: #f2f2f2;height: 20px">
122
+ <td style="width: 15%" v-for="row in $parent.$parent.typeData">{{ row.type }}</td>
123
+ </tr>
124
+ <tr>
125
+ <td style="width: 15%" v-for="row in $parent.$parent.typeData">{{ row.type_num || '0' }}</td>
126
+ </tr>
127
+ </table>
128
+ </form>
129
+ </div>
130
+ </criteria>
131
+ <list :model="model" partial='list' >
132
+ <div partial>
133
+ <div class="auto app-text" style="margin-top: 5px;">
134
+ <div class="panel" style="padding: 10px 10px 5px 10px;">
135
+ <div class="panel-body panel-self" :style="row.f_repairtype === '抢险维修'?'border: 1px solid red;':''">
136
+ <div class="col-xs-6">
137
+ <p class="panel-title col-xs-5 text-left font" style="float: left"><b>工单类型:</b></p>
138
+ <p class="panel-title col-xs-7 text-left input-font" >{{ row.f_workorder_type }}</p>
139
+ </div>
140
+ <div class="col-xs-6">
141
+ <p class="panel-title col-xs-5 text-left font" style="float: left"><b>报修类型:</b></p>
142
+ <p class="panel-title col-xs-7 text-left input-font"><span :style="row.f_repairtype === '抢险维修'?'color:red;':''">{{ row.f_repairtype }}</span>
143
+ </p>
144
+ </div>
145
+ <div class="col-xs-12">
146
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>工单编号:</b></p>
147
+ <p class="panel-title col-xs-5 text-left input-font" style="width: 74%"><span :style="row.f_repairtype === '抢险维修'?'color:red;':''">{{ row.f_service_id }}</span>
148
+ </p>
149
+ </div>
150
+
151
+ <div class="col-xs-12">
152
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>派单时间:</b></p>
153
+ <p class="panel-title col-xs-7 text-left input-font" style="width: 79%">{{ row.f_created_date }}</p>
154
+ </div>
155
+ <div class="col-xs-12">
156
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>用户名称:</b></p>
157
+ <p class="panel-title col-xs-7 text-left input-font">{{ row.f_user_name }}
158
+ </p>
159
+ </div>
160
+ <div class="col-xs-12">
161
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>用户地址:</b></p>
162
+ <p class="panel-title col-xs-7 text-left input-font">{{ row.f_address }} &nbsp;&nbsp; {{row.f_contact_name}} </p>
163
+ </div>
164
+ <div class="col-xs-12">
165
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>来电电话:</b></p>
166
+ <p class="panel-title col-xs-7 text-left input-font">{{ row.f_phone || '无' }}
167
+ <img src="../../../assets/telphonesend.png" style="width: 12px;"
168
+ @click.stop.prevent='$parent.$parent.$parent.makeAPhoneCall(row.f_phone)'>
169
+ </p>
170
+ </div>
171
+ <div class="col-xs-12">
172
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>联系电话:</b></p>
173
+ <p class="panel-title col-xs-7 text-left input-font">{{ row.f_contact_phone || '无' }}
174
+ <img src="../../../assets/telphonesend.png" style="width: 12px;"
175
+ @click.stop.prevent='$parent.$parent.$parent.makeAPhoneCall(row.f_contact_phone)'>
176
+ </p>
177
+ </div>
178
+ <div class="col-xs-6">
179
+ <p class="panel-title col-xs-5 text-left font" style="float: left"><b>派单员:</b></p>
180
+ <p class="panel-title col-xs-7 text-left input-font">{{row.f_attendant}} </p>
181
+ </div>
182
+ <div class="col-xs-12">
183
+ <p class="panel-title col-xs-5 text-left font" style="float: left"><b>故障明细:</b></p>
184
+ <p class="panel-title col-xs-7 text-left input-font">{{$parent.$parent.$parent.getfailure(row.failure)}} </p>
185
+ </div>
186
+ <div class="col-xs-12" v-show="row.f_remarks">
187
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>工单备注:</b></p>
188
+ <p class="panel-title col-xs-7 text-left input-font">{{ row.f_remarks }}</p>
189
+ </div>
190
+ <div class="col-xs-12" v-show="row.f_back_remarks">
191
+ <p class="panel-title col-xs-5 text-left font" style="width: 21%;float: left"><b>退回原因:</b></p>
192
+ <p class="panel-title col-xs-7 text-left input-font">{{ row.f_back_remarks }}</p>
193
+ </div>
194
+ <div class="col-xs-12">
195
+ <button type="button" name="button" class="btn btn-primary" style="background-color:#499edf;float: right" @click="$parent.$parent.$parent.inspect(row)">接单</button>
196
+ </div>
197
+ </div>
198
+ </div>
199
+ </div>
200
+ </div>
201
+ </list>
202
+ </criteria-paged>
203
+ </div>
204
+
205
+ </template>
206
+
207
+ <script>
208
+ import Vue from 'vue'
209
+ import { PagedList,HttpResetClass } from 'vue-client'
210
+ import * as Util from '../../../components/Util'
211
+
212
+ export default {
213
+ title: '在线接单',
214
+ data() {
215
+ return {
216
+ model: new PagedList(`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/sql/phoneOperatorService`, 20, { userid: `"${Vue.user.name}"` }, null, false),
217
+ repairTypeOptions: [],
218
+ typeData: [],
219
+ showMessage: true
220
+ }
221
+ },
222
+ ready(){
223
+ this.$refs.paged.$refs.cri.search()
224
+ if (this.$appdata.getSingleValue('取消在线接单二次确定') === '是') {
225
+ this.showMessage = false
226
+ }
227
+ this.repairTypeOptions = this.$appdata.getParam('报修类型')
228
+ },
229
+
230
+ methods: {
231
+ // 获取现有的报修类型对应的数量
232
+ async initRepairTypeNum(val) {
233
+ const http = new HttpResetClass()
234
+ const res = await http.load('post',`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/sql/getOperatorServiceTypeNum`,{data: {condition: val.condition,userid:val.userid}},{resolveMsg: null, rejectMsg: null})
235
+ const typeData = []
236
+ for (let i = 0; i < this.repairTypeOptions.length; i++) {
237
+ let one = {
238
+ type: this.repairTypeOptions[i].label,
239
+ type_num: 0
240
+ }
241
+ for (const data of res.data) {
242
+ if (this.repairTypeOptions[i].label == data.type) {
243
+ one.type_num = data.type_num
244
+ } else {
245
+ continue
246
+ }
247
+ }
248
+ typeData.push(one)
249
+ }
250
+ this.typeData = typeData
251
+ },
252
+ getfailure(val){
253
+ if (val) {
254
+ var result = ''
255
+ // 把字符串转换成故障列表对象
256
+ var array = JSON.parse(val)
257
+ if(Array.isArray(array)) {
258
+ array.forEach((value) => {
259
+ result += value.f_failure_type + ':'
260
+ value.failurecase.forEach((failure) => {
261
+ result += failure + ' '
262
+ })
263
+ result += ';'
264
+ })
265
+ }
266
+ return result
267
+ }
268
+ },
269
+ search (args) {
270
+ let data = {}
271
+ data.condition = this.$refs.paged.$refs.cri.condition?this.$refs.paged.$refs.cri.condition:'1=1'
272
+ data.condition += " "+"and f_workorder_type like '%报修单%'";
273
+ data.condition += " "+`and f_filiale_id = '${Vue.user.orgid}'`;
274
+ data.userid = Vue.user.name
275
+ this.initRepairTypeNum(data)
276
+ return this.model.search(data, args.model)
277
+ },
278
+ inspect(row){
279
+ if (this.showMessage) {
280
+ this.$showMessage(`确定要接编号为${row.f_service_id}的单子吗?`, ['confirm', 'cancel']).then((isconfirm)=>{
281
+ //tag)
282
+ if (isconfirm === 'confirm') {
283
+ let userdata = Object.assign({}, userdata, row)
284
+ userdata.f_advice = '自我接单'
285
+ userdata.f_meet_date = Util.toStandardTimeString()
286
+ userdata.serviceacitivity = [] //Vue.user.name
287
+ userdata.serviceacitivity.push({f_reciever: Vue.user.name})
288
+ let data = ''
289
+ data = {
290
+ model: userdata,
291
+ f_handlingtype:'转维修员',
292
+ // loginUser: {name: '何文强', ename: 'hwq'}
293
+ loginUser: {name: Vue.user.name, ename: Vue.user.ename}
294
+ }
295
+ let HttpReset = new HttpResetClass()
296
+ HttpReset.load("POST",`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/logic/siteSend`,data).then((res)=>{
297
+ if (res.data.code==300){
298
+ this.$refs.paged.$refs.cri.search()
299
+ return this.$showMessage('没有抢到该单哦!')
300
+ }else {
301
+ this.$refs.paged.$refs.cri.search()
302
+ return this.$showMessage('接单成功!请及时处理。')
303
+ }
304
+ })
305
+ }
306
+ })
307
+ } else {
308
+ let userdata = Object.assign({}, userdata, row)
309
+ userdata.f_advice = '自我接单'
310
+ userdata.f_meet_date = Util.toStandardTimeString()
311
+ userdata.serviceacitivity = [] //Vue.user.name
312
+ userdata.serviceacitivity.push({f_reciever: Vue.user.name})
313
+ let data = ''
314
+ data = {
315
+ model: userdata,
316
+ // loginUser: {name: '何文强', ename: 'hwq'}
317
+ loginUser: {name: Vue.user.name, ename: Vue.user.ename}
318
+ }
319
+ let HttpReset = new HttpResetClass()
320
+ HttpReset.load("POST",`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/logic/siteSend`,data).then((res)=>{
321
+ if (res.data.code==300){
322
+ this.$refs.paged.$refs.cri.search()
323
+ return this.$showMessage('没有抢到该单哦!')
324
+ }else {
325
+ this.$refs.paged.$refs.cri.search()
326
+ return this.$showMessage('接单成功!请及时处理。')
327
+ }
328
+ })
329
+ }
330
+ },
331
+ makeAPhoneCall(phoneNumber) {
332
+ this.$androidUtil.makeAPhoneCall(phoneNumber)
333
+ }
334
+ }
335
+ }
336
+ </script>