safecheck-client 3.0.34-1 → 3.0.34-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 (63) hide show
  1. package/package.json +1 -1
  2. package/src/components/android/AndroidDefectDeal.vue +634 -633
  3. package/src/components/android/AreaPlan.vue +1 -7
  4. package/src/components/android/ImgSelfAndroid.vue +181 -181
  5. package/src/components/android/PaperFeedback.vue +1 -1
  6. package/src/components/android/PaperFeedbackTemp.vue +1 -1
  7. package/src/components/android/SafecheckDevices.vue +2 -2
  8. package/src/components/android/SafecheckDevicesTemp.vue +1 -1
  9. package/src/components/android/userinfo/SafecheckUserInfo.vue +1 -1
  10. package/src/filiale/baiyin/android/AndroidDefectDeal.vue +633 -633
  11. package/src/filiale/baiyin/android.js +10 -10
  12. package/src/filiale/baiyin/pc/CheckPlanAreaList.vue +485 -485
  13. package/src/filiale/baiyin/pc/CheckSearchUser.vue +1067 -1067
  14. package/src/filiale/baiyin/pc/DefectListNew.vue +597 -597
  15. package/src/filiale/baiyin/pc/DefectMainNew.vue +63 -63
  16. package/src/filiale/baiyin/pc/DefectPaperNew.vue +1052 -1052
  17. package/src/filiale/baiyin/pc/PaperList.vue +790 -790
  18. package/src/filiale/baiyin/pc/PlanChooser.vue +167 -167
  19. package/src/filiale/baiyin/pc/PlanManage.vue +834 -834
  20. package/src/filiale/baiyin/pc/RightTreeSafe.vue +348 -348
  21. package/src/filiale/baiyin/pc/RoleSelector.vue +160 -160
  22. package/src/filiale/bayan/android/PaperFeedback.vue +1 -1
  23. package/src/filiale/bayan/android/SafecheckDevices.vue +1 -1
  24. package/src/filiale/bayan/android/SafecheckUserInfo.vue +1 -1
  25. package/src/filiale/dexin/android/SafecheckDevices.vue +1 -1
  26. package/src/filiale/hanzhong/android/PaperFeedback.vue +1 -1
  27. package/src/filiale/hanzhong/android/SafecheckDevices.vue +1 -1
  28. package/src/filiale/hanzhong/android/SafecheckUserInfo.vue +1 -1
  29. package/src/filiale/jiaxian/android/SafecheckDevices.vue +1298 -1298
  30. package/src/filiale/jiaxian/android.js +10 -10
  31. package/src/filiale/jiaxian/pc.js +12 -12
  32. package/src/filiale/jingyang/android/PaperFeedback.vue +1 -1
  33. package/src/filiale/jingyang/android/SafecheckUserInfo.vue +1 -1
  34. package/src/filiale/pingxiang/android/PaperFeedback.vue +1 -1
  35. package/src/filiale/qingjian/android/PhoneUpUserinfo.vue +1270 -1270
  36. package/src/filiale/qingjian/android/SafecheckDevices.vue +1 -1
  37. package/src/filiale/qingjian/android/SafecheckOrderV.vue +2844 -2844
  38. package/src/filiale/qingjian/android/SafecheckUserInfo.vue +1 -1
  39. package/src/filiale/shiquan/android/SafecheckDevices.vue +1 -1
  40. package/src/filiale/siyang/android/SafecheckUserInfo.vue +1 -1
  41. package/src/filiale/wuan/android/SafecheckOrderV.vue +4 -1
  42. package/src/filiale/wuan/android/SafecheckUserInfo.vue +6 -5
  43. package/src/filiale/yangchunboneng/android/CurrentCreate.vue +8 -11
  44. package/src/filiale/yangchunboneng/android/DailyworkloadQuery.vue +8 -13
  45. package/src/filiale/yangchunboneng/android/NewCheckpaperAndroid.vue +1362 -1362
  46. package/src/filiale/yangchunboneng/android/PaperFeedback.vue +1731 -1731
  47. package/src/filiale/yangchunboneng/android/PhoneUpUserinfo.vue +1235 -1235
  48. package/src/filiale/yangchunboneng/android/SafecheckDevices.vue +1332 -1332
  49. package/src/filiale/yangchunboneng/android/SafecheckOrderV.vue +2845 -2845
  50. package/src/filiale/yangchunboneng/android/SafecheckUserInfo.vue +887 -887
  51. package/src/filiale/yangchunboneng/android/safeHistoryLook.vue +8 -13
  52. package/src/filiale/yangchunboneng/pc/CheckBookUser.vue +4 -4
  53. package/src/filiale/yangchunboneng/pc/CheckSearchUser.vue +1192 -1192
  54. package/src/filiale/yangchunboneng/pc/DefectPaperNew.vue +54 -3
  55. package/src/filiale/yangchunboneng/pc/PaperDefectMain.vue +972 -944
  56. package/src/filiale/yangchunboneng/pc/PaperList.vue +29 -0
  57. package/src/filiale/yongzhou/android/PaperFeedback.vue +1 -1
  58. package/src/filiale/yongzhou/android/SafecheckDevices.vue +1 -1
  59. package/src/filiale/yongzhou/android/SafecheckUserInfo.vue +1 -1
  60. package/src/filiale/yunchengminsheng/android/PaperFeedback.vue +1 -1
  61. package/src/filiale/yunchengminsheng/android/SafecheckDevices.vue +1 -1
  62. package/src/filiale/yunchengminsheng/android/SafecheckUserInfo.vue +1 -1
  63. package/src/main.js +33 -33
@@ -1,1731 +1,1731 @@
1
- <template>
2
- <work-busy :is-busy="is_busy"></work-busy>
3
- <form novalidate class="form-horizontal" style="width: 95%;margin: auto">
4
- <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__">
5
- <div class="form-group col-md-12 col-sm-12 col-xs-12">
6
- <label class="control-label font text-left col-md-4 col-xs-4">备注</label>
7
- <div class="col-md-12 col-sm-12 col-xs-12">
8
- <textarea v-model="paper.f_repair_approved_note" class="form-control"></textarea>
9
- </div>
10
- </div>
11
- </div>
12
- <div class="form-group col-sm-12 col-xs-12 col-md-12 info" :class="style__">
13
- <div class="text-center">
14
- <label class="font">总体安检照片请依次拍摄:</label>
15
- </div>
16
- <div class="col-md-12 col-sm-12 col-xs-12">
17
- <ol class="showIi">
18
- <li>1.燃气设施全景</li>
19
- <li>2.燃气表照片</li>
20
- <li>3.灶具照片</li>
21
- <li>4.其他照片</li>
22
- </ol>
23
- </div>
24
- </div>
25
- <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
26
- <label class="text-left font">总体安检照片</label>
27
-
28
- <div class="auto" :class="style__">
29
- <div class="panel" style="padding: 10px 10px 5px 10px;">
30
- <div class="panel-body panel-self"
31
- style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
32
- <div class="row" style="height: 240px;overflow: scroll;top: 1px">
33
- <div class="col-xs-4 col-sm-3 col-md-2" style="margin-bottom: 35px"
34
- v-for="(index, img) in paper.f_overall_imgs">
35
- <img-self-android :src="img.f_overall_path" alt="总体安检照片" :width="140" :height="170"></img-self-android>
36
- <img src="../../../assets/删除.png" @click="delfile('f_overall_path', img.f_overall_path, index)"
37
- style="width: 15px;margin-top: -80px" alt="">
38
- </div>
39
- </div>
40
- <div class="row text-right div-photo">
41
- <button type="button" name="button" class="btn btn-photo"
42
- @click="takePic('f_overall_path', '总体安检照片')">拍照</button>
43
- <!--<button type="button" name="button" class="btn btn-primary btn-photo" @click="takePic('f_overall_path', '总体安检照片1')">拍照</button>-->
44
- <!--&nbsp;&nbsp;&nbsp;&nbsp;<img src="../../../assets/remove.png" :class="style__" @click="delfile('f_overall_path', img.f_overall_path)" style="width: 25%;"></img>-->
45
- </div>
46
- </div>
47
- </div>
48
- </div>
49
- </div>
50
- <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
51
- <label class="text-left font">总体隐患照片</label>
52
- <div class="auto" :class="style__">
53
- <div class="panel" style="padding: 10px 10px 5px 10px;">
54
- <div class="panel-body panel-self"
55
- style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
56
- <div class="row" style="height: 240px;overflow: scroll;top: 1px">
57
- <div class="col-xs-4 col-sm-3 col-md-2" style="margin-bottom: 35px" v-for="(index, img) in defectImgs">
58
- <img-self-android :src="img" alt="总体隐患照片" :width="140" :height="170"></img-self-android>
59
- <!-- <img src="../../assets/删除.png" @click="delfile('f_overall_path', img.f_overall_path,index)" style="width: 15px;margin-top: -80px" alt="">-->
60
- </div>
61
- </div>
62
- </div>
63
- </div>
64
- </div>
65
- </div>
66
- <div class="form-group col-sm-12 col-xs-12 col-md-12 info" :class="style__">
67
- <div class="text-center">
68
- <label class="font">隐患汇总:</label>
69
- </div>
70
- <div class="col-md-12 col-sm-12 col-xs-12">
71
- <ol class="showIi">
72
- <li v-for="item in defectReason">{{ item.deviceitem }}</li>
73
- </ol>
74
- </div>
75
- </div>
76
- <div class="form-group col-sm-12 col-xs-12 col-md-12 info" :class="style__">
77
- <div class="text-center">
78
- <label class="font">整改建议汇总:</label>
79
- </div>
80
- <div class="col-md-12 col-sm-12 col-xs-12">
81
- <ol class="showIi">
82
- <li v-for="item in defectToolTip">{{ item }}</li>
83
- </ol>
84
- </div>
85
- </div>
86
- <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
87
- <input type="checkbox" id="readInstructionsCheckbox" v-model="paper.f_read_instructions" />
88
- <label for="readInstructionsCheckbox" class="text-left font">我已阅读须知内容</label> </div>
89
- <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
90
- <label class="text-left font">用户签名</label>
91
- <div class="auto">
92
- <div class="panel">
93
- <div class="panel-body panel-self"
94
- style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
95
- <div class="row" style="height: 240px;overflow: scroll;top: 1px">
96
- <div class="col-sm-4">
97
- <img :class="style__" :src="paper.f_sign_path" :width="200" :height="150" />
98
- </div>
99
- </div>
100
- <div class="row text-right div-photo">
101
- <button type="button" name="button" class="btn btn-primary btn-photo" @click="sign">签名</button>
102
- </div>
103
- </div>
104
- </div>
105
- </div>
106
- </div>
107
- <div class="form-group col-sm-12 col-xs-12 col-md-12 " :style="timeSet(this.isneedDate) ? '' : 'display:none'">
108
- <label>请输入超期原因:</label><br />
109
- <textarea style="width: 100%;" v-model="paper.f_exceed_reason"></textarea>
110
- </div>
111
- <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__" v-show="showbacklist == '是'">
112
- <div class="col-xs-6 col-sm-6">
113
- <input type="checkbox" v-model="backlistisselect" :readonly="enabled" /><label
114
- class="text-left font">限制该用户购气</label>
115
- </div>
116
- <div class="col-xs-6 col-sm-6">
117
- <input type="checkbox" v-model="deletebacklistisselect" :readonly="deleteenabled" /><label
118
- class="text-left font">取消该用户购气</label>
119
- </div>
120
- </div>
121
- <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__"
122
- v-if="Vue.$appdata.getParam('安检天然气安全使用须知检查') == '是'">
123
- <div class="col-xs-12 col-sm-12">
124
- <input type="checkbox" v-model="paper.f_gas_guidelines" /><label class="text-left font">天然气安全使用须知</label>
125
- </div>
126
- <div class="col-xs-12 col-sm-12">
127
- <input type="checkbox" v-model="paper.f_safety_warning" /><label class="text-left font">天然气室内使用安全警示</label>
128
- </div>
129
- <div class="col-xs-12 col-sm-12">
130
- <input type="checkbox" v-model="paper.f_gas_manual" /><label class="text-left font">安全用气手册</label>
131
- </div>
132
- </div>
133
- <div class="row">
134
- <label for="readsafe" class="text-left font">蓝牙状态:{{blueState}}</label>
135
- <button type="button" @click="initBlueState()">重新连接</button>
136
- </div>
137
- <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__">
138
- <div class="form-group col-md-12 col-sm-12 col-xs-12">
139
- <input type="checkbox" id='readsafe' v-model="paper.f_defect_notified" class="showIi" />
140
- <label for="readsafe" class="text-left font">安检通知书/隐患整改通知书</label> </div>
141
- <div class="form-group col-md-12 col-sm-12 col-xs-12" v-if="paper.f_defect_notified">
142
- <div class="form-group col-md-12 col-sm-12 col-xs-12">
143
- <button type="button" @click="print()">打印隐患整改单</button>
144
- </div>
145
- <div class="form-group col-md-12 col-sm-12 col-xs-12">
146
- <label class="text-left font">安检通知书/隐患整改通知书照片(要求能清晰反应安检通知单和用户签字内容):</label>
147
- <div class="auto">
148
- <div class="panel" style="padding: 10px 10px 5px 10px;">
149
- <div class="panel-body panel-self"
150
- style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
151
- <div class="row" style="height: 240px;overflow: scroll;top: 1px">
152
- <div class="col-sm-4">
153
- <img-self-android :src="paper.f_notified_path" alt="安检通知书/隐患整改通知书照片" width="150" height="200"></img-self-android>
154
- </div>
155
- </div>
156
- <div class="row text-right div-photo">
157
- <button type="button" name="button" class="btn btn-primary btn-photo"
158
- @click="takePic('f_notified_path', '安检通知书/隐患整改通知书照片')">拍照</button>
159
- &nbsp;&nbsp;&nbsp;&nbsp;<img src="../../../assets/remove.png" :class="style__"
160
- @click="delfile('f_notified_path', this.paper.f_notified_path)" style="width: 25%;"></img>
161
- </div>
162
- </div>
163
- </div>
164
- </div>
165
- </div>
166
- </div>
167
- <div class="form-group col-md-12 col-sm-12 col-xs-12">
168
- <div class="row">
169
- <label class="text-left">请对我们的服务做出评价:</label>
170
- </div>
171
- <div class="col-xs-4 col-sm-4" v-for="item in radios">
172
- <input v-model="paper.f_client_evaluation" :value="item.label" :checked='item.isChecked'
173
- @click="check(item.value)" type="radio">{{ item.label }}
174
- </div>
175
-
176
- <!--<div class="col-sm-4">-->
177
- <!--<radio-group :value.sync="paper.f_client_evaluation" type="success" buttons="false">-->
178
- <!--<radio value="满意">满意</radio>-->
179
- <!--<radio value="基本满意">基本满意</radio>-->
180
- <!--<radio value="不满意">不满意</radio>-->
181
- <!--</radio-group>-->
182
- <!--</div>-->
183
- </div>
184
-
185
- <div class="form-group col-md-12 col-sm-12 col-xs-12" v-if="isRecodr == 'false'">
186
- <label class="text-left font">反馈录音:</label>
187
- <div class="col-md-12 col-sm-12 col-xs-12">
188
- <button type="button" name="button" class="btn btn-primary btn-voice" @click="record">
189
- <img src="../../../assets/录音.png" style="width: 14%;">
190
- <span v-if="!paper.f_recording1_path">开始录音</span>
191
- <span v-if="paper.f_recording1_path">已录音</span>
192
- </button>
193
- &nbsp;&nbsp;&nbsp;&nbsp;<img src="../../../assets/remove.png" style="width: 15px;" :class="style__"
194
- @click="delAudioFile('f_recording1_path', paper.f_recording1_path)"></img>
195
- </div>
196
- </div>
197
-
198
- <div v-if="false">
199
- <div class="text-center form-group col-md-12 col-sm-12 col-xs-12">
200
- <button style="width: 30%;margin:3%;margin-bottom: 0%" type="button"
201
- v-show="$parent.$parent.actionEnabled && upload_state != '已传' && (paper.f_complete != '已完成' || paper.back_f_entry_status != '入户')"
202
- class="btn save-btn" @click="$parent.$parent.save('temp')">临时保存</button>
203
- <button style="width: 30%;margin:3%;margin-bottom: 0%" type="button"
204
- v-show="$parent.$parent.actionEnabled && upload_state != '已传' && (paper.f_complete != '已完成' || paper.back_f_entry_status != '入户')"
205
- class="btn save-btn " @click="$parent.$parent.save('finish')">完成安检</button>
206
- </div>
207
- <div class="text-center form-group col-md-12 col-sm-12 col-xs-12">
208
- <button style="width: 30%;margin:3%;margin-bottom: 0%;margin-top: 0%" id="upload" type="button"
209
- v-show="$parent.$parent.actionEnabled && upload_state != '已传' && (paper.f_complete != '已完成' || paper.back_f_entry_status != '入户')"
210
- class="btn upload-btn " @click="$parent.$parent.uploadCheckPaper">上传</button>
211
- <button style="width: 30%;margin:3%;margin-bottom: 0%;margin-top: 0%"
212
- v-if="(safeCheckToRepair == true || safeCheckToRepair == 'true') && $parent.$parent.actionEnabled"
213
- class="btn repair-btn btn-warning " type="button" @click="showToRepair">转维修</button>
214
- </div>
215
- </div>
216
-
217
- </div>
218
- </form>
219
- <!-- <modal :show.sync="showCheckToRepair" v-ref:modal :backdrop="isback">-->
220
- <!-- <div slot="modal-header" class="modal-header">-->
221
- <!-- <h4 class="modal-title">-->
222
- <!-- 安检转维修-->
223
- <!-- </h4>-->
224
- <!-- </div>-->
225
- <!-- <div slot="modal-body" class="modal-body">-->
226
- <!-- <div v-if="showrepair">-->
227
- <!-- <div class="row">-->
228
- <!-- <label class="col-xs-4 col-md-4 control-label text-left">派单方式</label>-->
229
- <!-- <div class="col-xs-8 col-md-8">-->
230
- <!-- <label v-for="handling1 in handling" >-->
231
- <!-- <input type="radio"-->
232
- <!-- v-model="meading"-->
233
- <!-- value="{{handling1.label}}">-->
234
- <!-- {{handling1.label}}-->
235
- <!-- </label>-->
236
- <!-- </div>-->
237
- <!-- </div>-->
238
- <!-- <div class="row" v-if="meading == '转站点'">-->
239
- <!-- <label class="col-xs-4 col-md-4 control-label font text-left" for="f_reciever">站点</label>-->
240
- <!-- &lt;!&ndash;<input type="text" v-show="false" v-model="serviceacitivity.f_reciever"&ndash;&gt;-->
241
- <!-- &lt;!&ndash;v-validate:f_reciever='{ required: true }'>&ndash;&gt;-->
242
- <!-- <div class="col-xs-8 col-md-8">-->
243
- <!-- <right-tree @ready="onReady" islist :Url="Url" :userid="userid" :source="source" v-on:re-res="reres" :textContent="选择站点管理员" :selectData="" v-ref:f_reciever>-->
244
- <!-- </right-tree>-->
245
- <!-- </div>-->
246
- <!-- </div>-->
247
-
248
- <!-- <div class="row" style="margin-top: 6px" v-if="meading == '转维修员'">-->
249
- <!-- <label class="col-xs-4 col-md-4 control-label font text-left">维修人</label>-->
250
- <!-- <div class="col-xs-8">-->
251
- <!-- <v-select :value="$parent.$parent.model.serviceacitivity[0].f_reciever" :value-single="true"-->
252
- <!-- :options='f_repair_person' placeholder='请选择维修员'-->
253
- <!-- close-on-select v-on:change="repiarmancg"></v-select>-->
254
- <!-- </div>-->
255
-
256
- <!-- </div>-->
257
- <!-- <div class="row" style="margin-top: 6px">-->
258
- <!-- <label for="f_repair" class="col-xs-4 col-md-4 control-label font text-left">报修类型</label>-->
259
- <!-- <div class="col-xs-8 col-md-8">-->
260
- <!-- <v-select :value.sync="$parent.$parent.model.f_repairtype" :value-single="true"-->
261
- <!-- :options='repairstypes' placeholder='报修类型'-->
262
- <!-- close-on-select>-->
263
- <!-- </v-select>-->
264
- <!-- </div>-->
265
- <!-- </div>-->
266
-
267
- <!-- <div class="row" style="margin-top: 6px">-->
268
- <!-- <label class="control-label font text-left col-md-4 col-xs-4">备注</label>-->
269
- <!-- <div class="col-xs-8 col-md-8">-->
270
- <!-- <input type="text" v-model="$parent.$parent.model.f_remarks"/>-->
271
- <!-- </div>-->
272
-
273
- <!-- </div>-->
274
-
275
- <!-- </div>-->
276
- <!-- <div v-if="!showrepair">-->
277
- <!-- 暂无隐患设备信息-->
278
- <!-- </div>-->
279
- <!-- </div>-->
280
- <!-- <div slot="modal-footer" class="modal-footer">-->
281
- <!-- <button type="button" class="btn btn-default" @click="uploadPaper()">确定</button>-->
282
- <!-- <button type="button" class="btn btn-default" @click="undo()">取消</button>-->
283
- <!-- </div>-->
284
- <!-- </modal>-->
285
- <!--拉黑框-->
286
- <modal :show.sync="showmodel" v-ref:modal>
287
- <div slot="modal-header" class="modal-header">
288
- <h4 class="modal-title">
289
- 限制用户购气
290
- </h4>
291
- </div>
292
- <div slot="modal-body" class="modal-body">
293
- <!-- <div class="row" style="margin-top: 6px">-->
294
- <!-- <label style="color: red;">注:当前页面无法取消对用户的限制购气</label>-->
295
- <!-- </div>-->
296
- <div class="row" style="margin-top: 6px">
297
- <label class="col-xs-4 col-md-4 control-label font text-left">限制原因</label>
298
- <div class="col-xs-8 col-md-8">
299
- <v-select :value.sync="cause" :value-single="true" :options='causedatas' placeholder='限制原因' close-on-select>
300
- </v-select>
301
- </div>
302
- </div>
303
-
304
- <div class="row" style="margin-top: 6px">
305
- <label class="control-label font text-left col-md-4 col-xs-4">备注</label>
306
- <div class="col-xs-8 col-md-8">
307
- <input type="text" v-model="causeremarks" />
308
- </div>
309
-
310
- </div>
311
- <!-- <div class="row" style="margin-top: 6px">-->
312
- <!-- <textarea id="el_ca_tx" v-model.trim="cause" style="border-radius:4px;width: 100%;" placeholder="请输入限制用户购气原因" >-->
313
- <!-- </textarea>-->
314
- <!-- </div>-->
315
- </div>
316
- <div slot="modal-footer" class="modal-footer">
317
- <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="backlist()">确认</button>
318
- <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="cancel()">取消</button>
319
- </div>
320
- </modal>
321
-
322
- <modal :show.sync="showmodelthree" v-ref:modal>
323
- <div slot="modal-header" class="modal-header">
324
- <h4 class="modal-title">
325
- 取消限制用户购气
326
- </h4>
327
- </div>
328
- <div slot="modal-body" class="modal-body">
329
- <!-- <div class="row" style="margin-top: 6px">-->
330
- <!-- <label style="color: red;">注:当前页面无法取消对用户的限制购气</label>-->
331
- <!-- </div>-->
332
- <div class="row" style="margin-top: 6px">
333
- <label for="f_repair" class="col-xs-4 col-md-4 control-label font text-left">取消原因</label>
334
- <div class="col-xs-8 col-md-8">
335
- <v-select :value.sync="deletecause" :value-single="true" :options='delcausedatas' placeholder='取消原因'
336
- close-on-select>
337
- </v-select>
338
- </div>
339
- </div>
340
-
341
- <div class="row" style="margin-top: 6px">
342
- <label class="control-label font text-left col-md-4 col-xs-4">备注</label>
343
- <div class="col-xs-8 col-md-8">
344
- <input type="text" v-model="causeremarks" />
345
- </div>
346
-
347
- </div>
348
- <!-- <div class="row" style="margin-top: 6px">-->
349
- <!-- <textarea id="el_ca_txt" v-model.trim="deletecause" style="border-radius:4px;width: 100%;" placeholder="请输入取消限制用户购气原因" >-->
350
- <!-- </textarea>-->
351
- <!-- </div>-->
352
- </div>
353
- <div slot="modal-footer" class="modal-footer">
354
- <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="deletebacklist()">确认</button>
355
- <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="deletecancel()">取消</button>
356
- </div>
357
- </modal>
358
- <modal :show.sync="showgas" v-ref:modal>
359
- <div slot="modal-header" class="modal-header">
360
- <h4 class="modal-title">
361
- 用户须知
362
- </h4>
363
- </div>
364
- <div slot="modal-body" class="modal-body">
365
- <!-- <div class="row" style="margin-top: 6px">-->
366
- <!-- <label style="color: red;">注:当前页面无法取消对用户的限制购气</label>-->
367
- <!-- </div>-->
368
- <div class="row" style="margin-top: 6px">
369
- <sapn v-if="paper.f_check_type == '民用'">{{ gasinstructions ? gasinstructions : '请配置民用用户须知' }}</sapn>
370
- <sapn v-if="paper.f_check_type == '非民用'">{{ setgasinstructions ? setgasinstructions : '请配置非民用用户须知' }}</sapn>
371
- </div>
372
- </div>
373
- <div slot="modal-footer" class="modal-footer">
374
- <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="closeshowgas()">确认</button>
375
- </div>
376
- </modal>
377
- </template>
378
-
379
- <script>
380
- import Vue from 'vue'
381
- import * as Util from '../../Util'
382
- import { HttpResetClass } from 'vue-client'
383
- import RadioGroup from 'vue-client/src/vue-strap/src/radioGroup'
384
- import Radio from 'vue-client/src/vue-strap/src/radioBtn'
385
- import co from 'co'
386
-
387
- // let getRepairParam = function * (self){
388
- // let data = {
389
- // $parent.$parent.model: self.$parent.$parent.model, loginUser: {
390
- // name: self.role == 'view'?self.$login.f.name:Vue.user.name,
391
- // ename: self.role == 'view'?self.$login.f.ename:Vue.user.ename
392
- // }, user: self.user, callObj: self.callObj
393
- // }
394
- // if(self.$parent.$parent.meading == '转维修员'){
395
- // data.toRepair = '一级派单'
396
- // }
397
- // data.$parent.$parent.model.f_attendant = data.loginUser.name
398
- // ////tag
399
- // ////tag
400
- // let res
401
- // let errString = self.$parent. $parent.errorVerify()
402
- // if(errString){
403
- // ////tag
404
- // if (Vue.android)
405
- // self.undo()
406
- // this.$showMessage(errString)
407
- // return
408
- // } else {
409
- // if(self.role == 'inspect'){
410
- // if(self.$parent.$parent.meading == '转维修员' && (self.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || self.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)){
411
- // this.$showMessage("请选择维修员!")
412
- // return
413
- // }
414
- // if(self.$parent.$parent.meading == '转站点' && (self.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || self.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)){
415
- // HostApp.alert()
416
- // this.$showMessage("请选择站点!")
417
- // return
418
- // }
419
- // if(self.$parent.$parent.model.f_repairtype == ''){
420
- // this.$showMessage("请选择报修类型!")
421
- // return
422
- // }
423
- // ////tag)
424
- // let checkResult = '正常'
425
- // let options = [{"data": "已处理"},{"data": "未处理"}]
426
- // let value = ''
427
- // let codata = JSON.parse(JSON.stringify(self.paper))
428
- // for(let device in codata){
429
- // ////tag)
430
- // let f_device_type
431
- // if(device.startsWith("device")){
432
- // for(let item in codata[device]) {
433
- // if(codata[device].length > 1 ){
434
- // let j = Number.parseInt(item)+1
435
- // f_device_type = `${codata[device][item].f_device_type}${j}`
436
- // }else{
437
- // f_device_type = codata[device][item].f_device_type
438
- // }
439
- // // ////tag
440
- // let details = []
441
- // for(let i in codata[device][item].f_items){
442
- // let items = codata[device][item].f_items[i]
443
- // ////tag
444
- // if(items.f_is_defect == true || items.f_is_defect == 'true'){
445
- // checkResult = '有隐患'
446
- // ////tag
447
- // let res = yield self.$resetpost(`${self.Url}/rs/sql/getDeviceItem`,{data:{f_device_id:codata[device][item].f_device_id,f_item_name:items.f_item_name}})
448
- // ////tag)
449
- // self.$set('detail.f_defect_id', res.data[0].id)
450
- // self.$set('detail.f_project',`${items.f_item_name}:${items.f_item_value}`)
451
- // self.$set('detail.type',items.type)
452
- // self.$set('detail.options',options)
453
- // details.push(JSON.parse(JSON.stringify(self.detail)))
454
- // }
455
- // if(items.type == 'selector'){
456
- // items.selected = ''
457
- // }
458
- // self.detail = {}
459
- // }
460
- // ////tag
461
- // self.$set('defectDevice.f_type',f_device_type)
462
- // self.$set('defectDevice.details',details)
463
- // if(self.defectDevice.details.length >0 ){
464
- // self.repairitems.push(JSON.parse(JSON.stringify(self.defectDevice)))
465
- // }
466
- // self.defectDevice = {}
467
- // ////tag
468
- // }
469
- // }
470
- // }
471
- // self.$set('$parent.$parent.model.f_repairitems.data',self.repairitems)
472
- //
473
- //
474
- // ////tag)
475
- // res = self.$androidUtil.bzLogic('safecheckToRepair',data)
476
- // ////tag
477
- // ////tag
478
- // ////tag
479
- // if(res.code == 200){
480
- // self.$parent.$parent.isSafeCheckToRepair = true
481
- // self.undo()
482
- // self.$set('paper.f_SafeToRepair_id',res.data.f_service_id)
483
- // ////tag
484
- // self.$resetpost(`${self.Url}/rs/logic/updatePaperRepair`,{data:{f_paper_id:self.paper.f_paper_id,f_SafeToRepair_id:res.data.f_service_id}}).then((ret)=>{
485
- // ////tag
486
- // if(ret.data.code ==200){
487
- // ////tag
488
- // self.$parent.$parent.$back()
489
- // }else{
490
- // self.$showMessage('安检转维修失败!')
491
- // }
492
- // }).catch(v=>{
493
- // ////tag)
494
- // self.$showMessage('安检转维修失败!')
495
- // })
496
- // }else{
497
- // self.$showMessage('安检转维修失败!')
498
- // }
499
- // }
500
- // }
501
- // }
502
-
503
-
504
-
505
- // let getRepairs = async function(self,url) {
506
- // // 获取配置信息
507
- // try {
508
- // let val = {source: 'this.getParentByType($department$).getAllChildrens().where(row.getAttributes().get($rolestr$).indexOf($维修员$) != -1 ))', userid: `${Vue.user.id}`}
509
- // let repairs =[]
510
- // let res = await Vue.resetpost(`${url}/rs/search`,{data: val},{resolveMsg: null, rejectMsg: null})
511
- // res.data.forEach((item) => {
512
- // repairs.push({label: item.name, value: item})
513
- // })
514
- // self.f_repair_person = repairs
515
- // if(self.$parent.$parent.role == 'inspect'){
516
- // let res = self.$androidUtil.bzLogic('getUserInfo',{id:self.paper.f_userinfoid})
517
- // if(res.code == 200){
518
- // self.$parent.$parent.user = res.data[0]
519
- // self.$parent.$parent.model.f_area = self.$parent.$parent.user.f_area
520
- // }
521
- // }else{
522
- // ////tag
523
- // self.$resetpost(`${self.Url}/rs/sql/safeCheckgetUserInfo`,{data:{id:self.paper.f_userinfoid}},{resolveMsg: null, rejectMsg: null}).then((res)=>{
524
- // ////tag
525
- // if(res.data.length != 0){
526
- // self.$parent.$parent.user = res.data[0]
527
- // self.$parent.$parent.model.f_area = self.$parent.$parent.user.f_area
528
- // }
529
- // })
530
- // // path({alias:'getUserInfo',data:{id:this.paper.f_userinfoid}})
531
- // }
532
- // } catch (error) {
533
- // ////tag
534
- // }
535
- // }
536
-
537
- export default {
538
- title: '用户反馈',
539
- data() {
540
- return {
541
- blueState:'',
542
- is_busy:false,
543
- defectImgs: [],
544
- defectToolTip: [],
545
- defectReason: [],
546
- images: [],
547
- showmodelthree: false,
548
- isneedDate: this.$parent.$parent.isneedDate,
549
- plan: this.$parent.$parent.item,
550
- meading: this.$parent.$parent.meading,
551
- paper: this.$parent.$parent.data,
552
- printContent: [],
553
- upload_state: this.$parent.$parent.item.f_upload_state,
554
- enabled: false,//控制限制购气是否可选
555
- deleteenabled: false,
556
- showmodel: false,
557
- showbacklist: '是',
558
- backlistisselect: false,
559
- deletebacklistisselect: false,
560
- radios: [
561
- {
562
- label: '满意',
563
- value: 0,
564
- isChecked: false,
565
- },
566
- {
567
- label: '基本满意',
568
- value: 1,
569
- isChecked: false,
570
- },
571
- {
572
- label: '不满意',
573
- value: 2,
574
- isChecked: false,
575
- },
576
- ],
577
- repairitems: [],
578
- repairstypes: this.$appdata.getParam('报修类型'),
579
- causedatas: this.$appdata.getParam('安检限购原因'),
580
- delcausedatas: this.$appdata.getParam('安检取消限购原因'),
581
- causeremarks: '',
582
- // f_repair_person: this.readRepair(),
583
- showrepair: false,
584
- safeCheckToRepair: '',
585
- showCheckToRepair: false,
586
- userid: '',
587
- source:
588
- 'dep=this.getParentByType($organization$).getSpecialResByType($department$),' +
589
- 'tool.getFullTree(dep.where(row.hasSpecialRole($派单员$)))',
590
- isback: false,
591
- defectDevice: {},
592
- detail: {},
593
- callObj: null,
594
- user: {},
595
- role: this.$parent.$parent.role,
596
- handling: [{ label: '转站点', value: '转站点' }, { label: '转维修员', value: '转维修员' }],
597
- Url: this.$androidUtil.getProxyUrl(),
598
- cause: "",
599
- deletecause: "",
600
- isRecodr: "false", //单值参数,为true则是开启全程录音
601
- showgas: false,
602
- gasinstructions: '', // 民用用户须知
603
- setgasinstructions: '' // 非民用用户须知
604
- }
605
- },
606
- props: ['idx'],
607
- components: {
608
- RadioGroup,
609
- Radio
610
- },
611
- methods: {
612
- initBlueState(){
613
- let state = HostApp.getBluetoothState()
614
- if (state && state.state == 3){
615
- this.blueState = '连接完成'
616
- }else {
617
- if (state && state.state == -1){
618
- this.$showMessage('蓝牙连接未打开,打开后重新尝试')
619
- return
620
- }
621
- this.blueState = '连接失败,请重试'
622
- this.$androidUtil.print(JSON.stringify([{ type: 4, value: 2, unit: 'line' }]))
623
- let state2 = HostApp.getBluetoothState()
624
- if (state2 && state2.state == 3){
625
- this.blueState = '连接完成'
626
- }else {
627
- this.blueState = '连接失败,请重试'
628
- }
629
- }
630
- },
631
- timeSet(val) {
632
- //////tag
633
- if (!val) {
634
- return
635
- }
636
- let time = new Date(val).getTime()
637
- let time2 = new Date().getTime()
638
- if (time2 > time) {
639
- return true
640
- }
641
- },
642
- // async isoverDate(){
643
- // ////tag
644
- // let res= await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/rs/sql/androidGetuserinfo`, {data:{
645
- // condition:"f_plan_item_id='"+this.$parent.$parent.item.id+"'"
646
- // }
647
- // })
648
- // this.isneedDate=res.data[0]["f_subscribe_date"]
649
- // ////tag
650
- // },
651
- check(index) {
652
- ////tag
653
- // 先取消所有选中项
654
- for (let item of this.radios) {
655
- item.isChecked = false;
656
- }
657
- //再设置当前点击项选中
658
- this.paper.f_client_evaluation = this.radios[index].label;
659
- // 设置值,以供传递
660
- this.radios[index].isChecked = true;
661
- ////tag;
662
- },
663
- getSignValue(fileName) {
664
- this.f_signname = fileName
665
- },
666
- cameraCallBack(prop, fileName) {
667
- if (prop == 'f_overall_path') {
668
- let f_overall_path = fileName + '?' + Math.random()
669
- HostApp.__this__.paper.f_overall_imgs.push({
670
- f_overall_path: f_overall_path
671
- })
672
- } else {
673
- HostApp.__this__.paper[prop] = fileName + '?' + Math.random()
674
- }
675
- HostApp.__callback__ = null
676
- HostApp.__this__ = null
677
- },
678
- takePic(prop, title, index) {
679
- const obj = HostApp.getGpsDetailAddress()
680
- HostApp.__callback__ = this.cameraCallBack
681
- HostApp.__this__ = this
682
- ////tag
683
- ////tag
684
- let fileName
685
- if (prop == 'f_overall_path') {
686
- if (!this.paper.f_overall_imgs[index] || this.paper.f_overall_imgs[index].f_overall_path.includes("nopic.png")) {
687
- fileName = Util.guid() + '-' + prop + '.jpg'
688
- } else {
689
- fileName = Util.getFileName(this.paper.f_overall_imgs[index].f_overall_path)
690
- }
691
- } else {
692
- if (!this.paper[prop] || this.paper[prop].includes("nopic.png")) {
693
- fileName = Util.guid() + '-' + prop + '.jpg'
694
- } else {
695
- fileName = Util.getFileName(this.paper[prop])
696
- }
697
- }
698
- let jingweidu = ''
699
- if (this.$parent.$parent.is_has_jingweidu == 'true') {
700
- jingweidu = '\t经度:' + obj.longitude + '\t纬度:' + obj.latitude
701
- }
702
- HostApp._open_a_page({
703
- type: 'boomerang',
704
- page: 'com.aofeng.hybrid.android.peripheral.CameraActivity',
705
- param: {
706
- file: fileName,
707
- requestCode: 111,
708
- callback: 'javascript:HostApp.__callback__("' + prop + '", "%s");',
709
- watermark: title + '\t时间:' + Util.toStandardTimeString() + '\t' + Vue.user.name + '\t' + this.paper.f_userinfo_code + '\t' + this.paper.f_user_name + '\t' + this.paper.f_address
710
- + jingweidu
711
- }
712
- })
713
- },
714
- amrCallBack(fileName) {
715
- HostApp.__this__.$set('paper.f_recording1_path', fileName)
716
- HostApp.__callback__ = null
717
- HostApp.__this__ = null
718
- },
719
- record() {
720
- if (this.$parent.$parent.role != 'inspect') {
721
- if (this.paper.f_recording1_path != '') {
722
- window.location = this.paper.f_recording1_path
723
- }
724
- } else {
725
- HostApp.__callback__ = this.amrCallBack
726
- HostApp.__this__ = this
727
- let fileName
728
- if (!this.paper.f_recording1_path) {
729
- fileName = Util.guid() + '.amr'
730
- } else {
731
- fileName = Util.getFileName(this.paper.f_recording1_path)
732
- }
733
- HostApp._open_a_page({
734
- type: 'boomerang',
735
- page: 'com.aofeng.hybrid.android.peripheral.AudioClipActivity',
736
- param: { file: fileName, requestCode: 111, callback: 'javascript:HostApp.__callback__("%s");' }
737
- })
738
- }
739
- },
740
- // 签名回调
741
- signCallback(prop, fileName) {
742
- // HostApp.alert('绑定属性:' + prop + ' 文件全路径如file:///storage/sdcard0/safecheck/abc.jpg:' + fullFileName)
743
- HostApp.__this__.$set('paper.f_sign_path', fileName)
744
- HostApp.__callback__ = null
745
- HostApp.__this__ = null
746
- },
747
- // 用户签名
748
- sign() {
749
- if (!this.paper.f_read_instructions) {
750
- this.$showMessage('请先阅读并勾选用户须知内容后进行签名!')
751
- return
752
- }
753
- this.delAudioFile('f_sign_path', this.paper.f_sign_path)
754
- let prop = 'f_sign_path'
755
- let idx = 'aofeng'
756
- let fileName
757
- if (!this.paper.f_sign_path) {
758
- fileName = Util.guid() + '-valve-' + idx + '-' + prop + '.jpg'
759
- } else {
760
- fileName = Util.getFileName(this.paper.f_sign_path)
761
- }
762
- HostApp.__callback__ = this.signCallback
763
- HostApp.__this__ = this
764
- HostApp.getSignature({
765
- file: fileName,
766
- requestCode: 111,
767
- callback: 'javascript:HostApp.__callback__("' + prop + '", "%s");'
768
- })
769
- },
770
- delfile(prop, fileName, index) {
771
- if (fileName == Vue.nopic)
772
- return
773
- else {
774
- if (prop == 'f_overall_path') {
775
- this.paper.f_overall_imgs.splice(index, 1)
776
- HostApp.delfile(fileName)
777
- } else {
778
- HostApp.delfile(fileName)
779
- this.paper[prop] = Vue.nopic
780
- }
781
- }
782
- },
783
- delAudioFile(prop, fileName) {
784
- if (!fileName)
785
- return
786
- else {
787
- HostApp.delfile(fileName)
788
- this.paper[prop] = null
789
- }
790
- },
791
- //获取打印用户信息
792
- getUser() {
793
- this.printContent.push({
794
- type: 3,
795
- text: '客户信息',
796
- fontsize: 2,
797
- isbold: false,
798
- align: 'left'
799
- })
800
- if (this.paper.f_user_name == undefined)
801
- this.paper.f_user_name = ''
802
- this.printContent.push({
803
- type: 3,
804
- text: '客户姓名:' + this.paper.f_user_name,
805
- fontsize: 2,
806
- isbold: false,
807
- align: 'left'
808
- })
809
- if (this.paper.f_userinfo_code == undefined)
810
- this.paper.f_userinfo_code = ''
811
- this.printContent.push({
812
- type: 3,
813
- text: '客户编号:' + this.paper.f_userinfo_code,
814
- fontsize: 2,
815
- isbold: false,
816
- align: 'left'
817
- })
818
- if (this.paper.f_address == undefined)
819
- this.paper.f_address = ''
820
- this.printContent.push({ type: 3, text: '客户地址:' + this.paper.f_address, fontsize: 2, isbold: false, align: 'left' })
821
- if (this.paper.f_user_phone == undefined)
822
- this.paper.f_user_phone = ''
823
- this.printContent.push({
824
- type: 3,
825
- text: '客户电话:' + this.paper.f_user_phone,
826
- fontsize: 2,
827
- isbold: false,
828
- align: 'left'
829
- })
830
- this.printContent.push({ type: 3, text: '气表表号:' + (this.$parent.$parent.item.f_plan_meters[0].f_meter_no || ''), fontsize: 2, isbold: false, align: 'left' })
831
- this.printContent.push({ type: 3, text: '表具品牌:' + (this.$parent.$parent.item.f_plan_meters[0].f_aliasname || ''), fontsize: 2, isbold: false, align: 'left' })
832
- this.printContent.push({ type: 3, text: '表具类型:' + (this.$parent.$parent.item.f_plan_meters[0].f_meter_type || ''), fontsize: 2, isbold: false, align: 'left' })
833
- this.printContent.push({ type: 3, text: '表具规格:' + (this.$parent.$parent.item.f_plan_meters[0].f_diaphgram_size || ''), fontsize: 2, isbold: false, align: 'left' })
834
- this.printContent.push({ type: 3, text: '进气方向:' + (this.$parent.$parent.item.f_plan_meters[0].f_flow_direction || ''), fontsize: 2, isbold: false, align: 'left' })
835
- this.printContent.push({ type: 3, text: '安检时间:' + this.getNowFormatDate(), fontsize: 2, isbold: false, align: 'left' })
836
- },
837
- verify() {
838
- let hasError = this.$parent.$parent.verifyUser()
839
- if (hasError)
840
- return hasError
841
- hasError = this.$parent.$parent.verifyDevices()
842
- if (hasError)
843
- return hasError
844
- },
845
- print() {
846
- let state = HostApp.getBluetoothState()
847
- if (state && state.state == 3){
848
- this.blueState = '连接完成'
849
- }else {
850
- this.blueState = '连接失败,请重试'
851
- }
852
- if (state && state.state == -1){
853
- this.$showMessage('蓝牙未打开,请确认蓝牙是否打开')
854
- return
855
- }
856
- this.is_busy = true
857
- setTimeout(() => {
858
- this.is_busy = false
859
- }, 10000)
860
- let errString = this.verify()
861
- if (errString) {
862
- ////tag
863
- if (Vue.android)
864
- this.$showMessage(errString)
865
- return
866
- }
867
- // 文本
868
- let feedPageHead = { type: 4, value: 2, unit: 'line' }
869
- this.printContent.push({ type: 3, text: ' 阳春市博能燃气 ', fontsize: 3, isbold: true, align: 'center' })
870
- this.printContent.push({ type: 3, text: ' 用户燃气设施安全检查单 ', fontsize: 3, isbold: true, align: 'center' })
871
- this.printContent.push(feedPageHead)
872
- this.getUser()
873
- this.printContent.push({
874
- type: 3,
875
- text: '-------------------------------',
876
- fontsize: 3,
877
- isbold: false,
878
- align: 'center'
879
- })
880
- this.printContent.push({ type: 3, text: '安检执行', fontsize: 3, isbold: true, align: 'left' })
881
- this.printContent.push({ type: 3, text: this.defectReason.length > 0 ? '已安检有问题' : '已安检无问题', fontsize: 3, isbold: true, align: 'left' })
882
- this.printContent.push({
883
- type: 3,
884
- text: '-------------------------------',
885
- fontsize: 3,
886
- isbold: false,
887
- align: 'center'
888
- })
889
- this.printContent.push({ type: 3, text: '问题登记', fontsize: 3, isbold: true, align: 'left' })
890
- for (var i = 0; i < this.defectReason.length; i++) {
891
- this.printContent.push({ type: 3, text: (i + 1) + ':' + this.defectReason[i].deviceitem + ';', fontsize: 3, isbold: true, align: 'left' })
892
- }
893
- this.printContent.push({
894
- type: 3,
895
- text: '-------------------------------',
896
- fontsize: 3,
897
- isbold: false,
898
- align: 'center'
899
- })
900
-
901
- this.getTableData()
902
- this.printContent.push({
903
- type: 3,
904
- text: '-------------------------------',
905
- fontsize: 3,
906
- isbold: false,
907
- align: 'center'
908
- })
909
- this.printContent.push({ type: 3, text: '备注', fontsize: 3, isbold: true, align: 'left' })
910
- if (this.f_repair_approved_note) {
911
- this.printContent.push({ type: 3, text: this.f_repair_approved_note, fontsize: 3, isbold: true, align: 'left' })
912
- } else {
913
- this.printContent.push({ type: 4, value: 2, unit: 'line' })
914
- }
915
- this.printContent.push({
916
- type: 3,
917
- text: '-------------------------------',
918
- fontsize: 3,
919
- isbold: false,
920
- align: 'center'
921
- })
922
-
923
- this.printContent.push({ type: 3, text: '安全须知', fontsize: 3, isbold: true, align: 'left' })
924
- if (this.paper.f_check_type == '民用') {
925
- this.printContent.push({ type: 3, text: this.gasinstructions, fontsize: 3, isbold: true, align: 'left' })
926
- } else {
927
- this.printContent.push({ type: 3, text: this.setgasinstructions, fontsize: 3, isbold: true, align: 'left' })
928
- }
929
- this.getCheck()
930
- this.printContent.push({
931
- type: 3,
932
- text: '-------------------------------',
933
- fontsize: 3,
934
- isbold: false,
935
- align: 'center'
936
- })
937
- this.printContent.push({ type: 3, text: '表具读数:仅对安检时表其显示数据登记,最终数据以机械读数及收费系统数据核对为准!', fontsize: 3, isbold: true, align: 'left' })
938
- this.printContent.push({ type: 3, text: '博能燃气24小时服务电话:6168119', fontsize: 3, isbold: true, align: 'left' })
939
- this.printContent.push({ type: 4, value: 2, unit: 'line' })
940
- this.printContent.push({ type: 4, value: 2, unit: 'line' })
941
- let arrstr = JSON.stringify(this.printContent)
942
- console.log(arrstr);
943
- let temp = JSON.parse(arrstr)
944
- console.log(temp);
945
- ////tag
946
- const result = this.$androidUtil.print(arrstr)
947
- console.log(result);
948
- this.$set('printContent', [])
949
- this.is_busy = false
950
- },
951
- getTableData() {
952
- let codata = this.$parent.$parent.data
953
- for (let device in codata) {
954
- if (device.startsWith('device')) {
955
- if (codata[device].length > 0 && codata[device][0].f_device_type == '采集项') {
956
- this.printContent.push({ type: 3, text: '信息采集', fontsize: 3, isbold: true, align: 'left' })
957
- for (let i = 0; i < codata[device][0].f_items.length; i++) {
958
- switch (codata[device][0].f_items[i].f_item_name) {
959
- case '灶数量(台)': this.printContent.push({ type: 3, text: '灶数量(台):' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
960
- case '热水器数量(台)': this.printContent.push({ type: 3, text: '热水器数量(台):' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
961
- case '锅炉数量(台)': this.printContent.push({ type: 3, text: '锅炉数量(台):' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
962
- case '热水器安装位置': this.printContent.push({ type: 3, text: '热水器安装位置:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
963
- case '热水器类型': this.printContent.push({ type: 3, text: '热水器类型:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
964
- case '特殊信息': this.printContent.push({ type: 3, text: '特殊信息:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
965
- case '天然气燃具数量(台)': this.printContent.push({ type: 3, text: '天然气燃具数量:' + (codata[device][0].f_items[i].f_item_value.toString() || '') + '(台)', fontsize: 3, isbold: true, align: 'left' }); break;
966
- case '灶具品牌': this.printContent.push({ type: 3, text: '灶具品牌:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
967
- case '灶具品牌启用年': this.printContent.push({ type: 3, text: '灶具品牌启用年:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
968
- case '热水器品牌': this.printContent.push({ type: 3, text: '热水器品牌:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
969
- case '热水器启用年': this.printContent.push({ type: 3, text: '热水器启用年:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
970
- default: break;
971
- }
972
- }
973
- this.printContent.push({
974
- type: 3,
975
- text: '-------------------------------',
976
- fontsize: 3,
977
- isbold: false,
978
- align: 'center'
979
- })
980
- }
981
- if (codata[device].length > 0 && codata[device][0].f_device_type == '燃气表') {
982
- this.printContent.push({ type: 3, text: '表具读数', fontsize: 3, isbold: true, align: 'left' })
983
- for (let i = 0; i < codata[device][0].f_items.length; i++) {
984
- switch (codata[device][0].f_items[i].f_item_name) {
985
- case '已用金额': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '已用金额:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
986
- case '机械读数': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '机械读数:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
987
- case '电子读数': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '电子读数:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
988
- case '计量误差异常差值': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '偏差:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
989
- case '剩余气量': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '剩余气量:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
990
- case '剩余金额': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '剩余金额:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
991
- default: break;
992
- }
993
- }
994
- }
995
- }
996
- }
997
- },
998
- //打印安检信息
999
- getCheck() {
1000
- // let telephone = '96777'
1001
- // if (Vue.config.safecheck != undefined) {
1002
- // if (Vue.config.safecheck.ApproveConfig != undefined) {
1003
- // if (Vue.config.safecheck.ApproveConfig.checkphone != undefined) {
1004
- // telephone = Vue.config.safecheck.ApproveConfig.checkphone
1005
- // }
1006
- // }
1007
- // }
1008
- // this.printContent.push({
1009
- // type: 3,
1010
- // text: '-------------------------------',
1011
- // fontsize: 3,
1012
- // isbold: false,
1013
- // align: 'center'
1014
- // })
1015
- // this.printContent.push({type: 3, text: '咨询电话;' + telephone, fontsize: 2, isbold: false, align: 'left'})
1016
- // this.printContent.push({type: 3, text: '安检人:' + Vue.user.name, fontsize: 2, isbold: false, align: 'left'})
1017
- // this.printContent.push({
1018
- // type: 3,
1019
- // text: '安检时间:' + this.getNowFormatDate(),
1020
- // fontsize: 2,
1021
- // isbold: false,
1022
- // align: 'left'
1023
- // })
1024
- this.printContent.push({
1025
- type: 3,
1026
- text: '-------------------------------',
1027
- fontsize: 3,
1028
- isbold: false,
1029
- align: 'center'
1030
- })
1031
- let f_sign_path = this.paper.f_sign_path
1032
- this.printContent.push({ type: 3, text: '用户签字:', fontsize: 2, isbold: false, align: 'left' })
1033
- if(f_sign_path){
1034
- f_sign_path = f_sign_path.replace('http://newimg/','')
1035
- this.printContent.push({ type: 5, url: f_sign_path, align: 'left' })
1036
- }else{
1037
- this.printContent.push({ type: 4, value: 2, unit: 'line' })
1038
- }
1039
- },
1040
-
1041
- getDefect() {
1042
- let showmore = false
1043
- if (Vue.config.safecheck != undefined) {
1044
- if (Vue.config.safecheck.ApproveConfig != undefined) {
1045
- if (Vue.config.safecheck.ApproveConfig.showmore != undefined) {
1046
- showmore = Vue.config.safecheck.ApproveConfig.showmore
1047
- }
1048
- }
1049
- }
1050
-
1051
- let backData = this.$parent.$parent.getAllDefect()
1052
- // 对隐患信息进行遍历
1053
- let res = JSON.parse(backData.f_defect_content)
1054
- this.printContent.push({
1055
- type: 3,
1056
- text: '安检结果:' + res.result,
1057
- fontsize: 2,
1058
- isbold: false,
1059
- align: 'left'
1060
- })
1061
- this.printContent.push({
1062
- type: 3,
1063
- text: '-------------------------------',
1064
- fontsize: 3,
1065
- isbold: false,
1066
- align: 'center'
1067
- })
1068
-
1069
-
1070
- if (showmore) {
1071
- //全部打印
1072
- for (let dev in this.$parent.$parent.config) {
1073
- for (let device in backData) {
1074
- if (device.startsWith("device")) {
1075
- for (let item in backData[device]) {
1076
- //遍历结果
1077
- if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1078
- let error = true
1079
- for (let i in backData[device][item].f_items) {
1080
- if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1081
- error = false
1082
- }
1083
- }
1084
- if (error) {
1085
- this.printContent.push({
1086
- type: 3,
1087
- text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':正常',
1088
- fontsize: 2,
1089
- isbold: false,
1090
- align: 'left'
1091
- })
1092
- } else {
1093
- this.printContent.push({
1094
- type: 3,
1095
- text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':有隐患',
1096
- fontsize: 2,
1097
- isbold: true,
1098
- align: 'left'
1099
- })
1100
- }
1101
-
1102
- for (let i in backData[device][item].f_items) {
1103
- if (backData[device][item].f_items[i].f_item_value != '' && backData[device][item].f_items[i].f_item_value != null) {
1104
- this.printContent.push({
1105
- type: 3,
1106
- text: backData[device][item].f_items[i].f_item_name + backData[device][item].f_items[i].f_item_value,
1107
- fontsize: 2,
1108
- isbold: false,
1109
- align: 'left'
1110
- })
1111
- }
1112
- }
1113
- this.printContent.push({ type: 4, value: 2, unit: 'line' })
1114
- }
1115
- }
1116
- }
1117
- }
1118
- }
1119
-
1120
- for (let dev in this.$parent.$parent.config) {
1121
- for (let device in backData) {
1122
- if (device.startsWith("device")) {
1123
- for (let item in backData[device]) {
1124
- //遍历结果
1125
- if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1126
- let error = true
1127
- for (let i in backData[device][item].f_items) {
1128
- if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1129
- error = false
1130
- }
1131
- }
1132
- if (!error) {
1133
- this.printContent.push({
1134
- type: 3,
1135
- text: '隐患:',
1136
- fontsize: 2,
1137
- isbold: true,
1138
- align: 'left'
1139
- })
1140
- }
1141
- }
1142
- }
1143
- }
1144
- }
1145
- for (let device in backData) {
1146
- if (device.startsWith("device")) {
1147
- for (let item in backData[device]) {
1148
- if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1149
- for (let i in backData[device][item].f_items) {
1150
- if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1151
- this.printContent.push({
1152
- type: 3,
1153
- text: backData[device][item].f_items[i].f_item_name + ' ' + backData[device][item].f_items[i].f_item_value,
1154
- fontsize: 2,
1155
- isbold: true,
1156
- align: 'left'
1157
- })
1158
- }
1159
- }
1160
- }
1161
- }
1162
- }
1163
- }
1164
-
1165
- }
1166
- } else {
1167
- for (let dev in this.$parent.$parent.config) {
1168
- for (let device in backData) {
1169
- if (device.startsWith("device")) {
1170
- for (let item in backData[device]) {
1171
- //遍历结果
1172
- if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1173
- let error = true
1174
- for (let i in backData[device][item].f_items) {
1175
- if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1176
- error = false
1177
- }
1178
- }
1179
- if (error) {
1180
- this.printContent.push({
1181
- type: 3,
1182
- text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':正常',
1183
- fontsize: 2,
1184
- isbold: false,
1185
- align: 'left'
1186
- })
1187
- } else {
1188
- this.printContent.push({
1189
- type: 3,
1190
- text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':有隐患',
1191
- fontsize: 2,
1192
- isbold: false,
1193
- align: 'left'
1194
- })
1195
- }
1196
-
1197
- for (let i in backData[device][item].f_items) {
1198
- if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1199
- this.printContent.push({
1200
- type: 3,
1201
- text: '隐患:' + backData[device][item].f_items[i].f_item_name + backData[device][item].f_items[i].f_item_value,
1202
- fontsize: 2,
1203
- isbold: false,
1204
- align: 'left'
1205
- })
1206
- }
1207
- }
1208
- this.printContent.push({ type: 4, value: 2, unit: 'line' })
1209
- }
1210
- }
1211
- }
1212
- }
1213
- }
1214
- }
1215
- },
1216
- //获取当前时间
1217
- getNowFormatDate() {
1218
- var date = new Date();
1219
- var seperator1 = "-";
1220
- var seperator2 = ":";
1221
- var month = date.getMonth() + 1;
1222
- var strDate = date.getDate();
1223
- if (month >= 1 && month <= 9) {
1224
- month = "0" + month;
1225
- }
1226
- if (strDate >= 0 && strDate <= 9) {
1227
- strDate = "0" + strDate;
1228
- }
1229
- var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
1230
- + " " + date.getHours() + seperator2 + date.getMinutes()
1231
- + seperator2 + date.getSeconds();
1232
- return currentdate;
1233
- },
1234
- readRepair() {
1235
- let url = this.$androidUtil.getProxyUrl()
1236
- let gen = getRepairs(this, url)
1237
- return co(gen)
1238
- },
1239
- showToRepair() {
1240
- let res = this.hasDefect()
1241
- ////tag
1242
- ////tag
1243
- if (res == '正常') {
1244
- this.showrepair = false
1245
- } else {
1246
- this.showrepair = true
1247
- this.assignObj()
1248
- }
1249
- this.showCheckToRepair = !this.showCheckToRepair
1250
- },
1251
- // 选中部门
1252
- reres(val) {
1253
- if (val.res == undefined) {
1254
- return
1255
- }
1256
- this.$parent.$parent.model.serviceacitivity[0].f_meetunit = val.res
1257
- this.$parent.$parent.model.f_meetunit = val.res
1258
- this.$parent.$parent.model.f_orgstr = val.resids
1259
- var arr = val.res.split('.')
1260
- this.$parent.$parent.model.f_outlets = arr[arr.length - 1]
1261
- this.$parent.$parent.model.serviceacitivity[0].f_reciever = val.resids
1262
- },
1263
- assignObj() {
1264
- this.$parent.$parent.model.f_contact_phone = this.paper.f_user_phone
1265
- this.$parent.$parent.model.f_user_name = this.paper.f_user_name
1266
- this.$parent.$parent.model.f_address = this.paper.f_address
1267
- this.$parent.$parent.model.f_user_type = this.paper.f_check_type
1268
- this.$parent.$parent.model.f_street = this.paper.f_street
1269
- this.$parent.$parent.model.f_residential_area = this.paper.f_residential_area
1270
- this.$parent.$parent.model.f_building = this.paper.f_building
1271
- this.$parent.$parent.model.f_unit = this.paper.f_unit
1272
- this.$parent.$parent.model.f_floor = this.paper.f_floor
1273
- this.$parent.$parent.model.f_room = this.paper.f_room
1274
- this.$parent.$parent.model.f_floor = this.paper.f_floor
1275
- this.$parent.$parent.model.f_userinfo_id = this.paper.f_userinfoid
1276
- this.$parent.$parent.model.f_userinfo_code = this.paper.f_userinfo_code
1277
- },
1278
- hasDefect() {
1279
- let checkResult = '正常'
1280
- let codata = JSON.parse(JSON.stringify(this.paper))
1281
- for (let device in this.paper) {
1282
- if (device.startsWith("device")) {
1283
- for (let item in this.paper[device]) {
1284
- for (let i in this.paper[device][item].f_items) {
1285
- let items = this.paper[device][item].f_items[i]
1286
- ////tag
1287
- if (items.f_is_defect == true || items.f_is_defect == 'true') {
1288
- checkResult = '有隐患'
1289
- }
1290
- }
1291
- }
1292
- }
1293
- }
1294
- return checkResult
1295
- },
1296
- uploadPaper() {
1297
- if (this.showrepair) {
1298
- ////tag
1299
- ////tag
1300
- ////tag
1301
- ////tag
1302
-
1303
- if (this.meading == '转维修员' && (this.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || this.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)) {
1304
- this.$showMessage("请选择维修员!")
1305
- return
1306
- }
1307
- if (this.$parent.$parent.meading == '转站点' && (this.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || this.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)) {
1308
- this.$showMessage("请选择站点!")
1309
- return
1310
- }
1311
- if (this.$parent.$parent.model.f_repairtype == '') {
1312
- this.$showMessage("请选择报修类型!")
1313
- return
1314
- }
1315
- this.$parent.$parent.isToRepair = true
1316
- this.$parent.$parent.uploadCheckPaper()
1317
- // this.$parent.$parent.savePaper(false).then((res) => {
1318
- // ////tag
1319
- // if(res != true){
1320
- // ////tag
1321
- // return
1322
- // }else{
1323
- // this.$parent.$parent.todo()
1324
- // }
1325
- // })
1326
- } else {
1327
- this.$parent.$parent.undo()
1328
- }
1329
-
1330
- },
1331
- //确认安检转维修
1332
-
1333
- undo() {
1334
- this.showCheckToRepair = !this.showCheckToRepair
1335
- this.$parent.$parent.model.serviceacitivity[0].f_reciever = ''
1336
- this.$parent.$parent.model.serviceacitivity[0].f_meetunit = ''
1337
- this.$parent.$parent.model.f_repairtype = ''
1338
- this.meading = '转站点'
1339
- },
1340
- //取消拉黑
1341
- async deletebacklist() {
1342
- if (!this.deletecause) {
1343
- this.$showMessage("请填写取消拉黑原因!")
1344
- return
1345
- }
1346
- this.paper.f_blocking_cause = this.deletecause
1347
- ////tag)
1348
- let http = new HttpResetClass()
1349
- ////tag
1350
- let res1 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1351
- data: {
1352
- items: "version",
1353
- tablename: "t_userinfo",
1354
- condition: "f_userinfo_id=" + this.paper.f_userinfoid,
1355
- orderitem: "f_userinfo_id"
1356
- }
1357
- }, { resolveMsg: null, rejectMsg: null })
1358
- ////tag)
1359
- ////tag
1360
- let res2 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/backlistOperate`, {
1361
- data: {
1362
- "f_operat_type": "取消拉黑",
1363
- "f_state": "待审核",
1364
- "f_black_state": "待审核",
1365
- "f_remark": this.causeremarks,
1366
- "f_user_name": this.paper.f_user_name,
1367
- "f_comments": this.paper.f_delete_cause,
1368
- "f_operator": Vue.user.name,
1369
- "f_operatorid": Vue.user.id,
1370
- "f_orgid": Vue.user.orgid,
1371
- "f_orgname": Vue.user.orgs,
1372
- "f_depid": Vue.user.depids,
1373
- "f_depname": Vue.user.deps,
1374
- "f_describe": `${Vue.user.name}对用户${this.paper.f_user_name}进行取消拉黑`,
1375
- "f_userinfo_id": {
1376
- "f_userinfo_id": this.paper.f_userinfoid,
1377
- "f_user_state": "正常",
1378
- "version": res1.data[0].version
1379
- },
1380
- "f_limit_times": "",
1381
- "f_limit_value": ""
1382
- }
1383
- }, { resolveMsg: null, rejectMsg: null })
1384
-
1385
- ////tag)
1386
- if (res2.data.code == 200) {
1387
- this.showmodelthree = false
1388
- this.deleteenabled = true
1389
- this.paper.f_blacklist = "否"
1390
- this.causeremarks = ''
1391
- this.$showMessage("取消该用户限制购气成功!")
1392
- } else {
1393
- this.$showMessage("网络异常,请稍后再试!")
1394
- }
1395
- },
1396
- async backlist() {
1397
- if (!this.cause) {
1398
- this.$showMessage("请填写拉黑原因!")
1399
- return
1400
- }
1401
- this.paper.f_blocking_cause = this.cause
1402
- ////tag)
1403
- let http = new HttpResetClass()
1404
- ////tag
1405
- let res1 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1406
- data: {
1407
- items: "version",
1408
- tablename: "t_userinfo",
1409
- condition: "f_userinfo_id=" + this.paper.f_userinfoid,
1410
- orderitem: "f_userinfo_id"
1411
- }
1412
- }, { resolveMsg: null, rejectMsg: null })
1413
- ////tag)
1414
- ////tag
1415
- let limit_times = 1
1416
- let limit_value = 3
1417
- if (Vue.config.safecheck && Vue.config.safecheck.ApproveConfig.limit_times && Vue.config.safecheck.ApproveConfig.limit_value) {
1418
- limit_times = Vue.config.safecheck.ApproveConfig.limit_times
1419
- limit_value = Vue.config.safecheck.ApproveConfig.limit_value
1420
- }
1421
- let res2 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/backlistOperate`, {
1422
- data: {
1423
- data: this.$parent.$parent.data,
1424
- item: this.$parent.$parent.data.item,
1425
- "f_operat_type": "拉黑",
1426
- "f_state": "待审核",
1427
- "f_black_state": "待审核",
1428
- "f_user_name": this.paper.f_user_name,
1429
- "f_comments": this.paper.f_blocking_cause,
1430
- "f_remark": this.causeremarks,
1431
- "f_operator": Vue.user.name,
1432
- "f_operate_date": Util.toStandardTimeString(),
1433
- "f_operatorid": Vue.user.id,
1434
- "f_orgid": Vue.user.orgid,
1435
- "f_orgname": Vue.user.orgs,
1436
- "f_depid": Vue.user.depids,
1437
- "f_depname": Vue.user.deps,
1438
- "f_describe": `${Vue.user.name}对用户${this.paper.f_user_name}进行拉黑`,
1439
- "f_userinfo_id": {
1440
- "f_userinfo_id": this.paper.f_userinfoid
1441
- },
1442
- "f_limit_times": limit_times,
1443
- "f_limit_value": limit_value
1444
- }
1445
- }, { resolveMsg: null, rejectMsg: null })
1446
-
1447
- ////tag)
1448
- if (res2.data.code == 200) {
1449
- this.showmodel = false
1450
- this.enabled = true
1451
- this.paper.f_blacklist = "是"
1452
- this.$showMessage("将该用户限制购气成功!")
1453
- } else if (res2.data.msg == '数据增加重复') {
1454
- this.showmodel = false
1455
- this.enabled = true
1456
- this.$showMessage("该用户已被限制购气,请勿重复提交!")
1457
- } else {
1458
- this.$showMessage("网络异常,请稍后再试!")
1459
- }
1460
- },
1461
- cancel() {
1462
- this.backlistisselect = false
1463
- this.showmodel = false
1464
- },
1465
- deletecancel() {
1466
- this.deletebacklistisselect = false
1467
- this.showmodelthree = false
1468
- },
1469
- closeshowgas() {
1470
- this.showgas = false
1471
- },
1472
- repiarmancg(val) {
1473
- if (val) {
1474
- ////tag
1475
- this.$parent.$parent.model.serviceacitivity[0].f_reciever = val.name
1476
- let http1 = new HttpResetClass()
1477
- http1.load('POST', `${this.Url}/rs/sql/tel_singleTable_OrderBy`, {
1478
- data: {
1479
- items: 'f_user_telephone',
1480
- tablename: 't_user',
1481
- condition: `name = '${val}'`,
1482
- orderitem: 'id'
1483
- }
1484
- }, { resolveMsg: null, rejectMsg: null }).then((ress) => {
1485
- this.$parent.$parent.model.f_repairman_phone = ress.data[0].f_user_telephone
1486
- })
1487
- }
1488
- },
1489
- },
1490
- async ready() {
1491
- let state = HostApp.getBluetoothState()
1492
- if (state && state.state == 3){
1493
- this.blueState = '连接完成'
1494
- }else {
1495
- this.blueState = '连接失败,请重试'
1496
- }
1497
- this.isRecodr = this.$appdata.getSingleValue('无限制录音')
1498
- if (this.$appdata.getSingleValue('安检时显示拉黑')) {
1499
- this.showbacklist = this.$appdata.getSingleValue('安检时显示拉黑');
1500
- }
1501
- if (Vue.config.safecheck != undefined) {
1502
- if (Vue.config.safecheck.ApproveConfig != undefined) {
1503
- if (Vue.config.safecheck.ApproveConfig.gasinstructions != undefined) {
1504
- this.gasinstructions = Vue.config.safecheck.ApproveConfig.gasinstructions
1505
- }
1506
- if (Vue.config.safecheck.ApproveConfig.setgasinstructions != undefined) {
1507
- this.setgasinstructions = Vue.config.safecheck.ApproveConfig.setgasinstructions
1508
- }
1509
- }
1510
- }
1511
- // await this.isoverDate()
1512
- ////tag
1513
- ////tag
1514
- ////tag)
1515
- ////tag))
1516
- if (this.$parent.$parent.role == 'repair') {
1517
- this.$set('style__', 'divmask')
1518
- this.$set('style_view_', '')
1519
- } else if (this.$parent.$parent.role == 'view' || this.$parent.$parent.item.f_upload_state == '已传') {
1520
- this.$set('style__', 'divmask')
1521
- this.$set('style_view_', 'divmask')
1522
- ////tag
1523
- } else {
1524
- this.$set('style__', '')
1525
- this.$set('style_view_', '')
1526
- }
1527
-
1528
- for (let item of this.radios) {
1529
- if (this.paper.f_client_evaluation == item.label) {
1530
- item.isChecked = true;
1531
- }
1532
- }
1533
- if (!this.paper.f_notified_path)
1534
- this.$set('paper.f_notified_path', Vue.nopic)
1535
- if (!this.paper.f_sign_path)
1536
- this.$set('paper.f_sign_path', Vue.nopic)
1537
- ////tag
1538
- if (!this.paper.f_overall_imgs) {
1539
- let imgs = []
1540
- // imgs.push({f_overall_path:Vue.nopic})
1541
- this.$set('paper.f_overall_imgs', imgs)
1542
- ////tag
1543
- }
1544
- if (!this.paper.f_overall2_path)
1545
- this.$set('paper.f_overall2_path', Vue.nopic)
1546
-
1547
- this.userid = this.role == 'view' ? this.$login.f.id : Vue.user.id
1548
- if (Vue.config.safecheck != undefined) {
1549
- if (Vue.config.safecheck.ApproveConfig != undefined) {
1550
- if (Vue.config.safecheck.ApproveConfig.safeCheckToRepair != undefined) {
1551
- this.safeCheckToRepair = Vue.config.safecheck.ApproveConfig.safeCheckToRepair
1552
- }
1553
- }
1554
- }
1555
- let device = this.$parent.$parent.data
1556
- for (const deviceitem in device) {
1557
- if (deviceitem.startsWith('device')) {
1558
- //tag)
1559
- if (device[deviceitem].length == 0) {
1560
- continue
1561
- }
1562
- let items = device[deviceitem][0].f_items
1563
- let deviceType = device[deviceitem][0].f_device_type
1564
- for (let i = 0; i < items.length; i++) {
1565
- if (items[i].f_is_defect) {
1566
- let reason = items[i].f_item_name + ":"
1567
- if (items[i].type === 'selector' || items[i].type === 'radio' || items[i].type === 'checkbox') {
1568
- for (let j = 0; j < items[i].f_item_value.length; j++) {
1569
- if (j + 1 === items[i].f_item_value.length) {
1570
- reason += items[i].f_item_value[j]
1571
- } else {
1572
- reason += items[i].f_item_value[j] + ","
1573
- }
1574
- }
1575
- } else {
1576
- reason += items[i].f_item_value
1577
- }
1578
- if (items[i].f_path) {
1579
- this.defectImgs.push(items[i].f_path)
1580
- }
1581
- if (items[i].f_p1_path) {
1582
- this.defectImgs.push(items[i].f_p1_path)
1583
- }
1584
- if (items[i].f_p2_path) {
1585
- this.defectImgs.push(items[i].f_p2_path)
1586
- }
1587
- if (items[i].f_p3_path) {
1588
- this.defectImgs.push(items[i].f_p3_path)
1589
- }
1590
- if (items[i].tooltip) {
1591
- this.defectToolTip.push(items[i].tooltip)
1592
- }
1593
- this.defectReason.push({ device: deviceType, deviceitem: reason })
1594
- } else if (items[i].type === 'errorstring' && items[i].f_item_value) {
1595
- let reason = items[i].f_item_name + ":" + items[i].f_item_value
1596
- this.defectReason.push({ device: deviceType, deviceitem: reason })
1597
- }
1598
-
1599
- }
1600
- }
1601
- }
1602
- ////tag
1603
- ////tag
1604
- //tag
1605
- ////tag
1606
- //tag)
1607
- //tag)
1608
- //tag)
1609
- ////tag
1610
- ////tag
1611
- ////tag
1612
- },
1613
- watch: {
1614
- '$parent.$parent.isUpload'(val) {
1615
- ////tag
1616
- },
1617
- 'meading'(val) {
1618
- ////tag
1619
- this.$parent.$parent.meading = val
1620
- },
1621
- 'backlistisselect'(val) {
1622
- if (val == true) {
1623
- this.showmodel = true
1624
- this.deletebacklistisselect = false
1625
- }
1626
- },
1627
- 'deletebacklistisselect'(val) {
1628
- if (val == true) {
1629
- this.showmodelthree = true
1630
- this.backlistisselect = false
1631
- }
1632
- },
1633
- 'isRecodr'(val) {
1634
- if (val == 'false' || val == undefined || val == null || val == '' || val == 'undefined') {
1635
- this.isRecodr = "false";
1636
- }
1637
- },
1638
- 'paper.f_read_instructions'(val) {
1639
- if (val == true) {
1640
- this.showgas = true
1641
- }
1642
- }
1643
- }
1644
- }
1645
- </script>
1646
- <style scoped>
1647
- .panel-self {
1648
- border-radius: 5px;
1649
- border: 1px solid #c5e1f7;
1650
- background-color: #F2F6FA;
1651
- }
1652
-
1653
- .text-left {
1654
- text-align: left;
1655
- }
1656
-
1657
- .font {
1658
- font: 15px PingFang-SC-Medium;
1659
- color: #333333;
1660
- }
1661
-
1662
- .showIi {
1663
- font: 14px PingFang-SC-Medium;
1664
- color: #666666;
1665
- }
1666
-
1667
- .info {
1668
- margin-top: 15px;
1669
- border-radius: 5px;
1670
- background-color: #f3faff;
1671
- }
1672
-
1673
- .btn-photo {
1674
- border: 0;
1675
- border-radius: 7px;
1676
- background-color: #7dc1f4;
1677
- font: 15px PingFang-SC-Bold;
1678
- height: 20%;
1679
- }
1680
-
1681
- .div-photo {
1682
- width: auto;
1683
- height: auto;
1684
- /* margin-top: 10px; */
1685
- position: absolute;
1686
- bottom: 10px;
1687
- right: 10px;
1688
- }
1689
-
1690
- .btn-voice {
1691
- border-radius: 7px;
1692
- border: 1px solid #dedede;
1693
- background-color: #f5fbff;
1694
- font: 15px PingFang-SC-Bold;
1695
- color: #499edf;
1696
- }
1697
-
1698
- .save-btn {
1699
- width: 25%;
1700
- background-color: #499edf;
1701
- border-radius: 6px;
1702
- color: #FFFFFF;
1703
- font: 15px PingFang-SC-Bold;
1704
- }
1705
-
1706
- .upload-btn {
1707
- width: 25%;
1708
- background-color: #ffffff;
1709
- border: 1px solid #499edf;
1710
- border-radius: 6px;
1711
- color: #499edf;
1712
- font: 15px PingFang-SC-Bold;
1713
- }
1714
-
1715
- .repair-btn {
1716
- width: 25%;
1717
- border: 1px solid #499edf;
1718
- border-radius: 6px;
1719
- font: 15px PingFang-SC-Bold;
1720
- }
1721
-
1722
- #el_ca_tx {
1723
- width: 100%;
1724
- margin: 5px;
1725
- }
1726
-
1727
- #el_ca_txt {
1728
- width: 100%;
1729
- margin: 5px;
1730
- }
1731
- </style>
1
+ <template>
2
+ <work-busy :is-busy="is_busy"></work-busy>
3
+ <form novalidate class="form-horizontal" style="width: 95%;margin: auto">
4
+ <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__">
5
+ <div class="form-group col-md-12 col-sm-12 col-xs-12">
6
+ <label class="control-label font text-left col-md-4 col-xs-4">备注</label>
7
+ <div class="col-md-12 col-sm-12 col-xs-12">
8
+ <textarea v-model="paper.f_repair_approved_note" class="form-control"></textarea>
9
+ </div>
10
+ </div>
11
+ </div>
12
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 info" :class="style__">
13
+ <div class="text-center">
14
+ <label class="font">总体安检照片请依次拍摄:</label>
15
+ </div>
16
+ <div class="col-md-12 col-sm-12 col-xs-12">
17
+ <ol class="showIi">
18
+ <li>1.燃气设施全景</li>
19
+ <li>2.燃气表照片</li>
20
+ <li>3.灶具照片</li>
21
+ <li>4.其他照片</li>
22
+ </ol>
23
+ </div>
24
+ </div>
25
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
26
+ <label class="text-left font">总体安检照片</label>
27
+
28
+ <div class="auto" :class="style__">
29
+ <div class="panel" style="padding: 10px 10px 5px 10px;">
30
+ <div class="panel-body panel-self"
31
+ style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
32
+ <div class="row" style="height: 240px;overflow: scroll;top: 1px">
33
+ <div class="col-xs-4 col-sm-3 col-md-2" style="margin-bottom: 35px"
34
+ v-for="(index, img) in paper.f_overall_imgs">
35
+ <img-self-android :src="img.f_overall_path" alt="总体安检照片" :width="140" :height="170"></img-self-android>
36
+ <img src="../../../assets/删除.png" @click="delfile('f_overall_path', img.f_overall_path, index)"
37
+ style="width: 15px;margin-top: -80px" alt="">
38
+ </div>
39
+ </div>
40
+ <div class="row text-right div-photo">
41
+ <button type="button" name="button" class="btn btn-photo"
42
+ @click="takePic('f_overall_path', '总体安检照片')">拍照</button>
43
+ <!--<button type="button" name="button" class="btn btn-primary btn-photo" @click="takePic('f_overall_path', '总体安检照片1')">拍照</button>-->
44
+ <!--&nbsp;&nbsp;&nbsp;&nbsp;<img src="../../../assets/remove.png" :class="style__" @click="delfile('f_overall_path', img.f_overall_path)" style="width: 25%;"></img>-->
45
+ </div>
46
+ </div>
47
+ </div>
48
+ </div>
49
+ </div>
50
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
51
+ <label class="text-left font">总体隐患照片</label>
52
+ <div class="auto" :class="style__">
53
+ <div class="panel" style="padding: 10px 10px 5px 10px;">
54
+ <div class="panel-body panel-self"
55
+ style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
56
+ <div class="row" style="height: 240px;overflow: scroll;top: 1px">
57
+ <div class="col-xs-4 col-sm-3 col-md-2" style="margin-bottom: 35px" v-for="(index, img) in defectImgs">
58
+ <img-self-android :src="img" alt="总体隐患照片" :width="140" :height="170"></img-self-android>
59
+ <!-- <img src="../../assets/删除.png" @click="delfile('f_overall_path', img.f_overall_path,index)" style="width: 15px;margin-top: -80px" alt="">-->
60
+ </div>
61
+ </div>
62
+ </div>
63
+ </div>
64
+ </div>
65
+ </div>
66
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 info" :class="style__">
67
+ <div class="text-center">
68
+ <label class="font">隐患汇总:</label>
69
+ </div>
70
+ <div class="col-md-12 col-sm-12 col-xs-12">
71
+ <ol class="showIi">
72
+ <li v-for="item in defectReason">{{ item.deviceitem }}</li>
73
+ </ol>
74
+ </div>
75
+ </div>
76
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 info" :class="style__">
77
+ <div class="text-center">
78
+ <label class="font">整改建议汇总:</label>
79
+ </div>
80
+ <div class="col-md-12 col-sm-12 col-xs-12">
81
+ <ol class="showIi">
82
+ <li v-for="item in defectToolTip">{{ item }}</li>
83
+ </ol>
84
+ </div>
85
+ </div>
86
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
87
+ <input type="checkbox" id="readInstructionsCheckbox" v-model="paper.f_read_instructions" />
88
+ <label for="readInstructionsCheckbox" class="text-left font">我已阅读须知内容</label> </div>
89
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 " :class="style__">
90
+ <label class="text-left font">用户签名</label>
91
+ <div class="auto">
92
+ <div class="panel">
93
+ <div class="panel-body panel-self"
94
+ style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
95
+ <div class="row" style="height: 240px;overflow: scroll;top: 1px">
96
+ <div class="col-sm-4">
97
+ <img :class="style__" :src="paper.f_sign_path" :width="200" :height="150" />
98
+ </div>
99
+ </div>
100
+ <div class="row text-right div-photo">
101
+ <button type="button" name="button" class="btn btn-primary btn-photo" @click="sign">签名</button>
102
+ </div>
103
+ </div>
104
+ </div>
105
+ </div>
106
+ </div>
107
+ <div class="form-group col-sm-12 col-xs-12 col-md-12 " :style="timeSet(this.isneedDate) ? '' : 'display:none'">
108
+ <label>请输入超期原因:</label><br />
109
+ <textarea style="width: 100%;" v-model="paper.f_exceed_reason"></textarea>
110
+ </div>
111
+ <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__" v-show="showbacklist == '是'">
112
+ <div class="col-xs-6 col-sm-6">
113
+ <input type="checkbox" v-model="backlistisselect" :readonly="enabled" /><label
114
+ class="text-left font">限制该用户购气</label>
115
+ </div>
116
+ <div class="col-xs-6 col-sm-6">
117
+ <input type="checkbox" v-model="deletebacklistisselect" :readonly="deleteenabled" /><label
118
+ class="text-left font">取消该用户购气</label>
119
+ </div>
120
+ </div>
121
+ <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__"
122
+ v-if="Vue.$appdata.getParam('安检天然气安全使用须知检查') == '是'">
123
+ <div class="col-xs-12 col-sm-12">
124
+ <input type="checkbox" v-model="paper.f_gas_guidelines" /><label class="text-left font">天然气安全使用须知</label>
125
+ </div>
126
+ <div class="col-xs-12 col-sm-12">
127
+ <input type="checkbox" v-model="paper.f_safety_warning" /><label class="text-left font">天然气室内使用安全警示</label>
128
+ </div>
129
+ <div class="col-xs-12 col-sm-12">
130
+ <input type="checkbox" v-model="paper.f_gas_manual" /><label class="text-left font">安全用气手册</label>
131
+ </div>
132
+ </div>
133
+ <div class="row">
134
+ <label for="readsafe" class="text-left font">蓝牙状态:{{blueState}}</label>
135
+ <button type="button" @click="initBlueState()">重新连接</button>
136
+ </div>
137
+ <div class="form-group col-md-12 col-sm-12 col-xs-12" :class="style__">
138
+ <div class="form-group col-md-12 col-sm-12 col-xs-12">
139
+ <input type="checkbox" id='readsafe' v-model="paper.f_defect_notified" class="showIi" />
140
+ <label for="readsafe" class="text-left font">安检通知书/隐患整改通知书</label> </div>
141
+ <div class="form-group col-md-12 col-sm-12 col-xs-12" v-if="paper.f_defect_notified">
142
+ <div class="form-group col-md-12 col-sm-12 col-xs-12">
143
+ <button type="button" @click="print()">打印隐患整改单</button>
144
+ </div>
145
+ <div class="form-group col-md-12 col-sm-12 col-xs-12">
146
+ <label class="text-left font">安检通知书/隐患整改通知书照片(要求能清晰反应安检通知单和用户签字内容):</label>
147
+ <div class="auto">
148
+ <div class="panel" style="padding: 10px 10px 5px 10px;">
149
+ <div class="panel-body panel-self"
150
+ style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
151
+ <div class="row" style="height: 240px;overflow: scroll;top: 1px">
152
+ <div class="col-sm-4">
153
+ <img-self-android :src="paper.f_notified_path" alt="安检通知书/隐患整改通知书照片" width="150" height="200"></img-self-android>
154
+ </div>
155
+ </div>
156
+ <div class="row text-right div-photo">
157
+ <button type="button" name="button" class="btn btn-primary btn-photo"
158
+ @click="takePic('f_notified_path', '安检通知书/隐患整改通知书照片')">拍照</button>
159
+ &nbsp;&nbsp;&nbsp;&nbsp;<img src="../../../assets/remove.png" :class="style__"
160
+ @click="delfile('f_notified_path', this.paper.f_notified_path)" style="width: 25%;"></img>
161
+ </div>
162
+ </div>
163
+ </div>
164
+ </div>
165
+ </div>
166
+ </div>
167
+ <div class="form-group col-md-12 col-sm-12 col-xs-12">
168
+ <div class="row">
169
+ <label class="text-left">请对我们的服务做出评价:</label>
170
+ </div>
171
+ <div class="col-xs-4 col-sm-4" v-for="item in radios">
172
+ <input v-model="paper.f_client_evaluation" :value="item.label" :checked='item.isChecked'
173
+ @click="check(item.value)" type="radio">{{ item.label }}
174
+ </div>
175
+
176
+ <!--<div class="col-sm-4">-->
177
+ <!--<radio-group :value.sync="paper.f_client_evaluation" type="success" buttons="false">-->
178
+ <!--<radio value="满意">满意</radio>-->
179
+ <!--<radio value="基本满意">基本满意</radio>-->
180
+ <!--<radio value="不满意">不满意</radio>-->
181
+ <!--</radio-group>-->
182
+ <!--</div>-->
183
+ </div>
184
+
185
+ <div class="form-group col-md-12 col-sm-12 col-xs-12" v-if="isRecodr == 'false'">
186
+ <label class="text-left font">反馈录音:</label>
187
+ <div class="col-md-12 col-sm-12 col-xs-12">
188
+ <button type="button" name="button" class="btn btn-primary btn-voice" @click="record">
189
+ <img src="../../../assets/录音.png" style="width: 14%;">
190
+ <span v-if="!paper.f_recording1_path">开始录音</span>
191
+ <span v-if="paper.f_recording1_path">已录音</span>
192
+ </button>
193
+ &nbsp;&nbsp;&nbsp;&nbsp;<img src="../../../assets/remove.png" style="width: 15px;" :class="style__"
194
+ @click="delAudioFile('f_recording1_path', paper.f_recording1_path)"></img>
195
+ </div>
196
+ </div>
197
+
198
+ <div v-if="false">
199
+ <div class="text-center form-group col-md-12 col-sm-12 col-xs-12">
200
+ <button style="width: 30%;margin:3%;margin-bottom: 0%" type="button"
201
+ v-show="$parent.$parent.actionEnabled && upload_state != '已传' && (paper.f_complete != '已完成' || paper.back_f_entry_status != '入户')"
202
+ class="btn save-btn" @click="$parent.$parent.save('temp')">临时保存</button>
203
+ <button style="width: 30%;margin:3%;margin-bottom: 0%" type="button"
204
+ v-show="$parent.$parent.actionEnabled && upload_state != '已传' && (paper.f_complete != '已完成' || paper.back_f_entry_status != '入户')"
205
+ class="btn save-btn " @click="$parent.$parent.save('finish')">完成安检</button>
206
+ </div>
207
+ <div class="text-center form-group col-md-12 col-sm-12 col-xs-12">
208
+ <button style="width: 30%;margin:3%;margin-bottom: 0%;margin-top: 0%" id="upload" type="button"
209
+ v-show="$parent.$parent.actionEnabled && upload_state != '已传' && (paper.f_complete != '已完成' || paper.back_f_entry_status != '入户')"
210
+ class="btn upload-btn " @click="$parent.$parent.uploadCheckPaper">上传</button>
211
+ <button style="width: 30%;margin:3%;margin-bottom: 0%;margin-top: 0%"
212
+ v-if="(safeCheckToRepair == true || safeCheckToRepair == 'true') && $parent.$parent.actionEnabled"
213
+ class="btn repair-btn btn-warning " type="button" @click="showToRepair">转维修</button>
214
+ </div>
215
+ </div>
216
+
217
+ </div>
218
+ </form>
219
+ <!-- <modal :show.sync="showCheckToRepair" v-ref:modal :backdrop="isback">-->
220
+ <!-- <div slot="modal-header" class="modal-header">-->
221
+ <!-- <h4 class="modal-title">-->
222
+ <!-- 安检转维修-->
223
+ <!-- </h4>-->
224
+ <!-- </div>-->
225
+ <!-- <div slot="modal-body" class="modal-body">-->
226
+ <!-- <div v-if="showrepair">-->
227
+ <!-- <div class="row">-->
228
+ <!-- <label class="col-xs-4 col-md-4 control-label text-left">派单方式</label>-->
229
+ <!-- <div class="col-xs-8 col-md-8">-->
230
+ <!-- <label v-for="handling1 in handling" >-->
231
+ <!-- <input type="radio"-->
232
+ <!-- v-model="meading"-->
233
+ <!-- value="{{handling1.label}}">-->
234
+ <!-- {{handling1.label}}-->
235
+ <!-- </label>-->
236
+ <!-- </div>-->
237
+ <!-- </div>-->
238
+ <!-- <div class="row" v-if="meading == '转站点'">-->
239
+ <!-- <label class="col-xs-4 col-md-4 control-label font text-left" for="f_reciever">站点</label>-->
240
+ <!-- &lt;!&ndash;<input type="text" v-show="false" v-model="serviceacitivity.f_reciever"&ndash;&gt;-->
241
+ <!-- &lt;!&ndash;v-validate:f_reciever='{ required: true }'>&ndash;&gt;-->
242
+ <!-- <div class="col-xs-8 col-md-8">-->
243
+ <!-- <right-tree @ready="onReady" islist :Url="Url" :userid="userid" :source="source" v-on:re-res="reres" :textContent="选择站点管理员" :selectData="" v-ref:f_reciever>-->
244
+ <!-- </right-tree>-->
245
+ <!-- </div>-->
246
+ <!-- </div>-->
247
+
248
+ <!-- <div class="row" style="margin-top: 6px" v-if="meading == '转维修员'">-->
249
+ <!-- <label class="col-xs-4 col-md-4 control-label font text-left">维修人</label>-->
250
+ <!-- <div class="col-xs-8">-->
251
+ <!-- <v-select :value="$parent.$parent.model.serviceacitivity[0].f_reciever" :value-single="true"-->
252
+ <!-- :options='f_repair_person' placeholder='请选择维修员'-->
253
+ <!-- close-on-select v-on:change="repiarmancg"></v-select>-->
254
+ <!-- </div>-->
255
+
256
+ <!-- </div>-->
257
+ <!-- <div class="row" style="margin-top: 6px">-->
258
+ <!-- <label for="f_repair" class="col-xs-4 col-md-4 control-label font text-left">报修类型</label>-->
259
+ <!-- <div class="col-xs-8 col-md-8">-->
260
+ <!-- <v-select :value.sync="$parent.$parent.model.f_repairtype" :value-single="true"-->
261
+ <!-- :options='repairstypes' placeholder='报修类型'-->
262
+ <!-- close-on-select>-->
263
+ <!-- </v-select>-->
264
+ <!-- </div>-->
265
+ <!-- </div>-->
266
+
267
+ <!-- <div class="row" style="margin-top: 6px">-->
268
+ <!-- <label class="control-label font text-left col-md-4 col-xs-4">备注</label>-->
269
+ <!-- <div class="col-xs-8 col-md-8">-->
270
+ <!-- <input type="text" v-model="$parent.$parent.model.f_remarks"/>-->
271
+ <!-- </div>-->
272
+
273
+ <!-- </div>-->
274
+
275
+ <!-- </div>-->
276
+ <!-- <div v-if="!showrepair">-->
277
+ <!-- 暂无隐患设备信息-->
278
+ <!-- </div>-->
279
+ <!-- </div>-->
280
+ <!-- <div slot="modal-footer" class="modal-footer">-->
281
+ <!-- <button type="button" class="btn btn-default" @click="uploadPaper()">确定</button>-->
282
+ <!-- <button type="button" class="btn btn-default" @click="undo()">取消</button>-->
283
+ <!-- </div>-->
284
+ <!-- </modal>-->
285
+ <!--拉黑框-->
286
+ <modal :show.sync="showmodel" v-ref:modal>
287
+ <div slot="modal-header" class="modal-header">
288
+ <h4 class="modal-title">
289
+ 限制用户购气
290
+ </h4>
291
+ </div>
292
+ <div slot="modal-body" class="modal-body">
293
+ <!-- <div class="row" style="margin-top: 6px">-->
294
+ <!-- <label style="color: red;">注:当前页面无法取消对用户的限制购气</label>-->
295
+ <!-- </div>-->
296
+ <div class="row" style="margin-top: 6px">
297
+ <label class="col-xs-4 col-md-4 control-label font text-left">限制原因</label>
298
+ <div class="col-xs-8 col-md-8">
299
+ <v-select :value.sync="cause" :value-single="true" :options='causedatas' placeholder='限制原因' close-on-select>
300
+ </v-select>
301
+ </div>
302
+ </div>
303
+
304
+ <div class="row" style="margin-top: 6px">
305
+ <label class="control-label font text-left col-md-4 col-xs-4">备注</label>
306
+ <div class="col-xs-8 col-md-8">
307
+ <input type="text" v-model="causeremarks" />
308
+ </div>
309
+
310
+ </div>
311
+ <!-- <div class="row" style="margin-top: 6px">-->
312
+ <!-- <textarea id="el_ca_tx" v-model.trim="cause" style="border-radius:4px;width: 100%;" placeholder="请输入限制用户购气原因" >-->
313
+ <!-- </textarea>-->
314
+ <!-- </div>-->
315
+ </div>
316
+ <div slot="modal-footer" class="modal-footer">
317
+ <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="backlist()">确认</button>
318
+ <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="cancel()">取消</button>
319
+ </div>
320
+ </modal>
321
+
322
+ <modal :show.sync="showmodelthree" v-ref:modal>
323
+ <div slot="modal-header" class="modal-header">
324
+ <h4 class="modal-title">
325
+ 取消限制用户购气
326
+ </h4>
327
+ </div>
328
+ <div slot="modal-body" class="modal-body">
329
+ <!-- <div class="row" style="margin-top: 6px">-->
330
+ <!-- <label style="color: red;">注:当前页面无法取消对用户的限制购气</label>-->
331
+ <!-- </div>-->
332
+ <div class="row" style="margin-top: 6px">
333
+ <label for="f_repair" class="col-xs-4 col-md-4 control-label font text-left">取消原因</label>
334
+ <div class="col-xs-8 col-md-8">
335
+ <v-select :value.sync="deletecause" :value-single="true" :options='delcausedatas' placeholder='取消原因'
336
+ close-on-select>
337
+ </v-select>
338
+ </div>
339
+ </div>
340
+
341
+ <div class="row" style="margin-top: 6px">
342
+ <label class="control-label font text-left col-md-4 col-xs-4">备注</label>
343
+ <div class="col-xs-8 col-md-8">
344
+ <input type="text" v-model="causeremarks" />
345
+ </div>
346
+
347
+ </div>
348
+ <!-- <div class="row" style="margin-top: 6px">-->
349
+ <!-- <textarea id="el_ca_txt" v-model.trim="deletecause" style="border-radius:4px;width: 100%;" placeholder="请输入取消限制用户购气原因" >-->
350
+ <!-- </textarea>-->
351
+ <!-- </div>-->
352
+ </div>
353
+ <div slot="modal-footer" class="modal-footer">
354
+ <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="deletebacklist()">确认</button>
355
+ <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="deletecancel()">取消</button>
356
+ </div>
357
+ </modal>
358
+ <modal :show.sync="showgas" v-ref:modal>
359
+ <div slot="modal-header" class="modal-header">
360
+ <h4 class="modal-title">
361
+ 用户须知
362
+ </h4>
363
+ </div>
364
+ <div slot="modal-body" class="modal-body">
365
+ <!-- <div class="row" style="margin-top: 6px">-->
366
+ <!-- <label style="color: red;">注:当前页面无法取消对用户的限制购气</label>-->
367
+ <!-- </div>-->
368
+ <div class="row" style="margin-top: 6px">
369
+ <sapn v-if="paper.f_check_type == '民用'">{{ gasinstructions ? gasinstructions : '请配置民用用户须知' }}</sapn>
370
+ <sapn v-if="paper.f_check_type == '非民用'">{{ setgasinstructions ? setgasinstructions : '请配置非民用用户须知' }}</sapn>
371
+ </div>
372
+ </div>
373
+ <div slot="modal-footer" class="modal-footer">
374
+ <button type="button" name="button" class="col-sm-3 btn btn-primary" @click="closeshowgas()">确认</button>
375
+ </div>
376
+ </modal>
377
+ </template>
378
+
379
+ <script>
380
+ import Vue from 'vue'
381
+ import * as Util from '../../Util'
382
+ import { HttpResetClass } from 'vue-client'
383
+ import RadioGroup from 'vue-client/src/vue-strap/src/radioGroup'
384
+ import Radio from 'vue-client/src/vue-strap/src/radioBtn'
385
+ import co from 'co'
386
+
387
+ // let getRepairParam = function * (self){
388
+ // let data = {
389
+ // $parent.$parent.model: self.$parent.$parent.model, loginUser: {
390
+ // name: self.role == 'view'?self.$login.f.name:Vue.user.name,
391
+ // ename: self.role == 'view'?self.$login.f.ename:Vue.user.ename
392
+ // }, user: self.user, callObj: self.callObj
393
+ // }
394
+ // if(self.$parent.$parent.meading == '转维修员'){
395
+ // data.toRepair = '一级派单'
396
+ // }
397
+ // data.$parent.$parent.model.f_attendant = data.loginUser.name
398
+ // ////tag
399
+ // ////tag
400
+ // let res
401
+ // let errString = self.$parent. $parent.errorVerify()
402
+ // if(errString){
403
+ // ////tag
404
+ // if (Vue.android)
405
+ // self.undo()
406
+ // this.$showMessage(errString)
407
+ // return
408
+ // } else {
409
+ // if(self.role == 'inspect'){
410
+ // if(self.$parent.$parent.meading == '转维修员' && (self.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || self.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)){
411
+ // this.$showMessage("请选择维修员!")
412
+ // return
413
+ // }
414
+ // if(self.$parent.$parent.meading == '转站点' && (self.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || self.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)){
415
+ // HostApp.alert()
416
+ // this.$showMessage("请选择站点!")
417
+ // return
418
+ // }
419
+ // if(self.$parent.$parent.model.f_repairtype == ''){
420
+ // this.$showMessage("请选择报修类型!")
421
+ // return
422
+ // }
423
+ // ////tag)
424
+ // let checkResult = '正常'
425
+ // let options = [{"data": "已处理"},{"data": "未处理"}]
426
+ // let value = ''
427
+ // let codata = JSON.parse(JSON.stringify(self.paper))
428
+ // for(let device in codata){
429
+ // ////tag)
430
+ // let f_device_type
431
+ // if(device.startsWith("device")){
432
+ // for(let item in codata[device]) {
433
+ // if(codata[device].length > 1 ){
434
+ // let j = Number.parseInt(item)+1
435
+ // f_device_type = `${codata[device][item].f_device_type}${j}`
436
+ // }else{
437
+ // f_device_type = codata[device][item].f_device_type
438
+ // }
439
+ // // ////tag
440
+ // let details = []
441
+ // for(let i in codata[device][item].f_items){
442
+ // let items = codata[device][item].f_items[i]
443
+ // ////tag
444
+ // if(items.f_is_defect == true || items.f_is_defect == 'true'){
445
+ // checkResult = '有隐患'
446
+ // ////tag
447
+ // let res = yield self.$resetpost(`${self.Url}/rs/sql/getDeviceItem`,{data:{f_device_id:codata[device][item].f_device_id,f_item_name:items.f_item_name}})
448
+ // ////tag)
449
+ // self.$set('detail.f_defect_id', res.data[0].id)
450
+ // self.$set('detail.f_project',`${items.f_item_name}:${items.f_item_value}`)
451
+ // self.$set('detail.type',items.type)
452
+ // self.$set('detail.options',options)
453
+ // details.push(JSON.parse(JSON.stringify(self.detail)))
454
+ // }
455
+ // if(items.type == 'selector'){
456
+ // items.selected = ''
457
+ // }
458
+ // self.detail = {}
459
+ // }
460
+ // ////tag
461
+ // self.$set('defectDevice.f_type',f_device_type)
462
+ // self.$set('defectDevice.details',details)
463
+ // if(self.defectDevice.details.length >0 ){
464
+ // self.repairitems.push(JSON.parse(JSON.stringify(self.defectDevice)))
465
+ // }
466
+ // self.defectDevice = {}
467
+ // ////tag
468
+ // }
469
+ // }
470
+ // }
471
+ // self.$set('$parent.$parent.model.f_repairitems.data',self.repairitems)
472
+ //
473
+ //
474
+ // ////tag)
475
+ // res = self.$androidUtil.bzLogic('safecheckToRepair',data)
476
+ // ////tag
477
+ // ////tag
478
+ // ////tag
479
+ // if(res.code == 200){
480
+ // self.$parent.$parent.isSafeCheckToRepair = true
481
+ // self.undo()
482
+ // self.$set('paper.f_SafeToRepair_id',res.data.f_service_id)
483
+ // ////tag
484
+ // self.$resetpost(`${self.Url}/rs/logic/updatePaperRepair`,{data:{f_paper_id:self.paper.f_paper_id,f_SafeToRepair_id:res.data.f_service_id}}).then((ret)=>{
485
+ // ////tag
486
+ // if(ret.data.code ==200){
487
+ // ////tag
488
+ // self.$parent.$parent.$back()
489
+ // }else{
490
+ // self.$showMessage('安检转维修失败!')
491
+ // }
492
+ // }).catch(v=>{
493
+ // ////tag)
494
+ // self.$showMessage('安检转维修失败!')
495
+ // })
496
+ // }else{
497
+ // self.$showMessage('安检转维修失败!')
498
+ // }
499
+ // }
500
+ // }
501
+ // }
502
+
503
+
504
+
505
+ // let getRepairs = async function(self,url) {
506
+ // // 获取配置信息
507
+ // try {
508
+ // let val = {source: 'this.getParentByType($department$).getAllChildrens().where(row.getAttributes().get($rolestr$).indexOf($维修员$) != -1 ))', userid: `${Vue.user.id}`}
509
+ // let repairs =[]
510
+ // let res = await Vue.resetpost(`${url}/rs/search`,{data: val},{resolveMsg: null, rejectMsg: null})
511
+ // res.data.forEach((item) => {
512
+ // repairs.push({label: item.name, value: item})
513
+ // })
514
+ // self.f_repair_person = repairs
515
+ // if(self.$parent.$parent.role == 'inspect'){
516
+ // let res = self.$androidUtil.bzLogic('getUserInfo',{id:self.paper.f_userinfoid})
517
+ // if(res.code == 200){
518
+ // self.$parent.$parent.user = res.data[0]
519
+ // self.$parent.$parent.model.f_area = self.$parent.$parent.user.f_area
520
+ // }
521
+ // }else{
522
+ // ////tag
523
+ // self.$resetpost(`${self.Url}/rs/sql/safeCheckgetUserInfo`,{data:{id:self.paper.f_userinfoid}},{resolveMsg: null, rejectMsg: null}).then((res)=>{
524
+ // ////tag
525
+ // if(res.data.length != 0){
526
+ // self.$parent.$parent.user = res.data[0]
527
+ // self.$parent.$parent.model.f_area = self.$parent.$parent.user.f_area
528
+ // }
529
+ // })
530
+ // // path({alias:'getUserInfo',data:{id:this.paper.f_userinfoid}})
531
+ // }
532
+ // } catch (error) {
533
+ // ////tag
534
+ // }
535
+ // }
536
+
537
+ export default {
538
+ title: '用户反馈',
539
+ data() {
540
+ return {
541
+ blueState:'',
542
+ is_busy:false,
543
+ defectImgs: [],
544
+ defectToolTip: [],
545
+ defectReason: [],
546
+ images: [],
547
+ showmodelthree: false,
548
+ isneedDate: this.$parent.$parent.isneedDate,
549
+ plan: this.$parent.$parent.item,
550
+ meading: this.$parent.$parent.meading,
551
+ paper: this.$parent.$parent.data,
552
+ printContent: [],
553
+ upload_state: this.$parent.$parent.item.f_upload_state,
554
+ enabled: false,//控制限制购气是否可选
555
+ deleteenabled: false,
556
+ showmodel: false,
557
+ showbacklist: '是',
558
+ backlistisselect: false,
559
+ deletebacklistisselect: false,
560
+ radios: [
561
+ {
562
+ label: '满意',
563
+ value: 0,
564
+ isChecked: false,
565
+ },
566
+ {
567
+ label: '基本满意',
568
+ value: 1,
569
+ isChecked: false,
570
+ },
571
+ {
572
+ label: '不满意',
573
+ value: 2,
574
+ isChecked: false,
575
+ },
576
+ ],
577
+ repairitems: [],
578
+ repairstypes: this.$appdata.getParam('报修类型'),
579
+ causedatas: this.$appdata.getParam('安检限购原因'),
580
+ delcausedatas: this.$appdata.getParam('安检取消限购原因'),
581
+ causeremarks: '',
582
+ // f_repair_person: this.readRepair(),
583
+ showrepair: false,
584
+ safeCheckToRepair: '',
585
+ showCheckToRepair: false,
586
+ userid: '',
587
+ source:
588
+ 'dep=this.getParentByType($organization$).getSpecialResByType($department$),' +
589
+ 'tool.getFullTree(dep.where(row.hasSpecialRole($派单员$)))',
590
+ isback: false,
591
+ defectDevice: {},
592
+ detail: {},
593
+ callObj: null,
594
+ user: {},
595
+ role: this.$parent.$parent.role,
596
+ handling: [{ label: '转站点', value: '转站点' }, { label: '转维修员', value: '转维修员' }],
597
+ Url: this.$androidUtil.getProxyUrl(),
598
+ cause: "",
599
+ deletecause: "",
600
+ isRecodr: "false", //单值参数,为true则是开启全程录音
601
+ showgas: false,
602
+ gasinstructions: '', // 民用用户须知
603
+ setgasinstructions: '' // 非民用用户须知
604
+ }
605
+ },
606
+ props: ['idx'],
607
+ components: {
608
+ RadioGroup,
609
+ Radio
610
+ },
611
+ methods: {
612
+ initBlueState(){
613
+ let state = HostApp.getBluetoothState()
614
+ if (state && state.state == 3){
615
+ this.blueState = '连接完成'
616
+ }else {
617
+ if (state && state.state == -1){
618
+ this.$showMessage('蓝牙连接未打开,打开后重新尝试')
619
+ return
620
+ }
621
+ this.blueState = '连接失败,请重试'
622
+ this.$androidUtil.print(JSON.stringify([{ type: 4, value: 2, unit: 'line' }]))
623
+ let state2 = HostApp.getBluetoothState()
624
+ if (state2 && state2.state == 3){
625
+ this.blueState = '连接完成'
626
+ }else {
627
+ this.blueState = '连接失败,请重试'
628
+ }
629
+ }
630
+ },
631
+ timeSet(val) {
632
+ //////tag
633
+ if (!val) {
634
+ return
635
+ }
636
+ let time = new Date(val).getTime()
637
+ let time2 = new Date().getTime()
638
+ if (time2 > time) {
639
+ return true
640
+ }
641
+ },
642
+ // async isoverDate(){
643
+ // ////tag
644
+ // let res= await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/rs/sql/androidGetuserinfo`, {data:{
645
+ // condition:"f_plan_item_id='"+this.$parent.$parent.item.id+"'"
646
+ // }
647
+ // })
648
+ // this.isneedDate=res.data[0]["f_subscribe_date"]
649
+ // ////tag
650
+ // },
651
+ check(index) {
652
+ ////tag
653
+ // 先取消所有选中项
654
+ for (let item of this.radios) {
655
+ item.isChecked = false;
656
+ }
657
+ //再设置当前点击项选中
658
+ this.paper.f_client_evaluation = this.radios[index].label;
659
+ // 设置值,以供传递
660
+ this.radios[index].isChecked = true;
661
+ ////tag;
662
+ },
663
+ getSignValue(fileName) {
664
+ this.f_signname = fileName
665
+ },
666
+ cameraCallBack(prop, fileName) {
667
+ if (prop == 'f_overall_path') {
668
+ let f_overall_path = fileName + '?' + Math.random()
669
+ HostApp.__this__.paper.f_overall_imgs.push({
670
+ f_overall_path: f_overall_path
671
+ })
672
+ } else {
673
+ HostApp.__this__.paper[prop] = fileName + '?' + Math.random()
674
+ }
675
+ HostApp.__callback__ = null
676
+ HostApp.__this__ = null
677
+ },
678
+ takePic(prop, title, index) {
679
+ HostApp.__callback__ = this.cameraCallBack
680
+ HostApp.__this__ = this
681
+ ////tag
682
+ ////tag
683
+ let fileName
684
+ if (prop == 'f_overall_path') {
685
+ if (!this.paper.f_overall_imgs[index] || this.paper.f_overall_imgs[index].f_overall_path.includes("nopic.png")) {
686
+ fileName = Util.guid() + '-' + prop + '.jpg'
687
+ } else {
688
+ fileName = Util.getFileName(this.paper.f_overall_imgs[index].f_overall_path)
689
+ }
690
+ } else {
691
+ if (!this.paper[prop] || this.paper[prop].includes("nopic.png")) {
692
+ fileName = Util.guid() + '-' + prop + '.jpg'
693
+ } else {
694
+ fileName = Util.getFileName(this.paper[prop])
695
+ }
696
+ }
697
+ let jingweidu = ''
698
+ if (this.$parent.$parent.is_has_jingweidu == 'true') {
699
+ const obj = HostApp.getGpsDetailAddress()
700
+ jingweidu = '\t经度:' + obj.longitude + '\t纬度:' + obj.latitude
701
+ }
702
+ HostApp._open_a_page({
703
+ type: 'boomerang',
704
+ page: 'com.aofeng.hybrid.android.peripheral.CameraActivity',
705
+ param: {
706
+ file: fileName,
707
+ requestCode: 111,
708
+ callback: 'javascript:HostApp.__callback__("' + prop + '", "%s");',
709
+ watermark: title + '\t时间:' + Util.toStandardTimeString() + '\t' + Vue.user.name + '\t' + this.paper.f_userinfo_code + '\t' + this.paper.f_user_name + '\t' + this.paper.f_address
710
+ + jingweidu
711
+ }
712
+ })
713
+ },
714
+ amrCallBack(fileName) {
715
+ HostApp.__this__.$set('paper.f_recording1_path', fileName)
716
+ HostApp.__callback__ = null
717
+ HostApp.__this__ = null
718
+ },
719
+ record() {
720
+ if (this.$parent.$parent.role != 'inspect') {
721
+ if (this.paper.f_recording1_path != '') {
722
+ window.location = this.paper.f_recording1_path
723
+ }
724
+ } else {
725
+ HostApp.__callback__ = this.amrCallBack
726
+ HostApp.__this__ = this
727
+ let fileName
728
+ if (!this.paper.f_recording1_path) {
729
+ fileName = Util.guid() + '.amr'
730
+ } else {
731
+ fileName = Util.getFileName(this.paper.f_recording1_path)
732
+ }
733
+ HostApp._open_a_page({
734
+ type: 'boomerang',
735
+ page: 'com.aofeng.hybrid.android.peripheral.AudioClipActivity',
736
+ param: { file: fileName, requestCode: 111, callback: 'javascript:HostApp.__callback__("%s");' }
737
+ })
738
+ }
739
+ },
740
+ // 签名回调
741
+ signCallback(prop, fileName) {
742
+ // HostApp.alert('绑定属性:' + prop + ' 文件全路径如file:///storage/sdcard0/safecheck/abc.jpg:' + fullFileName)
743
+ HostApp.__this__.$set('paper.f_sign_path', fileName)
744
+ HostApp.__callback__ = null
745
+ HostApp.__this__ = null
746
+ },
747
+ // 用户签名
748
+ sign() {
749
+ if (!this.paper.f_read_instructions) {
750
+ this.$showMessage('请先阅读并勾选用户须知内容后进行签名!')
751
+ return
752
+ }
753
+ this.delAudioFile('f_sign_path', this.paper.f_sign_path)
754
+ let prop = 'f_sign_path'
755
+ let idx = 'aofeng'
756
+ let fileName
757
+ if (!this.paper.f_sign_path) {
758
+ fileName = Util.guid() + '-valve-' + idx + '-' + prop + '.jpg'
759
+ } else {
760
+ fileName = Util.getFileName(this.paper.f_sign_path)
761
+ }
762
+ HostApp.__callback__ = this.signCallback
763
+ HostApp.__this__ = this
764
+ HostApp.getSignature({
765
+ file: fileName,
766
+ requestCode: 111,
767
+ callback: 'javascript:HostApp.__callback__("' + prop + '", "%s");'
768
+ })
769
+ },
770
+ delfile(prop, fileName, index) {
771
+ if (fileName == Vue.nopic)
772
+ return
773
+ else {
774
+ if (prop == 'f_overall_path') {
775
+ this.paper.f_overall_imgs.splice(index, 1)
776
+ HostApp.delfile(fileName)
777
+ } else {
778
+ HostApp.delfile(fileName)
779
+ this.paper[prop] = Vue.nopic
780
+ }
781
+ }
782
+ },
783
+ delAudioFile(prop, fileName) {
784
+ if (!fileName)
785
+ return
786
+ else {
787
+ HostApp.delfile(fileName)
788
+ this.paper[prop] = null
789
+ }
790
+ },
791
+ //获取打印用户信息
792
+ getUser() {
793
+ this.printContent.push({
794
+ type: 3,
795
+ text: '客户信息',
796
+ fontsize: 2,
797
+ isbold: false,
798
+ align: 'left'
799
+ })
800
+ if (this.paper.f_user_name == undefined)
801
+ this.paper.f_user_name = ''
802
+ this.printContent.push({
803
+ type: 3,
804
+ text: '客户姓名:' + this.paper.f_user_name,
805
+ fontsize: 2,
806
+ isbold: false,
807
+ align: 'left'
808
+ })
809
+ if (this.paper.f_userinfo_code == undefined)
810
+ this.paper.f_userinfo_code = ''
811
+ this.printContent.push({
812
+ type: 3,
813
+ text: '客户编号:' + this.paper.f_userinfo_code,
814
+ fontsize: 2,
815
+ isbold: false,
816
+ align: 'left'
817
+ })
818
+ if (this.paper.f_address == undefined)
819
+ this.paper.f_address = ''
820
+ this.printContent.push({ type: 3, text: '客户地址:' + this.paper.f_address, fontsize: 2, isbold: false, align: 'left' })
821
+ if (this.paper.f_user_phone == undefined)
822
+ this.paper.f_user_phone = ''
823
+ this.printContent.push({
824
+ type: 3,
825
+ text: '客户电话:' + this.paper.f_user_phone,
826
+ fontsize: 2,
827
+ isbold: false,
828
+ align: 'left'
829
+ })
830
+ this.printContent.push({ type: 3, text: '气表表号:' + (this.$parent.$parent.item.f_plan_meters[0].f_meter_no || ''), fontsize: 2, isbold: false, align: 'left' })
831
+ this.printContent.push({ type: 3, text: '表具品牌:' + (this.$parent.$parent.item.f_plan_meters[0].f_aliasname || ''), fontsize: 2, isbold: false, align: 'left' })
832
+ this.printContent.push({ type: 3, text: '表具类型:' + (this.$parent.$parent.item.f_plan_meters[0].f_meter_type || ''), fontsize: 2, isbold: false, align: 'left' })
833
+ this.printContent.push({ type: 3, text: '表具规格:' + (this.$parent.$parent.item.f_plan_meters[0].f_diaphgram_size || ''), fontsize: 2, isbold: false, align: 'left' })
834
+ this.printContent.push({ type: 3, text: '进气方向:' + (this.$parent.$parent.item.f_plan_meters[0].f_flow_direction || ''), fontsize: 2, isbold: false, align: 'left' })
835
+ this.printContent.push({ type: 3, text: '安检时间:' + this.getNowFormatDate(), fontsize: 2, isbold: false, align: 'left' })
836
+ },
837
+ verify() {
838
+ let hasError = this.$parent.$parent.verifyUser()
839
+ if (hasError)
840
+ return hasError
841
+ hasError = this.$parent.$parent.verifyDevices()
842
+ if (hasError)
843
+ return hasError
844
+ },
845
+ print() {
846
+ let state = HostApp.getBluetoothState()
847
+ if (state && state.state == 3){
848
+ this.blueState = '连接完成'
849
+ }else {
850
+ this.blueState = '连接失败,请重试'
851
+ }
852
+ if (state && state.state == -1){
853
+ this.$showMessage('蓝牙未打开,请确认蓝牙是否打开')
854
+ return
855
+ }
856
+ this.is_busy = true
857
+ setTimeout(() => {
858
+ this.is_busy = false
859
+ }, 10000)
860
+ let errString = this.verify()
861
+ if (errString) {
862
+ ////tag
863
+ if (Vue.android)
864
+ this.$showMessage(errString)
865
+ return
866
+ }
867
+ // 文本
868
+ let feedPageHead = { type: 4, value: 2, unit: 'line' }
869
+ this.printContent.push({ type: 3, text: ' 阳春市博能燃气 ', fontsize: 3, isbold: true, align: 'center' })
870
+ this.printContent.push({ type: 3, text: ' 用户燃气设施安全检查单 ', fontsize: 3, isbold: true, align: 'center' })
871
+ this.printContent.push(feedPageHead)
872
+ this.getUser()
873
+ this.printContent.push({
874
+ type: 3,
875
+ text: '-------------------------------',
876
+ fontsize: 3,
877
+ isbold: false,
878
+ align: 'center'
879
+ })
880
+ this.printContent.push({ type: 3, text: '安检执行', fontsize: 3, isbold: true, align: 'left' })
881
+ this.printContent.push({ type: 3, text: this.defectReason.length > 0 ? '已安检有问题' : '已安检无问题', fontsize: 3, isbold: true, align: 'left' })
882
+ this.printContent.push({
883
+ type: 3,
884
+ text: '-------------------------------',
885
+ fontsize: 3,
886
+ isbold: false,
887
+ align: 'center'
888
+ })
889
+ this.printContent.push({ type: 3, text: '问题登记', fontsize: 3, isbold: true, align: 'left' })
890
+ for (var i = 0; i < this.defectReason.length; i++) {
891
+ this.printContent.push({ type: 3, text: (i + 1) + ':' + this.defectReason[i].deviceitem + ';', fontsize: 3, isbold: true, align: 'left' })
892
+ }
893
+ this.printContent.push({
894
+ type: 3,
895
+ text: '-------------------------------',
896
+ fontsize: 3,
897
+ isbold: false,
898
+ align: 'center'
899
+ })
900
+
901
+ this.getTableData()
902
+ this.printContent.push({
903
+ type: 3,
904
+ text: '-------------------------------',
905
+ fontsize: 3,
906
+ isbold: false,
907
+ align: 'center'
908
+ })
909
+ this.printContent.push({ type: 3, text: '备注', fontsize: 3, isbold: true, align: 'left' })
910
+ if (this.f_repair_approved_note) {
911
+ this.printContent.push({ type: 3, text: this.f_repair_approved_note, fontsize: 3, isbold: true, align: 'left' })
912
+ } else {
913
+ this.printContent.push({ type: 4, value: 2, unit: 'line' })
914
+ }
915
+ this.printContent.push({
916
+ type: 3,
917
+ text: '-------------------------------',
918
+ fontsize: 3,
919
+ isbold: false,
920
+ align: 'center'
921
+ })
922
+
923
+ this.printContent.push({ type: 3, text: '安全须知', fontsize: 3, isbold: true, align: 'left' })
924
+ if (this.paper.f_check_type == '民用') {
925
+ this.printContent.push({ type: 3, text: this.gasinstructions, fontsize: 3, isbold: true, align: 'left' })
926
+ } else {
927
+ this.printContent.push({ type: 3, text: this.setgasinstructions, fontsize: 3, isbold: true, align: 'left' })
928
+ }
929
+ this.getCheck()
930
+ this.printContent.push({
931
+ type: 3,
932
+ text: '-------------------------------',
933
+ fontsize: 3,
934
+ isbold: false,
935
+ align: 'center'
936
+ })
937
+ this.printContent.push({ type: 3, text: '表具读数:仅对安检时表其显示数据登记,最终数据以机械读数及收费系统数据核对为准!', fontsize: 3, isbold: true, align: 'left' })
938
+ this.printContent.push({ type: 3, text: '博能燃气24小时服务电话:6168119', fontsize: 3, isbold: true, align: 'left' })
939
+ this.printContent.push({ type: 4, value: 2, unit: 'line' })
940
+ this.printContent.push({ type: 4, value: 2, unit: 'line' })
941
+ let arrstr = JSON.stringify(this.printContent)
942
+ console.log(arrstr);
943
+ let temp = JSON.parse(arrstr)
944
+ console.log(temp);
945
+ ////tag
946
+ const result = this.$androidUtil.print(arrstr)
947
+ console.log(result);
948
+ this.$set('printContent', [])
949
+ this.is_busy = false
950
+ },
951
+ getTableData() {
952
+ let codata = this.$parent.$parent.data
953
+ for (let device in codata) {
954
+ if (device.startsWith('device')) {
955
+ if (codata[device].length > 0 && codata[device][0].f_device_type == '采集项') {
956
+ this.printContent.push({ type: 3, text: '信息采集', fontsize: 3, isbold: true, align: 'left' })
957
+ for (let i = 0; i < codata[device][0].f_items.length; i++) {
958
+ switch (codata[device][0].f_items[i].f_item_name) {
959
+ case '灶数量(台)': this.printContent.push({ type: 3, text: '灶数量(台):' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
960
+ case '热水器数量(台)': this.printContent.push({ type: 3, text: '热水器数量(台):' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
961
+ case '锅炉数量(台)': this.printContent.push({ type: 3, text: '锅炉数量(台):' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
962
+ case '热水器安装位置': this.printContent.push({ type: 3, text: '热水器安装位置:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
963
+ case '热水器类型': this.printContent.push({ type: 3, text: '热水器类型:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
964
+ case '特殊信息': this.printContent.push({ type: 3, text: '特殊信息:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
965
+ case '天然气燃具数量(台)': this.printContent.push({ type: 3, text: '天然气燃具数量:' + (codata[device][0].f_items[i].f_item_value.toString() || '') + '(台)', fontsize: 3, isbold: true, align: 'left' }); break;
966
+ case '灶具品牌': this.printContent.push({ type: 3, text: '灶具品牌:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
967
+ case '灶具品牌启用年': this.printContent.push({ type: 3, text: '灶具品牌启用年:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
968
+ case '热水器品牌': this.printContent.push({ type: 3, text: '热水器品牌:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
969
+ case '热水器启用年': this.printContent.push({ type: 3, text: '热水器启用年:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' }); break;
970
+ default: break;
971
+ }
972
+ }
973
+ this.printContent.push({
974
+ type: 3,
975
+ text: '-------------------------------',
976
+ fontsize: 3,
977
+ isbold: false,
978
+ align: 'center'
979
+ })
980
+ }
981
+ if (codata[device].length > 0 && codata[device][0].f_device_type == '燃气表') {
982
+ this.printContent.push({ type: 3, text: '表具读数', fontsize: 3, isbold: true, align: 'left' })
983
+ for (let i = 0; i < codata[device][0].f_items.length; i++) {
984
+ switch (codata[device][0].f_items[i].f_item_name) {
985
+ case '已用金额': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '已用金额:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
986
+ case '机械读数': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '机械读数:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
987
+ case '电子读数': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '电子读数:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
988
+ case '计量误差异常差值': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '偏差:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
989
+ case '剩余气量': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '剩余气量:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
990
+ case '剩余金额': codata[device][0].f_items[i].f_item_value ? (this.printContent.push({ type: 3, text: '剩余金额:' + (codata[device][0].f_items[i].f_item_value.toString() || ''), fontsize: 3, isbold: true, align: 'left' })) : null ; break;
991
+ default: break;
992
+ }
993
+ }
994
+ }
995
+ }
996
+ }
997
+ },
998
+ //打印安检信息
999
+ getCheck() {
1000
+ // let telephone = '96777'
1001
+ // if (Vue.config.safecheck != undefined) {
1002
+ // if (Vue.config.safecheck.ApproveConfig != undefined) {
1003
+ // if (Vue.config.safecheck.ApproveConfig.checkphone != undefined) {
1004
+ // telephone = Vue.config.safecheck.ApproveConfig.checkphone
1005
+ // }
1006
+ // }
1007
+ // }
1008
+ // this.printContent.push({
1009
+ // type: 3,
1010
+ // text: '-------------------------------',
1011
+ // fontsize: 3,
1012
+ // isbold: false,
1013
+ // align: 'center'
1014
+ // })
1015
+ // this.printContent.push({type: 3, text: '咨询电话;' + telephone, fontsize: 2, isbold: false, align: 'left'})
1016
+ // this.printContent.push({type: 3, text: '安检人:' + Vue.user.name, fontsize: 2, isbold: false, align: 'left'})
1017
+ // this.printContent.push({
1018
+ // type: 3,
1019
+ // text: '安检时间:' + this.getNowFormatDate(),
1020
+ // fontsize: 2,
1021
+ // isbold: false,
1022
+ // align: 'left'
1023
+ // })
1024
+ this.printContent.push({
1025
+ type: 3,
1026
+ text: '-------------------------------',
1027
+ fontsize: 3,
1028
+ isbold: false,
1029
+ align: 'center'
1030
+ })
1031
+ let f_sign_path = this.paper.f_sign_path
1032
+ this.printContent.push({ type: 3, text: '用户签字:', fontsize: 2, isbold: false, align: 'left' })
1033
+ if(f_sign_path){
1034
+ f_sign_path = f_sign_path.replace('http://newimg/','')
1035
+ this.printContent.push({ type: 5, url: f_sign_path, align: 'left' })
1036
+ }else{
1037
+ this.printContent.push({ type: 4, value: 2, unit: 'line' })
1038
+ }
1039
+ },
1040
+
1041
+ getDefect() {
1042
+ let showmore = false
1043
+ if (Vue.config.safecheck != undefined) {
1044
+ if (Vue.config.safecheck.ApproveConfig != undefined) {
1045
+ if (Vue.config.safecheck.ApproveConfig.showmore != undefined) {
1046
+ showmore = Vue.config.safecheck.ApproveConfig.showmore
1047
+ }
1048
+ }
1049
+ }
1050
+
1051
+ let backData = this.$parent.$parent.getAllDefect()
1052
+ // 对隐患信息进行遍历
1053
+ let res = JSON.parse(backData.f_defect_content)
1054
+ this.printContent.push({
1055
+ type: 3,
1056
+ text: '安检结果:' + res.result,
1057
+ fontsize: 2,
1058
+ isbold: false,
1059
+ align: 'left'
1060
+ })
1061
+ this.printContent.push({
1062
+ type: 3,
1063
+ text: '-------------------------------',
1064
+ fontsize: 3,
1065
+ isbold: false,
1066
+ align: 'center'
1067
+ })
1068
+
1069
+
1070
+ if (showmore) {
1071
+ //全部打印
1072
+ for (let dev in this.$parent.$parent.config) {
1073
+ for (let device in backData) {
1074
+ if (device.startsWith("device")) {
1075
+ for (let item in backData[device]) {
1076
+ //遍历结果
1077
+ if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1078
+ let error = true
1079
+ for (let i in backData[device][item].f_items) {
1080
+ if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1081
+ error = false
1082
+ }
1083
+ }
1084
+ if (error) {
1085
+ this.printContent.push({
1086
+ type: 3,
1087
+ text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':正常',
1088
+ fontsize: 2,
1089
+ isbold: false,
1090
+ align: 'left'
1091
+ })
1092
+ } else {
1093
+ this.printContent.push({
1094
+ type: 3,
1095
+ text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':有隐患',
1096
+ fontsize: 2,
1097
+ isbold: true,
1098
+ align: 'left'
1099
+ })
1100
+ }
1101
+
1102
+ for (let i in backData[device][item].f_items) {
1103
+ if (backData[device][item].f_items[i].f_item_value != '' && backData[device][item].f_items[i].f_item_value != null) {
1104
+ this.printContent.push({
1105
+ type: 3,
1106
+ text: backData[device][item].f_items[i].f_item_name + backData[device][item].f_items[i].f_item_value,
1107
+ fontsize: 2,
1108
+ isbold: false,
1109
+ align: 'left'
1110
+ })
1111
+ }
1112
+ }
1113
+ this.printContent.push({ type: 4, value: 2, unit: 'line' })
1114
+ }
1115
+ }
1116
+ }
1117
+ }
1118
+ }
1119
+
1120
+ for (let dev in this.$parent.$parent.config) {
1121
+ for (let device in backData) {
1122
+ if (device.startsWith("device")) {
1123
+ for (let item in backData[device]) {
1124
+ //遍历结果
1125
+ if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1126
+ let error = true
1127
+ for (let i in backData[device][item].f_items) {
1128
+ if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1129
+ error = false
1130
+ }
1131
+ }
1132
+ if (!error) {
1133
+ this.printContent.push({
1134
+ type: 3,
1135
+ text: '隐患:',
1136
+ fontsize: 2,
1137
+ isbold: true,
1138
+ align: 'left'
1139
+ })
1140
+ }
1141
+ }
1142
+ }
1143
+ }
1144
+ }
1145
+ for (let device in backData) {
1146
+ if (device.startsWith("device")) {
1147
+ for (let item in backData[device]) {
1148
+ if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1149
+ for (let i in backData[device][item].f_items) {
1150
+ if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1151
+ this.printContent.push({
1152
+ type: 3,
1153
+ text: backData[device][item].f_items[i].f_item_name + ' ' + backData[device][item].f_items[i].f_item_value,
1154
+ fontsize: 2,
1155
+ isbold: true,
1156
+ align: 'left'
1157
+ })
1158
+ }
1159
+ }
1160
+ }
1161
+ }
1162
+ }
1163
+ }
1164
+
1165
+ }
1166
+ } else {
1167
+ for (let dev in this.$parent.$parent.config) {
1168
+ for (let device in backData) {
1169
+ if (device.startsWith("device")) {
1170
+ for (let item in backData[device]) {
1171
+ //遍历结果
1172
+ if (backData[device].length != 0 && backData[device][item].f_device_type == dev) {
1173
+ let error = true
1174
+ for (let i in backData[device][item].f_items) {
1175
+ if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1176
+ error = false
1177
+ }
1178
+ }
1179
+ if (error) {
1180
+ this.printContent.push({
1181
+ type: 3,
1182
+ text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':正常',
1183
+ fontsize: 2,
1184
+ isbold: false,
1185
+ align: 'left'
1186
+ })
1187
+ } else {
1188
+ this.printContent.push({
1189
+ type: 3,
1190
+ text: dev + (backData[device].indexOf(backData[device][item]) + 1) + ':有隐患',
1191
+ fontsize: 2,
1192
+ isbold: false,
1193
+ align: 'left'
1194
+ })
1195
+ }
1196
+
1197
+ for (let i in backData[device][item].f_items) {
1198
+ if (backData[device][item].f_items[i].f_is_defect == true || backData[device][item].f_items[i].f_is_defect == 'true') {
1199
+ this.printContent.push({
1200
+ type: 3,
1201
+ text: '隐患:' + backData[device][item].f_items[i].f_item_name + backData[device][item].f_items[i].f_item_value,
1202
+ fontsize: 2,
1203
+ isbold: false,
1204
+ align: 'left'
1205
+ })
1206
+ }
1207
+ }
1208
+ this.printContent.push({ type: 4, value: 2, unit: 'line' })
1209
+ }
1210
+ }
1211
+ }
1212
+ }
1213
+ }
1214
+ }
1215
+ },
1216
+ //获取当前时间
1217
+ getNowFormatDate() {
1218
+ var date = new Date();
1219
+ var seperator1 = "-";
1220
+ var seperator2 = ":";
1221
+ var month = date.getMonth() + 1;
1222
+ var strDate = date.getDate();
1223
+ if (month >= 1 && month <= 9) {
1224
+ month = "0" + month;
1225
+ }
1226
+ if (strDate >= 0 && strDate <= 9) {
1227
+ strDate = "0" + strDate;
1228
+ }
1229
+ var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
1230
+ + " " + date.getHours() + seperator2 + date.getMinutes()
1231
+ + seperator2 + date.getSeconds();
1232
+ return currentdate;
1233
+ },
1234
+ readRepair() {
1235
+ let url = this.$androidUtil.getProxyUrl()
1236
+ let gen = getRepairs(this, url)
1237
+ return co(gen)
1238
+ },
1239
+ showToRepair() {
1240
+ let res = this.hasDefect()
1241
+ ////tag
1242
+ ////tag
1243
+ if (res == '正常') {
1244
+ this.showrepair = false
1245
+ } else {
1246
+ this.showrepair = true
1247
+ this.assignObj()
1248
+ }
1249
+ this.showCheckToRepair = !this.showCheckToRepair
1250
+ },
1251
+ // 选中部门
1252
+ reres(val) {
1253
+ if (val.res == undefined) {
1254
+ return
1255
+ }
1256
+ this.$parent.$parent.model.serviceacitivity[0].f_meetunit = val.res
1257
+ this.$parent.$parent.model.f_meetunit = val.res
1258
+ this.$parent.$parent.model.f_orgstr = val.resids
1259
+ var arr = val.res.split('.')
1260
+ this.$parent.$parent.model.f_outlets = arr[arr.length - 1]
1261
+ this.$parent.$parent.model.serviceacitivity[0].f_reciever = val.resids
1262
+ },
1263
+ assignObj() {
1264
+ this.$parent.$parent.model.f_contact_phone = this.paper.f_user_phone
1265
+ this.$parent.$parent.model.f_user_name = this.paper.f_user_name
1266
+ this.$parent.$parent.model.f_address = this.paper.f_address
1267
+ this.$parent.$parent.model.f_user_type = this.paper.f_check_type
1268
+ this.$parent.$parent.model.f_street = this.paper.f_street
1269
+ this.$parent.$parent.model.f_residential_area = this.paper.f_residential_area
1270
+ this.$parent.$parent.model.f_building = this.paper.f_building
1271
+ this.$parent.$parent.model.f_unit = this.paper.f_unit
1272
+ this.$parent.$parent.model.f_floor = this.paper.f_floor
1273
+ this.$parent.$parent.model.f_room = this.paper.f_room
1274
+ this.$parent.$parent.model.f_floor = this.paper.f_floor
1275
+ this.$parent.$parent.model.f_userinfo_id = this.paper.f_userinfoid
1276
+ this.$parent.$parent.model.f_userinfo_code = this.paper.f_userinfo_code
1277
+ },
1278
+ hasDefect() {
1279
+ let checkResult = '正常'
1280
+ let codata = JSON.parse(JSON.stringify(this.paper))
1281
+ for (let device in this.paper) {
1282
+ if (device.startsWith("device")) {
1283
+ for (let item in this.paper[device]) {
1284
+ for (let i in this.paper[device][item].f_items) {
1285
+ let items = this.paper[device][item].f_items[i]
1286
+ ////tag
1287
+ if (items.f_is_defect == true || items.f_is_defect == 'true') {
1288
+ checkResult = '有隐患'
1289
+ }
1290
+ }
1291
+ }
1292
+ }
1293
+ }
1294
+ return checkResult
1295
+ },
1296
+ uploadPaper() {
1297
+ if (this.showrepair) {
1298
+ ////tag
1299
+ ////tag
1300
+ ////tag
1301
+ ////tag
1302
+
1303
+ if (this.meading == '转维修员' && (this.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || this.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)) {
1304
+ this.$showMessage("请选择维修员!")
1305
+ return
1306
+ }
1307
+ if (this.$parent.$parent.meading == '转站点' && (this.$parent.$parent.model.serviceacitivity[0].f_reciever == '' || this.$parent.$parent.model.serviceacitivity[0].f_reciever == undefined)) {
1308
+ this.$showMessage("请选择站点!")
1309
+ return
1310
+ }
1311
+ if (this.$parent.$parent.model.f_repairtype == '') {
1312
+ this.$showMessage("请选择报修类型!")
1313
+ return
1314
+ }
1315
+ this.$parent.$parent.isToRepair = true
1316
+ this.$parent.$parent.uploadCheckPaper()
1317
+ // this.$parent.$parent.savePaper(false).then((res) => {
1318
+ // ////tag
1319
+ // if(res != true){
1320
+ // ////tag
1321
+ // return
1322
+ // }else{
1323
+ // this.$parent.$parent.todo()
1324
+ // }
1325
+ // })
1326
+ } else {
1327
+ this.$parent.$parent.undo()
1328
+ }
1329
+
1330
+ },
1331
+ //确认安检转维修
1332
+
1333
+ undo() {
1334
+ this.showCheckToRepair = !this.showCheckToRepair
1335
+ this.$parent.$parent.model.serviceacitivity[0].f_reciever = ''
1336
+ this.$parent.$parent.model.serviceacitivity[0].f_meetunit = ''
1337
+ this.$parent.$parent.model.f_repairtype = ''
1338
+ this.meading = '转站点'
1339
+ },
1340
+ //取消拉黑
1341
+ async deletebacklist() {
1342
+ if (!this.deletecause) {
1343
+ this.$showMessage("请填写取消拉黑原因!")
1344
+ return
1345
+ }
1346
+ this.paper.f_blocking_cause = this.deletecause
1347
+ ////tag)
1348
+ let http = new HttpResetClass()
1349
+ ////tag
1350
+ let res1 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1351
+ data: {
1352
+ items: "version",
1353
+ tablename: "t_userinfo",
1354
+ condition: "f_userinfo_id=" + this.paper.f_userinfoid,
1355
+ orderitem: "f_userinfo_id"
1356
+ }
1357
+ }, { resolveMsg: null, rejectMsg: null })
1358
+ ////tag)
1359
+ ////tag
1360
+ let res2 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/backlistOperate`, {
1361
+ data: {
1362
+ "f_operat_type": "取消拉黑",
1363
+ "f_state": "待审核",
1364
+ "f_black_state": "待审核",
1365
+ "f_remark": this.causeremarks,
1366
+ "f_user_name": this.paper.f_user_name,
1367
+ "f_comments": this.paper.f_delete_cause,
1368
+ "f_operator": Vue.user.name,
1369
+ "f_operatorid": Vue.user.id,
1370
+ "f_orgid": Vue.user.orgid,
1371
+ "f_orgname": Vue.user.orgs,
1372
+ "f_depid": Vue.user.depids,
1373
+ "f_depname": Vue.user.deps,
1374
+ "f_describe": `${Vue.user.name}对用户${this.paper.f_user_name}进行取消拉黑`,
1375
+ "f_userinfo_id": {
1376
+ "f_userinfo_id": this.paper.f_userinfoid,
1377
+ "f_user_state": "正常",
1378
+ "version": res1.data[0].version
1379
+ },
1380
+ "f_limit_times": "",
1381
+ "f_limit_value": ""
1382
+ }
1383
+ }, { resolveMsg: null, rejectMsg: null })
1384
+
1385
+ ////tag)
1386
+ if (res2.data.code == 200) {
1387
+ this.showmodelthree = false
1388
+ this.deleteenabled = true
1389
+ this.paper.f_blacklist = "否"
1390
+ this.causeremarks = ''
1391
+ this.$showMessage("取消该用户限制购气成功!")
1392
+ } else {
1393
+ this.$showMessage("网络异常,请稍后再试!")
1394
+ }
1395
+ },
1396
+ async backlist() {
1397
+ if (!this.cause) {
1398
+ this.$showMessage("请填写拉黑原因!")
1399
+ return
1400
+ }
1401
+ this.paper.f_blocking_cause = this.cause
1402
+ ////tag)
1403
+ let http = new HttpResetClass()
1404
+ ////tag
1405
+ let res1 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1406
+ data: {
1407
+ items: "version",
1408
+ tablename: "t_userinfo",
1409
+ condition: "f_userinfo_id=" + this.paper.f_userinfoid,
1410
+ orderitem: "f_userinfo_id"
1411
+ }
1412
+ }, { resolveMsg: null, rejectMsg: null })
1413
+ ////tag)
1414
+ ////tag
1415
+ let limit_times = 1
1416
+ let limit_value = 3
1417
+ if (Vue.config.safecheck && Vue.config.safecheck.ApproveConfig.limit_times && Vue.config.safecheck.ApproveConfig.limit_value) {
1418
+ limit_times = Vue.config.safecheck.ApproveConfig.limit_times
1419
+ limit_value = Vue.config.safecheck.ApproveConfig.limit_value
1420
+ }
1421
+ let res2 = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/backlistOperate`, {
1422
+ data: {
1423
+ data: this.$parent.$parent.data,
1424
+ item: this.$parent.$parent.data.item,
1425
+ "f_operat_type": "拉黑",
1426
+ "f_state": "待审核",
1427
+ "f_black_state": "待审核",
1428
+ "f_user_name": this.paper.f_user_name,
1429
+ "f_comments": this.paper.f_blocking_cause,
1430
+ "f_remark": this.causeremarks,
1431
+ "f_operator": Vue.user.name,
1432
+ "f_operate_date": Util.toStandardTimeString(),
1433
+ "f_operatorid": Vue.user.id,
1434
+ "f_orgid": Vue.user.orgid,
1435
+ "f_orgname": Vue.user.orgs,
1436
+ "f_depid": Vue.user.depids,
1437
+ "f_depname": Vue.user.deps,
1438
+ "f_describe": `${Vue.user.name}对用户${this.paper.f_user_name}进行拉黑`,
1439
+ "f_userinfo_id": {
1440
+ "f_userinfo_id": this.paper.f_userinfoid
1441
+ },
1442
+ "f_limit_times": limit_times,
1443
+ "f_limit_value": limit_value
1444
+ }
1445
+ }, { resolveMsg: null, rejectMsg: null })
1446
+
1447
+ ////tag)
1448
+ if (res2.data.code == 200) {
1449
+ this.showmodel = false
1450
+ this.enabled = true
1451
+ this.paper.f_blacklist = "是"
1452
+ this.$showMessage("将该用户限制购气成功!")
1453
+ } else if (res2.data.msg == '数据增加重复') {
1454
+ this.showmodel = false
1455
+ this.enabled = true
1456
+ this.$showMessage("该用户已被限制购气,请勿重复提交!")
1457
+ } else {
1458
+ this.$showMessage("网络异常,请稍后再试!")
1459
+ }
1460
+ },
1461
+ cancel() {
1462
+ this.backlistisselect = false
1463
+ this.showmodel = false
1464
+ },
1465
+ deletecancel() {
1466
+ this.deletebacklistisselect = false
1467
+ this.showmodelthree = false
1468
+ },
1469
+ closeshowgas() {
1470
+ this.showgas = false
1471
+ },
1472
+ repiarmancg(val) {
1473
+ if (val) {
1474
+ ////tag
1475
+ this.$parent.$parent.model.serviceacitivity[0].f_reciever = val.name
1476
+ let http1 = new HttpResetClass()
1477
+ http1.load('POST', `${this.Url}/rs/sql/tel_singleTable_OrderBy`, {
1478
+ data: {
1479
+ items: 'f_user_telephone',
1480
+ tablename: 't_user',
1481
+ condition: `name = '${val}'`,
1482
+ orderitem: 'id'
1483
+ }
1484
+ }, { resolveMsg: null, rejectMsg: null }).then((ress) => {
1485
+ this.$parent.$parent.model.f_repairman_phone = ress.data[0].f_user_telephone
1486
+ })
1487
+ }
1488
+ },
1489
+ },
1490
+ async ready() {
1491
+ let state = HostApp.getBluetoothState()
1492
+ if (state && state.state == 3){
1493
+ this.blueState = '连接完成'
1494
+ }else {
1495
+ this.blueState = '连接失败,请重试'
1496
+ }
1497
+ this.isRecodr = this.$appdata.getSingleValue('无限制录音')
1498
+ if (this.$appdata.getSingleValue('安检时显示拉黑')) {
1499
+ this.showbacklist = this.$appdata.getSingleValue('安检时显示拉黑');
1500
+ }
1501
+ if (Vue.config.safecheck != undefined) {
1502
+ if (Vue.config.safecheck.ApproveConfig != undefined) {
1503
+ if (Vue.config.safecheck.ApproveConfig.gasinstructions != undefined) {
1504
+ this.gasinstructions = Vue.config.safecheck.ApproveConfig.gasinstructions
1505
+ }
1506
+ if (Vue.config.safecheck.ApproveConfig.setgasinstructions != undefined) {
1507
+ this.setgasinstructions = Vue.config.safecheck.ApproveConfig.setgasinstructions
1508
+ }
1509
+ }
1510
+ }
1511
+ // await this.isoverDate()
1512
+ ////tag
1513
+ ////tag
1514
+ ////tag)
1515
+ ////tag))
1516
+ if (this.$parent.$parent.role == 'repair') {
1517
+ this.$set('style__', 'divmask')
1518
+ this.$set('style_view_', '')
1519
+ } else if (this.$parent.$parent.role == 'view' || this.$parent.$parent.item.f_upload_state == '已传') {
1520
+ this.$set('style__', 'divmask')
1521
+ this.$set('style_view_', 'divmask')
1522
+ ////tag
1523
+ } else {
1524
+ this.$set('style__', '')
1525
+ this.$set('style_view_', '')
1526
+ }
1527
+
1528
+ for (let item of this.radios) {
1529
+ if (this.paper.f_client_evaluation == item.label) {
1530
+ item.isChecked = true;
1531
+ }
1532
+ }
1533
+ if (!this.paper.f_notified_path)
1534
+ this.$set('paper.f_notified_path', Vue.nopic)
1535
+ if (!this.paper.f_sign_path)
1536
+ this.$set('paper.f_sign_path', Vue.nopic)
1537
+ ////tag
1538
+ if (!this.paper.f_overall_imgs) {
1539
+ let imgs = []
1540
+ // imgs.push({f_overall_path:Vue.nopic})
1541
+ this.$set('paper.f_overall_imgs', imgs)
1542
+ ////tag
1543
+ }
1544
+ if (!this.paper.f_overall2_path)
1545
+ this.$set('paper.f_overall2_path', Vue.nopic)
1546
+
1547
+ this.userid = this.role == 'view' ? this.$login.f.id : Vue.user.id
1548
+ if (Vue.config.safecheck != undefined) {
1549
+ if (Vue.config.safecheck.ApproveConfig != undefined) {
1550
+ if (Vue.config.safecheck.ApproveConfig.safeCheckToRepair != undefined) {
1551
+ this.safeCheckToRepair = Vue.config.safecheck.ApproveConfig.safeCheckToRepair
1552
+ }
1553
+ }
1554
+ }
1555
+ let device = this.$parent.$parent.data
1556
+ for (const deviceitem in device) {
1557
+ if (deviceitem.startsWith('device')) {
1558
+ //tag)
1559
+ if (device[deviceitem].length == 0) {
1560
+ continue
1561
+ }
1562
+ let items = device[deviceitem][0].f_items
1563
+ let deviceType = device[deviceitem][0].f_device_type
1564
+ for (let i = 0; i < items.length; i++) {
1565
+ if (items[i].f_is_defect) {
1566
+ let reason = items[i].f_item_name + ":"
1567
+ if (items[i].type === 'selector' || items[i].type === 'radio' || items[i].type === 'checkbox') {
1568
+ for (let j = 0; j < items[i].f_item_value.length; j++) {
1569
+ if (j + 1 === items[i].f_item_value.length) {
1570
+ reason += items[i].f_item_value[j]
1571
+ } else {
1572
+ reason += items[i].f_item_value[j] + ","
1573
+ }
1574
+ }
1575
+ } else {
1576
+ reason += items[i].f_item_value
1577
+ }
1578
+ if (items[i].f_path) {
1579
+ this.defectImgs.push(items[i].f_path)
1580
+ }
1581
+ if (items[i].f_p1_path) {
1582
+ this.defectImgs.push(items[i].f_p1_path)
1583
+ }
1584
+ if (items[i].f_p2_path) {
1585
+ this.defectImgs.push(items[i].f_p2_path)
1586
+ }
1587
+ if (items[i].f_p3_path) {
1588
+ this.defectImgs.push(items[i].f_p3_path)
1589
+ }
1590
+ if (items[i].tooltip) {
1591
+ this.defectToolTip.push(items[i].tooltip)
1592
+ }
1593
+ this.defectReason.push({ device: deviceType, deviceitem: reason })
1594
+ } else if (items[i].type === 'errorstring' && items[i].f_item_value) {
1595
+ let reason = items[i].f_item_name + ":" + items[i].f_item_value
1596
+ this.defectReason.push({ device: deviceType, deviceitem: reason })
1597
+ }
1598
+
1599
+ }
1600
+ }
1601
+ }
1602
+ ////tag
1603
+ ////tag
1604
+ //tag
1605
+ ////tag
1606
+ //tag)
1607
+ //tag)
1608
+ //tag)
1609
+ ////tag
1610
+ ////tag
1611
+ ////tag
1612
+ },
1613
+ watch: {
1614
+ '$parent.$parent.isUpload'(val) {
1615
+ ////tag
1616
+ },
1617
+ 'meading'(val) {
1618
+ ////tag
1619
+ this.$parent.$parent.meading = val
1620
+ },
1621
+ 'backlistisselect'(val) {
1622
+ if (val == true) {
1623
+ this.showmodel = true
1624
+ this.deletebacklistisselect = false
1625
+ }
1626
+ },
1627
+ 'deletebacklistisselect'(val) {
1628
+ if (val == true) {
1629
+ this.showmodelthree = true
1630
+ this.backlistisselect = false
1631
+ }
1632
+ },
1633
+ 'isRecodr'(val) {
1634
+ if (val == 'false' || val == undefined || val == null || val == '' || val == 'undefined') {
1635
+ this.isRecodr = "false";
1636
+ }
1637
+ },
1638
+ 'paper.f_read_instructions'(val) {
1639
+ if (val == true) {
1640
+ this.showgas = true
1641
+ }
1642
+ }
1643
+ }
1644
+ }
1645
+ </script>
1646
+ <style scoped>
1647
+ .panel-self {
1648
+ border-radius: 5px;
1649
+ border: 1px solid #c5e1f7;
1650
+ background-color: #F2F6FA;
1651
+ }
1652
+
1653
+ .text-left {
1654
+ text-align: left;
1655
+ }
1656
+
1657
+ .font {
1658
+ font: 15px PingFang-SC-Medium;
1659
+ color: #333333;
1660
+ }
1661
+
1662
+ .showIi {
1663
+ font: 14px PingFang-SC-Medium;
1664
+ color: #666666;
1665
+ }
1666
+
1667
+ .info {
1668
+ margin-top: 15px;
1669
+ border-radius: 5px;
1670
+ background-color: #f3faff;
1671
+ }
1672
+
1673
+ .btn-photo {
1674
+ border: 0;
1675
+ border-radius: 7px;
1676
+ background-color: #7dc1f4;
1677
+ font: 15px PingFang-SC-Bold;
1678
+ height: 20%;
1679
+ }
1680
+
1681
+ .div-photo {
1682
+ width: auto;
1683
+ height: auto;
1684
+ /* margin-top: 10px; */
1685
+ position: absolute;
1686
+ bottom: 10px;
1687
+ right: 10px;
1688
+ }
1689
+
1690
+ .btn-voice {
1691
+ border-radius: 7px;
1692
+ border: 1px solid #dedede;
1693
+ background-color: #f5fbff;
1694
+ font: 15px PingFang-SC-Bold;
1695
+ color: #499edf;
1696
+ }
1697
+
1698
+ .save-btn {
1699
+ width: 25%;
1700
+ background-color: #499edf;
1701
+ border-radius: 6px;
1702
+ color: #FFFFFF;
1703
+ font: 15px PingFang-SC-Bold;
1704
+ }
1705
+
1706
+ .upload-btn {
1707
+ width: 25%;
1708
+ background-color: #ffffff;
1709
+ border: 1px solid #499edf;
1710
+ border-radius: 6px;
1711
+ color: #499edf;
1712
+ font: 15px PingFang-SC-Bold;
1713
+ }
1714
+
1715
+ .repair-btn {
1716
+ width: 25%;
1717
+ border: 1px solid #499edf;
1718
+ border-radius: 6px;
1719
+ font: 15px PingFang-SC-Bold;
1720
+ }
1721
+
1722
+ #el_ca_tx {
1723
+ width: 100%;
1724
+ margin: 5px;
1725
+ }
1726
+
1727
+ #el_ca_txt {
1728
+ width: 100%;
1729
+ margin: 5px;
1730
+ }
1731
+ </style>