safecheck-client 3.0.34-9 → 3.0.34-90

Sign up to get free protection for your applications and to get access to all the features.
Files changed (136) hide show
  1. package/package.json +1 -1
  2. package/src/App-/345/215/225/351/241/265/351/235/242/346/211/223/345/214/205/347/224/250.vue +55 -0
  3. package/src/assets/123.png +0 -0
  4. package/src/assets/f8632d3c8c4c1cb68e99da754cab1a7.png +0 -0
  5. package/src/components/LoadData.vue +62 -0
  6. package/src/components/NewDefectList/DefectListNew.vue +1 -0
  7. package/src/components/android/AddPlanItemYy.vue +451 -0
  8. package/src/components/android/AndroidDefectDeal.vue +634 -634
  9. package/src/components/android/AndroidDefectDealBeforeSafe.vue +502 -0
  10. package/src/components/android/AreaSelect.vue +198 -0
  11. package/src/components/android/BuildingSelect.vue +192 -0
  12. package/src/components/android/CheckPlanSelect.vue +229 -0
  13. package/src/components/android/CurrentCreateYy.vue +1051 -0
  14. package/src/components/android/PaperFeedback.vue +33 -0
  15. package/src/components/android/QRCode/QRCodeBinding.vue +300 -0
  16. package/src/components/android/QRCode/QRCodePage.vue +212 -0
  17. package/src/components/android/SafecheckDevices.vue +2 -2
  18. package/src/components/android/SafecheckOrderV.vue +8 -12
  19. package/src/components/android/UserinfoSelect.vue +714 -0
  20. package/src/components/android/examples/410.png +0 -0
  21. package/src/components/android/examples/SafeListExamples.vue +279 -0
  22. package/src/components/android/examples/UserExamples.vue +137 -0
  23. package/src/components/android/examples/ViewDetailsExamples.vue +1235 -0
  24. package/src/components/android/examples/touxiang.png +0 -0
  25. package/src/components/pc/SafeVisitInfo.vue +261 -0
  26. package/src/components/rongcheng/AddPlanItem.vue +8 -0
  27. package/src/components/rongcheng/AspiratedUserInfo.vue +1 -1
  28. package/src/components/rongcheng/CheckSearchUser.vue +46 -16
  29. package/src/components/rongcheng/PaperStatem.vue +6 -1
  30. package/src/components/rongcheng/PhoneDevicesInfo.vue +16 -1
  31. package/src/components/rongcheng/PhoneUpUserinfo.vue +0 -92
  32. package/src/components/rongcheng/SafecheckOrderV.vue +12 -3
  33. package/src/components/rongcheng/SafecheckOrderVCli.vue +9 -0
  34. package/src/filiale/baiyin/android/AndroidDefectDeal.vue +4 -4
  35. package/src/filiale/baiyin/android/SafecheckOrderV.vue +2785 -0
  36. package/src/filiale/baiyin/android.js +1 -0
  37. package/src/filiale/baiyin/pc/CheckSearchUser.vue +2 -2
  38. package/src/filiale/baiyin/pc/DefectListNew.vue +3 -3
  39. package/src/filiale/baiyin/pc/PaperList.vue +7 -7
  40. package/src/filiale/bayan/android/AddPlanItem.vue +8 -0
  41. package/src/filiale/bayan/android/PaperFeedback.vue +63 -49
  42. package/src/filiale/bayan/android/PhoneUpUserinfo.vue +40 -40
  43. package/src/filiale/bayan/android/SafecheckOrderV.vue +58 -58
  44. package/src/filiale/bayan/android/SafecheckUserInfo.vue +5 -0
  45. package/src/filiale/bayan/pc/PaperList.vue +1 -0
  46. package/src/filiale/fugou/pc/CheckBookSearchUser.vue +35 -15
  47. package/src/filiale/huaran/android/SafecheckOrderV.vue +2803 -0
  48. package/src/filiale/huaran/android.js +12 -0
  49. package/src/filiale/huaran/pc/CheckBook.vue +313 -0
  50. package/src/filiale/huaran/pc/CheckBookAll.vue +69 -0
  51. package/src/filiale/huaran/pc/CheckBookArea.vue +170 -0
  52. package/src/filiale/huaran/pc/CheckBookCompany.vue +166 -0
  53. package/src/filiale/huaran/pc/CheckBookDetails.vue +196 -0
  54. package/src/filiale/huaran/pc/CheckBookEntry.vue +61 -0
  55. package/src/filiale/huaran/pc/CheckBookList.vue +386 -0
  56. package/src/filiale/huaran/pc/CheckBookSearchArea.vue +564 -0
  57. package/src/filiale/huaran/pc/CheckBookSearchUnit.vue +229 -0
  58. package/src/filiale/huaran/pc/CheckBookSearchUser.vue +604 -0
  59. package/src/filiale/huaran/pc/CheckBookUser.vue +112 -0
  60. package/src/filiale/huaran/pc/PaperList.vue +822 -0
  61. package/src/filiale/huaran/pc/PlanManage.vue +887 -0
  62. package/src/filiale/huaran/pc/checkPlanList.vue +419 -0
  63. package/src/filiale/huaran/pc/checkUserList.vue +867 -0
  64. package/src/filiale/huaran/pc.js +27 -0
  65. package/src/filiale/jiaxian/android/AddPlanItem.vue +447 -0
  66. package/src/filiale/jiaxian/android/PhoneUpUserinfo.vue +1229 -0
  67. package/src/filiale/jiaxian/android/SafecheckDevices.vue +6 -6
  68. package/src/filiale/jiaxian/android/SafecheckOrderV.vue +2807 -0
  69. package/src/filiale/jiaxian/android/SafecheckUserInfo.vue +784 -0
  70. package/src/filiale/jiaxian/android.js +4 -0
  71. package/src/filiale/jingyang/android/AddPlanItem.vue +458 -458
  72. package/src/filiale/jingyang/android/CurrentCreate.vue +1080 -1080
  73. package/src/filiale/jingyang/android/SafecheckOrderV.vue +2734 -2734
  74. package/src/filiale/jingyang/android.js +15 -15
  75. package/src/filiale/kelai/pc/CheckPlanAreaList.vue +15 -7
  76. package/src/filiale/qianneng/android/SafecheckOrderV.vue +1 -1
  77. package/src/filiale/qingtongxia/android/AddPlanItem.vue +450 -0
  78. package/src/filiale/qingtongxia/android/CurrentCreate.vue +1053 -0
  79. package/src/filiale/qingtongxia/android/PhoneUpUserinfo.vue +1230 -0
  80. package/src/filiale/qingtongxia/android/SafecheckUserInfo.vue +782 -0
  81. package/src/filiale/qingtongxia/android.js +14 -10
  82. package/src/filiale/ruihua/android/SafecheckOrderV.vue +2747 -0
  83. package/src/filiale/ruihua/android/SafecheckUserInfo.vue +804 -0
  84. package/src/filiale/ruihua/android.js +11 -0
  85. package/src/filiale/shanxian/android/SafecheckOrderV.vue +1 -1
  86. package/src/filiale/shanxian/pc/checkUserList.vue +4 -4
  87. package/src/filiale/siyang/android/AddPlanItem.vue +450 -0
  88. package/src/filiale/siyang/android/AppCheckPlan.vue +246 -0
  89. package/src/filiale/siyang/android/CurrentCreate.vue +1051 -0
  90. package/src/filiale/siyang/android.js +15 -11
  91. package/src/filiale/siyang/pc/CheckBookList.vue +396 -0
  92. package/src/filiale/siyang/pc/CheckBookSearchArea.vue +667 -0
  93. package/src/filiale/siyang/pc/CheckPlanAreaList.vue +512 -0
  94. package/src/filiale/siyang/pc/CheckSearchUser.vue +1035 -0
  95. package/src/filiale/siyang/pc/HiddenSituation.vue +167 -0
  96. package/src/filiale/siyang/pc/checkPlanList.vue +367 -0
  97. package/src/filiale/siyang/pc/checkUserList.vue +22 -18
  98. package/src/filiale/siyang/pc.js +22 -16
  99. package/src/filiale/tongchuan/android/Select.vue +421 -0
  100. package/src/filiale/tongchuan/android.js +1 -0
  101. package/src/filiale/tongchuan/pc/CheckPlanCountChartArea.vue +3 -1
  102. package/src/filiale/tongchuan/pc/DefectPaperWeiXiu.vue +6 -2
  103. package/src/filiale/tongchuan/pc/HiddenSituation.vue +3 -1
  104. package/src/filiale/tongchuan/pc/NewCheckpaper.vue +13 -22
  105. package/src/filiale/tongchuan/pc/PaperDefectMain.vue +1 -1
  106. package/src/filiale/tongchuan/pc/SelectCheckPlan.vue +5 -2
  107. package/src/filiale/tongchuan/utils/EventListener.js +29 -0
  108. package/src/filiale/tongchuan/utils/coerceBoolean.js +7 -0
  109. package/src/filiale/weinan/android/SafecheckDevices.vue +1 -1
  110. package/src/filiale/weinan/android/SafecheckOrderV.vue +6 -2
  111. package/src/filiale/weinan/pc/CheckBookSearchUserList.vue +75 -62
  112. package/src/filiale/weinan/pc/CheckDetail.vue +11 -11
  113. package/src/filiale/weinan/pc/DefectPaperNew.vue +31 -0
  114. package/src/filiale/weinan/pc/DeviceChange.vue +1088 -0
  115. package/src/filiale/weinan/pc/checkUserList.vue +49 -113
  116. package/src/filiale/weinan/pc.js +1 -0
  117. package/src/filiale/wuan/android/SafecheckOrderV.vue +2241 -2240
  118. package/src/filiale/wuan/android/SafecheckUserInfo.vue +596 -592
  119. package/src/filiale/xilan/pc/checkUserList.vue +772 -0
  120. package/src/filiale/xilan/pc.js +12 -0
  121. package/src/filiale/yangchunboneng/android/SafecheckDevices.vue +10 -6
  122. package/src/filiale/yangchunboneng/android/SafecheckOrderV.vue +21 -1
  123. package/src/filiale/yangchunboneng/pc/CheckBookSearchUser.vue +23 -11
  124. package/src/filiale/yangchunboneng/pc/CheckBookUser.vue +6 -6
  125. package/src/filiale/yangchunboneng/pc/CheckPlanAreaList.vue +96 -30
  126. package/src/filiale/yangchunboneng/pc/CheckSearchUser.vue +10 -10
  127. package/src/filiale/yangchunboneng/pc/DefectPaperNew.vue +10 -10
  128. package/src/filiale/yangchunboneng/pc/PaperDefectMain.vue +84 -10
  129. package/src/filiale/yangchunboneng/pc/PaperList.vue +6 -6
  130. package/src/filiale/yuansheng/android/SafecheckDevices.vue +11 -1
  131. package/src/filiale/yuansheng/pc/NewCheckpaper.vue +10 -2
  132. package/src/main-/345/215/225/351/241/265/351/235/242/346/211/223/345/214/205/347/224/250.js +24 -0
  133. package/src/main.js +34 -33
  134. package/src/safecheck-android.js +11 -0
  135. package/src/safecheck-page.js +12 -0
  136. package/src/safecheck.js +3 -0
@@ -0,0 +1,1235 @@
1
+ <style scoped id="printStyle">
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-top: 40px"
67
+ v-show="paperdata.f_entry_status == '入户'">
68
+ <thead>
69
+ <tr>
70
+ <th colspan="4" style="text-align: center">用户安检概况</th>
71
+ </tr>
72
+ </thead>
73
+ <tbody>
74
+ <tr>
75
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
76
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
77
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
78
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}
79
+ </td>
80
+ </tr>
81
+ <tr>
82
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
83
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_entry_status }}
84
+ </td>
85
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">燃气使用:</td>
86
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_usegas }}</td>
87
+ </tr>
88
+ <tr>
89
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">备注:</td>
90
+ <td colspan="3"
91
+ style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
92
+ {{ paperdata.f_repair_approved_note }}
93
+ </td>
94
+ </tr>
95
+ </tbody>
96
+ </table>
97
+ <table class="table table-striped table-bordered" style="margin-top: 35px"
98
+ v-show="paperdata.f_entry_status == '入户'">
99
+ <thead>
100
+ <tr>
101
+ <th style="text-align: center">总体安检照片</th>
102
+ </tr>
103
+ </thead>
104
+ <tbody>
105
+ <tr>
106
+ <td style="margin: auto;text-align: center">
107
+ <div class="container" style="max-width: 550px;background: #FFFFFF">
108
+ <div class="img" v-for="img in paperdata.f_overall_imgs">
109
+ <img-self-android :list="paperdata.f_overall_imgs" :src="img.f_overall_path"
110
+ style="float: left" width="150" height="200"></img-self-android>
111
+ </div>
112
+ </div>
113
+
114
+
115
+ </td>
116
+
117
+ </tr>
118
+ </tbody>
119
+ </table>
120
+ <table class="table table-striped table-bordered" style="width: 100%"
121
+ v-show="paperdata.f_entry_status == '入户' && (paperdata.f_sign_path || f_user_path)">
122
+ <thead>
123
+ <tr>
124
+ <th style="text-align: center">用户签名照片</th>
125
+ </tr>
126
+ </thead>
127
+ <tbody>
128
+ <tr>
129
+ <td style="margin: auto;text-align: center" v-if="paperdata.f_sign_path">
130
+ <div class="container" style="max-width: 500px;background: #FFFFFF">
131
+ <div class="img" style="float: none">
132
+ <img-self-android :src="`rs/image/file/` + paperdata.f_sign_path" width="200"
133
+ height="200"></img-self-android>
134
+ </div>
135
+ </div>
136
+ </td>
137
+ <td style="margin: auto;text-align: center" v-if="f_user_path">
138
+ <div class="container" style="max-width: 550px;background: #FFFFFF">
139
+ <div class="img" style="float: none">
140
+ <img-self-android :src="`rs/image/file/` + f_user_path" width="200"
141
+ height="200"></img-self-android>
142
+ </div>
143
+ </div>
144
+ </td>
145
+ </tr>
146
+ </tbody>
147
+ </table>
148
+ <table class="table table-striped table-bordered"
149
+ v-show="paperdata.f_entry_status == '入户' && paperdata.f_defect_notified">
150
+ <thead>
151
+ <tr>
152
+ <th style="text-align: center">安检通知书/隐患整改通知书</th>
153
+ </tr>
154
+ </thead>
155
+ <tbody>
156
+ <tr>
157
+ <td style="margin: auto;text-align: center">
158
+ <div class="container" style="max-width: 500px;background: #FFFFFF">
159
+ <div class="img" style="float: none">
160
+ <img-self-android :src="`rs/image/file/` + paperdata.f_notified_path" width="486"
161
+ height="300"></img-self-android>
162
+ </div>
163
+ </div>
164
+ </td>
165
+ </tr>
166
+ </tbody>
167
+ </table>
168
+ <table class="table table-striped table-bordered"
169
+ v-show="paperdata.f_entry_status == '入户' && paperdata.f_video_path">
170
+ <thead>
171
+ <tr>
172
+ <th style="text-align: center">安检视频</th>
173
+ </tr>
174
+ </thead>
175
+ <tbody>
176
+ <tr>
177
+ <td style="margin: auto;text-align: center">
178
+ <div class="container" style="max-width: 500px;background: #FFFFFF">
179
+ <video width="320" height="200" controls v-if="paperdata.f_video_path">
180
+ <source :src="paperdata.f_video_path" type="video/mp4">
181
+ </video>
182
+ </div>
183
+ </td>
184
+ </tr>
185
+ </tbody>
186
+ </table>
187
+ </div>
188
+ </div>
189
+ <div class style="width: 1%;height: 100%;background-color: #F1F8FF;float: left;"></div>
190
+ <div class="col-md-6" style="height: 100%;overflow: scroll">
191
+ <div style="width: 95%;margin-left: 5%">
192
+ <table class="table table-striped table-bordered" v-for="config in deviceconfig2" style="margin-top: 35px">
193
+ <thead>
194
+ <tr>
195
+ <th style="text-align: center">{{ config.f_device_type }}</th>
196
+ </tr>
197
+ </thead>
198
+ <tr v-for="dev in config.f_items">
199
+ <td>
200
+ <div class="row">
201
+ <div class="col-md-8" style="text-align: center;">
202
+ <label>
203
+ <button-link type="button" class="btn btn-link" :style="'color:black'">
204
+ {{ dev.f_item_name }}
205
+ </button-link>
206
+ </label>
207
+ </div>
208
+ <div class="col-md-4" style="text-align: center">
209
+ <label style="font-weight: normal" v-if="dev.type != 'picture'">{{
210
+ dev.f_item_lists[0].f_item_value
211
+ }}</label>
212
+ <label style="font-weight: normal" v-if="dev.type == 'picture'">
213
+ <div v-if="dev.f_path">
214
+ <button-link style="color: black" type="button" class="btn btn-link"
215
+ @click="showpath(`rs/image/file/` + dev.f_path)">查看照片
216
+ </button-link>
217
+ </div>
218
+ <div v-else>无照片</div>
219
+ </label>
220
+ </div>
221
+ </div>
222
+ </td>
223
+ </tr>
224
+ </table>
225
+ </div>
226
+ </div>
227
+ </div>
228
+ </div>
229
+ </div>
230
+ <modal :show.sync="imgshow" v-ref:modal backdrop="true">
231
+ <header slot="modal-header" class="modal-header">
232
+ {{ picturename }}
233
+ </header>
234
+ <article slot="modal-body" class="modal-body">
235
+ <div class="from-group">
236
+ <div class="row">
237
+ <div class="col-md-6">
238
+ <img-self-android v-if="showimg1" :src="showimg1" width="240" height="300"></img-self-android>
239
+ </div>
240
+ <div class="col-md-6">
241
+ <img-self-android v-if="showimg2" :src="showimg2" width="240" height="300"></img-self-android>
242
+ </div>
243
+ <div class="col-md-6" v-for="item in otherDarginShowImgs">
244
+ <img-self-android v-if="item.path" :src="item.path" width="240" height="300"></img-self-android>
245
+ </div>
246
+ </div>
247
+ </div>
248
+ </article>
249
+ <footer slot="modal-footer" class="modal-footer" v-show="false">
250
+ <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
251
+ </footer>
252
+ </modal>
253
+ <modal :show.sync="imgshow2" v-ref:modal backdrop="true">
254
+ <header slot="modal-header" class="modal-header">
255
+ {{ paperdata.f_entry_status }}照片
256
+ </header>
257
+ <article slot="modal-body" class="modal-body">
258
+ <div class="from-group">
259
+ <div class="row">
260
+ <div class="col-md-6">
261
+ <img-self-android v-if="this.paperdata.f_entry_status == '到访不遇' && this.paperdata.f_noanswer_path"
262
+ :src="showimg3" width="282" height="400"></img-self-android>
263
+ </div>
264
+ <div class="col-md-6">
265
+ <img-self-android v-if="this.paperdata.f_entry_status == '到访不遇' && this.paperdata.f_noanswer1_path"
266
+ :src="showimg5" width="282" height="400"></img-self-android>
267
+ </div>
268
+ <div class="col-md-6">
269
+ <img-self-android v-if="this.paperdata.f_entry_status == '到访不遇' && this.paperdata.f_noanswer2_path"
270
+ :src="showimg6" width="282" height="400"></img-self-android>
271
+ </div>
272
+ <div class="col-md-6">
273
+ <img-self-android v-if="this.paperdata.f_entry_status == '拒检' && this.paperdata.f_rejectcheck_path"
274
+ :src="showimg4" width="282" height="400"></img-self-android>
275
+ </div>
276
+ <div class="col-md-6">
277
+ <img-self-android v-if="this.paperdata.f_entry_status == '拒检' && this.paperdata.f_rejectcheck1_path"
278
+ :src="showimg7" width="282" height="400"></img-self-android>
279
+ </div>
280
+ <div class="col-md-6">
281
+ <img-self-android v-if="this.paperdata.f_entry_status == '拒检' && this.paperdata.f_rejectcheck2_path"
282
+ :src="showimg8" width="282" height="400"></img-self-android>
283
+ </div>
284
+ </div>
285
+ </div>
286
+ </article>
287
+ <footer slot="modal-footer" class="modal-footer" v-show="false">
288
+ <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
289
+ </footer>
290
+ </modal>
291
+ <!-- <modal :show.sync="showModel" :width="'50%'" :backdrop="false">-->
292
+ <!-- <div slot="modal-header" class="modal-header">-->
293
+ <!-- <h4 class="modal-title">-->
294
+ <!-- 安检审核备注-->
295
+ <!-- </h4>-->
296
+ <!-- </div>-->
297
+ <!-- <div slot="modal-body" class="modal-body">-->
298
+ <!-- <div class="row">-->
299
+ <!-- <div class="form-group col-sm-4">-->
300
+ <!-- <label class="font_normal_body">审核备注:</label>-->
301
+ <!-- <textarea v-model="message"></textarea>-->
302
+ <!-- </div>-->
303
+ <!-- </div>-->
304
+ <!-- </div>-->
305
+ <!-- <div slot="modal-footer" class="modal-footer" style="text-align: center">-->
306
+ <!-- <button class="button_search" style="margin-right: 15px" @click="auditFailOK()">确定</button>-->
307
+ <!-- <button class="button_search" style="margin-right: 15px" @click="auditFailCancel()">取消</button>-->
308
+ <!-- </div>-->
309
+ <!-- </modal>-->
310
+ </template>
311
+
312
+ <script>
313
+ import Vue from 'vue'
314
+ import * as Util from '../../Util'
315
+
316
+ // let asyncReady = async function (self) {
317
+ // // 获取配置信息
318
+ // try {
319
+ // let res = await new HttpResetClass().load('post', 'rs/sql/safe_singleTable_OrderBy', {
320
+ // data: {
321
+ // items: 'f_dir',
322
+ // tablename: 't_organization',
323
+ // condition: `id = '${self.item.f_filialeid}'`,
324
+ // orderitem: 'id'
325
+ // }
326
+ // })/*.then(res=>{*/
327
+ // //tag
328
+ // //tag)
329
+ // console.log(res)
330
+ // if (!res.data[0].f_dir) {
331
+ // self.$showMessage("该公司无组织目录,无法获取配置文件,请联系管理员确认")
332
+ // } else {
333
+ // //this.f_dir=res.data[0].f_dir
334
+ // let url = self.newConfig == '是' ? '/safecheck/rs/safe_vue' : '/safecheck/rs/vue'
335
+ // try {
336
+ // let res1 = await new HttpResetClass().load('GET', `${url}/DevicesConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {}, {
337
+ // resolveMsg: '获取居民配置项成功!',
338
+ // rejectMsg: '获取居民配置项出错!'
339
+ // })/*.then(res=>{*/
340
+ // //tag
341
+ // //this.safeConfig["民用配置项"]=Object.assign({},res.data)
342
+ // if (!Vue.config.safecheck) {
343
+ // Vue.config = {safecheck: {}}
344
+ // }
345
+ // Vue.config.safecheck.DevicesConfig = res1.data
346
+ // console.log(Vue.config.safecheck.DevicesConfig)
347
+ // /*})*/
348
+ // let res2 = await new HttpResetClass().load('GET', `${url}/DevicesSetConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {}, {
349
+ // resolveMsg: '获取非居民配置项成功!',
350
+ // rejectMsg: '获取非居民配置项出错!'
351
+ // })/*.then(res=>{*/
352
+ // //tag
353
+ // //this.safeConfig["非民用配置项"]=Object.assign({},res.data)
354
+ // Vue.config.safecheck.DevicesSetConfig = {}
355
+ // } catch (e) {
356
+ // self.$showMessage("获取配置文件失败" + e)
357
+ // self.loading = false
358
+ // }
359
+ // }
360
+ // if (self.data.f_recheck_id) {
361
+ // let res3 = await new HttpResetClass().load('post', 'rs/sql/safe_singleTable_OrderBy', {
362
+ // data: {
363
+ // items: '*',
364
+ // tablename: 't_check_paper',
365
+ // condition: `id = '${self.data.f_recheck_id}'`,
366
+ // orderitem: 'id'
367
+ // }
368
+ // })
369
+ // self.lastCheckData = res3.data[0]
370
+ // }
371
+ // } catch (error) {
372
+ // // 忽略704,文件找不到异常R
373
+ // if (error.status !== 704) {
374
+ // throw error
375
+ // }
376
+ // this.loading = false
377
+ // }
378
+ // }
379
+ export default {
380
+ title: '安检单',
381
+ props: ['f_plan_id', 'item', 'role'],
382
+ data() {
383
+ return {
384
+ f_user_path: '',
385
+ message: '',
386
+ showButton: false,
387
+ showModel: false,
388
+ data: {
389
+ f_devices: [],
390
+ f_defect_content: ''
391
+ },
392
+ lastCheckData: {},
393
+ paperdata: {},
394
+ picturename: '隐患照片',
395
+ defectDevice: {},
396
+ hasDevice: false,
397
+ deviceCollect: {},
398
+ deviceCollects: [],
399
+ isshow: true,
400
+ ajresult: '',
401
+ loading: true,
402
+ imgshow: false,
403
+ imgshow2: false,
404
+ isUpload: false,
405
+ livedispose: '',
406
+ showimg1: '',
407
+ showimg2: '',
408
+ showimg3: '',
409
+ showimg4: '',
410
+ showimg5: '',
411
+ showimg6: '',
412
+ showimg7: '',
413
+ showimg8: '',
414
+ hiddenDangerImgNumber: 0, //配置项中隐患照片数
415
+ otherDarginShowImgs: [],//其他隐患图片
416
+ startClick: false, //开始安检按钮是否可点击
417
+ isStrat: false, //是否开始安检
418
+ checkResult: {},//查询结果
419
+ newcheckResult: {},
420
+ timer: null,
421
+ showModal: false,
422
+ pic_to_be_viewed: '',
423
+ showBack: true,
424
+ devices: [],
425
+ devicesAll: [],
426
+ configAJ: [],
427
+ configRQ: [],
428
+ deviceconfig: {},
429
+ newConfig: '',
430
+ deviceconfig2: [],
431
+ f_devices: [],
432
+ config: {
433
+ "燃气表": {
434
+ "checkmust": true,
435
+ "index": 1,
436
+ "items": {
437
+ "基表编号": { "index": 1, "type": "string", "readonly": true },
438
+ "气表型号": { "index": 2, "type": "string", "readonly": true },
439
+ "气表品牌": { "index": 3, "type": "string", "readonly": true },
440
+ "进气方向": { "index": 4, "type": "string", "readonly": true },
441
+ "初始表底": { "index": 5, "type": "number", "isshow": false, "readonly": true },
442
+ "上期表读数": { "index": 6, "type": "number", "readonly": true, isshow: false },
443
+ "累购气量": { "index": 7, "type": "number", "readonly": true },
444
+ "已用气量": { "index": 8, "type": "number", "checkmust": false },//基表数
445
+ "剩余气量": { "index": 9, "type": "number", "checkmust": false },//累购-已用
446
+ //显示屏数 --实际剩余气量
447
+ "气量异常差值": { "index": 10, "type": "number", "readonly": true },
448
+ "表箱号": { "index": 11, "type": "string", "readonly": true },
449
+ "燃气表照片": { "index": 12, "type": "picture", "checkmust": false },
450
+ }
451
+ // 注意,配置项的index必须与上面的固定配置保持'顺序'
452
+ }
453
+ },
454
+ //金额
455
+ config2: {
456
+ "燃气表": {
457
+ "checkmust": true,
458
+ "index": 1,
459
+ "items": {
460
+ "基表编号": { "index": 1, "type": "string", "readonly": true },
461
+ "气表型号": { "index": 2, "type": "string", "readonly": true },
462
+ "气表品牌": { "index": 3, "type": "string", "readonly": true },
463
+ "进气方向": { "index": 4, "type": "string", "readonly": true },
464
+ "初始表底": { "index": 5, "type": "number", "isshow": false, "readonly": true },
465
+ "上期表读数": { "index": 6, "type": "number", "readonly": true, isshow: false },
466
+ "累购金额": { "index": 7, "type": "number", "readonly": true },
467
+ "已用金额": { "index": 8, "type": "number", "checkmust": false },
468
+ //显示屏数 --实际剩余气量
469
+ "剩余金额": { "index": 9, "type": "number", "checkmust": false },
470
+ "金额异常差值": { "index": 10, "type": "number", "readonly": true },
471
+ "表箱号": { "index": 11, "type": "string", "readonly": true },
472
+ "燃气表照片": { "index": 12, "type": "picture", "checkmust": false },
473
+ }
474
+ }
475
+ },
476
+ }
477
+ },
478
+ computed: {
479
+ selector: {
480
+ get() {
481
+ return 'paper-state'
482
+ },
483
+ set(val) {
484
+ if (this.isStrat) {
485
+ this.$goto(val, { userinfo: this.data }, 'paper-router')
486
+ } else {
487
+ this.$showMessage('未开始安检!')
488
+ }
489
+ }
490
+ },
491
+ actionEnabled: {
492
+ get() {
493
+ return this.role == 'inspect'
494
+ }
495
+ }
496
+ },
497
+ methods: {
498
+ // exportToPDF() {
499
+ // const element = document.getElementById('toPdf') // 替换为您要导出的页面元素的ID
500
+ // html2pdf(element)
501
+ // },
502
+
503
+ //安检审核成功
504
+ // auditSuccesss() {
505
+ // this.loading = true;
506
+ // var reqdata = {
507
+ // audit_result: '通过',
508
+ // operator: "success",
509
+ // audit_time: Util.getNowDate(),
510
+ // user_name: this.$login.f.name,
511
+ // id: this.item.id,
512
+ // f_check_item_id: this.item.f_check_item_id
513
+ // }
514
+ // new HttpResetClass().load('POST', '/rs/logic/updateAafeAudit', {data: reqdata}, {
515
+ // resolveMsg: '安检审核成功!',
516
+ // rejectMsg: '安检审核出错!'
517
+ // }).then((res) => {
518
+ // if (res.data.code == 200) {
519
+ // this.loading = false;
520
+ // this.$back()
521
+ // }
522
+ // })
523
+ // },
524
+ auditFail() {
525
+ this.showModel = true;
526
+ },
527
+ // auditFailOK() {
528
+ //
529
+ // this.loading = true;
530
+ // var reqdata = {
531
+ // message: this.message,
532
+ // audit_result: '不通过',
533
+ // operator: "fail",
534
+ // audit_time: Util.getNowDate(),
535
+ // user_name: this.$login.f.name,
536
+ // id: this.item.id,
537
+ // f_check_item_id: this.item.f_check_item_id
538
+ // }
539
+ // new HttpResetClass().load('POST', '/rs/logic/updateAafeAudit', {data: reqdata}, {
540
+ // resolveMsg: '安检审核成功!',
541
+ // rejectMsg: '安检审核出错!'
542
+ // }).then((res) => {
543
+ // if (res.data.code == 200) {
544
+ // this.loading = false;
545
+ // this.message = '';
546
+ // this.showModel = false;
547
+ // this.$back()
548
+ // }
549
+ // })
550
+ // },
551
+ auditFailCancel() {
552
+ this.showModel = false;
553
+ this.message = '';
554
+ },
555
+
556
+ // devicesCollect() {
557
+ // //tag
558
+ // //tag)
559
+ // //tag)
560
+ // //tag
561
+ // this.deviceCollects = []
562
+ // let checkResult = '正常'
563
+ // this.result = '正常'
564
+ // let codata = JSON.parse(JSON.stringify(this.data))
565
+ // //tag)
566
+ // for (let device in this.data) {
567
+ // let f_device_type
568
+ // if (device.startsWith("device")) {
569
+ // for (let item in this.data[device]) {
570
+ // if (this.data[device].length > 1) {
571
+ // let j = Number.parseInt(item) + 1
572
+ // f_device_type = `${this.data[device][item].f_device_type}${j}`
573
+ // } else {
574
+ // f_device_type = this.data[device][item].f_device_type
575
+ // }
576
+ // // //tag
577
+ // let deviceelse = []
578
+ // let deviceInfos = []
579
+ // for (let i in this.data[device][item].f_items) {
580
+ // let defects = ''
581
+ //
582
+ // let items = this.data[device][item].f_items[i]
583
+ //
584
+ //
585
+ // if ((items.type === 'selector' || items.type === 'radio' || items.type === 'checkbox' || items.type === 'picture') && items.f_item_value != null && items.f_item_value instanceof Array) {
586
+ // for (let i in items.f_item_value) {
587
+ // let f_item_value = items.f_item_value[i]
588
+ //
589
+ // //tag)
590
+ // //tag)
591
+ // //tag)
592
+ // //tag)
593
+ //
594
+ // if (!this.config[this.data[device][item].f_device_type].items[items.f_item_name] && (items.isdefect && (items.isdefect == 'true' || items.isdefect == true))) {
595
+ // continue
596
+ // }
597
+ // /*if(items.f_is_defect != true && items.f_is_defect != 'true'){
598
+ // continue
599
+ // }*/
600
+ // if (items.f_is_defect == 'true' || items.f_is_defect == true) {
601
+ // checkResult = '有隐患'
602
+ // this.result = '有隐患'
603
+ // defects = `${defects}:${items.f_item_value}/`
604
+ // }
605
+ // /*let options = this.config[this.data[device][item].f_device_type].items[items.f_item_name].options
606
+ // for (let option in options) {
607
+ // if (options[option].data == f_item_value) {
608
+ // if (options[option].isdefect == 'true' || options[option].isdefect == true) {
609
+ // checkResult = '有隐患'
610
+ // this.result = '有隐患'
611
+ // defects = `${defects}:${options[option].data}/`
612
+ // // let level = options[option].level
613
+ // }
614
+ // }
615
+ // }*/
616
+ // //tag)
617
+ // }
618
+ // if (defects != '') {
619
+ // console.log('有隐患items', items)
620
+ // deviceInfos.push(`${items.f_item_name}${defects.substring(0, defects.length - 1)}${items.f_else ? items.f_else : ''}`)
621
+ // }
622
+ // } else if ((items.type === 'string' || items.type === 'number') && items.f_is_defect && items.f_item_value[0]) {
623
+ // checkResult = '有隐患'
624
+ // this.result = '有隐患'
625
+ // deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
626
+ //
627
+ // } else if (items.f_item_name == '金额异常差值') {
628
+ // var deviation = this.$appdata.getSingleValue('金额异常差值允许误差')
629
+ // //tag
630
+ // if (parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN") {
631
+ // if (parseFloat(items.f_item_value[0]) > parseFloat(deviation) || parseFloat(items.f_item_value[0]) < parseFloat(deviation) * -1) {
632
+ // checkResult = '有隐患'
633
+ // this.result = '有隐患'
634
+ // deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
635
+ // }
636
+ // }
637
+ // } else if (items.f_item_name == '气量异常差值') {
638
+ // var deviation = this.$appdata.getSingleValue('气量异常差值允许误差')
639
+ // //tag
640
+ // if (parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN") {
641
+ // if (parseFloat(items.f_item_value[0]) > parseFloat(deviation) || parseFloat(items.f_item_value[0]) < parseFloat(deviation) * -1) {
642
+ // checkResult = '有隐患'
643
+ // this.result = '有隐患'
644
+ // deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
645
+ // }
646
+ // }
647
+ // }
648
+ // if (!this.config[this.data[device][item].f_device_type].items[items.f_item_name]) {
649
+ // // console.log('this.config[this.data[device][item].f_device_type]', this.config[this.data[device][item].f_device_type])
650
+ // // console.log('this.deviceconfig2', this.deviceconfig2)
651
+ // for (let dev in this.deviceconfig2) {
652
+ // if (this.deviceconfig2[dev].checkname == this.data[device][item].f_device_type) {
653
+ // this.deviceconfig2[dev].items.push({
654
+ // lname: items.f_item_name
655
+ // })
656
+ // }
657
+ // }
658
+ // }
659
+ // //tag)
660
+ // //tag
661
+ // //tag
662
+ // if (items.type === 'selector') {
663
+ // items.selected = []
664
+ // } else if (items.type === 'inputSelector') {
665
+ // items.selected = ''
666
+ // }
667
+ // }
668
+ //
669
+ //
670
+ // //tag
671
+ // this.$set('deviceCollect.name', f_device_type)
672
+ // this.$set('deviceCollect.value', checkResult)
673
+ // this.$set('deviceCollect.devices', deviceInfos)
674
+ // this.$set('deviceCollect.else', deviceelse)
675
+ // console.log('deviceCollect.devices', this.deviceCollect.devices)
676
+ // console.log('deviceCollect.else', this.deviceCollect.else)
677
+ // //tag)
678
+ // if (this.deviceCollect.name) {
679
+ // //tag
680
+ // this.deviceCollects.push(JSON.parse(JSON.stringify(this.deviceCollect)))
681
+ // }
682
+ //
683
+ // checkResult = '正常'
684
+ // this.deviceCollect = {}
685
+ // }
686
+ // }
687
+ // }
688
+ // if (this.deviceCollects.length > 0) {
689
+ // this.hasDevice = true
690
+ // }
691
+ // this.ajresult = JSON.parse(this.data.f_defect_content).result
692
+ // this.showimg3 = this.data.f_noanswer_path
693
+ // this.showimg5 = this.data.f_noanswer1_path
694
+ // this.showimg6 = this.data.f_noanswer2_path
695
+ // this.showimg4 = this.data.f_rejectcheck_path
696
+ // this.showimg7 = this.data.f_rejectcheck1_path
697
+ // this.showimg8 = this.data.f_rejectcheck2_path
698
+ // this.paperdata = this.data
699
+ // this.f_user_path = this.paperdata.f_user_pictures ? JSON.parse(this.paperdata.f_user_pictures)[0].f_user_path : ''
700
+ // this.loading = false
701
+ // },
702
+ imgclose() {
703
+ this.imgshow = false
704
+ },
705
+ putDevices() {
706
+ ////tag
707
+ this.$set('data.approve', "true")
708
+ this.$set('data.writeback', "false")
709
+ if (Vue.config.safecheck.ApproveConfig != undefined) {
710
+ if (Vue.config.safecheck.ApproveConfig.approve != undefined) {
711
+ this.$set('data.approve', Vue.config.safecheck.ApproveConfig.approve)
712
+ }
713
+ if (Vue.config.safecheck.ApproveConfig.writeback != undefined) {
714
+ this.$set('data.writeback', Vue.config.safecheck.ApproveConfig.writeback)
715
+ }
716
+ if (Vue.config.safecheck.ApproveConfig.livedispose != undefined) {
717
+ this.livedispose = Vue.config.safecheck.ApproveConfig.livedispose
718
+ }
719
+ if (Vue.config.safecheck.ApproveConfig.hiddendanger != undefined) {
720
+ if (parseInt(Vue.config.safecheck.ApproveConfig.hiddendanger) >= 3) {
721
+ this.hiddenDangerImgNumber = 3
722
+ } else {
723
+ this.hiddenDangerImgNumber = parseInt(Vue.config.safecheck.ApproveConfig.hiddendanger)
724
+ }
725
+ }
726
+ }
727
+ //tag
728
+
729
+ //tag)
730
+ // if (!this.item.f_safecheck_type) {
731
+ // this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType['年度普检'][this.item.f_check_type]])
732
+ // } else {
733
+ // if (Vue.config.safecheck.DevicesConfig != undefined)
734
+ // this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType[this.item.f_safecheck_type][this.item.f_check_type]])
735
+ // }
736
+ //遍历安检项配置
737
+ // for (let i in this.config) {
738
+ // //取得安检项索引值
739
+ // let n = this.config[i].index
740
+ // this.devices[n - 1] = {device: i, n: n, checkmust: this.config[i].checkmust}
741
+ // this.$set('data.' + 'device' + n, [])
742
+ // let items = []
743
+ // for (let it in this.config[i].items) {
744
+ // //赋值下拉选项
745
+ // if (this.config[i].items[it].type == 'selector') {
746
+ // for (let op in this.config[i].items[it].options)
747
+ // if (this.config[i].items[it].options[op].isdefault == true) {
748
+ // items.push({
749
+ // f_defect_level: this.config[i].items[it].options[op].level,
750
+ // f_is_defect: this.config[i].items[it].options[op].isdefect,
751
+ // f_item_name: it,
752
+ // f_item_value: this.config[i].items[it].options[op].data,
753
+ // f_path: "",
754
+ // type: "selector"
755
+ // })
756
+ // }
757
+ // }
758
+ // }
759
+ // n = n + 1
760
+ // }
761
+
762
+ },
763
+ showpath(val1, val2) {
764
+ //tag
765
+ //tag
766
+ if (val1) {
767
+ this.showimg1 = val1
768
+ this.picturename = val2
769
+ this.imgshow = true
770
+ }
771
+ },
772
+ showpicture(val1, val2) {
773
+ //tag
774
+ if (val2 == '气量异常差值' || val2 == '金额异常差值') {
775
+ return
776
+ }
777
+ for (let i = 0; i < this.devicesAll.length; i++) {
778
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
779
+ if (this.devicesAll[i][j].f_device_type == val1) {
780
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
781
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
782
+ if (!this.devicesAll[i][j].f_items[k].f_is_defect) {
783
+ return false
784
+ } else {
785
+ this.showimg1 = this.devicesAll[i][j].f_items[k].f_path
786
+ this.showimg2 = this.devicesAll[i][j].f_items[k].f_second_path
787
+ this.otherDarginShowImgs = []
788
+ for (let l = 0; l < this.hiddenDangerImgNumber; l++) {
789
+ let img = { path: '' }
790
+ if (this.devicesAll[i][j].f_items[k]['f_p' + (l + 1) + '_path']) {
791
+ img.path = this.devicesAll[i][j].f_items[k]['f_p' + (l + 1) + '_path'] + '?' + Math.random()
792
+ this.otherDarginShowImgs.push(img)
793
+ }
794
+ }
795
+ this.picturename = '隐患照片'
796
+ this.imgshow = true
797
+ return true
798
+ }
799
+ }
800
+ }
801
+
802
+ }
803
+ }
804
+ }
805
+ },
806
+ isred(val1, val2) {
807
+ //tag
808
+ if (val2 == '气量异常差值' || val2 == '金额异常差值') {
809
+ return
810
+ }
811
+ for (let i = 0; i < this.devicesAll.length; i++) {
812
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
813
+ if (this.devicesAll[i][j].f_device_type == val1) {
814
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
815
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
816
+ if (!this.devicesAll[i][j].f_items[k].f_is_defect) {
817
+ return false
818
+ } else {
819
+ return true
820
+ }
821
+ }
822
+ }
823
+
824
+ }
825
+ }
826
+ }
827
+ },
828
+ showpicture2() {
829
+ this.imgshow2 = true
830
+ },
831
+ getDeviceValue(val1, val2) {
832
+ let aa = ''
833
+ for (let i = 0; i < this.devicesAll.length; i++) {
834
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
835
+ if (this.devicesAll[i][j].f_device_type == val1) {
836
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
837
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
838
+ if (this.devicesAll[i][j].f_items[k].f_item_lists[0]) {
839
+ for (let l = 0; l < this.devicesAll[i][j].f_items[k].f_item_lists.length; l++) {
840
+ let val = this.devicesAll[i][j].f_items[k].f_item_lists[l].f_item_value
841
+ aa += (val === null ? '空' : val) + ' '
842
+ }
843
+ return aa
844
+ }
845
+ }
846
+ }
847
+
848
+ }
849
+ }
850
+ }
851
+
852
+ },
853
+ getDevicePath(val1, val2) {
854
+ for (let i = 0; i < this.devicesAll.length; i++) {
855
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
856
+ if (this.devicesAll[i][j].f_device_type == val1) {
857
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
858
+ if (this.devicesAll[i][j].f_items[k].f_item_name == val2) {
859
+ return this.devicesAll[i][j].f_items[k].f_path
860
+ }
861
+ }
862
+
863
+ }
864
+ }
865
+ }
866
+
867
+ },
868
+ // getDeviceAll() {
869
+ // let keyall = Object.keys(this.data)
870
+ // for (let i = 0; i < keyall.length; i++) {
871
+ // //tag)
872
+ // if ((keyall[i].startsWith('f_devices') || keyall[i].startsWith('devices')) && keyall[i] != 'deviceundefined') {
873
+ // this.devicesAll.push(this.data[keyall[i]])
874
+ // //tag
875
+ // }
876
+ // }
877
+ // //tag
878
+ // //tag)
879
+ // this.devicesCollect()
880
+ //
881
+ // },
882
+
883
+ back() {
884
+ if (this.role == 'inspect') {
885
+ if (!this.isStrat) {
886
+ this.$back()
887
+ return
888
+ } else {
889
+ this.savePaper(true).then(() => {
890
+ this.$back()
891
+ this.isStrat = false
892
+ })
893
+ }
894
+ } else {
895
+ this.$back()
896
+ }
897
+ },
898
+ checkIsStart() {
899
+ alert('asdad')
900
+ return
901
+ },
902
+
903
+ viewPic(fileName) {
904
+ //tag
905
+ if (this.role == 'view') {
906
+ if (!fileName.endsWith('nopic.png')) {
907
+ this.pic_to_be_viewed = fileName
908
+ this.showModal = true
909
+ }
910
+ } else {
911
+ HostApp.viewPic(fileName)
912
+ }
913
+ },
914
+ tick() {
915
+ this.timer = null
916
+ this.data.f_offsite_time = Util.toStandardTimeString()
917
+ this.timer = window.setTimeout(this.tick, 1000)
918
+ },
919
+ getRepairState() {
920
+ let repaired = true
921
+ this.data.f_defects.forEach((defect) => {
922
+ repaired = repaired & (defect.f_ratification == '已处理')
923
+ })
924
+ return repaired
925
+ },
926
+ verifyRepairDefects() {
927
+ this.data.f_repair_date = Util.toStandardTimeString()
928
+ this.data.f_repaired = this.getRepairState() ? '已修' : '在修'
929
+ },
930
+ genuineSave(saveOnly) {
931
+ HostApp.__this__.save(saveOnly)
932
+ if (!saveOnly)
933
+ HostApp.__this__.disableTimer()
934
+ HostApp.__callback__ = null
935
+ HostApp.__this__ = null
936
+ },
937
+ setUrgency() {
938
+ this.data.f_defect_urgency = 'Z'
939
+ let that = this
940
+ this.data.f_defects.forEach(function (defect) {
941
+ if (that.data.f_defect_urgency > defect.f_defect_level.charAt(0))
942
+ that.data.f_defect_urgency = defect.f_defect_level.charAt(0)
943
+ })
944
+ if (this.data.f_defect_urgency == 'Z')
945
+ this.data.f_defect_urgency = null
946
+ },
947
+ disableTimer() {
948
+ if (this.timer) {
949
+ window.clearTimeout(this.timer)
950
+ this.timer = null
951
+ }
952
+ },
953
+ loaded(paper) {
954
+ if (!paper.hasOwnProperty('id')) {
955
+ this.$showMessage("该安检单在手机上已经不存在,可能是卸载过程序。可以进入重新安检,或返回安检计划。")
956
+ this.init()
957
+ } else {
958
+ Util.booleanFilter(paper)
959
+ HostApp.__this__.$set('data', paper)
960
+ HostApp.__this__.$goto('paper-state', {}, 'paper-router')
961
+ // 如果打回重检则重新计时
962
+ //tag
963
+ if (HostApp.__this__.role == 'inspect'
964
+ && HostApp.__this__.data.f_approved
965
+ && HostApp.__this__.data.f_approved == '打回') {
966
+ //tag
967
+ HostApp.__this__.data.f_onsite_time = Util.toStandardTimeString()
968
+ HostApp.__this__.tick()
969
+ }
970
+ }
971
+ HostApp.__callback__ = null
972
+ HostApp.__this__ = null
973
+ },
974
+ S4() {
975
+ return (((1 + Math.random()) * 0x10000) | 0).toString(16).substring(1);
976
+ },
977
+ init() {
978
+ this.data.f_noplan_item_id = this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4() + "" + this.S4()
979
+ this.data.ename = Vue.user.ename
980
+ this.data.f_outlets = Vue.user.f_parentname
981
+ this.data.f_meetunit = Vue.user.orgpathnames
982
+ this.data.orgpathstr = Vue.user.orgpathstr
983
+ this.data.f_check_item_id = this.item.id
984
+ this.data.f_check_plan_id = this.f_plan_id
985
+ this.data.f_checker_id = Vue.user.id
986
+ this.data.f_checker_name = Vue.user.name
987
+ this.data.f_check_type = this.item.f_user_type
988
+ this.data.f_subcompany = this.item.f_subcompany
989
+ this.data.f_approved = this.item.f_approved
990
+ this.data.f_repair_approved = this.item.f_repair_approved
991
+ this.data.f_no_checkplan = this.item.f_no_checkplan
992
+ this.data.f_approved = this.item.f_approved
993
+ this.data.f_filialeid = this.item.f_filialeid
994
+ this.data.f_orgstr = this.item.f_orgstr
995
+ this.data.version = this.item.version
996
+ this.$set('data.f_meters', this.item.f_plan_meters)
997
+ this.$set('data.f_userinfo_code', this.item.f_userinfo_code)
998
+ // 安检状态
999
+ this.$set('data.f_entry_status', '入户')
1000
+ this.$set('data.f_usegas', '已使用')
1001
+ this.$set('data.f_state', this.item.f_state)
1002
+ // 用户信息
1003
+ this.$set('data.f_user_name', this.item.f_user_name)
1004
+ this.$set('data.f_user_phone', this.item.f_user_phone)
1005
+ this.$set('data.f_userinfoid', this.item.f_userinfoid)
1006
+ this.$set('data.f_address', this.item.f_address)
1007
+ this.$set('data.f_card_id', this.item.f_card_id)
1008
+ this.$set('data.f_area', this.item.f_area)
1009
+ this.$set('data.f_street', this.item.f_street)
1010
+ this.$set('data.f_room', this.item.f_room)
1011
+ this.$set('data.f_building', this.item.f_building)
1012
+ this.$set('data.f_unit', this.item.f_unit)
1013
+ this.$set('data.f_floor', this.item.f_floor)
1014
+ this.$set('data.f_residential_area', this.item.f_residential_area)
1015
+ this.$set('data.f_idnumber', this.item.f_idnumber)
1016
+ this.$set('data.f_comments', this.item.f_comments)
1017
+ this.$set('data.f_userproperties', this.item.f_userproperties)
1018
+ // 处置方式
1019
+ this.$set('data.f_no_gas_device', false)
1020
+ this.$set('data.f_close_valve', false)
1021
+ this.$set('data.f_unload_battery', false)
1022
+ if (this.data.f_check_item_id == '' && this.item.f_no_checkplan == '无计划安检') {
1023
+ this.data.f_check_item_id = this.data.f_noplan_item_id
1024
+ }
1025
+
1026
+ //房屋结构
1027
+ // this.$set('data.f_room_style', '多层')
1028
+ //供暖方式
1029
+ // this.$set('data.f_heating_style', '热力公司集中供暖')
1030
+ if (this.item.f_plan_meters) {
1031
+ for (let de in this.devices) {
1032
+ this.$set('data.device' + this.devices[de].n, [])
1033
+ for (let i = 0; i < this.item.f_plan_meters.length; i++) {
1034
+ if (this.item.f_plan_meters[i].f_meter_type) {
1035
+ if (this.devices[de].device == "燃气表" && this.item.f_plan_meters[i].f_meter_type.indexOf('机表') > 0) {
1036
+ delete this.config['燃气表']['items']['累计购气量']
1037
+ this.data['device' + this.devices[de].n].push({
1038
+ f_device_type: "燃气表",
1039
+ f_items: [{
1040
+ f_defect_level: null,
1041
+ f_device_id: "",
1042
+ f_is_defect: "",
1043
+ f_item_name: "表品牌",
1044
+ f_item_value: this.item.f_plan_meters[i].f_aliasname,
1045
+ f_path: "",
1046
+ type: "string"
1047
+ },
1048
+ {
1049
+ f_defect_level: null,
1050
+ f_device_id: "",
1051
+ f_is_defect: "",
1052
+ f_item_name: "位置",
1053
+ f_item_value: this.item.f_plan_meters[i].f_weizhi,
1054
+ f_path: "",
1055
+ type: "selector"
1056
+ },
1057
+ {
1058
+ f_defect_level: null,
1059
+ f_device_id: "",
1060
+ f_is_defect: "",
1061
+ f_item_name: "表号",
1062
+ f_item_value: this.item.f_plan_meters[i].f_meter_no,
1063
+ f_path: "",
1064
+ type: "number"
1065
+ },
1066
+ {
1067
+ f_defect_level: null,
1068
+ f_device_id: "",
1069
+ f_is_defect: "",
1070
+ f_item_name: "表封号",
1071
+ f_item_value: this.item.f_plan_meters[i].f_metertitles,
1072
+ f_path: "",
1073
+ type: "number"
1074
+ },
1075
+ {
1076
+ f_defect_level: null,
1077
+ f_device_id: "",
1078
+ f_is_defect: "",
1079
+ f_item_name: "表型号",
1080
+ f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1081
+ f_path: "",
1082
+ type: "selector"
1083
+ },
1084
+ {
1085
+ f_defect_level: null,
1086
+ f_device_id: "",
1087
+ f_is_defect: "",
1088
+ f_item_name: "表底数",
1089
+ f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1090
+ f_path: "",
1091
+ type: "number"
1092
+ }
1093
+ ]
1094
+ })
1095
+ } else if (this.devices[de].device == "燃气表") {
1096
+ delete this.config['燃气表']['items']['表底数']
1097
+ this.data['device' + this.devices[de].n].push({
1098
+ f_device_type: "燃气表",
1099
+ f_items: [{
1100
+ f_defect_level: null,
1101
+ f_device_id: "",
1102
+ f_is_defect: "",
1103
+ f_item_name: "表品牌",
1104
+ f_item_value: this.item.f_plan_meters[i].f_aliasname,
1105
+ f_path: "",
1106
+ type: "string"
1107
+ },
1108
+ {
1109
+ f_defect_level: null,
1110
+ f_device_id: "",
1111
+ f_is_defect: "",
1112
+ f_item_name: "位置",
1113
+ f_item_value: this.item.f_plan_meters[i].f_weizhi,
1114
+ f_path: "",
1115
+ type: "selector"
1116
+ },
1117
+ {
1118
+ f_defect_level: null,
1119
+ f_device_id: "",
1120
+ f_is_defect: "",
1121
+ f_item_name: "表号",
1122
+ f_item_value: this.item.f_plan_meters[i].f_meter_no,
1123
+ f_path: "",
1124
+ type: "number"
1125
+ },
1126
+ {
1127
+ f_defect_level: null,
1128
+ f_device_id: "",
1129
+ f_is_defect: "",
1130
+ f_item_name: "表封号",
1131
+ f_item_value: this.item.f_plan_meters[i].f_metertitles,
1132
+ f_path: "",
1133
+ type: "number"
1134
+ },
1135
+ {
1136
+ f_defect_level: null,
1137
+ f_device_id: "",
1138
+ f_is_defect: "",
1139
+ f_item_name: "表型号",
1140
+ f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1141
+ f_path: "",
1142
+ type: "selector"
1143
+ },
1144
+ {
1145
+ f_defect_level: null,
1146
+ f_device_id: "",
1147
+ f_is_defect: "",
1148
+ f_item_name: "累计购气量",
1149
+ f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1150
+ f_path: "",
1151
+ type: "number"
1152
+ }
1153
+ ]
1154
+ })
1155
+ }
1156
+ }
1157
+ }
1158
+ }
1159
+ }
1160
+
1161
+ this.$goto('paper-state', {}, 'paper-router')
1162
+ },
1163
+ extend(initalObj, finalObj) {
1164
+ var obj = finalObj || {};
1165
+ for (var i in initalObj) {
1166
+ var prop = initalObj[i];
1167
+
1168
+ // 避免相互引用对象导致死循环,如initalObj.a = initalObj的情况
1169
+ if (prop === obj) {
1170
+ continue;
1171
+ }
1172
+
1173
+ if (typeof prop === 'object') {
1174
+ if (obj[i]) {
1175
+ this.extend(obj[i], prop)
1176
+ } else {
1177
+ obj[i] = prop;
1178
+ }
1179
+ }
1180
+ }
1181
+ return obj;
1182
+ },
1183
+ //获取当前时间
1184
+ getNowFormatDate() {
1185
+ var date = new Date();
1186
+ var seperator1 = "-";
1187
+ var seperator2 = ":";
1188
+ var month = date.getMonth() + 1;
1189
+ var strDate = date.getDate();
1190
+ if (month >= 1 && month <= 9) {
1191
+ month = "0" + month;
1192
+ }
1193
+ if (strDate >= 0 && strDate <= 9) {
1194
+ strDate = "0" + strDate;
1195
+ }
1196
+ var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
1197
+ + " " + date.getHours() + seperator2 + date.getMinutes()
1198
+ + seperator2 + date.getSeconds();
1199
+ return currentdate;
1200
+ }
1201
+ },
1202
+ ready() {
1203
+ setTimeout(() => {
1204
+ this.loading = false;
1205
+ }, 3000)
1206
+ this.$resetpost(`rs/path/getUserinfomation`, { data: { condition: `id = '${this.item.id}'` } },{resolveMsg: null,rejectMsg: null}).then((respanse) => {
1207
+ this.paperdata = respanse.data[0]
1208
+ this.paperdata.f_overall_imgs.forEach(item => {
1209
+ item.f_overall_path = `rs/image/file/` + item.f_overall_path
1210
+ })
1211
+ this.deviceconfig2 = Object.assign(this.data, respanse.data[0].f_devices)
1212
+ })
1213
+
1214
+
1215
+ },
1216
+ watch: {
1217
+ },
1218
+ destroyed() {
1219
+ this.disableTimer()
1220
+ }
1221
+ }
1222
+
1223
+ </script>
1224
+ <style scoped>
1225
+ .table-striped thead tr th {
1226
+ background-color: rgb(223, 237, 251);
1227
+ padding: 10px;
1228
+ border-left: solid 0px #dae4f2;
1229
+ border-top: solid 1px #dae4f2;
1230
+ border-right: none;
1231
+ border-bottom: none;
1232
+ text-align: center;
1233
+ color: black;
1234
+ }
1235
+ </style>