safecheck-client 3.0.35-42 → 3.0.35-44

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,1479 +1,1479 @@
1
- <style scoped>
2
- .img {
3
- border: 1px solid #9773ed;
4
- width: auto;
5
- height: auto;
6
- float: left;
7
- text-align: center;
8
- margin: 6px;
9
- }
10
-
11
- img {
12
- margin: 6px;
13
- }
14
-
15
-
16
- .container {
17
- margin: 10px auto;
18
- width: 80%;
19
- height: auto;
20
- }
21
-
22
- div::-webkit-scrollbar {
23
- width: 0 !important;
24
- height: 0 !important;
25
- }
26
-
27
- div {
28
- -ms-overflow-style: none;
29
- overflow: -moz-scrollbars-none;
30
- }
31
-
32
- .divmask {
33
- pointer-events: none;
34
- }
35
-
36
- .app-header {
37
- border-radius: 50%;
38
- background: rgba(73, 158, 223, 0.4);
39
- color: #FFF;
40
- padding: 20px;
41
- text-align: center;
42
- font-size: 1.2em;
43
- z-index: 10;
44
- opacity: 0.5;
45
- bottom: 50px;
46
- margin-top: -20px;
47
- position: absolute;
48
- top: 10%;
49
- right: 2%;
50
- height: 8%;
51
- }
52
- </style>
53
-
54
- <template>
55
- <div class="basic-main" style="height: 100%">
56
- <div class="page-header app-header auto" style="padding: 15px;margin-right: 10px;right: 0%;height: 7%">
57
- <div @click="back()">
58
- <img src="../../../assets/back.png" style="margin: 0px"/>
59
- </div>
60
- </div>
61
- <work-busy :is-busy="loading"></work-busy>
62
- <div class="container-fluid" style="overflow: scroll">
63
- <div class="row">
64
- <div class="col-md-5" style="margin-right: 2%;margin-left: 2%;height: 100%;overflow: scroll">
65
- <div style="width: 100%;margin: auto">
66
- <table class="table table-striped table-bordered" style="margin-bottom: 6px">
67
- <thead>
68
- <tr>
69
- <th colspan="6" style="text-align: center">用户基本信息</th>
70
- </tr>
71
- </thead>
72
- <tbody>
73
- <tr>
74
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户编号:</td>
75
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_userinfo_code }}</td>
76
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户名称:</td>
77
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_user_name }}</td>
78
- </tr>
79
- <tr>
80
- <td style="text-align: center;border: #E9E9E9 solid 1px">证件号码:</td>
81
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_idnumber }}</td>
82
- <td style="text-align: center;border: #E9E9E9 solid 1px">用户类型:</td>
83
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_check_type }}</td>
84
- </tr>
85
- <tr>
86
- <td style="text-align: center;border: #E9E9E9 solid 1px">用户电话:</td>
87
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_user_phone }}</td>
88
- <td style="text-align: center;border: #E9E9E9 solid 1px">区 / 县:</td>
89
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_area }}</td>
90
- </tr>
91
- <tr>
92
- <td style="text-align: center;border: #E9E9E9 solid 1px">街 道:</td>
93
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_street }}</td>
94
- <td style="text-align: center;border: #E9E9E9 solid 1px">楼 号:</td>
95
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_building }}</td>
96
- </tr>
97
- <tr>
98
- <td style="text-align: center;border: #E9E9E9 solid 1px">单 元:</td>
99
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_unit }}</td>
100
- <td style="text-align: center;border: #E9E9E9 solid 1px">楼 层:</td>
101
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_floor }}</td>
102
- </tr>
103
- <tr>
104
- <td style="text-align: center;border: #E9E9E9 solid 1px">门 牌 号 :</td>
105
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_room }}</td>
106
- <td style="text-align: center;border: #E9E9E9 solid 1px">用户性质:</td>
107
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_userproperties }}</td>
108
- </tr>
109
- <tr>
110
- <td style="text-align: center;border: #E9E9E9 solid 1px">备注信息:</td>
111
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_comments }}</td>
112
- <td style="text-align: center;border: #E9E9E9 solid 1px">小区名称:</td>
113
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_residential_area }}</td>
114
- </tr>
115
- <tr>
116
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px">详细住址:</td>
117
- <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_address }}</td>
118
- </tr>
119
- </tbody>
120
- </table>
121
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
122
- <thead>
123
- <tr>
124
- <th colspan="4" style="text-align: center">用户安检概况</th>
125
- </tr>
126
- </thead>
127
- <tbody>
128
- <tr>
129
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
130
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
131
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
132
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
133
- </tr>
134
- <tr>
135
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
136
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_entry_status }}</td>
137
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">燃气使用:</td>
138
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_usegas }}</td>
139
- </tr>
140
- <tr>
141
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">用户满意度:</td>
142
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{
143
- paperdata.f_client_evaluation
144
- }}
145
- </td>
146
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">安检结果:</td>
147
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{ ajresult }}</td>
148
- </tr>
149
- <tr>
150
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">安检员:</td>
151
- <td colspan="3"
152
- style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
153
- {{ paperdata.f_checker_name }}
154
- </td>
155
- </tr>
156
- <tr>
157
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">备注:</td>
158
- <td colspan="3"
159
- style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
160
- {{ paperdata.f_repair_approved_note }}
161
- </td>
162
- </tr>
163
- <tr>
164
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">隐患详情:</td>
165
- <td colspan="3"
166
- style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
167
- <span v-for="deviceCollect in deviceCollects">
168
- <span class="li-font">
169
- {{ deviceCollect.name }}:{{ deviceCollect.value }}&nbsp;&nbsp;&nbsp;
170
- </span>
171
- <br>
172
- <span v-if="deviceCollect.value == '有隐患'">
173
- <lable>
174
- 隐患:
175
- </lable>
176
- <span class="li-font" v-for="val in deviceCollect.devices">
177
- {{ val }}&nbsp;&nbsp;&nbsp;
178
- </span><br>
179
- </span>
180
-
181
- </span>
182
- </td>
183
- </tr>
184
-
185
- </tbody>
186
- </table>
187
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status!='入户'">
188
- <thead>
189
- <tr>
190
- <th colspan="4" style="text-align: center">用户安检概况</th>
191
- </tr>
192
- </thead>
193
- <tbody>
194
- <tr>
195
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
196
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
197
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
198
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
199
- </tr>
200
- <tr>
201
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
202
- <td colspan="2" style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">
203
- {{ paperdata.f_entry_status }}
204
- </td>
205
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">
206
- <button-link style="color: black" type="button" class="btn btn-link" @click="showpicture2()">
207
- {{ dev.lname }}
208
- 查看{{ data.f_entry_status }}照片
209
- </button-link>
210
- </td>
211
- </tr>
212
-
213
- </tbody>
214
- </table>
215
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
216
- <thead>
217
- <tr>
218
- <th style="text-align: center">总体安检照片</th>
219
- </tr>
220
- </thead>
221
- <tbody>
222
- <tr>
223
- <td style="margin: auto;text-align: center">
224
- <div class="container" style="max-width: 550px;background: #FFFFFF">
225
- <div class="img" v-for="img in paperdata.f_overall_imgs">
226
- <img-self-safe :src="img.f_overall_path" style="float: left" width="150"
227
- height="200"></img-self-safe>
228
- </div>
229
- </div>
230
-
231
-
232
- </td>
233
-
234
- </tr>
235
- </tbody>
236
- </table>
237
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
238
- <thead>
239
- <tr>
240
- <th style="text-align: center">用户签名照片</th>
241
- </tr>
242
- </thead>
243
- <tbody>
244
- <tr>
245
- <td style="margin: auto;text-align: center">
246
- <div class="container" style="max-width: 500px;background: #FFFFFF">
247
- <div class="img" style="float: none">
248
- <img-self-safe :src="paperdata.f_sign_path" width="486" height="300"></img-self-safe>
249
- </div>
250
- </div>
251
- </td>
252
- </tr>
253
- </tbody>
254
- </table>
255
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户' && paperdata.f_defect_notified">
256
- <thead>
257
- <tr>
258
- <th style="text-align: center">安检通知书/隐患整改通知书</th>
259
- </tr>
260
- </thead>
261
- <tbody>
262
- <tr>
263
- <td style="margin: auto;text-align: center">
264
- <div class="container" style="max-width: 500px;background: #FFFFFF">
265
- <div class="img" style="float: none">
266
- <img-self-safe :src="paperdata.f_notified_path" width="486" height="300"></img-self-safe>
267
- </div>
268
- </div>
269
- </td>
270
- </tr>
271
- </tbody>
272
- </table>
273
- <table class="table table-striped table-bordered" v-show="item.f_recording1_path && isRecodrDownloadBtn">
274
- <thead>
275
- <tr>
276
- <th style="text-align: center">录音文件</th>
277
- </tr>
278
- </thead>
279
- <tbody>
280
- <tr>
281
- <td style="margin: auto;text-align: center">
282
- <div class="container" style="max-width: 500px; background: #FFFFFF;margin-bottom: 20px">
283
- <div id='item.id' ref="dp" style="height: 10vh; width:20vw ;margin-bottom:50px"></div>
284
- </div>
285
- <a class="button_spacing button_search-1" :download="item.f_user_name+'-'+item.f_check_type+'-'+录音文件.arm"
286
- :href="'rs/image/file/'+item.f_recording1_path" >录音下载</a>
287
- <button class="button_spacing button_search-1" type="button" @click="getbaseYin()">播放录音</button>
288
- <button class="button_spacing button_search-1" type="button" @click="stop()">停止播放</button>
289
- </td>
290
- </tr>
291
- </tbody>
292
- </table>
293
- <table class="table table-striped table-bordered" v-show="item.f_select_record_path && isRecodrDownloadBtn">
294
- <thead>
295
- <tr>
296
- <th style="text-align: center">录音文件</th>
297
- </tr>
298
- </thead>
299
- <tbody>
300
- <tr>
301
- <td style="margin: auto;text-align: center">
302
- <div class="container" style="max-width: 500px; background: #FFFFFF;margin-bottom: 20px">
303
- <div id='item.id' ref="dp" style="height: 10vh; width:20vw ;margin-bottom:50px"></div>
304
- </div>
305
- <a class="button_spacing button_search-1" :download="item.f_user_name+'-'+item.f_check_type+'-'+'录音文件.arm'"
306
- :href="'rs/image/file/'+item.f_select_record_path" >录音下载</a>
307
- <!-- <button class="button_spacing button_search-1" type="button" @click="getbaseYin()">播放录音</button>-->
308
- <!-- <button class="button_spacing button_search-1" type="button" @click="stop()">停止播放</button>-->
309
- </td>
310
- </tr>
311
- </tbody>
312
- </table>
313
- </div>
314
- </div>
315
- <div class style="width: 1%;height: 100%;background-color: #F1F8FF;float: left;"></div>
316
- <div class="col-md-6" style="height: 100%;overflow: scroll">
317
- <div style="width: 95%;margin-left: 5%">
318
- <table class="table table-striped table-bordered" v-for="config in deviceconfig2">
319
- <thead v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
320
- <tr>
321
- <th style="text-align: center">{{ config.checkname }}</th>
322
- </tr>
323
- </thead>
324
- <tbody v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
325
- <tr v-for="dev in config.items">
326
- <td v-if="dev.type!='text'">
327
- <div class="row">
328
- <div class="col-md-8" style="text-align: center;">
329
- <label>
330
- <button-link type="button" class="btn btn-link" @click="showpicture(config.checkname,dev.lname)"
331
- :style="isred(config.checkname,dev.lname)?'color:red':'color:black'">
332
- {{ dev.lname }}
333
- </button-link>
334
- </label>
335
- </div>
336
- <div class="col-md-4" style="text-align: center">
337
- <label style="font-weight: normal"
338
- v-if="dev.type!='picture'">{{ getDeviceValue(config.checkname, dev.lname) ? getDeviceValue(config.checkname, dev.lname) : '无' }}</label>
339
- <label style="font-weight: normal" v-if="dev.type=='picture'">
340
- <div v-show="getDevicePath(config.checkname,dev.lname)">
341
- <button-link style="color: black" type="button" class="btn btn-link"
342
- @click="showpath(getDevicePath(config.checkname,dev.lname),dev.lname)">查看照片
343
- </button-link>
344
- </div>
345
- <div v-show="!getDevicePath(config.checkname,dev.lname)">无照片</div>
346
- </label>
347
- </div>
348
- </div>
349
- </td>
350
- <td v-if="dev.type==='text'">
351
- <label style="width: 100%;text-align: center">{{ dev.lname }}</label>
352
- </td>
353
- </tr>
354
- </tbody>
355
- </table>
356
- </div>
357
- </div>
358
-
359
- </div>
360
- </div>
361
- </div>
362
- <modal :show.sync="imgshow" v-ref:modal backdrop="true">
363
- <header slot="modal-header" class="modal-header">
364
- {{ picturename }}
365
- </header>
366
- <article slot="modal-body" class="modal-body">
367
- <div class="from-group">
368
- <div class="row">
369
- <div class="col-md-6">
370
- <img-self-safe v-if="showimg1" :src="showimg1" width="240" height="300"></img-self-safe>
371
- </div>
372
- <div class="col-md-6">
373
- <img-self-safe v-if="showimg2" :src="showimg2" width="240" height="300"></img-self-safe>
374
- </div>
375
- <div class="col-md-6" v-for="item in otherDarginShowImgs">
376
- <img-self-safe v-if="item.path" :src="item.path" width="240" height="300"></img-self-safe>
377
- </div>
378
- </div>
379
- </div>
380
- </article>
381
- <footer slot="modal-footer" class="modal-footer" v-show="false">
382
- <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
383
- </footer>
384
- </modal>
385
- <modal :show.sync="imgshow2" v-ref:modal backdrop="true">
386
- <header slot="modal-header" class="modal-header">
387
- {{ paperdata.f_entry_status }}照片
388
- </header>
389
- <article slot="modal-body" class="modal-body">
390
- <div class="from-group">
391
- <div class="row">
392
- <div class="col-md-6">
393
- <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer_path" :src="showimg3" width="282"
394
- height="400"></img-self-safe>
395
- </div>
396
- <div class="col-md-6">
397
- <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer1_path" :src="showimg5" width="282"
398
- height="400"></img-self-safe>
399
- </div>
400
- <div class="col-md-6">
401
- <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer2_path" :src="showimg6" width="282"
402
- height="400"></img-self-safe>
403
- </div>
404
- <div class="col-md-6">
405
- <img-self-safe v-if="this.paperdata.f_entry_status=='拒检' && this.paperdata.f_rejectcheck_path" :src="showimg4" width="282"
406
- height="400"></img-self-safe>
407
- </div>
408
- <div class="col-md-6">
409
- <img-self-safe v-if="this.paperdata.f_entry_status=='拒检' && this.paperdata.f_rejectcheck1_path" :src="showimg7" width="282"
410
- height="400"></img-self-safe>
411
- </div>
412
- <div class="col-md-6">
413
- <img-self-safe v-if="this.paperdata.f_entry_status=='拒检' && this.paperdata.f_rejectcheck2_path" :src="showimg8" width="282"
414
- height="400"></img-self-safe>
415
- </div>
416
- </div>
417
- </div>
418
- </article>
419
- <footer slot="modal-footer" class="modal-footer" v-show="false">
420
- <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
421
- </footer>
422
- </modal>
423
- </template>
424
-
425
- <script>
426
- // import PaperUserm from './PaperUserm'
427
- // import PaperStatem from './PaperStatem'
428
- // import Devicesm from './Devicesm'
429
- // import PaperFeedbackm from './PaperFeedbackm'
430
- import ObjConfig from '../../../utils/GerJsonObjectConfig'
431
- import RadioGroup from 'vue-client/src/vue-strap/src/radioGroup'
432
- import Radio from 'vue-client/src/vue-strap/src/radioBtn'
433
- import Vue from 'vue'
434
- import * as Util from '../../Util'
435
- import {jsonSort} from '../../../utils/LdapHelper'
436
- import {HttpResetClass} from "vue-client";
437
- import WaveSurfer from 'wavesurfer.js'
438
- let asyncReady = async function (self) {
439
- // 获取配置信息
440
- try {
441
- let res = await new HttpResetClass().load('post', 'rs/sql/tel_singleTable_OrderBy', {
442
- data: {
443
- items: 'f_dir',
444
- tablename: 't_organization',
445
- condition: `id = '${self.item.f_filialeid}'`,
446
- orderitem: 'id'
447
- }
448
- })/*.then(res=>{*/
449
- //tag
450
- //tag)
451
- if (!res.data[0].f_dir) {
452
- self.$showMessage("该公司无组织目录,无法获取配置文件,请联系管理员确认")
453
- } else {
454
- //this.f_dir=res.data[0].f_dir
455
- try {
456
- let res1 = await new HttpResetClass().load('GET', `/safecheck/rs/vue/DevicesConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {}, {
457
- resolveMsg: '获取居民配置项成功!',
458
- rejectMsg: '获取居民配置项出错!'
459
- })/*.then(res=>{*/
460
- //tag
461
- //this.safeConfig["民用配置项"]=Object.assign({},res.data)
462
- Vue.config.safecheck.DevicesConfig = res1.data
463
- /*})*/
464
- let res2 = await new HttpResetClass().load('GET', `/safecheck/rs/vue/DevicesSetConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {}, {
465
- resolveMsg: '获取非居民配置项成功!',
466
- rejectMsg: '获取非居民配置项出错!'
467
- })/*.then(res=>{*/
468
- //tag
469
- //this.safeConfig["非民用配置项"]=Object.assign({},res.data)
470
- Vue.config.safecheck.DevicesSetConfig = res2.data
471
- /*}).then(res=> {
472
- })*/
473
-
474
- } catch (e) {
475
- self.$showMessage("获取配置文件失败" + e)
476
- }
477
- }
478
- } catch (error) {
479
- // 忽略704,文件找不到异常R
480
- if (error.status !== 704) {
481
- throw error
482
- }
483
- }
484
- }
485
- export default {
486
- title: '安检单',
487
- props: ['f_plan_id', 'item', 'role'],
488
- data() {
489
- return {
490
- wave:null,
491
- data: {
492
- f_devices: [],
493
- f_defect_content: '',
494
- },
495
- wavesurfer: null,
496
- options: {
497
- waveColor: '#1E90FF',
498
- progressColor: '#00FFFF',
499
- cursorColor: '#000000',
500
- barWidth: 3,
501
- hideScrollbar: true,
502
- height: 200,
503
- normalize: true
504
- },
505
- paperdata: {},
506
- picturename: '隐患照片',
507
- defectDevice: {},
508
- hasDevice: false,
509
- deviceCollect: {},
510
- deviceCollects: [],
511
- isshow: false,
512
- ajresult: '',
513
- loading: true,
514
- imgshow: false,
515
- imgshow2: false,
516
- isUpload: false,
517
- livedispose: '',
518
- showimg1: '',
519
- showimg2: '',
520
- showimg3: '',
521
- showimg4: '',
522
- showimg5: '',
523
- showimg6: '',
524
- showimg7: '',
525
- showimg8: '',
526
- hiddenDangerImgNumber: 0, //配置项中隐患照片数
527
- otherDarginShowImgs: [],//其他隐患图片
528
- startClick: false, //开始安检按钮是否可点击
529
- isStrat: false, //是否开始安检
530
- checkResult: {},//查询结果
531
- newcheckResult: {},
532
- timer: null,
533
- showModal: false,
534
- pic_to_be_viewed: '',
535
- showBack: true,
536
- devices: [],
537
- devicesAll: [],
538
- configAJ: [],
539
- configRQ: [],
540
- deviceconfig: {},
541
- deviceconfig2: [],
542
- f_devices: [],
543
- config: {
544
- "燃气表": {
545
- "checkmust": true,
546
- "index": 1,
547
- "items": {
548
- "气表品牌":{"index":1,"type":"string","readonly":true},
549
- "气表型号":{"index":2,"type":"string","readonly":true},
550
- "气表编号":{"index":3,"type":"string","readonly":true},
551
- "气表封号":{"index":4,"type":"string","readonly": true},
552
- "进气方向":{"index":5,"type":"string","readonly":true},
553
- "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true},
554
- "气表累购":{"index":7,"type":"number","readonly":true}, //卡
555
- "金额累购":{"index":7,"type":"number","readonly":true}, //卡
556
- "已用气量":{"index":8,"type":"number","checkmust": false},//基表数卡
557
- "已用金额":{"index":8,"type":"number","checkmust": false},//基表数卡
558
- "剩余气量":{"index":9,"type":"number","checkmust": false},//累购-已用
559
- "系统金额":{"index":9,"type":"number","checkmust": false},
560
- "表内剩余":{"index":10,"type":"number","readonly":false},
561
- "气量异常差值":{"index":11,"type":"number","readonly": true},
562
- "金额异常差值":{"index":11,"type":"number","readonly": true},
563
- "上次基数":{"index":12,"type":"number","readonly":true},
564
- "本次基数":{"index":13,"type":"number","readonly":false},
565
- "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
566
- }
567
- // 注意,配置项的index必须与上面的固定配置保持'顺序'
568
- }
569
- },
570
- //金额
571
- config2: {
572
- "燃气表": {
573
- "checkmust": true,
574
- "index": 1,
575
- "items": {
576
- "气表品牌":{"index":1,"type":"string","readonly":true},
577
- "气表型号":{"index":2,"type":"string","readonly":true},
578
- "气表编号":{"index":3,"type":"string","readonly":true},
579
- "气表封号":{"index":4,"type":"string","readonly": true},
580
- "进气方向":{"index":5,"type":"string","readonly":true},
581
- "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true},
582
- "气表累购":{"index":7,"type":"number","readonly":true}, //卡
583
- // "金额累购":{"index":7,"type":"number","readonly":true}, //卡
584
- "已用气量":{"index":8,"type":"number","checkmust": false},//基表数卡
585
- // "已用金额":{"index":8,"type":"number","checkmust": false},//基表数卡
586
- // "剩余气量":{"index":9,"type":"number","checkmust": false},//累购-已用
587
- // "系统金额":{"index":9,"type":"number","checkmust": false},
588
- "表内剩余":{"index":10,"type":"number","readonly":false},
589
- "气量异常差值":{"index":11,"type":"number","readonly": true},
590
- // "金额异常差值":{"index":11,"type":"number","readonly": true},
591
- "上次基数":{"index":12,"type":"number","readonly":true},
592
- "本次基数":{"index":13,"type":"number","readonly":false},
593
- "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
594
- }
595
- }
596
- },
597
- config3: {
598
- "燃气表": {
599
- "checkmust": true,
600
- "index": 1,
601
- "items": {
602
- "气表品牌":{"index":1,"type":"string","readonly":true},
603
- "气表型号":{"index":2,"type":"string","readonly":true},
604
- "气表编号":{"index":3,"type":"string","readonly":true},
605
- "气表封号":{"index":4,"type":"string","readonly": true},
606
- "进气方向":{"index":5,"type":"string","readonly":true},
607
- // "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true,"isshow":false},
608
- // "气表累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
609
- // "金额累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
610
- // "已用气量":{"index":8,"type":"number","checkmust": false,"isshow":false },//基表数卡
611
- // "已用金额":{"index":8,"type":"number","checkmust": false,"isshow":false},//基表数卡
612
- // "剩余气量":{"index":9,"type":"number","checkmust": false,"isshow":false},//累购-已用
613
- "系统金额":{"index":9,"type":"number","checkmust": false},
614
- "表内剩余":{"index":10,"type":"number","readonly":false},
615
- // "气量异常差值":{"index":11,"type":"number","readonly": true,"isshow":false},
616
- "金额异常差值":{"index":11,"type":"number","readonly": true},
617
- "上次基数":{"index":12,"type":"number","readonly":true},
618
- "本次基数":{"index":13,"type":"number","readonly":false},
619
- "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
620
- }
621
- }
622
- },
623
- config4: {
624
- "燃气表": {
625
- "checkmust": true,
626
- "index": 1,
627
- "items": {
628
- "气表品牌":{"index":1,"type":"string","readonly":true},
629
- "气表型号":{"index":2,"type":"string","readonly":true},
630
- "气表编号":{"index":3,"type":"string","readonly":true},
631
- "气表封号":{"index":4,"type":"string","readonly": true},
632
- "进气方向":{"index":5,"type":"string","readonly":true},
633
- // "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true,"isshow":false},
634
- // "气表累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
635
- // "金额累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
636
- // "已用气量":{"index":8,"type":"number","checkmust": false,"isshow":false },//基表数卡
637
- // "已用金额":{"index":8,"type":"number","checkmust": false,"isshow":false},//基表数卡
638
- // "剩余气量":{"index":9,"type":"number","checkmust": false,"isshow":false},//累购-已用
639
- // "系统金额":{"index":9,"type":"number","checkmust": false},
640
- "表内剩余":{"index":10,"type":"number","readonly":false},
641
- // "气量异常差值":{"index":11,"type":"number","readonly": true,"isshow":false},
642
- // "金额异常差值":{"index":11,"type":"number","readonly": true},
643
- "上次基数":{"index":12,"type":"number","readonly":true},
644
- "本次基数":{"index":13,"type":"number","readonly":false},
645
- "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
646
- }
647
- }
648
- },
649
- }
650
- },
651
- components: {
652
- RadioGroup,
653
- Radio,
654
- },
655
- computed: {
656
- isRecodrDownloadBtn(){
657
- // 投诉单下派还是处理
658
- let res = this.$appdata.getSingleValue('无限制录音');
659
- if (res == 'true'){
660
- return true;
661
- }else {
662
- return false;
663
- }
664
- },
665
- selector: {
666
- get() {
667
- return 'paper-state'
668
- },
669
- set(val) {
670
- if (this.isStrat) {
671
- //;
672
- this.$goto(val, {userinfo: this.data}, 'paper-router')
673
- } else {
674
- this.$showMessage('未开始安检!')
675
- }
676
- }
677
- },
678
- actionEnabled: {
679
- get() {
680
- return this.role == 'inspect'
681
- }
682
- }
683
- },
684
- methods: {
685
- async getbaseYin() {
686
- this.wave.playPause()
687
- },
688
- stop(){
689
- this.wave.stop()
690
- },
691
-
692
- devicesCollect() {
693
- //tag
694
- //tag)
695
- //tag)
696
- //tag
697
-
698
- this.deviceCollects = []
699
- let checkResult = '正常'
700
- this.result = '正常'
701
- let codata = JSON.parse(JSON.stringify(this.data))
702
- //tag)
703
- for (let device in this.data) {
704
- let f_device_type
705
- if (device.startsWith("device")) {
706
- for (let item in this.data[device]) {
707
- if (this.data[device].length > 1) {
708
- let j = Number.parseInt(item) + 1
709
- f_device_type = `${this.data[device][item].f_device_type}${j}`
710
- } else {
711
- f_device_type = this.data[device][item].f_device_type
712
- }
713
- // //tag
714
- let deviceInfos = []
715
- for (let i in this.data[device][item].f_items) {
716
- let defects = ''
717
- let items = this.data[device][item].f_items[i]
718
- if ((items.type === 'selector' || items.type === 'radio' || items.type === 'checkbox') && items.f_item_value != null && items.f_item_value instanceof Array) {
719
- for (let i in items.f_item_value) {
720
- let f_item_value = items.f_item_value[i]
721
-
722
- //tag)
723
- //tag)
724
- //tag)
725
- //tag)
726
- if (!this.config[this.data[device][item].f_device_type].items[items.f_item_name]) {
727
- continue
728
- }
729
- let options = this.config[this.data[device][item].f_device_type].items[items.f_item_name].options
730
- for (let option in options) {
731
- if (options[option].data == f_item_value) {
732
- if (options[option].isdefect == 'true' || options[option].isdefect == true) {
733
- checkResult = '有隐患'
734
- this.result = '有隐患'
735
- defects = `${defects}:${options[option].data}/`
736
- // let level = options[option].level
737
- }
738
- }
739
- }
740
- //tag)
741
- }
742
- if (defects != '') {
743
- deviceInfos.push(`${items.f_item_name}${defects.substring(0, defects.length - 1)}`)
744
- }
745
- } else if (items.type === 'string' && items.f_is_defect && items.f_item_value[0] ) {
746
- checkResult = '有隐患'
747
- this.result = '有隐患'
748
- deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
749
- } else if (items.f_item_name == '金额异常差值') {
750
- var deviation = this.$appdata.getSingleValue('金额异常差值允许误差')
751
- //tag
752
- if (parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN") {
753
- if (parseFloat(items.f_item_value[0]) > parseFloat(deviation) || parseFloat(items.f_item_value[0]) < parseFloat(deviation) * -1) {
754
- checkResult = '有隐患'
755
- this.result = '有隐患'
756
- deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
757
- }
758
- }
759
- } else if (items.f_item_name == '气量异常差值') {
760
- var deviation = this.$appdata.getSingleValue('气量异常差值允许误差')
761
- //tag
762
- if (parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN") {
763
- if (parseFloat(items.f_item_value[0]) > parseFloat(deviation) || parseFloat(items.f_item_value[0]) < parseFloat(deviation) * -1) {
764
- checkResult = '有隐患'
765
- this.result = '有隐患'
766
- deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
767
- }
768
- }
769
- }
770
- //tag)
771
- //tag
772
- //tag
773
- if (items.type === 'selector') {
774
- items.selected = []
775
- } else if (items.type === 'inputSelector') {
776
- items.selected = ''
777
- }
778
- }
779
-
780
-
781
- //tag
782
- this.$set('deviceCollect.name', f_device_type)
783
- this.$set('deviceCollect.value', checkResult)
784
- this.$set('deviceCollect.devices', deviceInfos)
785
- //tag)
786
- if (this.deviceCollect.name) {
787
- //tag
788
- this.deviceCollects.push(JSON.parse(JSON.stringify(this.deviceCollect)))
789
- }
790
-
791
- checkResult = '正常'
792
- this.deviceCollect = {}
793
- }
794
- }
795
- }
796
- if (this.deviceCollects.length > 0) {
797
- this.hasDevice = true
798
- }
799
- this.ajresult = JSON.parse(this.data.f_defect_content).result
800
- this.showimg3 = this.data.f_noanswer_path
801
- this.showimg5 = this.data.f_noanswer1_path
802
- this.showimg6 = this.data.f_noanswer2_path
803
- this.showimg4 = this.data.f_rejectcheck_path
804
- this.showimg7 = this.data.f_rejectcheck1_path
805
- this.showimg8 = this.data.f_rejectcheck2_path
806
- this.paperdata = this.data
807
- this.loading = false
808
- },
809
- imgclose() {
810
- this.imgshow = false
811
- },
812
- putDevices() {
813
- ////tag
814
- this.$set('data.approve', "true")
815
- this.$set('data.writeback', "false")
816
- if (Vue.config.safecheck.ApproveConfig != undefined) {
817
- if (Vue.config.safecheck.ApproveConfig.approve != undefined) {
818
- this.$set('data.approve', Vue.config.safecheck.ApproveConfig.approve)
819
- }
820
- if (Vue.config.safecheck.ApproveConfig.writeback != undefined) {
821
- this.$set('data.writeback', Vue.config.safecheck.ApproveConfig.writeback)
822
- }
823
- if (Vue.config.safecheck.ApproveConfig.livedispose != undefined) {
824
- this.livedispose = Vue.config.safecheck.ApproveConfig.livedispose
825
- }
826
- if(Vue.config.safecheck.ApproveConfig.hiddendanger != undefined) {
827
- if (parseInt(Vue.config.safecheck.ApproveConfig.hiddendanger) >= 3) {
828
- this.hiddenDangerImgNumber = 3
829
- }else {
830
- this.hiddenDangerImgNumber = parseInt(Vue.config.safecheck.ApproveConfig.hiddendanger)
831
- }
832
- }
833
- }
834
- //tag
835
-
836
- //tag)
837
- if (!this.item.f_safecheck_type) {
838
- this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType['年度普检'][this.item.f_check_type]])
839
- } else {
840
- if (Vue.config.safecheck.DevicesConfig != undefined)
841
- this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType[this.item.f_safecheck_type][this.item.f_check_type]])
842
- }
843
- //遍历安检项配置
844
- for (let i in this.config) {
845
- //取得安检项索引值
846
- let n = this.config[i].index
847
- this.devices[n - 1] = {device: i, n: n, checkmust: this.config[i].checkmust}
848
- this.$set('data.' + 'device' + n, [])
849
- let items = []
850
- for (let it in this.config[i].items) {
851
- //赋值下拉选项
852
- if (this.config[i].items[it].type == 'selector') {
853
- for (let op in this.config[i].items[it].options)
854
- if (this.config[i].items[it].options[op].isdefault == true) {
855
- items.push({
856
- f_defect_level: this.config[i].items[it].options[op].level,
857
- f_is_defect: this.config[i].items[it].options[op].isdefect,
858
- f_item_name: it,
859
- f_item_value: this.config[i].items[it].options[op].data,
860
- f_path: "",
861
- type: "selector"
862
- })
863
- }
864
- }
865
- }
866
- n = n + 1
867
- }
868
-
869
- },
870
- showpath(val1, val2) {
871
- //tag
872
- //tag
873
- if (val1) {
874
- this.showimg1 = val1
875
- this.picturename = val2
876
- this.imgshow = true
877
- }
878
- },
879
- showpicture(val1, val2) {
880
- //tag
881
- if (val2 == '气量异常差值' || val2 == '金额异常差值') {
882
- return
883
- }
884
- for (let i = 0; i < this.devicesAll.length; i++) {
885
- for (let j = 0; j < this.devicesAll[i].length; j++) {
886
- if (this.devicesAll[i][j].f_device_type == val1) {
887
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
888
- if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
889
- if (!this.devicesAll[i][j].f_items[k].f_is_defect) {
890
- return false
891
- } else {
892
- this.showimg1 = this.devicesAll[i][j].f_items[k].f_path
893
- this.showimg2 = this.devicesAll[i][j].f_items[k].f_second_path
894
- this.otherDarginShowImgs = []
895
- for (let l = 0; l < this.hiddenDangerImgNumber; l++) {
896
- let img = {path:''}
897
- if (this.devicesAll[i][j].f_items[k]['f_p' + (l+1)+'_path']) {
898
- img.path = this.devicesAll[i][j].f_items[k]['f_p' + (l+1)+'_path'] + '?' + Math.random()
899
- this.otherDarginShowImgs.push(img)
900
- }
901
- }
902
- this.picturename = '隐患照片'
903
- this.imgshow = true
904
- return true
905
- }
906
- }
907
- }
908
-
909
- }
910
- }
911
- }
912
- },
913
- isred(val1, val2) {
914
- //tag
915
- if (val2 == '气量异常差值' || val2 == '金额异常差值') {
916
- return
917
- }
918
- for (let i = 0; i < this.devicesAll.length; i++) {
919
- for (let j = 0; j < this.devicesAll[i].length; j++) {
920
- if (this.devicesAll[i][j].f_device_type == val1) {
921
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
922
- if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
923
- if (!this.devicesAll[i][j].f_items[k].f_is_defect) {
924
- return false
925
- } else {
926
- return true
927
- }
928
- }
929
- }
930
-
931
- }
932
- }
933
- }
934
- },
935
- showpicture2() {
936
- this.imgshow2 = true
937
- },
938
- getDeviceValue(val1, val2) {
939
- let aa = ''
940
- for (let i = 0; i < this.devicesAll.length; i++) {
941
- for (let j = 0; j < this.devicesAll[i].length; j++) {
942
- if (this.devicesAll[i][j].f_device_type == val1) {
943
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
944
- if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
945
- if (this.devicesAll[i][j].f_items[k].f_item_lists[0]) {
946
- for (let l = 0; l < this.devicesAll[i][j].f_items[k].f_item_lists.length; l++) {
947
- let val = this.devicesAll[i][j].f_items[k].f_item_lists[l].f_item_value
948
- aa += (val === null ? '空' : val) + ' '
949
- }
950
- return aa
951
- }
952
- }
953
- }
954
-
955
- }
956
- }
957
- }
958
-
959
- },
960
- getDevicePath(val1, val2) {
961
- for (let i = 0; i < this.devicesAll.length; i++) {
962
- for (let j = 0; j < this.devicesAll[i].length; j++) {
963
- if (this.devicesAll[i][j].f_device_type == val1) {
964
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
965
- if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
966
- return this.devicesAll[i][j].f_items[k].f_path
967
- }
968
- }
969
-
970
- }
971
- }
972
- }
973
-
974
- },
975
- getDeviceAll() {
976
- let keyall = Object.keys(this.data)
977
- for (let i = 0; i < keyall.length; i++) {
978
- //tag)
979
- if (keyall[i].startsWith('device') && keyall[i] != 'deviceundefined') {
980
- this.devicesAll.push(this.data[keyall[i]])
981
- //tag
982
- }
983
- }
984
- //tag
985
- //tag)
986
- this.devicesCollect()
987
-
988
- },
989
-
990
- back() {
991
- if (this.role == 'inspect') {
992
- if (!this.isStrat) {
993
- this.$back()
994
- return
995
- } else {
996
- this.savePaper(true).then(() => {
997
- this.$back()
998
- this.isStrat = false
999
- })
1000
- }
1001
- } else {
1002
- this.$back()
1003
- }
1004
- },
1005
- checkIsStart() {
1006
- alert('asdad')
1007
- return
1008
- },
1009
-
1010
- viewPic(fileName) {
1011
- //tag
1012
- if (this.role == 'view') {
1013
- if (!fileName.endsWith('nopic.png')) {
1014
- this.pic_to_be_viewed = fileName
1015
- this.showModal = true
1016
- }
1017
- } else {
1018
- HostApp.viewPic(fileName)
1019
- }
1020
- },
1021
- tick() {
1022
- this.timer = null
1023
- this.data.f_offsite_time = Util.toStandardTimeString()
1024
- this.timer = window.setTimeout(this.tick, 1000)
1025
- },
1026
- getRepairState() {
1027
- let repaired = true
1028
- this.data.f_defects.forEach((defect) => {
1029
- repaired = repaired & (defect.f_ratification == '已处理')
1030
- })
1031
- return repaired
1032
- },
1033
- verifyRepairDefects() {
1034
- this.data.f_repair_date = Util.toStandardTimeString()
1035
- this.data.f_repaired = this.getRepairState() ? '已修' : '在修'
1036
- },
1037
- genuineSave(saveOnly) {
1038
- HostApp.__this__.save(saveOnly)
1039
- if (!saveOnly)
1040
- HostApp.__this__.disableTimer()
1041
- HostApp.__callback__ = null
1042
- HostApp.__this__ = null
1043
- },
1044
- setUrgency() {
1045
- this.data.f_defect_urgency = 'Z'
1046
- let that = this
1047
- this.data.f_defects.forEach(function (defect) {
1048
- if (that.data.f_defect_urgency > defect.f_defect_level.charAt(0))
1049
- that.data.f_defect_urgency = defect.f_defect_level.charAt(0)
1050
- })
1051
- if (this.data.f_defect_urgency == 'Z')
1052
- this.data.f_defect_urgency = null
1053
- },
1054
- disableTimer() {
1055
- if (this.timer) {
1056
- window.clearTimeout(this.timer)
1057
- this.timer = null
1058
- }
1059
- },
1060
- loaded(paper) {
1061
- if (!paper.hasOwnProperty('id')) {
1062
- this.$showMessage("该安检单在手机上已经不存在,可能是卸载过程序。可以进入重新安检,或返回安检计划。")
1063
- this.init()
1064
- } else {
1065
- Util.booleanFilter(paper)
1066
- HostApp.__this__.$set('data', paper)
1067
- HostApp.__this__.$goto('paper-state', {}, 'paper-router')
1068
- // 如果打回重检则重新计时
1069
- //tag
1070
- if (HostApp.__this__.role == 'inspect'
1071
- && HostApp.__this__.data.f_approved
1072
- && HostApp.__this__.data.f_approved == '打回') {
1073
- //tag
1074
- HostApp.__this__.data.f_onsite_time = Util.toStandardTimeString()
1075
- HostApp.__this__.tick()
1076
- }
1077
- }
1078
- HostApp.__callback__ = null
1079
- HostApp.__this__ = null
1080
- },
1081
- S4() {
1082
- return (((1 + Math.random()) * 0x10000) | 0).toString(16).substring(1);
1083
- },
1084
- init() {
1085
- this.data.f_noplan_item_id = this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4()
1086
- this.data.ename = Vue.user.ename
1087
- this.data.f_outlets = Vue.user.f_parentname
1088
- this.data.f_meetunit = Vue.user.orgpathnames
1089
- this.data.orgpathstr = Vue.user.orgpathstr
1090
- this.data.f_check_item_id = this.item.id
1091
- this.data.f_check_plan_id = this.f_plan_id
1092
- this.data.f_checker_id = Vue.user.id
1093
- this.data.f_checker_name = Vue.user.name
1094
- this.data.f_check_type = this.item.f_user_type
1095
- this.data.f_subcompany = this.item.f_subcompany
1096
- this.data.f_approved = this.item.f_approved
1097
- this.data.f_repair_approved = this.item.f_repair_approved
1098
- this.data.f_no_checkplan = this.item.f_no_checkplan
1099
- this.data.f_approved = this.item.f_approved
1100
- this.data.f_filialeid = this.item.f_filialeid
1101
- this.data.f_orgstr = this.item.f_orgstr
1102
- this.data.version = this.item.version
1103
- this.$set('data.f_meters', this.item.f_plan_meters)
1104
- this.$set('data.f_userinfo_code', this.item.f_userinfo_code)
1105
- // 安检状态
1106
- this.$set('data.f_entry_status', '入户')
1107
- this.$set('data.f_usegas', '已使用')
1108
- this.$set('data.f_state', this.item.f_state)
1109
- // 用户信息
1110
- this.$set('data.f_user_name', this.item.f_user_name)
1111
- this.$set('data.f_user_phone', this.item.f_user_phone)
1112
- this.$set('data.f_userinfoid', this.item.f_userinfoid)
1113
- this.$set('data.f_address', this.item.f_address)
1114
- this.$set('data.f_card_id', this.item.f_card_id)
1115
- this.$set('data.f_area', this.item.f_area)
1116
- this.$set('data.f_street', this.item.f_street)
1117
- this.$set('data.f_room', this.item.f_room)
1118
- this.$set('data.f_building', this.item.f_building)
1119
- this.$set('data.f_unit', this.item.f_unit)
1120
- this.$set('data.f_floor', this.item.f_floor)
1121
- this.$set('data.f_residential_area', this.item.f_residential_area)
1122
- this.$set('data.f_idnumber', this.item.f_idnumber)
1123
- this.$set('data.f_comments', this.item.f_comments)
1124
- this.$set('data.f_userproperties', this.item.f_userproperties)
1125
- // 处置方式
1126
- this.$set('data.f_no_gas_device', false)
1127
- this.$set('data.f_close_valve', false)
1128
- this.$set('data.f_unload_battery', false)
1129
- if (this.data.f_check_item_id == '' && this.item.f_no_checkplan == '无计划安检') {
1130
- this.data.f_check_item_id = this.data.f_noplan_item_id
1131
- }
1132
-
1133
- //房屋结构
1134
- // this.$set('data.f_room_style', '多层')
1135
- //供暖方式
1136
- // this.$set('data.f_heating_style', '热力公司集中供暖')
1137
- if (this.item.f_plan_meters) {
1138
- for (let de in this.devices) {
1139
- this.$set('data.device' + this.devices[de].n, [])
1140
- for (let i = 0; i < this.item.f_plan_meters.length; i++) {
1141
- if (this.item.f_plan_meters[i].f_meter_type) {
1142
- if (this.devices[de].device == "燃气表" && this.item.f_plan_meters[i].f_meter_type.indexOf('机表') > 0) {
1143
- delete this.config['燃气表']['items']['累计购气量']
1144
- this.data['device' + this.devices[de].n].push({
1145
- f_device_type: "燃气表",
1146
- f_items: [{
1147
- f_defect_level: null,
1148
- f_device_id: "",
1149
- f_is_defect: "",
1150
- f_item_name: "表品牌",
1151
- f_item_value: this.item.f_plan_meters[i].f_aliasname,
1152
- f_path: "",
1153
- type: "string"
1154
- },
1155
- {
1156
- f_defect_level: null,
1157
- f_device_id: "",
1158
- f_is_defect: "",
1159
- f_item_name: "位置",
1160
- f_item_value: this.item.f_plan_meters[i].f_weizhi,
1161
- f_path: "",
1162
- type: "selector"
1163
- },
1164
- {
1165
- f_defect_level: null,
1166
- f_device_id: "",
1167
- f_is_defect: "",
1168
- f_item_name: "表号",
1169
- f_item_value: this.item.f_plan_meters[i].f_meter_no,
1170
- f_path: "",
1171
- type: "number"
1172
- },
1173
- {
1174
- f_defect_level: null,
1175
- f_device_id: "",
1176
- f_is_defect: "",
1177
- f_item_name: "表封号",
1178
- f_item_value: this.item.f_plan_meters[i].f_metertitles,
1179
- f_path: "",
1180
- type: "number"
1181
- },
1182
- {
1183
- f_defect_level: null,
1184
- f_device_id: "",
1185
- f_is_defect: "",
1186
- f_item_name: "表型号",
1187
- f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1188
- f_path: "",
1189
- type: "selector"
1190
- },
1191
- {
1192
- f_defect_level: null,
1193
- f_device_id: "",
1194
- f_is_defect: "",
1195
- f_item_name: "表底数",
1196
- f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1197
- f_path: "",
1198
- type: "number"
1199
- }
1200
- ]
1201
- })
1202
- } else if (this.devices[de].device == "燃气表") {
1203
- delete this.config['燃气表']['items']['表底数']
1204
- this.data['device' + this.devices[de].n].push({
1205
- f_device_type: "燃气表",
1206
- f_items: [{
1207
- f_defect_level: null,
1208
- f_device_id: "",
1209
- f_is_defect: "",
1210
- f_item_name: "表品牌",
1211
- f_item_value: this.item.f_plan_meters[i].f_aliasname,
1212
- f_path: "",
1213
- type: "string"
1214
- },
1215
- {
1216
- f_defect_level: null,
1217
- f_device_id: "",
1218
- f_is_defect: "",
1219
- f_item_name: "位置",
1220
- f_item_value: this.item.f_plan_meters[i].f_weizhi,
1221
- f_path: "",
1222
- type: "selector"
1223
- },
1224
- {
1225
- f_defect_level: null,
1226
- f_device_id: "",
1227
- f_is_defect: "",
1228
- f_item_name: "表号",
1229
- f_item_value: this.item.f_plan_meters[i].f_meter_no,
1230
- f_path: "",
1231
- type: "number"
1232
- },
1233
- {
1234
- f_defect_level: null,
1235
- f_device_id: "",
1236
- f_is_defect: "",
1237
- f_item_name: "表封号",
1238
- f_item_value: this.item.f_plan_meters[i].f_metertitles,
1239
- f_path: "",
1240
- type: "number"
1241
- },
1242
- {
1243
- f_defect_level: null,
1244
- f_device_id: "",
1245
- f_is_defect: "",
1246
- f_item_name: "表型号",
1247
- f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1248
- f_path: "",
1249
- type: "selector"
1250
- },
1251
- {
1252
- f_defect_level: null,
1253
- f_device_id: "",
1254
- f_is_defect: "",
1255
- f_item_name: "累计购气量",
1256
- f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1257
- f_path: "",
1258
- type: "number"
1259
- }
1260
- ]
1261
- })
1262
- }
1263
- }
1264
- }
1265
- }
1266
- }
1267
-
1268
- this.$goto('paper-state', {}, 'paper-router')
1269
- },
1270
- extend(initalObj, finalObj) {
1271
- var obj = finalObj || {};
1272
- for (var i in initalObj) {
1273
- var prop = initalObj[i];
1274
-
1275
- // 避免相互引用对象导致死循环,如initalObj.a = initalObj的情况
1276
- if (prop === obj) {
1277
- continue;
1278
- }
1279
-
1280
- if (typeof prop === 'object') {
1281
- if (obj[i]) {
1282
- this.extend(obj[i], prop)
1283
- } else {
1284
- obj[i] = prop;
1285
- }
1286
- }
1287
- }
1288
- return obj;
1289
- },
1290
- //获取当前时间
1291
- getNowFormatDate() {
1292
- var date = new Date();
1293
- var seperator1 = "-";
1294
- var seperator2 = ":";
1295
- var month = date.getMonth() + 1;
1296
- var strDate = date.getDate();
1297
- if (month >= 1 && month <= 9) {
1298
- month = "0" + month;
1299
- }
1300
- if (strDate >= 0 && strDate <= 9) {
1301
- strDate = "0" + strDate;
1302
- }
1303
- var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
1304
- + " " + date.getHours() + seperator2 + date.getMinutes()
1305
- + seperator2 + date.getSeconds();
1306
- return currentdate;
1307
- }
1308
- },
1309
- ready() {
1310
- this.putDevices()
1311
- if (this.item.f_state != '未检' || this.item.f_no_checkplan == '无计划安检') {
1312
- if (this.role != 'inspect') {
1313
- let that = this
1314
- let id
1315
- if (this.role == 'view') {
1316
- id = this.item.id
1317
- } else if (this.role == 'androidview') {
1318
- id = this.item.f_paper_id
1319
- }
1320
- this.$resetpost(`rs/path/getUserinfomation`, {data: {condition: `id = '${id}'`}}).then((respanse) => {
1321
- //tag
1322
- if (respanse.data.length != 0) {
1323
- // 包含 其它 特殊处理的数组
1324
- // 对应位置
1325
-
1326
- //tag
1327
-
1328
- that.data = Object.assign(that.data, respanse.data[0])
1329
- if (respanse.data[0].f_devices) {
1330
- for (let da in that.devices) {
1331
- that.$set('data.device' + that.devices[da].n, [])
1332
- }
1333
- respanse.data[0].f_devices.forEach((item) => {
1334
- for (let de in that.devices) {
1335
- if (that.devices[de].device == item.f_device_type) {
1336
- item.f_items.forEach((f_item) => {
1337
- //tag
1338
- //tag
1339
- let itemValues = []
1340
- f_item.f_item_lists.forEach((tempItem) => {
1341
- //tag
1342
- if (tempItem.f_item_value !== 'null') {
1343
- itemValues.push(tempItem.f_item_value)
1344
- }
1345
- })
1346
- f_item.f_item_value = itemValues
1347
- })
1348
- that.data['device' + that.devices[de].n].push({
1349
- f_device_type: item.f_device_type,
1350
- f_items: item.f_items
1351
- })
1352
- }
1353
- }
1354
- })
1355
- }
1356
- Util.replaceFalse(that.data)
1357
- Util.booleanFilter(that.data)
1358
- if (this.role == 'view') {
1359
- Util.ratifyPics(that.data)
1360
- Util.ratifyPics(that.picture)
1361
- } else {
1362
- Util.androidRatifyPics(that.data, this.$androidUtil.getProxyUrl())
1363
- }
1364
- //tag
1365
- }
1366
- // this.$goto('paper-message-blank', {userinfo:this.data,devices:this.devices,config:this.config,role:this.role}, 'self')
1367
- this.isshow = true
1368
- asyncReady(this).then(async () => {
1369
- //tag
1370
- //tag)
1371
- if (this.data.f_check_type == '民用') {
1372
- this.deviceconfig = Vue.config.safecheck.DevicesConfig
1373
- console.log('打印',this.deviceconfig)
1374
- if (typeof this.deviceconfig==='string'){
1375
- this.deviceconfig=JSON.parse(this.deviceconfig)
1376
- }
1377
- //tag)
1378
- } else if (this.data.f_check_type == '非民用') {
1379
- this.deviceconfig = Vue.config.safecheck.DevicesSetConfig
1380
- if (typeof this.deviceconfig==='string'){
1381
- this.deviceconfig=JSON.parse(this.deviceconfig)
1382
- }
1383
- //tag)
1384
- }
1385
- /*await this.$resetpost('rs/sql/SafecheckTableModel', {data: {condition: ` 1 = 1 and uf.f_userinfo_id = '${this.item.f_userinfoid}'`}}).then((res) => {
1386
- //tag)
1387
- this.meter_classify = res.data[0].f_meter_classify
1388
- })*/
1389
- await this.$resetpost('rs/sql/safe_singleTable_OrderBy', {data:
1390
- {
1391
- items: 'f_meter_classify',
1392
- tablename: 't_userfiles',
1393
- condition: `1 = 1 and f_userinfo_id = '${this.item.f_userinfoid}'`,
1394
- orderitem: 'f_userfiles_id'
1395
- }
1396
- }).then((res) => {
1397
- //tag)
1398
- this.meter_classify = res.data[0].f_meter_classify
1399
- })
1400
- if (this.data.f_collection_type == '按金额' && this.meter_classify=='机表') {
1401
- let aaa = Object.assign({}, this.config4["燃气表"].items, this.deviceconfig["燃气表"].items)
1402
- this.deviceconfig["燃气表"].items = aaa
1403
- //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1404
- //tag)
1405
- }else if(this.data.f_collection_type == '按金额'&& this.meter_classify =='物联网表') {
1406
- let aaa = Object.assign({}, this.config3["燃气表"].items, this.deviceconfig["燃气表"].items)
1407
- this.deviceconfig["燃气表"].items = aaa
1408
- //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1409
- //tag)
1410
- }else if(this.data.f_collection_type == '按气量'&& this.meter_classify =='气量卡表') {
1411
- let aaa = Object.assign({}, this.config2["燃气表"].items, this.deviceconfig["燃气表"].items)
1412
- this.deviceconfig["燃气表"].items = aaa
1413
- //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1414
- //tag)
1415
- } else {
1416
- let aaa = Object.assign({}, this.config["燃气表"].items, this.deviceconfig["燃气表"].items)
1417
- this.deviceconfig["燃气表"].items = aaa
1418
- //tag)
1419
- }
1420
- this.deviceconfig2 = ObjConfig.getObjConfig(this.deviceconfig)
1421
- this.deviceconfig2[0].items = jsonSort(this.deviceconfig2[0].items, "index")
1422
- this.deviceconfig2[1].items = jsonSort(this.deviceconfig2[1].items, "index")
1423
- this.deviceconfig2 = jsonSort(this.deviceconfig2, "index")
1424
- this.getDeviceAll()
1425
-
1426
-
1427
- })
1428
- }
1429
- ).catch(
1430
- (respanse) => {
1431
- //tag
1432
- alert('查找安检单失败')
1433
- })
1434
- }
1435
- }
1436
- this.$nextTick(()=>{
1437
- console.log("332",document.getElementById("item.id"))
1438
- this.wave = WaveSurfer.create({
1439
- container: document.getElementById("item.id"),
1440
- waveColor: this.options.waveColor,
1441
- progressColor: this.options.progressColor,
1442
- cursorColor: this.options.cursorColor,
1443
- barWidth: this.options.barWidth,
1444
- hideScrollbar: this.options.hideScrollbar,
1445
- height: this.options.height,
1446
- normalize: this.options.normalize
1447
- });
1448
- this.wave.load('/rs/audio/file/'+this.item.f_recording1_path)
1449
- this.wave.on("loading", percents => {
1450
- // 当前加载的进度
1451
- console.log("播放中",percents)
1452
- });
1453
- })
1454
-
1455
- },
1456
- watch: {
1457
- // 'isUpload'(val){
1458
- // //tag
1459
- // }
1460
- },
1461
- destroyed() {
1462
- //tag
1463
- this.disableTimer()
1464
- }
1465
- }
1466
-
1467
- </script>
1468
- <style scoped>
1469
- .table-striped thead tr th {
1470
- background-color: rgb(223, 237, 251);
1471
- padding: 10px;
1472
- border-left: solid 0px #dae4f2;
1473
- border-top: solid 1px #dae4f2;
1474
- border-right: none;
1475
- border-bottom: none;
1476
- text-align: center;
1477
- color: black;
1478
- }
1479
- </style>
1
+ <style scoped>
2
+ .img {
3
+ border: 1px solid #9773ed;
4
+ width: auto;
5
+ height: auto;
6
+ float: left;
7
+ text-align: center;
8
+ margin: 6px;
9
+ }
10
+
11
+ img {
12
+ margin: 6px;
13
+ }
14
+
15
+
16
+ .container {
17
+ margin: 10px auto;
18
+ width: 80%;
19
+ height: auto;
20
+ }
21
+
22
+ div::-webkit-scrollbar {
23
+ width: 0 !important;
24
+ height: 0 !important;
25
+ }
26
+
27
+ div {
28
+ -ms-overflow-style: none;
29
+ overflow: -moz-scrollbars-none;
30
+ }
31
+
32
+ .divmask {
33
+ pointer-events: none;
34
+ }
35
+
36
+ .app-header {
37
+ border-radius: 50%;
38
+ background: rgba(73, 158, 223, 0.4);
39
+ color: #FFF;
40
+ padding: 20px;
41
+ text-align: center;
42
+ font-size: 1.2em;
43
+ z-index: 10;
44
+ opacity: 0.5;
45
+ bottom: 50px;
46
+ margin-top: -20px;
47
+ position: absolute;
48
+ top: 10%;
49
+ right: 2%;
50
+ height: 8%;
51
+ }
52
+ </style>
53
+
54
+ <template>
55
+ <div class="basic-main" style="height: 100%">
56
+ <div class="page-header app-header auto" style="padding: 15px;margin-right: 10px;right: 0%;height: 7%">
57
+ <div @click="back()">
58
+ <img src="../../../assets/back.png" style="margin: 0px"/>
59
+ </div>
60
+ </div>
61
+ <work-busy :is-busy="loading"></work-busy>
62
+ <div class="container-fluid" style="overflow: scroll">
63
+ <div class="row">
64
+ <div class="col-md-5" style="margin-right: 2%;margin-left: 2%;height: 100%;overflow: scroll">
65
+ <div style="width: 100%;margin: auto">
66
+ <table class="table table-striped table-bordered" style="margin-bottom: 6px">
67
+ <thead>
68
+ <tr>
69
+ <th colspan="6" style="text-align: center">用户基本信息</th>
70
+ </tr>
71
+ </thead>
72
+ <tbody>
73
+ <tr>
74
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户编号:</td>
75
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_userinfo_code }}</td>
76
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户名称:</td>
77
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_user_name }}</td>
78
+ </tr>
79
+ <tr>
80
+ <td style="text-align: center;border: #E9E9E9 solid 1px">证件号码:</td>
81
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_idnumber }}</td>
82
+ <td style="text-align: center;border: #E9E9E9 solid 1px">用户类型:</td>
83
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_check_type }}</td>
84
+ </tr>
85
+ <tr>
86
+ <td style="text-align: center;border: #E9E9E9 solid 1px">用户电话:</td>
87
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_user_phone }}</td>
88
+ <td style="text-align: center;border: #E9E9E9 solid 1px">区 / 县:</td>
89
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_area }}</td>
90
+ </tr>
91
+ <tr>
92
+ <td style="text-align: center;border: #E9E9E9 solid 1px">街 道:</td>
93
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_street }}</td>
94
+ <td style="text-align: center;border: #E9E9E9 solid 1px">楼 号:</td>
95
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_building }}</td>
96
+ </tr>
97
+ <tr>
98
+ <td style="text-align: center;border: #E9E9E9 solid 1px">单 元:</td>
99
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_unit }}</td>
100
+ <td style="text-align: center;border: #E9E9E9 solid 1px">楼 层:</td>
101
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_floor }}</td>
102
+ </tr>
103
+ <tr>
104
+ <td style="text-align: center;border: #E9E9E9 solid 1px">门 牌 号 :</td>
105
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_room }}</td>
106
+ <td style="text-align: center;border: #E9E9E9 solid 1px">用户性质:</td>
107
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_userproperties }}</td>
108
+ </tr>
109
+ <tr>
110
+ <td style="text-align: center;border: #E9E9E9 solid 1px">备注信息:</td>
111
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_comments }}</td>
112
+ <td style="text-align: center;border: #E9E9E9 solid 1px">小区名称:</td>
113
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_residential_area }}</td>
114
+ </tr>
115
+ <tr>
116
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px">详细住址:</td>
117
+ <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_address }}</td>
118
+ </tr>
119
+ </tbody>
120
+ </table>
121
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
122
+ <thead>
123
+ <tr>
124
+ <th colspan="4" style="text-align: center">用户安检概况</th>
125
+ </tr>
126
+ </thead>
127
+ <tbody>
128
+ <tr>
129
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
130
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
131
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
132
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
133
+ </tr>
134
+ <tr>
135
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
136
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_entry_status }}</td>
137
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">燃气使用:</td>
138
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_usegas }}</td>
139
+ </tr>
140
+ <tr>
141
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">用户满意度:</td>
142
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{
143
+ paperdata.f_client_evaluation
144
+ }}
145
+ </td>
146
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">安检结果:</td>
147
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{ ajresult }}</td>
148
+ </tr>
149
+ <tr>
150
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">安检员:</td>
151
+ <td colspan="3"
152
+ style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
153
+ {{ paperdata.f_checker_name }}
154
+ </td>
155
+ </tr>
156
+ <tr>
157
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">备注:</td>
158
+ <td colspan="3"
159
+ style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
160
+ {{ paperdata.f_repair_approved_note }}
161
+ </td>
162
+ </tr>
163
+ <tr>
164
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">隐患详情:</td>
165
+ <td colspan="3"
166
+ style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
167
+ <span v-for="deviceCollect in deviceCollects">
168
+ <span class="li-font">
169
+ {{ deviceCollect.name }}:{{ deviceCollect.value }}&nbsp;&nbsp;&nbsp;
170
+ </span>
171
+ <br>
172
+ <span v-if="deviceCollect.value == '有隐患'">
173
+ <lable>
174
+ 隐患:
175
+ </lable>
176
+ <span class="li-font" v-for="val in deviceCollect.devices">
177
+ {{ val }}&nbsp;&nbsp;&nbsp;
178
+ </span><br>
179
+ </span>
180
+
181
+ </span>
182
+ </td>
183
+ </tr>
184
+
185
+ </tbody>
186
+ </table>
187
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status!='入户'">
188
+ <thead>
189
+ <tr>
190
+ <th colspan="4" style="text-align: center">用户安检概况</th>
191
+ </tr>
192
+ </thead>
193
+ <tbody>
194
+ <tr>
195
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
196
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
197
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
198
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
199
+ </tr>
200
+ <tr>
201
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
202
+ <td colspan="2" style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">
203
+ {{ paperdata.f_entry_status }}
204
+ </td>
205
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">
206
+ <button-link style="color: black" type="button" class="btn btn-link" @click="showpicture2()">
207
+ {{ dev.lname }}
208
+ 查看{{ data.f_entry_status }}照片
209
+ </button-link>
210
+ </td>
211
+ </tr>
212
+
213
+ </tbody>
214
+ </table>
215
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
216
+ <thead>
217
+ <tr>
218
+ <th style="text-align: center">总体安检照片</th>
219
+ </tr>
220
+ </thead>
221
+ <tbody>
222
+ <tr>
223
+ <td style="margin: auto;text-align: center">
224
+ <div class="container" style="max-width: 550px;background: #FFFFFF">
225
+ <div class="img" v-for="img in paperdata.f_overall_imgs">
226
+ <img-self-safe :src="img.f_overall_path" style="float: left" width="150"
227
+ height="200"></img-self-safe>
228
+ </div>
229
+ </div>
230
+
231
+
232
+ </td>
233
+
234
+ </tr>
235
+ </tbody>
236
+ </table>
237
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
238
+ <thead>
239
+ <tr>
240
+ <th style="text-align: center">用户签名照片</th>
241
+ </tr>
242
+ </thead>
243
+ <tbody>
244
+ <tr>
245
+ <td style="margin: auto;text-align: center">
246
+ <div class="container" style="max-width: 500px;background: #FFFFFF">
247
+ <div class="img" style="float: none">
248
+ <img-self-safe :src="paperdata.f_sign_path" width="486" height="300"></img-self-safe>
249
+ </div>
250
+ </div>
251
+ </td>
252
+ </tr>
253
+ </tbody>
254
+ </table>
255
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户' && paperdata.f_defect_notified">
256
+ <thead>
257
+ <tr>
258
+ <th style="text-align: center">安检通知书/隐患整改通知书</th>
259
+ </tr>
260
+ </thead>
261
+ <tbody>
262
+ <tr>
263
+ <td style="margin: auto;text-align: center">
264
+ <div class="container" style="max-width: 500px;background: #FFFFFF">
265
+ <div class="img" style="float: none">
266
+ <img-self-safe :src="paperdata.f_notified_path" width="486" height="300"></img-self-safe>
267
+ </div>
268
+ </div>
269
+ </td>
270
+ </tr>
271
+ </tbody>
272
+ </table>
273
+ <table class="table table-striped table-bordered" v-show="item.f_recording1_path && isRecodrDownloadBtn">
274
+ <thead>
275
+ <tr>
276
+ <th style="text-align: center">录音文件</th>
277
+ </tr>
278
+ </thead>
279
+ <tbody>
280
+ <tr>
281
+ <td style="margin: auto;text-align: center">
282
+ <div class="container" style="max-width: 500px; background: #FFFFFF;margin-bottom: 20px">
283
+ <div id='item.id' ref="dp" style="height: 10vh; width:20vw ;margin-bottom:50px"></div>
284
+ </div>
285
+ <a class="button_spacing button_search-1" :download="item.f_user_name+'-'+item.f_check_type+'-'+录音文件.arm"
286
+ :href="'rs/image/file/'+item.f_recording1_path" >录音下载</a>
287
+ <button class="button_spacing button_search-1" type="button" @click="getbaseYin()">播放录音</button>
288
+ <button class="button_spacing button_search-1" type="button" @click="stop()">停止播放</button>
289
+ </td>
290
+ </tr>
291
+ </tbody>
292
+ </table>
293
+ <table class="table table-striped table-bordered" v-show="item.f_select_record_path && isRecodrDownloadBtn">
294
+ <thead>
295
+ <tr>
296
+ <th style="text-align: center">录音文件</th>
297
+ </tr>
298
+ </thead>
299
+ <tbody>
300
+ <tr>
301
+ <td style="margin: auto;text-align: center">
302
+ <div class="container" style="max-width: 500px; background: #FFFFFF;margin-bottom: 20px">
303
+ <div id='item.id' ref="dp" style="height: 10vh; width:20vw ;margin-bottom:50px"></div>
304
+ </div>
305
+ <a class="button_spacing button_search-1" :download="item.f_user_name+'-'+item.f_check_type+'-'+'录音文件.arm'"
306
+ :href="'rs/image/file/'+item.f_select_record_path" >录音下载</a>
307
+ <!-- <button class="button_spacing button_search-1" type="button" @click="getbaseYin()">播放录音</button>-->
308
+ <!-- <button class="button_spacing button_search-1" type="button" @click="stop()">停止播放</button>-->
309
+ </td>
310
+ </tr>
311
+ </tbody>
312
+ </table>
313
+ </div>
314
+ </div>
315
+ <div class style="width: 1%;height: 100%;background-color: #F1F8FF;float: left;"></div>
316
+ <div class="col-md-6" style="height: 100%;overflow: scroll">
317
+ <div style="width: 95%;margin-left: 5%">
318
+ <table class="table table-striped table-bordered" v-for="config in deviceconfig2">
319
+ <thead v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
320
+ <tr>
321
+ <th style="text-align: center">{{ config.checkname }}</th>
322
+ </tr>
323
+ </thead>
324
+ <tbody v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
325
+ <tr v-for="dev in config.items">
326
+ <td v-if="dev.type!='text'">
327
+ <div class="row">
328
+ <div class="col-md-8" style="text-align: center;">
329
+ <label>
330
+ <button-link type="button" class="btn btn-link" @click="showpicture(config.checkname,dev.lname)"
331
+ :style="isred(config.checkname,dev.lname)?'color:red':'color:black'">
332
+ {{ dev.lname }}
333
+ </button-link>
334
+ </label>
335
+ </div>
336
+ <div class="col-md-4" style="text-align: center">
337
+ <label style="font-weight: normal"
338
+ v-if="dev.type!='picture'">{{ getDeviceValue(config.checkname, dev.lname) ? getDeviceValue(config.checkname, dev.lname) : '无' }}</label>
339
+ <label style="font-weight: normal" v-if="dev.type=='picture'">
340
+ <div v-show="getDevicePath(config.checkname,dev.lname)">
341
+ <button-link style="color: black" type="button" class="btn btn-link"
342
+ @click="showpath(getDevicePath(config.checkname,dev.lname),dev.lname)">查看照片
343
+ </button-link>
344
+ </div>
345
+ <div v-show="!getDevicePath(config.checkname,dev.lname)">无照片</div>
346
+ </label>
347
+ </div>
348
+ </div>
349
+ </td>
350
+ <td v-if="dev.type==='text'">
351
+ <label style="width: 100%;text-align: center">{{ dev.lname }}</label>
352
+ </td>
353
+ </tr>
354
+ </tbody>
355
+ </table>
356
+ </div>
357
+ </div>
358
+
359
+ </div>
360
+ </div>
361
+ </div>
362
+ <modal :show.sync="imgshow" v-ref:modal backdrop="true">
363
+ <header slot="modal-header" class="modal-header">
364
+ {{ picturename }}
365
+ </header>
366
+ <article slot="modal-body" class="modal-body">
367
+ <div class="from-group">
368
+ <div class="row">
369
+ <div class="col-md-6">
370
+ <img-self-safe v-if="showimg1" :src="showimg1" width="240" height="300"></img-self-safe>
371
+ </div>
372
+ <div class="col-md-6">
373
+ <img-self-safe v-if="showimg2" :src="showimg2" width="240" height="300"></img-self-safe>
374
+ </div>
375
+ <div class="col-md-6" v-for="item in otherDarginShowImgs">
376
+ <img-self-safe v-if="item.path" :src="item.path" width="240" height="300"></img-self-safe>
377
+ </div>
378
+ </div>
379
+ </div>
380
+ </article>
381
+ <footer slot="modal-footer" class="modal-footer" v-show="false">
382
+ <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
383
+ </footer>
384
+ </modal>
385
+ <modal :show.sync="imgshow2" v-ref:modal backdrop="true">
386
+ <header slot="modal-header" class="modal-header">
387
+ {{ paperdata.f_entry_status }}照片
388
+ </header>
389
+ <article slot="modal-body" class="modal-body">
390
+ <div class="from-group">
391
+ <div class="row">
392
+ <div class="col-md-6">
393
+ <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer_path" :src="showimg3" width="282"
394
+ height="400"></img-self-safe>
395
+ </div>
396
+ <div class="col-md-6">
397
+ <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer1_path" :src="showimg5" width="282"
398
+ height="400"></img-self-safe>
399
+ </div>
400
+ <div class="col-md-6">
401
+ <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer2_path" :src="showimg6" width="282"
402
+ height="400"></img-self-safe>
403
+ </div>
404
+ <div class="col-md-6">
405
+ <img-self-safe v-if="this.paperdata.f_entry_status=='拒检' && this.paperdata.f_rejectcheck_path" :src="showimg4" width="282"
406
+ height="400"></img-self-safe>
407
+ </div>
408
+ <div class="col-md-6">
409
+ <img-self-safe v-if="this.paperdata.f_entry_status=='拒检' && this.paperdata.f_rejectcheck1_path" :src="showimg7" width="282"
410
+ height="400"></img-self-safe>
411
+ </div>
412
+ <div class="col-md-6">
413
+ <img-self-safe v-if="this.paperdata.f_entry_status=='拒检' && this.paperdata.f_rejectcheck2_path" :src="showimg8" width="282"
414
+ height="400"></img-self-safe>
415
+ </div>
416
+ </div>
417
+ </div>
418
+ </article>
419
+ <footer slot="modal-footer" class="modal-footer" v-show="false">
420
+ <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
421
+ </footer>
422
+ </modal>
423
+ </template>
424
+
425
+ <script>
426
+ // import PaperUserm from './PaperUserm'
427
+ // import PaperStatem from './PaperStatem'
428
+ // import Devicesm from './Devicesm'
429
+ // import PaperFeedbackm from './PaperFeedbackm'
430
+ import ObjConfig from '../../../utils/GerJsonObjectConfig'
431
+ import RadioGroup from 'vue-client/src/vue-strap/src/radioGroup'
432
+ import Radio from 'vue-client/src/vue-strap/src/radioBtn'
433
+ import Vue from 'vue'
434
+ import * as Util from '../../Util'
435
+ import {jsonSort} from '../../../utils/LdapHelper'
436
+ import {HttpResetClass} from "vue-client";
437
+ import WaveSurfer from 'wavesurfer.js'
438
+ let asyncReady = async function (self) {
439
+ // 获取配置信息
440
+ try {
441
+ let res = await new HttpResetClass().load('post', 'rs/sql/tel_singleTable_OrderBy', {
442
+ data: {
443
+ items: 'f_dir',
444
+ tablename: 't_organization',
445
+ condition: `id = '${self.item.f_filialeid}'`,
446
+ orderitem: 'id'
447
+ }
448
+ })/*.then(res=>{*/
449
+ //tag
450
+ //tag)
451
+ if (!res.data[0].f_dir) {
452
+ self.$showMessage("该公司无组织目录,无法获取配置文件,请联系管理员确认")
453
+ } else {
454
+ //this.f_dir=res.data[0].f_dir
455
+ try {
456
+ let res1 = await new HttpResetClass().load('GET', `/safecheck/rs/vue/DevicesConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {}, {
457
+ resolveMsg: '获取居民配置项成功!',
458
+ rejectMsg: '获取居民配置项出错!'
459
+ })/*.then(res=>{*/
460
+ //tag
461
+ //this.safeConfig["民用配置项"]=Object.assign({},res.data)
462
+ Vue.config.safecheck.DevicesConfig = res1.data
463
+ /*})*/
464
+ let res2 = await new HttpResetClass().load('GET', `/safecheck/rs/vue/DevicesSetConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {}, {
465
+ resolveMsg: '获取非居民配置项成功!',
466
+ rejectMsg: '获取非居民配置项出错!'
467
+ })/*.then(res=>{*/
468
+ //tag
469
+ //this.safeConfig["非民用配置项"]=Object.assign({},res.data)
470
+ Vue.config.safecheck.DevicesSetConfig = res2.data
471
+ /*}).then(res=> {
472
+ })*/
473
+
474
+ } catch (e) {
475
+ self.$showMessage("获取配置文件失败" + e)
476
+ }
477
+ }
478
+ } catch (error) {
479
+ // 忽略704,文件找不到异常R
480
+ if (error.status !== 704) {
481
+ throw error
482
+ }
483
+ }
484
+ }
485
+ export default {
486
+ title: '安检单',
487
+ props: ['f_plan_id', 'item', 'role'],
488
+ data() {
489
+ return {
490
+ wave:null,
491
+ data: {
492
+ f_devices: [],
493
+ f_defect_content: '',
494
+ },
495
+ wavesurfer: null,
496
+ options: {
497
+ waveColor: '#1E90FF',
498
+ progressColor: '#00FFFF',
499
+ cursorColor: '#000000',
500
+ barWidth: 3,
501
+ hideScrollbar: true,
502
+ height: 200,
503
+ normalize: true
504
+ },
505
+ paperdata: {},
506
+ picturename: '隐患照片',
507
+ defectDevice: {},
508
+ hasDevice: false,
509
+ deviceCollect: {},
510
+ deviceCollects: [],
511
+ isshow: false,
512
+ ajresult: '',
513
+ loading: true,
514
+ imgshow: false,
515
+ imgshow2: false,
516
+ isUpload: false,
517
+ livedispose: '',
518
+ showimg1: '',
519
+ showimg2: '',
520
+ showimg3: '',
521
+ showimg4: '',
522
+ showimg5: '',
523
+ showimg6: '',
524
+ showimg7: '',
525
+ showimg8: '',
526
+ hiddenDangerImgNumber: 0, //配置项中隐患照片数
527
+ otherDarginShowImgs: [],//其他隐患图片
528
+ startClick: false, //开始安检按钮是否可点击
529
+ isStrat: false, //是否开始安检
530
+ checkResult: {},//查询结果
531
+ newcheckResult: {},
532
+ timer: null,
533
+ showModal: false,
534
+ pic_to_be_viewed: '',
535
+ showBack: true,
536
+ devices: [],
537
+ devicesAll: [],
538
+ configAJ: [],
539
+ configRQ: [],
540
+ deviceconfig: {},
541
+ deviceconfig2: [],
542
+ f_devices: [],
543
+ config: {
544
+ "燃气表": {
545
+ "checkmust": true,
546
+ "index": 1,
547
+ "items": {
548
+ "气表品牌":{"index":1,"type":"string","readonly":true},
549
+ "气表型号":{"index":2,"type":"string","readonly":true},
550
+ "气表编号":{"index":3,"type":"string","readonly":true},
551
+ "气表封号":{"index":4,"type":"string","readonly": true},
552
+ "进气方向":{"index":5,"type":"string","readonly":true},
553
+ "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true},
554
+ "气表累购":{"index":7,"type":"number","readonly":true}, //卡
555
+ "金额累购":{"index":7,"type":"number","readonly":true}, //卡
556
+ "已用气量":{"index":8,"type":"number","checkmust": false},//基表数卡
557
+ "已用金额":{"index":8,"type":"number","checkmust": false},//基表数卡
558
+ "剩余气量":{"index":9,"type":"number","checkmust": false},//累购-已用
559
+ "系统金额":{"index":9,"type":"number","checkmust": false},
560
+ "表内剩余":{"index":10,"type":"number","readonly":false},
561
+ "气量异常差值":{"index":11,"type":"number","readonly": true},
562
+ "金额异常差值":{"index":11,"type":"number","readonly": true},
563
+ "上次基数":{"index":12,"type":"number","readonly":true},
564
+ "本次基数":{"index":13,"type":"number","readonly":false},
565
+ "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
566
+ }
567
+ // 注意,配置项的index必须与上面的固定配置保持'顺序'
568
+ }
569
+ },
570
+ //金额
571
+ config2: {
572
+ "燃气表": {
573
+ "checkmust": true,
574
+ "index": 1,
575
+ "items": {
576
+ "气表品牌":{"index":1,"type":"string","readonly":true},
577
+ "气表型号":{"index":2,"type":"string","readonly":true},
578
+ "气表编号":{"index":3,"type":"string","readonly":true},
579
+ "气表封号":{"index":4,"type":"string","readonly": true},
580
+ "进气方向":{"index":5,"type":"string","readonly":true},
581
+ "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true},
582
+ "气表累购":{"index":7,"type":"number","readonly":true}, //卡
583
+ // "金额累购":{"index":7,"type":"number","readonly":true}, //卡
584
+ "已用气量":{"index":8,"type":"number","checkmust": false},//基表数卡
585
+ // "已用金额":{"index":8,"type":"number","checkmust": false},//基表数卡
586
+ // "剩余气量":{"index":9,"type":"number","checkmust": false},//累购-已用
587
+ // "系统金额":{"index":9,"type":"number","checkmust": false},
588
+ "表内剩余":{"index":10,"type":"number","readonly":false},
589
+ "气量异常差值":{"index":11,"type":"number","readonly": true},
590
+ // "金额异常差值":{"index":11,"type":"number","readonly": true},
591
+ "上次基数":{"index":12,"type":"number","readonly":true},
592
+ "本次基数":{"index":13,"type":"number","readonly":false},
593
+ "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
594
+ }
595
+ }
596
+ },
597
+ config3: {
598
+ "燃气表": {
599
+ "checkmust": true,
600
+ "index": 1,
601
+ "items": {
602
+ "气表品牌":{"index":1,"type":"string","readonly":true},
603
+ "气表型号":{"index":2,"type":"string","readonly":true},
604
+ "气表编号":{"index":3,"type":"string","readonly":true},
605
+ "气表封号":{"index":4,"type":"string","readonly": true},
606
+ "进气方向":{"index":5,"type":"string","readonly":true},
607
+ // "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true,"isshow":false},
608
+ // "气表累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
609
+ // "金额累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
610
+ // "已用气量":{"index":8,"type":"number","checkmust": false,"isshow":false },//基表数卡
611
+ // "已用金额":{"index":8,"type":"number","checkmust": false,"isshow":false},//基表数卡
612
+ // "剩余气量":{"index":9,"type":"number","checkmust": false,"isshow":false},//累购-已用
613
+ "系统金额":{"index":9,"type":"number","checkmust": false},
614
+ "表内剩余":{"index":10,"type":"number","readonly":false},
615
+ // "气量异常差值":{"index":11,"type":"number","readonly": true,"isshow":false},
616
+ "金额异常差值":{"index":11,"type":"number","readonly": true},
617
+ "上次基数":{"index":12,"type":"number","readonly":true},
618
+ "本次基数":{"index":13,"type":"number","readonly":false},
619
+ "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
620
+ }
621
+ }
622
+ },
623
+ config4: {
624
+ "燃气表": {
625
+ "checkmust": true,
626
+ "index": 1,
627
+ "items": {
628
+ "气表品牌":{"index":1,"type":"string","readonly":true},
629
+ "气表型号":{"index":2,"type":"string","readonly":true},
630
+ "气表编号":{"index":3,"type":"string","readonly":true},
631
+ "气表封号":{"index":4,"type":"string","readonly": true},
632
+ "进气方向":{"index":5,"type":"string","readonly":true},
633
+ // "初始表底":{"index":6,"type":"number","isshow":false,"readonly":true,"isshow":false},
634
+ // "气表累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
635
+ // "金额累购":{"index":7,"type":"number","readonly":true,"isshow":false}, //卡
636
+ // "已用气量":{"index":8,"type":"number","checkmust": false,"isshow":false },//基表数卡
637
+ // "已用金额":{"index":8,"type":"number","checkmust": false,"isshow":false},//基表数卡
638
+ // "剩余气量":{"index":9,"type":"number","checkmust": false,"isshow":false},//累购-已用
639
+ // "系统金额":{"index":9,"type":"number","checkmust": false},
640
+ "表内剩余":{"index":10,"type":"number","readonly":false},
641
+ // "气量异常差值":{"index":11,"type":"number","readonly": true,"isshow":false},
642
+ // "金额异常差值":{"index":11,"type":"number","readonly": true},
643
+ "上次基数":{"index":12,"type":"number","readonly":true},
644
+ "本次基数":{"index":13,"type":"number","readonly":false},
645
+ "周期用气":{"index":14,"type":"number","readonly":true}, //上次-本次
646
+ }
647
+ }
648
+ },
649
+ }
650
+ },
651
+ components: {
652
+ RadioGroup,
653
+ Radio,
654
+ },
655
+ computed: {
656
+ isRecodrDownloadBtn(){
657
+ // 投诉单下派还是处理
658
+ let res = this.$appdata.getSingleValue('无限制录音');
659
+ if (res == 'true'){
660
+ return true;
661
+ }else {
662
+ return false;
663
+ }
664
+ },
665
+ selector: {
666
+ get() {
667
+ return 'paper-state'
668
+ },
669
+ set(val) {
670
+ if (this.isStrat) {
671
+ //;
672
+ this.$goto(val, {userinfo: this.data}, 'paper-router')
673
+ } else {
674
+ this.$showMessage('未开始安检!')
675
+ }
676
+ }
677
+ },
678
+ actionEnabled: {
679
+ get() {
680
+ return this.role == 'inspect'
681
+ }
682
+ }
683
+ },
684
+ methods: {
685
+ async getbaseYin() {
686
+ this.wave.playPause()
687
+ },
688
+ stop(){
689
+ this.wave.stop()
690
+ },
691
+
692
+ devicesCollect() {
693
+ //tag
694
+ //tag)
695
+ //tag)
696
+ //tag
697
+
698
+ this.deviceCollects = []
699
+ let checkResult = '正常'
700
+ this.result = '正常'
701
+ let codata = JSON.parse(JSON.stringify(this.data))
702
+ //tag)
703
+ for (let device in this.data) {
704
+ let f_device_type
705
+ if (device.startsWith("device")) {
706
+ for (let item in this.data[device]) {
707
+ if (this.data[device].length > 1) {
708
+ let j = Number.parseInt(item) + 1
709
+ f_device_type = `${this.data[device][item].f_device_type}${j}`
710
+ } else {
711
+ f_device_type = this.data[device][item].f_device_type
712
+ }
713
+ // //tag
714
+ let deviceInfos = []
715
+ for (let i in this.data[device][item].f_items) {
716
+ let defects = ''
717
+ let items = this.data[device][item].f_items[i]
718
+ if ((items.type === 'selector' || items.type === 'radio' || items.type === 'checkbox') && items.f_item_value != null && items.f_item_value instanceof Array) {
719
+ for (let i in items.f_item_value) {
720
+ let f_item_value = items.f_item_value[i]
721
+
722
+ //tag)
723
+ //tag)
724
+ //tag)
725
+ //tag)
726
+ if (!this.config[this.data[device][item].f_device_type].items[items.f_item_name]) {
727
+ continue
728
+ }
729
+ let options = this.config[this.data[device][item].f_device_type].items[items.f_item_name].options
730
+ for (let option in options) {
731
+ if (options[option].data == f_item_value) {
732
+ if (options[option].isdefect == 'true' || options[option].isdefect == true) {
733
+ checkResult = '有隐患'
734
+ this.result = '有隐患'
735
+ defects = `${defects}:${options[option].data}/`
736
+ // let level = options[option].level
737
+ }
738
+ }
739
+ }
740
+ //tag)
741
+ }
742
+ if (defects != '') {
743
+ deviceInfos.push(`${items.f_item_name}${defects.substring(0, defects.length - 1)}`)
744
+ }
745
+ } else if (items.type === 'string' && items.f_is_defect && items.f_item_value[0] ) {
746
+ checkResult = '有隐患'
747
+ this.result = '有隐患'
748
+ deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
749
+ } else if (items.f_item_name == '金额异常差值') {
750
+ var deviation = this.$appdata.getSingleValue('金额异常差值允许误差')
751
+ //tag
752
+ if (parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN") {
753
+ if (parseFloat(items.f_item_value[0]) > parseFloat(deviation) || parseFloat(items.f_item_value[0]) < parseFloat(deviation) * -1) {
754
+ checkResult = '有隐患'
755
+ this.result = '有隐患'
756
+ deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
757
+ }
758
+ }
759
+ } else if (items.f_item_name == '气量异常差值') {
760
+ var deviation = this.$appdata.getSingleValue('气量异常差值允许误差')
761
+ //tag
762
+ if (parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN") {
763
+ if (parseFloat(items.f_item_value[0]) > parseFloat(deviation) || parseFloat(items.f_item_value[0]) < parseFloat(deviation) * -1) {
764
+ checkResult = '有隐患'
765
+ this.result = '有隐患'
766
+ deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
767
+ }
768
+ }
769
+ }
770
+ //tag)
771
+ //tag
772
+ //tag
773
+ if (items.type === 'selector') {
774
+ items.selected = []
775
+ } else if (items.type === 'inputSelector') {
776
+ items.selected = ''
777
+ }
778
+ }
779
+
780
+
781
+ //tag
782
+ this.$set('deviceCollect.name', f_device_type)
783
+ this.$set('deviceCollect.value', checkResult)
784
+ this.$set('deviceCollect.devices', deviceInfos)
785
+ //tag)
786
+ if (this.deviceCollect.name) {
787
+ //tag
788
+ this.deviceCollects.push(JSON.parse(JSON.stringify(this.deviceCollect)))
789
+ }
790
+
791
+ checkResult = '正常'
792
+ this.deviceCollect = {}
793
+ }
794
+ }
795
+ }
796
+ if (this.deviceCollects.length > 0) {
797
+ this.hasDevice = true
798
+ }
799
+ this.ajresult = JSON.parse(this.data.f_defect_content).result
800
+ this.showimg3 = this.data.f_noanswer_path
801
+ this.showimg5 = this.data.f_noanswer1_path
802
+ this.showimg6 = this.data.f_noanswer2_path
803
+ this.showimg4 = this.data.f_rejectcheck_path
804
+ this.showimg7 = this.data.f_rejectcheck1_path
805
+ this.showimg8 = this.data.f_rejectcheck2_path
806
+ this.paperdata = this.data
807
+ this.loading = false
808
+ },
809
+ imgclose() {
810
+ this.imgshow = false
811
+ },
812
+ putDevices() {
813
+ ////tag
814
+ this.$set('data.approve', "true")
815
+ this.$set('data.writeback', "false")
816
+ if (Vue.config.safecheck.ApproveConfig != undefined) {
817
+ if (Vue.config.safecheck.ApproveConfig.approve != undefined) {
818
+ this.$set('data.approve', Vue.config.safecheck.ApproveConfig.approve)
819
+ }
820
+ if (Vue.config.safecheck.ApproveConfig.writeback != undefined) {
821
+ this.$set('data.writeback', Vue.config.safecheck.ApproveConfig.writeback)
822
+ }
823
+ if (Vue.config.safecheck.ApproveConfig.livedispose != undefined) {
824
+ this.livedispose = Vue.config.safecheck.ApproveConfig.livedispose
825
+ }
826
+ if(Vue.config.safecheck.ApproveConfig.hiddendanger != undefined) {
827
+ if (parseInt(Vue.config.safecheck.ApproveConfig.hiddendanger) >= 3) {
828
+ this.hiddenDangerImgNumber = 3
829
+ }else {
830
+ this.hiddenDangerImgNumber = parseInt(Vue.config.safecheck.ApproveConfig.hiddendanger)
831
+ }
832
+ }
833
+ }
834
+ //tag
835
+
836
+ //tag)
837
+ if (!this.item.f_safecheck_type) {
838
+ this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType['年度普检'][this.item.f_check_type]])
839
+ } else {
840
+ if (Vue.config.safecheck.DevicesConfig != undefined)
841
+ this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType[this.item.f_safecheck_type][this.item.f_check_type]])
842
+ }
843
+ //遍历安检项配置
844
+ for (let i in this.config) {
845
+ //取得安检项索引值
846
+ let n = this.config[i].index
847
+ this.devices[n - 1] = {device: i, n: n, checkmust: this.config[i].checkmust}
848
+ this.$set('data.' + 'device' + n, [])
849
+ let items = []
850
+ for (let it in this.config[i].items) {
851
+ //赋值下拉选项
852
+ if (this.config[i].items[it].type == 'selector') {
853
+ for (let op in this.config[i].items[it].options)
854
+ if (this.config[i].items[it].options[op].isdefault == true) {
855
+ items.push({
856
+ f_defect_level: this.config[i].items[it].options[op].level,
857
+ f_is_defect: this.config[i].items[it].options[op].isdefect,
858
+ f_item_name: it,
859
+ f_item_value: this.config[i].items[it].options[op].data,
860
+ f_path: "",
861
+ type: "selector"
862
+ })
863
+ }
864
+ }
865
+ }
866
+ n = n + 1
867
+ }
868
+
869
+ },
870
+ showpath(val1, val2) {
871
+ //tag
872
+ //tag
873
+ if (val1) {
874
+ this.showimg1 = val1
875
+ this.picturename = val2
876
+ this.imgshow = true
877
+ }
878
+ },
879
+ showpicture(val1, val2) {
880
+ //tag
881
+ if (val2 == '气量异常差值' || val2 == '金额异常差值') {
882
+ return
883
+ }
884
+ for (let i = 0; i < this.devicesAll.length; i++) {
885
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
886
+ if (this.devicesAll[i][j].f_device_type == val1) {
887
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
888
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
889
+ if (!this.devicesAll[i][j].f_items[k].f_is_defect) {
890
+ return false
891
+ } else {
892
+ this.showimg1 = this.devicesAll[i][j].f_items[k].f_path
893
+ this.showimg2 = this.devicesAll[i][j].f_items[k].f_second_path
894
+ this.otherDarginShowImgs = []
895
+ for (let l = 0; l < this.hiddenDangerImgNumber; l++) {
896
+ let img = {path:''}
897
+ if (this.devicesAll[i][j].f_items[k]['f_p' + (l+1)+'_path']) {
898
+ img.path = this.devicesAll[i][j].f_items[k]['f_p' + (l+1)+'_path'] + '?' + Math.random()
899
+ this.otherDarginShowImgs.push(img)
900
+ }
901
+ }
902
+ this.picturename = '隐患照片'
903
+ this.imgshow = true
904
+ return true
905
+ }
906
+ }
907
+ }
908
+
909
+ }
910
+ }
911
+ }
912
+ },
913
+ isred(val1, val2) {
914
+ //tag
915
+ if (val2 == '气量异常差值' || val2 == '金额异常差值') {
916
+ return
917
+ }
918
+ for (let i = 0; i < this.devicesAll.length; i++) {
919
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
920
+ if (this.devicesAll[i][j].f_device_type == val1) {
921
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
922
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
923
+ if (!this.devicesAll[i][j].f_items[k].f_is_defect) {
924
+ return false
925
+ } else {
926
+ return true
927
+ }
928
+ }
929
+ }
930
+
931
+ }
932
+ }
933
+ }
934
+ },
935
+ showpicture2() {
936
+ this.imgshow2 = true
937
+ },
938
+ getDeviceValue(val1, val2) {
939
+ let aa = ''
940
+ for (let i = 0; i < this.devicesAll.length; i++) {
941
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
942
+ if (this.devicesAll[i][j].f_device_type == val1) {
943
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
944
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
945
+ if (this.devicesAll[i][j].f_items[k].f_item_lists[0]) {
946
+ for (let l = 0; l < this.devicesAll[i][j].f_items[k].f_item_lists.length; l++) {
947
+ let val = this.devicesAll[i][j].f_items[k].f_item_lists[l].f_item_value
948
+ aa += (val === null ? '空' : val) + ' '
949
+ }
950
+ return aa
951
+ }
952
+ }
953
+ }
954
+
955
+ }
956
+ }
957
+ }
958
+
959
+ },
960
+ getDevicePath(val1, val2) {
961
+ for (let i = 0; i < this.devicesAll.length; i++) {
962
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
963
+ if (this.devicesAll[i][j].f_device_type == val1) {
964
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
965
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
966
+ return this.devicesAll[i][j].f_items[k].f_path
967
+ }
968
+ }
969
+
970
+ }
971
+ }
972
+ }
973
+
974
+ },
975
+ getDeviceAll() {
976
+ let keyall = Object.keys(this.data)
977
+ for (let i = 0; i < keyall.length; i++) {
978
+ //tag)
979
+ if (keyall[i].startsWith('device') && keyall[i] != 'deviceundefined') {
980
+ this.devicesAll.push(this.data[keyall[i]])
981
+ //tag
982
+ }
983
+ }
984
+ //tag
985
+ //tag)
986
+ this.devicesCollect()
987
+
988
+ },
989
+
990
+ back() {
991
+ if (this.role == 'inspect') {
992
+ if (!this.isStrat) {
993
+ this.$back()
994
+ return
995
+ } else {
996
+ this.savePaper(true).then(() => {
997
+ this.$back()
998
+ this.isStrat = false
999
+ })
1000
+ }
1001
+ } else {
1002
+ this.$back()
1003
+ }
1004
+ },
1005
+ checkIsStart() {
1006
+ alert('asdad')
1007
+ return
1008
+ },
1009
+
1010
+ viewPic(fileName) {
1011
+ //tag
1012
+ if (this.role == 'view') {
1013
+ if (!fileName.endsWith('nopic.png')) {
1014
+ this.pic_to_be_viewed = fileName
1015
+ this.showModal = true
1016
+ }
1017
+ } else {
1018
+ HostApp.viewPic(fileName)
1019
+ }
1020
+ },
1021
+ tick() {
1022
+ this.timer = null
1023
+ this.data.f_offsite_time = Util.toStandardTimeString()
1024
+ this.timer = window.setTimeout(this.tick, 1000)
1025
+ },
1026
+ getRepairState() {
1027
+ let repaired = true
1028
+ this.data.f_defects.forEach((defect) => {
1029
+ repaired = repaired & (defect.f_ratification == '已处理')
1030
+ })
1031
+ return repaired
1032
+ },
1033
+ verifyRepairDefects() {
1034
+ this.data.f_repair_date = Util.toStandardTimeString()
1035
+ this.data.f_repaired = this.getRepairState() ? '已修' : '在修'
1036
+ },
1037
+ genuineSave(saveOnly) {
1038
+ HostApp.__this__.save(saveOnly)
1039
+ if (!saveOnly)
1040
+ HostApp.__this__.disableTimer()
1041
+ HostApp.__callback__ = null
1042
+ HostApp.__this__ = null
1043
+ },
1044
+ setUrgency() {
1045
+ this.data.f_defect_urgency = 'Z'
1046
+ let that = this
1047
+ this.data.f_defects.forEach(function (defect) {
1048
+ if (that.data.f_defect_urgency > defect.f_defect_level.charAt(0))
1049
+ that.data.f_defect_urgency = defect.f_defect_level.charAt(0)
1050
+ })
1051
+ if (this.data.f_defect_urgency == 'Z')
1052
+ this.data.f_defect_urgency = null
1053
+ },
1054
+ disableTimer() {
1055
+ if (this.timer) {
1056
+ window.clearTimeout(this.timer)
1057
+ this.timer = null
1058
+ }
1059
+ },
1060
+ loaded(paper) {
1061
+ if (!paper.hasOwnProperty('id')) {
1062
+ this.$showMessage("该安检单在手机上已经不存在,可能是卸载过程序。可以进入重新安检,或返回安检计划。")
1063
+ this.init()
1064
+ } else {
1065
+ Util.booleanFilter(paper)
1066
+ HostApp.__this__.$set('data', paper)
1067
+ HostApp.__this__.$goto('paper-state', {}, 'paper-router')
1068
+ // 如果打回重检则重新计时
1069
+ //tag
1070
+ if (HostApp.__this__.role == 'inspect'
1071
+ && HostApp.__this__.data.f_approved
1072
+ && HostApp.__this__.data.f_approved == '打回') {
1073
+ //tag
1074
+ HostApp.__this__.data.f_onsite_time = Util.toStandardTimeString()
1075
+ HostApp.__this__.tick()
1076
+ }
1077
+ }
1078
+ HostApp.__callback__ = null
1079
+ HostApp.__this__ = null
1080
+ },
1081
+ S4() {
1082
+ return (((1 + Math.random()) * 0x10000) | 0).toString(16).substring(1);
1083
+ },
1084
+ init() {
1085
+ this.data.f_noplan_item_id = this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4()
1086
+ this.data.ename = Vue.user.ename
1087
+ this.data.f_outlets = Vue.user.f_parentname
1088
+ this.data.f_meetunit = Vue.user.orgpathnames
1089
+ this.data.orgpathstr = Vue.user.orgpathstr
1090
+ this.data.f_check_item_id = this.item.id
1091
+ this.data.f_check_plan_id = this.f_plan_id
1092
+ this.data.f_checker_id = Vue.user.id
1093
+ this.data.f_checker_name = Vue.user.name
1094
+ this.data.f_check_type = this.item.f_user_type
1095
+ this.data.f_subcompany = this.item.f_subcompany
1096
+ this.data.f_approved = this.item.f_approved
1097
+ this.data.f_repair_approved = this.item.f_repair_approved
1098
+ this.data.f_no_checkplan = this.item.f_no_checkplan
1099
+ this.data.f_approved = this.item.f_approved
1100
+ this.data.f_filialeid = this.item.f_filialeid
1101
+ this.data.f_orgstr = this.item.f_orgstr
1102
+ this.data.version = this.item.version
1103
+ this.$set('data.f_meters', this.item.f_plan_meters)
1104
+ this.$set('data.f_userinfo_code', this.item.f_userinfo_code)
1105
+ // 安检状态
1106
+ this.$set('data.f_entry_status', '入户')
1107
+ this.$set('data.f_usegas', '已使用')
1108
+ this.$set('data.f_state', this.item.f_state)
1109
+ // 用户信息
1110
+ this.$set('data.f_user_name', this.item.f_user_name)
1111
+ this.$set('data.f_user_phone', this.item.f_user_phone)
1112
+ this.$set('data.f_userinfoid', this.item.f_userinfoid)
1113
+ this.$set('data.f_address', this.item.f_address)
1114
+ this.$set('data.f_card_id', this.item.f_card_id)
1115
+ this.$set('data.f_area', this.item.f_area)
1116
+ this.$set('data.f_street', this.item.f_street)
1117
+ this.$set('data.f_room', this.item.f_room)
1118
+ this.$set('data.f_building', this.item.f_building)
1119
+ this.$set('data.f_unit', this.item.f_unit)
1120
+ this.$set('data.f_floor', this.item.f_floor)
1121
+ this.$set('data.f_residential_area', this.item.f_residential_area)
1122
+ this.$set('data.f_idnumber', this.item.f_idnumber)
1123
+ this.$set('data.f_comments', this.item.f_comments)
1124
+ this.$set('data.f_userproperties', this.item.f_userproperties)
1125
+ // 处置方式
1126
+ this.$set('data.f_no_gas_device', false)
1127
+ this.$set('data.f_close_valve', false)
1128
+ this.$set('data.f_unload_battery', false)
1129
+ if (this.data.f_check_item_id == '' && this.item.f_no_checkplan == '无计划安检') {
1130
+ this.data.f_check_item_id = this.data.f_noplan_item_id
1131
+ }
1132
+
1133
+ //房屋结构
1134
+ // this.$set('data.f_room_style', '多层')
1135
+ //供暖方式
1136
+ // this.$set('data.f_heating_style', '热力公司集中供暖')
1137
+ if (this.item.f_plan_meters) {
1138
+ for (let de in this.devices) {
1139
+ this.$set('data.device' + this.devices[de].n, [])
1140
+ for (let i = 0; i < this.item.f_plan_meters.length; i++) {
1141
+ if (this.item.f_plan_meters[i].f_meter_type) {
1142
+ if (this.devices[de].device == "燃气表" && this.item.f_plan_meters[i].f_meter_type.indexOf('机表') > 0) {
1143
+ delete this.config['燃气表']['items']['累计购气量']
1144
+ this.data['device' + this.devices[de].n].push({
1145
+ f_device_type: "燃气表",
1146
+ f_items: [{
1147
+ f_defect_level: null,
1148
+ f_device_id: "",
1149
+ f_is_defect: "",
1150
+ f_item_name: "表品牌",
1151
+ f_item_value: this.item.f_plan_meters[i].f_aliasname,
1152
+ f_path: "",
1153
+ type: "string"
1154
+ },
1155
+ {
1156
+ f_defect_level: null,
1157
+ f_device_id: "",
1158
+ f_is_defect: "",
1159
+ f_item_name: "位置",
1160
+ f_item_value: this.item.f_plan_meters[i].f_weizhi,
1161
+ f_path: "",
1162
+ type: "selector"
1163
+ },
1164
+ {
1165
+ f_defect_level: null,
1166
+ f_device_id: "",
1167
+ f_is_defect: "",
1168
+ f_item_name: "表号",
1169
+ f_item_value: this.item.f_plan_meters[i].f_meter_no,
1170
+ f_path: "",
1171
+ type: "number"
1172
+ },
1173
+ {
1174
+ f_defect_level: null,
1175
+ f_device_id: "",
1176
+ f_is_defect: "",
1177
+ f_item_name: "表封号",
1178
+ f_item_value: this.item.f_plan_meters[i].f_metertitles,
1179
+ f_path: "",
1180
+ type: "number"
1181
+ },
1182
+ {
1183
+ f_defect_level: null,
1184
+ f_device_id: "",
1185
+ f_is_defect: "",
1186
+ f_item_name: "表型号",
1187
+ f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1188
+ f_path: "",
1189
+ type: "selector"
1190
+ },
1191
+ {
1192
+ f_defect_level: null,
1193
+ f_device_id: "",
1194
+ f_is_defect: "",
1195
+ f_item_name: "表底数",
1196
+ f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1197
+ f_path: "",
1198
+ type: "number"
1199
+ }
1200
+ ]
1201
+ })
1202
+ } else if (this.devices[de].device == "燃气表") {
1203
+ delete this.config['燃气表']['items']['表底数']
1204
+ this.data['device' + this.devices[de].n].push({
1205
+ f_device_type: "燃气表",
1206
+ f_items: [{
1207
+ f_defect_level: null,
1208
+ f_device_id: "",
1209
+ f_is_defect: "",
1210
+ f_item_name: "表品牌",
1211
+ f_item_value: this.item.f_plan_meters[i].f_aliasname,
1212
+ f_path: "",
1213
+ type: "string"
1214
+ },
1215
+ {
1216
+ f_defect_level: null,
1217
+ f_device_id: "",
1218
+ f_is_defect: "",
1219
+ f_item_name: "位置",
1220
+ f_item_value: this.item.f_plan_meters[i].f_weizhi,
1221
+ f_path: "",
1222
+ type: "selector"
1223
+ },
1224
+ {
1225
+ f_defect_level: null,
1226
+ f_device_id: "",
1227
+ f_is_defect: "",
1228
+ f_item_name: "表号",
1229
+ f_item_value: this.item.f_plan_meters[i].f_meter_no,
1230
+ f_path: "",
1231
+ type: "number"
1232
+ },
1233
+ {
1234
+ f_defect_level: null,
1235
+ f_device_id: "",
1236
+ f_is_defect: "",
1237
+ f_item_name: "表封号",
1238
+ f_item_value: this.item.f_plan_meters[i].f_metertitles,
1239
+ f_path: "",
1240
+ type: "number"
1241
+ },
1242
+ {
1243
+ f_defect_level: null,
1244
+ f_device_id: "",
1245
+ f_is_defect: "",
1246
+ f_item_name: "表型号",
1247
+ f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1248
+ f_path: "",
1249
+ type: "selector"
1250
+ },
1251
+ {
1252
+ f_defect_level: null,
1253
+ f_device_id: "",
1254
+ f_is_defect: "",
1255
+ f_item_name: "累计购气量",
1256
+ f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1257
+ f_path: "",
1258
+ type: "number"
1259
+ }
1260
+ ]
1261
+ })
1262
+ }
1263
+ }
1264
+ }
1265
+ }
1266
+ }
1267
+
1268
+ this.$goto('paper-state', {}, 'paper-router')
1269
+ },
1270
+ extend(initalObj, finalObj) {
1271
+ var obj = finalObj || {};
1272
+ for (var i in initalObj) {
1273
+ var prop = initalObj[i];
1274
+
1275
+ // 避免相互引用对象导致死循环,如initalObj.a = initalObj的情况
1276
+ if (prop === obj) {
1277
+ continue;
1278
+ }
1279
+
1280
+ if (typeof prop === 'object') {
1281
+ if (obj[i]) {
1282
+ this.extend(obj[i], prop)
1283
+ } else {
1284
+ obj[i] = prop;
1285
+ }
1286
+ }
1287
+ }
1288
+ return obj;
1289
+ },
1290
+ //获取当前时间
1291
+ getNowFormatDate() {
1292
+ var date = new Date();
1293
+ var seperator1 = "-";
1294
+ var seperator2 = ":";
1295
+ var month = date.getMonth() + 1;
1296
+ var strDate = date.getDate();
1297
+ if (month >= 1 && month <= 9) {
1298
+ month = "0" + month;
1299
+ }
1300
+ if (strDate >= 0 && strDate <= 9) {
1301
+ strDate = "0" + strDate;
1302
+ }
1303
+ var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
1304
+ + " " + date.getHours() + seperator2 + date.getMinutes()
1305
+ + seperator2 + date.getSeconds();
1306
+ return currentdate;
1307
+ }
1308
+ },
1309
+ ready() {
1310
+ this.putDevices()
1311
+ if (this.item.f_state != '未检' || this.item.f_no_checkplan == '无计划安检') {
1312
+ if (this.role != 'inspect') {
1313
+ let that = this
1314
+ let id
1315
+ if (this.role == 'view') {
1316
+ id = this.item.id
1317
+ } else if (this.role == 'androidview') {
1318
+ id = this.item.f_paper_id
1319
+ }
1320
+ this.$resetpost(`rs/path/getUserinfomation`, {data: {condition: `id = '${id}'`}}).then((respanse) => {
1321
+ //tag
1322
+ if (respanse.data.length != 0) {
1323
+ // 包含 其它 特殊处理的数组
1324
+ // 对应位置
1325
+
1326
+ //tag
1327
+
1328
+ that.data = Object.assign(that.data, respanse.data[0])
1329
+ if (respanse.data[0].f_devices) {
1330
+ for (let da in that.devices) {
1331
+ that.$set('data.device' + that.devices[da].n, [])
1332
+ }
1333
+ respanse.data[0].f_devices.forEach((item) => {
1334
+ for (let de in that.devices) {
1335
+ if (that.devices[de].device == item.f_device_type) {
1336
+ item.f_items.forEach((f_item) => {
1337
+ //tag
1338
+ //tag
1339
+ let itemValues = []
1340
+ f_item.f_item_lists.forEach((tempItem) => {
1341
+ //tag
1342
+ if (tempItem.f_item_value !== 'null') {
1343
+ itemValues.push(tempItem.f_item_value)
1344
+ }
1345
+ })
1346
+ f_item.f_item_value = itemValues
1347
+ })
1348
+ that.data['device' + that.devices[de].n].push({
1349
+ f_device_type: item.f_device_type,
1350
+ f_items: item.f_items
1351
+ })
1352
+ }
1353
+ }
1354
+ })
1355
+ }
1356
+ Util.replaceFalse(that.data)
1357
+ Util.booleanFilter(that.data)
1358
+ if (this.role == 'view') {
1359
+ Util.ratifyPics(that.data)
1360
+ Util.ratifyPics(that.picture)
1361
+ } else {
1362
+ Util.androidRatifyPics(that.data, this.$androidUtil.getProxyUrl())
1363
+ }
1364
+ //tag
1365
+ }
1366
+ // this.$goto('paper-message-blank', {userinfo:this.data,devices:this.devices,config:this.config,role:this.role}, 'self')
1367
+ this.isshow = true
1368
+ asyncReady(this).then(async () => {
1369
+ //tag
1370
+ //tag)
1371
+ if (this.data.f_check_type == '民用') {
1372
+ this.deviceconfig = Vue.config.safecheck.DevicesConfig
1373
+ console.log('打印',this.deviceconfig)
1374
+ if (typeof this.deviceconfig==='string'){
1375
+ this.deviceconfig=JSON.parse(this.deviceconfig)
1376
+ }
1377
+ //tag)
1378
+ } else if (this.data.f_check_type == '非民用') {
1379
+ this.deviceconfig = Vue.config.safecheck.DevicesSetConfig
1380
+ if (typeof this.deviceconfig==='string'){
1381
+ this.deviceconfig=JSON.parse(this.deviceconfig)
1382
+ }
1383
+ //tag)
1384
+ }
1385
+ /*await this.$resetpost('rs/sql/SafecheckTableModel', {data: {condition: ` 1 = 1 and uf.f_userinfo_id = '${this.item.f_userinfoid}'`}}).then((res) => {
1386
+ //tag)
1387
+ this.meter_classify = res.data[0].f_meter_classify
1388
+ })*/
1389
+ await this.$resetpost('rs/sql/safe_singleTable_OrderBy', {data:
1390
+ {
1391
+ items: 'f_meter_classify',
1392
+ tablename: 't_userfiles',
1393
+ condition: `1 = 1 and f_userinfo_id = '${this.item.f_userinfoid}'`,
1394
+ orderitem: 'f_userfiles_id'
1395
+ }
1396
+ }).then((res) => {
1397
+ //tag)
1398
+ this.meter_classify = res.data[0].f_meter_classify
1399
+ })
1400
+ if (this.data.f_collection_type == '按金额' && this.meter_classify=='机表') {
1401
+ let aaa = Object.assign({}, this.config4["燃气表"].items, this.deviceconfig["燃气表"].items)
1402
+ this.deviceconfig["燃气表"].items = aaa
1403
+ //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1404
+ //tag)
1405
+ }else if(this.data.f_collection_type == '按金额'&& this.meter_classify =='物联网表') {
1406
+ let aaa = Object.assign({}, this.config3["燃气表"].items, this.deviceconfig["燃气表"].items)
1407
+ this.deviceconfig["燃气表"].items = aaa
1408
+ //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1409
+ //tag)
1410
+ }else if(this.data.f_collection_type == '按气量'&& this.meter_classify =='气量卡表') {
1411
+ let aaa = Object.assign({}, this.config2["燃气表"].items, this.deviceconfig["燃气表"].items)
1412
+ this.deviceconfig["燃气表"].items = aaa
1413
+ //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1414
+ //tag)
1415
+ } else {
1416
+ let aaa = Object.assign({}, this.config["燃气表"].items, this.deviceconfig["燃气表"].items)
1417
+ this.deviceconfig["燃气表"].items = aaa
1418
+ //tag)
1419
+ }
1420
+ this.deviceconfig2 = ObjConfig.getObjConfig(this.deviceconfig)
1421
+ this.deviceconfig2[0].items = jsonSort(this.deviceconfig2[0].items, "index")
1422
+ this.deviceconfig2[1].items = jsonSort(this.deviceconfig2[1].items, "index")
1423
+ this.deviceconfig2 = jsonSort(this.deviceconfig2, "index")
1424
+ this.getDeviceAll()
1425
+
1426
+
1427
+ })
1428
+ }
1429
+ ).catch(
1430
+ (respanse) => {
1431
+ //tag
1432
+ alert('查找安检单失败')
1433
+ })
1434
+ }
1435
+ }
1436
+ this.$nextTick(()=>{
1437
+ console.log("332",document.getElementById("item.id"))
1438
+ this.wave = WaveSurfer.create({
1439
+ container: document.getElementById("item.id"),
1440
+ waveColor: this.options.waveColor,
1441
+ progressColor: this.options.progressColor,
1442
+ cursorColor: this.options.cursorColor,
1443
+ barWidth: this.options.barWidth,
1444
+ hideScrollbar: this.options.hideScrollbar,
1445
+ height: this.options.height,
1446
+ normalize: this.options.normalize
1447
+ });
1448
+ this.wave.load('/rs/audio/file/'+this.item.f_recording1_path)
1449
+ this.wave.on("loading", percents => {
1450
+ // 当前加载的进度
1451
+ console.log("播放中",percents)
1452
+ });
1453
+ })
1454
+
1455
+ },
1456
+ watch: {
1457
+ // 'isUpload'(val){
1458
+ // //tag
1459
+ // }
1460
+ },
1461
+ destroyed() {
1462
+ //tag
1463
+ this.disableTimer()
1464
+ }
1465
+ }
1466
+
1467
+ </script>
1468
+ <style scoped>
1469
+ .table-striped thead tr th {
1470
+ background-color: rgb(223, 237, 251);
1471
+ padding: 10px;
1472
+ border-left: solid 0px #dae4f2;
1473
+ border-top: solid 1px #dae4f2;
1474
+ border-right: none;
1475
+ border-bottom: none;
1476
+ text-align: center;
1477
+ color: black;
1478
+ }
1479
+ </style>