telephone-clients 3.0.103 → 3.0.104-11

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.
Files changed (132) hide show
  1. package/package.json +3 -3
  2. package/src/App.vue +54 -56
  3. package/src/assets//345/210/240/351/231/244.png +0 -0
  4. package/src/components/Util/RightTreeSafe.vue +2 -2
  5. package/src/components/Util/RightTreeSafeDep.vue +350 -0
  6. package/src/components/android/AddMyTask.vue +7 -0
  7. package/src/components/guoxin/Console.vue +9 -0
  8. package/src/components/guoxin/VisitInfo.vue +0 -11
  9. package/src/components/pc/NewRepairPaper.vue +370 -370
  10. package/src/components/pc/RepairsWork.vue +23 -2
  11. package/src/components/pc/RoleSelectorDep.vue +158 -0
  12. package/src/components/pc/TelFindUser.vue +1 -1
  13. package/src/components/pc/TelListener.vue +47 -16
  14. package/src/components/pc/VisitInfo.vue +44 -17
  15. package/src/components/pc/WorkCenter.vue +1 -1
  16. package/src/components/pc/WorkCenterList.vue +1 -1
  17. package/src/components/pc/WorkHistory.vue +20 -2
  18. package/src/components/pc/WorkListAll.vue +1 -1
  19. package/src/components/pc/WorkListAllNew.vue +10 -3
  20. package/src/components/pc/WorkListNew.vue +9 -3
  21. package/src/components/pc/olddata/OldWorkList.vue +193 -0
  22. package/src/components/telreport/RepairsDetailsReport.vue +98 -0
  23. package/src/components/telreport/TableFaultReport.vue +96 -0
  24. package/src/components/telreport/Traffic.vue +3 -3
  25. package/src/components/telreport/TrafficClassificationReport.vue +134 -0
  26. package/src/components/temp/ChangemeterInfo.vue +75 -87
  27. package/src/components/temp/DeviceInfo.vue +80 -82
  28. package/src/components/temp/HandplanInfo.vue +14 -3
  29. package/src/components/temp/InfoTable.vue +5 -2
  30. package/src/components/temp/MetereadInfo.vue +1 -4
  31. package/src/components/temp/OldRepairList.vue +100 -0
  32. package/src/components/temp/RepairList.vue +2 -2
  33. package/src/components/weinan/Console.vue +1 -1
  34. package/src/components/weinan/RecordList.vue +2 -2
  35. package/src/components/weinan/SiteSend.vue +2 -2
  36. package/src/components/weinan/SiteSendWeixiu.vue +7 -16
  37. package/src/components/weinan/StandWorkWeixiu.vue +1 -1
  38. package/src/components/weinan/WorkList.vue +73 -0
  39. package/src/components/weinan/WorkListAll.vue +90 -14
  40. package/src/components/weinan/WorkListWeixiu.vue +1 -1
  41. package/src/components/workorder/CompletedRepair.vue +269 -183
  42. package/src/components/workorder/FaultAll.vue +826 -826
  43. package/src/components/workorder/PhoneStandWork.vue +354 -354
  44. package/src/components/workorder/PhoneUpDetail.vue +3 -0
  45. package/src/components/workorder/RepairDetails.vue +12 -2
  46. package/src/components/workorder/RepairFirstV.vue +1 -1
  47. package/src/components/workorder/RepairOrderV.vue +1446 -1446
  48. package/src/filiale/furuike/pc/ComplainWork.vue +348 -348
  49. package/src/filiale/furuike/pc/Seekwork.vue +352 -352
  50. package/src/filiale/gongyi/android/RepairOrderV.vue +1415 -1415
  51. package/src/filiale/hanzhong/telephone.js +1 -1
  52. package/src/filiale/kelai/android/AppTakePic.vue +143 -0
  53. package/src/filiale/kelai/android/PhoneVentilationLeave.vue +176 -0
  54. package/src/filiale/kelai/pc/WorkCenterList.vue +20 -3
  55. package/src/filiale/kelai/pc/WorkListAllNew.vue +47 -9
  56. package/src/filiale/kelai/pc/serviceDeleteOrder.vue +55 -0
  57. package/src/filiale/kelai/telephone.js +9 -8
  58. package/src/filiale/kelai/telephoneAndroid.js +3 -1
  59. package/src/filiale/liaoyuan/android/RepairOrderV.vue +831 -831
  60. package/src/filiale/qianneng/android/FaultAll.vue +883 -883
  61. package/src/filiale/qianneng/android/MaterIialOne.vue +123 -123
  62. package/src/filiale/qianneng/android/RepairOrderV.vue +874 -874
  63. package/src/filiale/qianneng/android/TemporarySingle.vue +25 -0
  64. package/src/filiale/qianneng/android/chargesList.vue +161 -161
  65. package/src/filiale/qianneng/pc/MaterialDetailed.vue +15 -3
  66. package/src/filiale/qianneng/pc/MaterialStatistics.vue +144 -0
  67. package/src/filiale/qianneng/pc/NewRepairPaper.vue +467 -467
  68. package/src/filiale/qianneng/pc/RepairsWork.vue +992 -982
  69. package/src/filiale/qianneng/pc/WorkHistory.vue +2 -2
  70. package/src/filiale/qianneng/pc/WorkListAllNew.vue +53 -5
  71. package/src/filiale/qianneng/pc/changetable.vue +273 -0
  72. package/src/filiale/qianneng/telephone.js +2 -0
  73. package/src/filiale/rizhao/pc/DispatchMan.vue +3 -3
  74. package/src/filiale/rizhao/pc/DispatchWork.vue +3 -3
  75. package/src/filiale/rizhao/pc/Traffic.vue +3 -3
  76. package/src/filiale/rizhao/pc/WorkListAllNew.vue +8 -3
  77. package/src/filiale/rizhao/telephone.js +1 -1
  78. package/src/filiale/rongcheng/CliWorkListAll.vue +442 -407
  79. package/src/filiale/rongcheng/FaultAll.vue +3 -3
  80. package/src/filiale/rongcheng/RepairOrderV.vue +1445 -0
  81. package/src/filiale/rongcheng/telephoneAndroid.js +3 -1
  82. package/src/filiale/shanxian/android/RepairFirstV.vue +5 -1
  83. package/src/filiale/shanxian/pc/RepairsWork.vue +826 -0
  84. package/src/filiale/shanxian/pc/WorkList.vue +1 -1
  85. package/src/filiale/shanxian/telephone.js +13 -12
  86. package/src/filiale/shexian/android/AddMyTask.vue +7 -0
  87. package/src/filiale/shexian/android/CompletedRepair.vue +280 -0
  88. package/src/filiale/shexian/android/FaultAll.vue +847 -0
  89. package/src/filiale/shexian/android/Outlay.vue +182 -165
  90. package/src/filiale/shexian/android/RepairFirstV.vue +16 -2
  91. package/src/filiale/shexian/android/RepairInfo.vue +1 -0
  92. package/src/filiale/shexian/pc/QueryVisitHistory.vue +237 -0
  93. package/src/filiale/shexian/pc/TelAgentVoiceReport.vue +271 -0
  94. package/src/filiale/shexian/pc/TelByOrderManCount.vue +10 -2
  95. package/src/filiale/shexian/pc/WorkList.vue +782 -740
  96. package/src/filiale/shexian/pc/WorkListAllNew.vue +75 -67
  97. package/src/filiale/shexian/telephone.js +21 -18
  98. package/src/filiale/shexian/telephoneAndroid.js +32 -26
  99. package/src/filiale/tongchuan/android/RepairDetails.vue +623 -0
  100. package/src/filiale/tongchuan/android/TicketDetails.vue +3 -0
  101. package/src/filiale/tongchuan/pc/UserWork.vue +805 -805
  102. package/src/filiale/tongchuan/pc/WorkOrderStatistics.vue +2 -2
  103. package/src/filiale/tongchuan/telephone.js +52 -52
  104. package/src/filiale/tongchuan/telephoneAndroid.js +23 -22
  105. package/src/filiale/wenxi/android/FailureShow.vue +61 -0
  106. package/src/filiale/wenxi/android/PhoneUpUserinfo.vue +1053 -0
  107. package/src/filiale/wenxi/android/RepairInfo.vue +158 -74
  108. package/src/filiale/wenxi/android/RepairOrderV.vue +805 -1419
  109. package/src/filiale/wenxi/android/RepairUserInfo.vue +532 -0
  110. package/src/filiale/wenxi/android/ZHihuanFirst.vue +502 -0
  111. package/src/filiale/wenxi/pc/DistributeWork.vue +107 -121
  112. package/src/filiale/wenxi/pc/FailureEdit.vue +1 -1
  113. package/src/filiale/wenxi/pc/GasWork.vue +747 -0
  114. package/src/filiale/wenxi/pc/MetereadInfo.vue +82 -0
  115. package/src/filiale/wenxi/pc/RepairsWork.vue +15 -0
  116. package/src/filiale/wenxi/pc/TelFindUser.vue +213 -116
  117. package/src/filiale/wenxi/pc/WorkListAll.vue +348 -297
  118. package/src/filiale/wenxi/telephone.js +4 -5
  119. package/src/filiale/wenxi/telephoneAndroid.js +4 -1
  120. package/src/filiale/wuan/android/RepairOrderV.vue +1384 -1384
  121. package/src/filiale/wuhai/telephone.js +1 -1
  122. package/src/filiale/yuncheng/pc/TelFindUser.vue +302 -0
  123. package/src/filiale/yuncheng/telephone.js +12 -0
  124. package/src/filiale/zhongsheng/android/FaultAll.vue +741 -0
  125. package/src/filiale/zhongsheng/android/RepairOrderV.vue +1430 -1430
  126. package/src/filiale/zhongsheng/android/RepairUserInfo.vue +241 -214
  127. package/src/filiale/zhongsheng/pc/RepairsWork.vue +775 -775
  128. package/src/filiale/zhongsheng/telephone.js +23 -23
  129. package/src/filiale/zhongsheng/telephoneAndroid.js +2 -1
  130. package/src/main.js +1 -1
  131. package/src/telephone.js +17 -1
  132. package/src/weinan.js +6 -0
@@ -0,0 +1,747 @@
1
+ <template xmlns:v-validate="http://www.w3.org/1999/xhtml">
2
+ <div class="auto select-overspread form-horizontal auto" id="pc-repair-work">
3
+ <validator name="v">
4
+ <div class="row">
5
+ <!-- <div class="col-sm-6 form-group form-fix-width">-->
6
+ <!-- <label class="font_normal_body" style="width: 30%">来电电话</label>-->
7
+ <!-- <input style="width: 60%" type="text" readonly v-model='model.f_phone' class="form-control"></input>-->
8
+ <!-- </div>-->
9
+ <!-- <div class="col-sm-6 form-group form-fix-width" >-->
10
+ <!-- <label style="width: 30%" class="font_normal_body" for="f_user_name" :class="model.f_user_name ? '': 'class-error' ">联系人</label>-->
11
+ <!-- <input style="width: 60%" type="text" v-model='model.f_user_name' id="f_user_name" name="f_user_name" class="form-control"/>-->
12
+ <!-- </div>-->
13
+ <div class="col-sm-6 form-group form-fix-width">
14
+ <label for="f_area" class="font_normal_body" style="width: 30%">用气性质</label>
15
+ <v-select :value.sync="model.f_gasproperties" :value-single="true"
16
+ :options='gastypes' placeholder='用气性质'
17
+ close-on-select>
18
+ </v-select>
19
+ </div>
20
+ <!-- <div class="col-sm-6 form-group form-fix-width">-->
21
+ <!-- <label style="width: 30%" class="font_normal_body " for="f_contact_phone" :class="model.f_contact_phone ? '' : 'class-error'">联系电话</label>-->
22
+ <!-- <input style="width: 60%" type="text" v-model='model.f_contact_phone' id="f_contact_phone" class="form-control"/>-->
23
+ <!-- </div>-->
24
+ <div class="col-sm-12 form-group form-fix-width">
25
+ <label style="width: 15%" for="f_address" class="font_normal_body">详细地址</label>
26
+ <input style="width: 65%" type="text" class="form-control" v-model="model.f_address" id="f_address"
27
+ placeholder="详细地址"
28
+ v-el:address v-next-el="idnumber"/>
29
+ </div>
30
+ <div class="col-sm-12 form-group form-fix-width">
31
+ <label style="width: 15%" for="f_address" class="font_normal_body">来电电话</label>
32
+ <input style="width: 65%" type="number" class="form-control" v-model="model.f_phone" id="f_phone"
33
+ placeholder="来电电话"
34
+ v-el:address v-next-el="idnumber"/>
35
+ </div>
36
+ </div>
37
+ <div class="row">
38
+ <div class="col-sm-6 form-group form-fix-width" v-if="selectSendshow && operType != '修改工单'">
39
+ <label class="font_normal_body" style="width: 30%">转接方式</label>
40
+ <div class="form-control">
41
+ <label v-for="handling1 in handling">
42
+ <input type="radio"
43
+ v-model="model.f_handlingtype"
44
+ value="{{handling1.label}}">
45
+ {{ handling1.label }}
46
+ </label>
47
+ </div>
48
+ </div>
49
+ <div class="col-sm-6 form-group form-fix-width">
50
+ <label class=" font_normal_body" style="width: 30%">派单类型</label>
51
+ <v-select :value.sync="model.f_handlingtype" :value-single="true"
52
+ :options='handling' placeholder='请选择派单类型'
53
+ close-on-select
54
+ ></v-select>
55
+ </div>
56
+ <div class="col-sm-6 form-group form-fix-width" v-if="meading == '转站点'">
57
+ <label class=" font_normal_body" style="width: 30%">选择站点</label>
58
+ <input type="text" v-show="false" v-model="serviceacitivity.f_reciever">
59
+ <right-tree islist :userid="userid" :source="source" v-on:re-res="reres" :textContent="选择站点" :selectData="">
60
+
61
+ </right-tree>
62
+ </div>
63
+ <div class="col-sm-6 form-group form-fix-width" :class="[$v.f_reciever.required ? 'select-error' : '']"
64
+ v-if="meading == '转维修员'">
65
+ <label class="font_normal_body" style="width: 30%">置换员</label>
66
+ <v-select :value="model.serviceacitivity[0].f_reciever" :value-single="true"
67
+ :options='repairers' placeholder='请选择置换员'
68
+ close-on-select v-on:change="repiarmancg"></v-select>
69
+ </div>
70
+ <div class="col-sm-6 form-group form-fix-width">
71
+ <label class=" font_normal_body" style="width: 30%">工单来源</label>
72
+ <v-select :value="model.f_source" :value-single="true"
73
+ :options='sources' placeholder='请选择工单来源'
74
+ close-on-select
75
+ v-on:change="sourcechange"></v-select>
76
+ </div>
77
+ <div class="col-sm-6 form-group form-fix-width">
78
+ <label class=" font_normal_body" style="width: 30%">预约时间</label>
79
+ <datepicker placeholder="请选择预约时间"
80
+ :value.sync="model.f_yuyue_date"
81
+ v-model="model.f_yuyue_date"
82
+ :format="'yyyy-MM-dd HH:mm:ss'"
83
+ style="width: 60%"></datepicker>
84
+ </div>
85
+ </div>
86
+ <div class="row">
87
+ <div class="col-sm-12 form-group form-fix-width">
88
+ <label class="font_normal_body" style="width: 15%">备注</label>
89
+ <textarea style="width: 80%" name="name" rows="2" class="ver-textarea" class="form-control"
90
+ v-model='model.f_remarks'></textarea>
91
+ </div>
92
+ </div>
93
+ <div class="row">
94
+ <button type="button" name="button" class="btn btn-difault" v-if="operType !== '报修'" @click="$emit('cancel')">
95
+ 取消
96
+ </button>
97
+ <button type="button" name="button" style="float: right" class="button_spacing button_search" @click="save">
98
+ 提交
99
+ </button>
100
+ </div>
101
+ </validator>
102
+ <modal v-if="addressshow" :show.sync="true" v-ref:modal backdrop="false" width="90%" height="90%">
103
+ <header slot="modal-header" class="modal-header">
104
+ <h4 class="modal-title">地址管理</h4>
105
+ </header>
106
+ <article slot="modal-body" class="modal-body">
107
+ <batch_orders @submit="rerefParent" @cancel="addressclose" :clear="rowsdata">
108
+
109
+ </batch_orders>
110
+ </article>
111
+ <footer slot="modal-footer" class="modal-footer">
112
+ <button type="button" name="button" style="float: right" class="button_spacing button_search"
113
+ @click="closeAddressModal">
114
+ 关闭
115
+ </button>
116
+ </footer>
117
+ </modal>
118
+ </div>
119
+ </template>
120
+
121
+ <script>
122
+ import {HttpResetClass} from 'vue-client'
123
+ import * as Util from '../../../components/Util'
124
+ // 获取派单类型, 类型 : 转站点,转维修员,自选模式
125
+ let getSendType = async function (self) {
126
+ try {
127
+ // 如果初始化为派维修员,则不获取配置文件
128
+ if (self.meading == '转维修员') {
129
+ self.model.f_handlingtype = '转维修员'
130
+ } else {
131
+ let http = new HttpResetClass()
132
+ let result = await http.load('GET', `rs/vue/sendType.json`, {}, {resolveMsg: null, rejectMsg: null})
133
+ //tag
134
+ if (result.data.sendType == '自选模式') {
135
+ self.selectSendshow = true
136
+ } else {
137
+ // 转站点/转维修员
138
+ if (result.data.sendType == '转维修员') {
139
+ self.model.f_handlingtype = '转维修员'
140
+ }
141
+ self.meading = result.data.sendType
142
+ }
143
+ }
144
+ } catch (e) {
145
+ //tag
146
+ } finally {
147
+ // 获取维修员
148
+ if (self.meading == '转维修员') {
149
+ self.repairers = []
150
+ self.getEmp()
151
+ }
152
+ self.model.f_user_type = "民用"
153
+ if (self.operType === '报修') {
154
+ // self.assignObj()
155
+ } else if (self.operType === '重新派单') {
156
+ // 通过当前登录人获取需要重新派发单子,也可对单子进行修改
157
+ self.setModifyOrder()
158
+ } else if (self.operType === '修改工单') {
159
+ // 通过传入数据,查询出工单,选择站点将不可点击
160
+ self.setModifyOrder()
161
+ }
162
+ }
163
+ }
164
+ // 工作类型对应的各项设置
165
+ const config = {
166
+ '报修': {
167
+ url: 'rs/logic/callerSendZH'
168
+ },
169
+ '重新派单': {
170
+ url: 'rs/logic/resend'
171
+ },
172
+ '修改工单': {
173
+ url: 'rs/logic/modifyOrder'
174
+ },
175
+ }
176
+
177
+ export default {
178
+ title: '置换通气单',
179
+ props: {
180
+ data: { // 用户基本信息
181
+ type: Object,
182
+ default: null
183
+ },
184
+ type: { // 类型,为区分复选框,当组件重用并切重用组件同时出现,复选框id相同时会有干扰,
185
+ type: String
186
+ },
187
+ callObj: { // 话务对象
188
+ type: Object,
189
+ default: null
190
+ },
191
+ loginUser: {
192
+ type: Object
193
+ },
194
+ modifyOrder: { // 修改工单传入得工单信息
195
+ type: Object
196
+ },
197
+ operType: { // 操作类型,有报修,重新派单,修改工单,其中修改时,选择站点将不可点击,重新派单和修改要先将工单查询出来
198
+ type: String,
199
+ default: '报修'
200
+ },
201
+ meading: {
202
+ type: String,
203
+ default: '转维修员'
204
+ }
205
+ },
206
+ data() {
207
+ return {
208
+ rowsdata: false, //
209
+ saveing: false,
210
+ selectSendshow: false,
211
+ // 维修员信息
212
+ repairers: [],
213
+ // 建档时表具信息
214
+ materdata: {
215
+ type: Object
216
+ },
217
+ mattershow: false,
218
+ // 小区编号
219
+ districtname_id: '',
220
+ servicesource: '话务来电', // 工单来源
221
+ addressshow: false,
222
+ addressselect: false,
223
+ phoneValid: false,
224
+ residential: [],
225
+ row: {
226
+ f_residential_area: ''
227
+ },
228
+ residentialquery: '',
229
+ areacondition: '',
230
+ testdata: {f_equipment: ''},
231
+ residentialTemplate: 'f_villagename',
232
+ unitTemplate: 'f_unitname',
233
+ model: {
234
+ // 一次派单
235
+ serviceacitivity: [{
236
+ f_service_acitivity_type: '派单'
237
+ }],
238
+ f_yuyue_date: '', // 预约时间
239
+ f_source: '话务来电',
240
+ f_service_id: '',
241
+ f_userinfo_id: '',
242
+ f_contact_phone: '',
243
+ f_meetunit: '',
244
+ f_phone: '',
245
+ f_user_name: '',
246
+ f_address: '',
247
+ f_repair_date: Util.getNowDate(),
248
+ f_card_id: '',
249
+ f_reciever: '',
250
+ f_remarks: '',
251
+ f_user_type: '民用',
252
+ f_gasproperties: '居民用气',
253
+ f_area: '',
254
+ f_unit_name: '',
255
+ f_street: '',
256
+ f_residential_area: '',
257
+ f_building: '',
258
+ f_handlingtype: '转维修员',
259
+ f_unit: '',
260
+ f_floor: '',
261
+ f_room: '',
262
+ aState: null,
263
+ f_addressid: '',
264
+ f_orgid: this.$login.f.orgid,
265
+ f_orgname: this.$login.f.orgs,
266
+ f_depname: this.$login.f.dops,
267
+ f_depid: this.$login.f.depids,
268
+ f_operator: this.$login.f.name,
269
+ f_operatorid: this.$login.f.id,
270
+ f_filiale: '',
271
+ f_filiale_id: '',
272
+ f_change_tag: ''
273
+ },
274
+ addressuser: [], // 存工单数据数组
275
+ types: [],
276
+ information: [], // 用来存放字表信息
277
+ serviceList: null, // 用来存放查询当前地址下的未完成工单
278
+ id: '', // 编写测试时会使用
279
+ f_service_id: '',
280
+ repairstypes: this.$appdata.getParam('报修类型'),
281
+ usertypes: this.$appdata.getParam('用户类型'),
282
+ gastypes: this.$appdata.getParam('用气性质'),
283
+ stands: this.$appdata.getParam('站点管理员'),
284
+ sources: this.$appdata.getParam('工单来源'),
285
+ handling: [{label: '转站点', value: '转站点'}, {label: '转置换员', value: '转维修员'}],
286
+ source:
287
+ 'dep=this.getParentByType($organization$).getSpecialResByType($department$),' +
288
+ 'tool.getFullTree(dep.where(row.hasSpecialRole($派单员$)))',
289
+ userid: this.$login.f.id,
290
+ }
291
+ },
292
+ ready() {
293
+ // 获取sendType.json配置信息 获取派单类型 转站点,转维修员,自选模式
294
+ getSendType(this)
295
+ },
296
+ methods: {
297
+ assignObj() {
298
+ if (this.data) {
299
+ this.model.f_address = this.data.f_address
300
+ this.model.f_user_name = this.data.f_user_name
301
+ this.model.f_meternumber = this.data.f_meternumber
302
+ this.model.f_user_type = this.data.f_user_type
303
+ this.model.f_contact_phone = this.data.f_user_phone
304
+ this.model.f_userinfo_id = this.data.f_userinfo_id
305
+ this.model.f_userinfo_code = this.data.f_userinfo_code
306
+ this.model.f_card_id = this.data.card_id
307
+ if (this.model.f_user_type === '民用') {
308
+ this.model.f_area = this.data.f_area
309
+ this.model.f_street = this.data.f_street
310
+ this.model.f_residential_area = this.data.f_residential_area
311
+ this.model.f_building = this.data.f_building
312
+ this.model.f_unit = this.data.f_unit
313
+ this.model.f_floor = this.data.f_floor
314
+ this.model.f_room = this.data.f_room
315
+ }
316
+ }
317
+ },
318
+ closeAddressModal() {
319
+ this.addressshow = false
320
+ },
321
+ // 当维修员发生改变,获取维修员手机号
322
+ repiarmancg(val) {
323
+ if (val) {
324
+ //tag
325
+ if (typeof val == 'string') {
326
+ this.model.serviceacitivity[0].f_reciever = val
327
+ let http1 = new HttpResetClass()
328
+ http1.load('POST', 'rs/sql/tel_singleTable_OrderBy', {
329
+ data: {
330
+ items: 'f_user_telephone',
331
+ tablename: 't_user',
332
+ condition: `name = '${val}'`,
333
+ orderitem: 'id'
334
+ }
335
+ }, {resolveMsg: null, rejectMsg: null}).then((ress) => {
336
+ this.model.f_repairman_phone = ress.data[0].f_user_telephone
337
+ })
338
+ }
339
+ }
340
+ },
341
+ // 当工单来源属性发生改变
342
+ sourcechange(val) {
343
+ if (val == undefined || val == '') {
344
+ return
345
+ }
346
+ this.model.f_source = val
347
+ this.servicesource = val
348
+ },
349
+ adressshow() {
350
+ this.addressshow = true
351
+ },
352
+ isshow() {
353
+ this.mattershow = true
354
+ },
355
+ // 获取维修员
356
+ getEmp() {
357
+ let val = {source: 'tool.getChildrenOfResName($置换员$)', userid: `${this.$login.f.id}`}
358
+ let http = new HttpResetClass()
359
+ http.load('POST', '/rs/search', {data: val}, {resolveMsg: null, rejectMsg: null}).then((res) => {
360
+ let result = res.data.filter(res => res.orgid == this.$login.f.orgid)
361
+ result.forEach((item) => {
362
+ this.repairers.push({label: `${item.name}`, value: item.name})
363
+
364
+ })
365
+ })
366
+ },
367
+ addressclose() {
368
+ this.addressuser = []
369
+ this.model.f_address = ''
370
+ this.model.f_addressid = ''
371
+ this.addressshow = false
372
+ },
373
+ // 控制地址管理组件显示与否
374
+ // 截取字符串
375
+ interceptString(val) {
376
+ },
377
+ // 选中地址
378
+ rerefParent(val) {
379
+ this.addressshow = false
380
+ this.addressuser = []
381
+ this.model.f_address = ''
382
+ this.model.f_addressid = ''
383
+ this.model.f_userinfo_id = ''
384
+ if (val.length > 0) {
385
+ //tag
386
+ this.model.f_address = val[0].name
387
+ this.model.f_addressid = val[0].id
388
+ this.model.f_userinfo_id = val[0].f_userinfo_id
389
+ val.forEach((item) => {
390
+ var address = {
391
+ f_address: item.name,
392
+ id: item.id,
393
+ f_userinfo_id: item.f_userinfo_id
394
+ }
395
+ this.addressuser.push(address)
396
+ })
397
+ }
398
+ },
399
+ // 选中部门
400
+ reres(val) {
401
+ if (val.res == undefined || val.res[0] == undefined || val.res[0] == '') {
402
+ return
403
+ }
404
+ this.model.serviceacitivity[0].f_meetunit = val.res[0]
405
+ this.model.f_meetunit = val.res[0]
406
+ this.model.f_filiale_id = val.orgobj[0].parentid
407
+ this.model.f_filiale = val.orgobj[0].parentname
408
+ this.model.f_outlets = val.res[0]
409
+ this.model.serviceacitivity[0].f_reciever = val.resids[0]
410
+ },
411
+ onReady() {
412
+ //tag
413
+ this.$emit('ready')
414
+ },
415
+ onError(error) {
416
+ //tag
417
+ this.$emit('error', error)
418
+ },
419
+ add(query) {
420
+ if (typeof (query) === 'string') {
421
+ this.model.f_residential_area = query
422
+ this.address()
423
+ }
424
+ },
425
+ // 修改或者重派工单时,加载工单的故障信息
426
+ projectCallback(item) {
427
+ if (item) {
428
+ return item.f_user_name
429
+ }
430
+
431
+ },
432
+ selectUnit(query) {
433
+ return this.$resetpost('rs/sql/tel_singleTable_OrderBy',
434
+ {
435
+ data: {
436
+ items: 'f_unitname',
437
+ tablename: 't_unitcoordinate',
438
+ condition: `(f_unitname like '${query}%' or F_TRANS_PINYIN_CAPITAL(f_unitname) like '${query}%')and rownum<10`,
439
+ orderitem: 'id'
440
+ }
441
+ }, {resolveMsg: null, rejectMsg: null}
442
+ )
443
+ },
444
+ selectResidential(query) {
445
+ return this.$resetpost('rs/sql/tel_singleTable_OrderBy',
446
+ {
447
+ data: {
448
+ items: 'f_villagename',
449
+ tablename: 't_villagecoordinate',
450
+ condition: `(f_villagename like '${query}%' or F_TRANS_PINYIN_CAPITAL(f_villagename) like '${query}%')and rownum<10`,
451
+ orderitem: 'id'
452
+ }
453
+ }, {resolveMsg: null, rejectMsg: null}
454
+ )
455
+ },
456
+ setModifyOrder() {
457
+ this.model = Object.assign({}, this.model, this.modifyOrder)
458
+ },
459
+ // 提交
460
+ getData(val) {
461
+ return this.residential
462
+ },
463
+
464
+ // 清理信息
465
+ cleardata(type) {
466
+ this.model = Object.assign({}, {
467
+ // 一次派单
468
+ serviceacitivity: [{
469
+ f_service_acitivity_type: '派单',
470
+ f_meetunit: this.model.serviceacitivity[0].f_meetunit,
471
+ f_reciever: this.model.serviceacitivity[0].f_reciever
472
+ }],
473
+ f_yuyue_date: '', // 预约时间
474
+ f_meetunit: this.model.f_meetunit,
475
+ f_outlets: this.model.f_outlets,
476
+ f_service_id: '',
477
+ f_contact_phone: '',
478
+ f_phone: '',
479
+ f_user_name: '',
480
+ f_userinfo_id: '',
481
+ failure: '',
482
+ f_address: '',
483
+ f_handlingtype: this.model.f_handlingtype,
484
+ f_repair_date: Util.getNowDate(),
485
+ f_card_id: '',
486
+ f_remarks: '',
487
+ f_user_type: '',
488
+ f_area: '',
489
+ f_street: '',
490
+ f_residential_area: '',
491
+ f_building: '',
492
+ f_unit: '',
493
+ f_floor: '',
494
+ f_room: '',
495
+ f_source: this.servicesource,
496
+ aState: null,
497
+ f_addressid: '',
498
+ f_orgid: this.$login.f.orgid,
499
+ f_orgname: this.$login.f.orgs,
500
+ f_depname: this.$login.f.dops,
501
+ f_depid: this.$login.f.depids,
502
+ f_operator: this.$login.f.name,
503
+ f_operatorid: this.$login.f.id,
504
+ f_filiale: this.model.f_filiale,
505
+ f_filiale_id: this.model.f_filiale_id
506
+ }),
507
+ this.modifyOrder = {}
508
+ this.addressuser = []
509
+ this.rowsdata = true
510
+ this.types = []
511
+ if (this.callObj && this.callObj.callNum && type != 'init') {
512
+ this.callObj.callNum = null
513
+ this.model.aState = null
514
+ }
515
+ },
516
+ async save() {
517
+ // 判断是否录入用气性质
518
+ if (this.model.f_gasproperties == '' || this.model.f_gasproperties == undefined) {
519
+ return this.$showAlert('请选择用气性质!', 'warning', 2000)
520
+ }
521
+ // 判断是否输入地址
522
+ if (this.model.f_address == '' || this.model.f_address == undefined) {
523
+ return this.$showAlert('请选择地址!', 'warning', 2000)
524
+ }
525
+ if (this.operType != '修改工单') {
526
+ if (this.model.serviceacitivity[0].f_reciever == '' || this.model.serviceacitivity[0].f_reciever == undefined) {
527
+ if (this.meading == '转维修员') {
528
+ return this.$showAlert('请选择置换人员', 'warning', 2000)
529
+ } else {
530
+ return this.$showAlert('请选择站点', 'warning', 2000)
531
+ }
532
+ }
533
+ }
534
+ this.model.f_user_type = '民用'
535
+ this.$emit('saveing')
536
+ if (this.meading == '转维修员') {
537
+ this.model.f_meetunit = this.$login.f.deps
538
+ this.model.f_orgid = this.$login.f.orgid
539
+ this.model.f_filiale = this.$login.f.org
540
+ this.model.f_outlets = this.$login.f.deps
541
+ this.model.f_filiale_id = this.$login.f.orgid
542
+ }
543
+ if (this.operType === '报修') {
544
+ this.model.f_change_tag = "散户派工"
545
+ let data = {
546
+ model: this.model, loginUser: {
547
+ name: this.loginUser.name,
548
+ ename: this.loginUser.ename
549
+ }, callObj: this.callObj
550
+ }
551
+ let url = ''
552
+ if (this.meading === '转站点') {
553
+ url = config[this.operType].url
554
+ } else {
555
+ url = config[this.operType].url
556
+ data.toRepair = '一级派单'
557
+ }
558
+ let http2 = new HttpResetClass()
559
+ let dataid = await http2.load('POST', url, data, {resolveMsg: null, rejectMsg: null})
560
+ //tag
561
+ var sendnum = 1
562
+ }
563
+ this.$emit('saveend')
564
+ this.$emit('commitsus', this.model.f_phone)
565
+ this.cleardata()
566
+ if (this.operType == '修改工单') {
567
+ this.$showMessage(`修改成功!`)
568
+ } else {
569
+ this.$showMessage(`本次下发 ${sendnum} 条置换单!`)
570
+ }
571
+ },
572
+ async checkServerList(addressid) {
573
+ if (addressid) {
574
+ let http1 = new HttpResetClass()
575
+ let res = await http1.load('POST', 'rs/sql/tel_getServiceActivity', {data: {condition: `f_addressid = '${addressid}'`}}, {
576
+ resolveMsg: null,
577
+ rejectMsg: null
578
+ })
579
+ //有未完成工单
580
+ let ls = res.data.length
581
+ var AddressService = {}
582
+ if (ls > 0) {
583
+ // 当前地址下还有工单未完成
584
+ AddressService = {
585
+ defname: res.data[0].defname,
586
+ f_service_id: res.data[0].f_service_id
587
+ }
588
+ } else {
589
+ AddressService = {
590
+ defname: '无工单'
591
+ }
592
+ }
593
+ return AddressService
594
+ }
595
+ },
596
+ // 处理故障输入
597
+ procFailure(value) {
598
+ this.model.failure = value
599
+ },
600
+ },
601
+ watch: {
602
+ // 转接类型
603
+ 'model.f_handlingtype'() {
604
+ // 清楚上次记录
605
+ this.model.serviceacitivity[0].f_reciever = ''
606
+ this.model.serviceacitivity[0].f_meetunit = ''
607
+ this.model.f_meetunit = ''
608
+ this.model.f_outlets = ''
609
+ this.model.f_repairman_phone = ''
610
+ if (this.model.f_handlingtype == '转维修员') {
611
+ this.meading = '转维修员'
612
+ this.repairers = []
613
+ this.getEmp()
614
+ } else {
615
+ this.repairers = []
616
+ this.meading = '转站点'
617
+ }
618
+ },
619
+ // 是否清空
620
+ 'cleantf'() {
621
+ this.cleardata()
622
+ },
623
+ 'model.f_contact_phone'(val) {
624
+ this.phoneValid = /^((0\d{2,3}-\d{7,8})|(1[3584]\d{9}))$/.test(this.model.f_contact_phone)
625
+ },
626
+ // 话务对象发生变化将来电电话赋值给f_phone
627
+ 'callObj.callNum'() {
628
+ this.cleardata('init')
629
+ this.model.f_phone = this.callObj.callNum
630
+ this.model.f_records_id = this.callObj.RecordsID
631
+ // this.model.f_contact_phone = this.callObj.callNum
632
+ this.model.f_repair_date = Util.getNowDate()
633
+ },
634
+ 'types.length'() {
635
+ var ev = new Event("resize", {"bubbles": true, "cancelable": false});
636
+ window.dispatchEvent(ev);
637
+ },
638
+ 'callObj.aState'() {
639
+ this.model.aState = this.callObj.aState
640
+ //tag
641
+ },
642
+ 'model.f_gasproperties'() {
643
+ if (this.model.f_gasproperties != '民用用气') {
644
+ this.model.f_user_type = '非民用'
645
+ } else {
646
+ this.model.f_user_type = '民用'
647
+ }
648
+ //tag
649
+ },
650
+ 'data'() {
651
+ this.assignObj()
652
+ },
653
+ },
654
+ computed: {
655
+ IsClickDisabled: function () {
656
+ if (this.$v.valid) {
657
+ if (this.model.aState === null) {
658
+ //tag
659
+ return false
660
+ }
661
+ if (this.model.f_phone && this.model.aState === '正在保存' && this.model.aState === '置忙') {
662
+ //tag
663
+ return false
664
+ }
665
+ if (!this.model.f_phone) {
666
+
667
+ //tag
668
+ return false
669
+ }
670
+ //tag
671
+ return true
672
+ } else {
673
+ //tag
674
+ return true
675
+ }
676
+ },
677
+ getTestData() {
678
+ return this.testdata
679
+ },
680
+ serviceacitivity() {
681
+ return this.model.serviceacitivity.find((row) => {
682
+ return row.f_service_acitivity_type === '派单'
683
+ })
684
+ },
685
+ alertObject() {
686
+ let result = this.model.failure.find((value) => {
687
+ return value.f_failure_type === '报警器'
688
+ })
689
+ if (result) {
690
+ return result
691
+ }
692
+ return {f_equipment: ''}
693
+ },
694
+ gasstove() {
695
+ let result = this.model.failure.find((value) => {
696
+ return value.f_failure_type === '燃气灶'
697
+ })
698
+ if (result) {
699
+ return result
700
+ }
701
+ return {f_equipment: ''}
702
+ },
703
+ furnace() {
704
+ let result = this.model.failure.find((value) => {
705
+ return value.f_failure_type === '壁挂炉'
706
+ })
707
+ if (result) {
708
+ return result
709
+ }
710
+ return {f_equipment: ''}
711
+ },
712
+ heater() {
713
+ let result = this.model.failure.find((value) => {
714
+ return value.f_failure_type === '热水器'
715
+ })
716
+ if (result) {
717
+ return result
718
+ }
719
+ return {f_equipment: ''}
720
+ },
721
+ lampblack() {
722
+ let result = this.model.failure.find((value) => {
723
+ return value.f_failure_type === '油烟机'
724
+ })
725
+ if (result) {
726
+ return result
727
+ }
728
+ return {f_equipment: ''}
729
+ }
730
+ },
731
+ events: {
732
+ getPosition(val) {
733
+ //tag
734
+ this.$dispatch('distribute', val)
735
+
736
+ }
737
+ },
738
+ components: {}
739
+ }
740
+
741
+ </script>
742
+ <style>
743
+ .class-error {
744
+ color: #a94442;
745
+ }
746
+
747
+ </style>