safecheck-client 3.0.39-5 → 3.0.39-7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (246) hide show
  1. package/.babelrc +5 -5
  2. package/.editorconfig +9 -9
  3. package/android.html +18 -18
  4. package/config/dev.env.js +6 -6
  5. package/config/index.js +38 -38
  6. package/config/prod.env.js +3 -3
  7. package/config/test.env.js +6 -6
  8. package/docs/AppBase.md +22 -22
  9. package/docs/Busy.md +14 -14
  10. package/docs/CriteriaPaged.md +47 -47
  11. package/docs/DataGrid.md +54 -54
  12. package/docs/DataModel.md +22 -22
  13. package/docs/Dynamic.md +42 -42
  14. package/docs/GetParams.md +11 -11
  15. package/docs/HttpBusy.md +13 -13
  16. package/docs/HttpStore.md +29 -29
  17. package/docs/MessageBox.md +28 -28
  18. package/docs/PagedList.md +29 -29
  19. package/docs/Pager.md +21 -21
  20. package/docs/Project.md +23 -23
  21. package/docs/Route.md +105 -105
  22. package/docs/SafetyCheck/AdjustPlan.md +13 -13
  23. package/docs/SafetyCheck/CheckerPlan.md +12 -12
  24. package/docs/Task.md +46 -46
  25. package/docs/TreeList.md +28 -28
  26. package/docs/TreeMixin.md +18 -18
  27. package/docs/all.md +10 -10
  28. package/docs/list.md +42 -42
  29. package/docs/partial.md +75 -75
  30. package/docs/selector.md +82 -82
  31. package/docs//345/274/200/345/217/221/346/226/207/346/241/243/Snippets.md +28 -28
  32. package/docs//345/274/200/345/217/221/346/226/207/346/241/243/vue-strap/345/217/230/346/233/264/350/256/260/345/275/225.md +7 -7
  33. package/docs//345/274/200/345/217/221/346/226/207/346/241/243/vue/345/217/230/346/233/264/350/256/260/345/275/225.md +13 -13
  34. package/docs//345/274/200/345/217/221/346/226/207/346/241/243//345/274/200/345/217/221/347/216/257/345/242/203/350/256/276/347/275/256.md +77 -77
  35. package/docs//347/225/214/351/235/242/345/210/266/344/275/234/350/247/204/350/214/203.md +54 -54
  36. package/examples/AddressList/App.vue +13 -13
  37. package/examples/AddressList/index.html +11 -11
  38. package/examples/DispatchList/App.vue +10 -10
  39. package/examples/DispatchList/BaseTree.vue +13 -13
  40. package/examples/DispatchList/Init.vue +22 -22
  41. package/examples/DispatchList/Test.vue +20 -20
  42. package/examples/DispatchList/index.html +11 -11
  43. package/examples/DispatchList/main.js +18 -18
  44. package/home.html +16 -16
  45. package/package.json +1 -1
  46. package/publish.bat +7 -7
  47. package/release.bat +5 -5
  48. package/src/Widget.vue +13 -13
  49. package/src/android-bootstrap/fonts/glyphicons-halflings-regular.svg +287 -287
  50. package/src/android-bootstrap/less/.csscomb.json +304 -304
  51. package/src/android-bootstrap/less/.csslintrc +19 -19
  52. package/src/android-bootstrap/less/alerts.less +73 -73
  53. package/src/android-bootstrap/less/badges.less +66 -66
  54. package/src/android-bootstrap/less/bootstrap.less +56 -56
  55. package/src/android-bootstrap/less/breadcrumbs.less +26 -26
  56. package/src/android-bootstrap/less/button-groups.less +247 -247
  57. package/src/android-bootstrap/less/buttons.less +173 -173
  58. package/src/android-bootstrap/less/carousel.less +269 -269
  59. package/src/android-bootstrap/less/close.less +34 -34
  60. package/src/android-bootstrap/less/code.less +69 -69
  61. package/src/android-bootstrap/less/component-animations.less +33 -33
  62. package/src/android-bootstrap/less/grid.less +84 -84
  63. package/src/android-bootstrap/less/input-groups.less +167 -167
  64. package/src/android-bootstrap/less/jumbotron.less +52 -52
  65. package/src/android-bootstrap/less/labels.less +64 -64
  66. package/src/android-bootstrap/less/list-group.less +141 -141
  67. package/src/android-bootstrap/less/media.less +66 -66
  68. package/src/android-bootstrap/less/mixins/alerts.less +14 -14
  69. package/src/android-bootstrap/less/mixins/background-variant.less +9 -9
  70. package/src/android-bootstrap/less/mixins/border-radius.less +18 -18
  71. package/src/android-bootstrap/less/mixins/buttons.less +69 -69
  72. package/src/android-bootstrap/less/mixins/center-block.less +7 -7
  73. package/src/android-bootstrap/less/mixins/clearfix.less +22 -22
  74. package/src/android-bootstrap/less/mixins/forms.less +90 -90
  75. package/src/android-bootstrap/less/mixins/gradients.less +59 -59
  76. package/src/android-bootstrap/less/mixins/grid-framework.less +92 -92
  77. package/src/android-bootstrap/less/mixins/grid.less +122 -122
  78. package/src/android-bootstrap/less/mixins/hide-text.less +21 -21
  79. package/src/android-bootstrap/less/mixins/image.less +33 -33
  80. package/src/android-bootstrap/less/mixins/labels.less +12 -12
  81. package/src/android-bootstrap/less/mixins/list-group.less +30 -30
  82. package/src/android-bootstrap/less/mixins/nav-divider.less +10 -10
  83. package/src/android-bootstrap/less/mixins/nav-vertical-align.less +9 -9
  84. package/src/android-bootstrap/less/mixins/opacity.less +8 -8
  85. package/src/android-bootstrap/less/mixins/pagination.less +24 -24
  86. package/src/android-bootstrap/less/mixins/panels.less +24 -24
  87. package/src/android-bootstrap/less/mixins/progress-bar.less +10 -10
  88. package/src/android-bootstrap/less/mixins/reset-filter.less +8 -8
  89. package/src/android-bootstrap/less/mixins/reset-text.less +18 -18
  90. package/src/android-bootstrap/less/mixins/resize.less +6 -6
  91. package/src/android-bootstrap/less/mixins/responsive-visibility.less +15 -15
  92. package/src/android-bootstrap/less/mixins/size.less +10 -10
  93. package/src/android-bootstrap/less/mixins/tab-focus.less +9 -9
  94. package/src/android-bootstrap/less/mixins/table-row.less +44 -44
  95. package/src/android-bootstrap/less/mixins/text-emphasis.less +9 -9
  96. package/src/android-bootstrap/less/mixins/text-overflow.less +8 -8
  97. package/src/android-bootstrap/less/mixins/vendor-prefixes.less +227 -227
  98. package/src/android-bootstrap/less/mixins.less +40 -40
  99. package/src/android-bootstrap/less/modals.less +151 -151
  100. package/src/android-bootstrap/less/navbar.less +660 -660
  101. package/src/android-bootstrap/less/navs.less +290 -290
  102. package/src/android-bootstrap/less/normalize.less +424 -424
  103. package/src/android-bootstrap/less/pager.less +76 -76
  104. package/src/android-bootstrap/less/pagination.less +89 -89
  105. package/src/android-bootstrap/less/panels.less +274 -274
  106. package/src/android-bootstrap/less/popovers.less +131 -131
  107. package/src/android-bootstrap/less/print.less +101 -101
  108. package/src/android-bootstrap/less/progress-bars.less +87 -87
  109. package/src/android-bootstrap/less/responsive-embed.less +35 -35
  110. package/src/android-bootstrap/less/responsive-utilities.less +194 -194
  111. package/src/android-bootstrap/less/scaffolding.less +161 -161
  112. package/src/android-bootstrap/less/tables.less +262 -262
  113. package/src/android-bootstrap/less/theme.less +291 -291
  114. package/src/android-bootstrap/less/thumbnails.less +36 -36
  115. package/src/android-bootstrap/less/tooltip.less +102 -102
  116. package/src/android-bootstrap/less/type.less +303 -303
  117. package/src/android-bootstrap/less/utilities.less +55 -55
  118. package/src/android-bootstrap/less/variables.less +896 -896
  119. package/src/android-bootstrap/less/wells.less +29 -29
  120. package/src/bootstrap/less/.csscomb.json +304 -304
  121. package/src/bootstrap/less/.csslintrc +19 -19
  122. package/src/bootstrap/less/alerts.less +73 -73
  123. package/src/bootstrap/less/badges.less +66 -66
  124. package/src/bootstrap/less/breadcrumbs.less +26 -26
  125. package/src/bootstrap/less/button-groups.less +247 -247
  126. package/src/bootstrap/less/buttons.less +172 -172
  127. package/src/bootstrap/less/carousel.less +269 -269
  128. package/src/bootstrap/less/close.less +34 -34
  129. package/src/bootstrap/less/code.less +69 -69
  130. package/src/bootstrap/less/component-animations.less +33 -33
  131. package/src/bootstrap/less/dropdowns.less +216 -216
  132. package/src/bootstrap/less/grid.less +84 -84
  133. package/src/bootstrap/less/input-groups.less +167 -167
  134. package/src/bootstrap/less/jumbotron.less +52 -52
  135. package/src/bootstrap/less/labels.less +64 -64
  136. package/src/bootstrap/less/list-group.less +141 -141
  137. package/src/bootstrap/less/media.less +66 -66
  138. package/src/bootstrap/less/mixins/alerts.less +14 -14
  139. package/src/bootstrap/less/mixins/background-variant.less +9 -9
  140. package/src/bootstrap/less/mixins/border-radius.less +18 -18
  141. package/src/bootstrap/less/mixins/buttons.less +69 -69
  142. package/src/bootstrap/less/mixins/center-block.less +7 -7
  143. package/src/bootstrap/less/mixins/clearfix.less +22 -22
  144. package/src/bootstrap/less/mixins/forms.less +90 -90
  145. package/src/bootstrap/less/mixins/gradients.less +59 -59
  146. package/src/bootstrap/less/mixins/grid-framework.less +92 -92
  147. package/src/bootstrap/less/mixins/grid.less +122 -122
  148. package/src/bootstrap/less/mixins/hide-text.less +21 -21
  149. package/src/bootstrap/less/mixins/image.less +33 -33
  150. package/src/bootstrap/less/mixins/labels.less +12 -12
  151. package/src/bootstrap/less/mixins/list-group.less +30 -30
  152. package/src/bootstrap/less/mixins/nav-divider.less +10 -10
  153. package/src/bootstrap/less/mixins/nav-vertical-align.less +9 -9
  154. package/src/bootstrap/less/mixins/opacity.less +8 -8
  155. package/src/bootstrap/less/mixins/pagination.less +24 -24
  156. package/src/bootstrap/less/mixins/panels.less +24 -24
  157. package/src/bootstrap/less/mixins/progress-bar.less +10 -10
  158. package/src/bootstrap/less/mixins/reset-filter.less +8 -8
  159. package/src/bootstrap/less/mixins/reset-text.less +18 -18
  160. package/src/bootstrap/less/mixins/resize.less +6 -6
  161. package/src/bootstrap/less/mixins/responsive-visibility.less +15 -15
  162. package/src/bootstrap/less/mixins/size.less +10 -10
  163. package/src/bootstrap/less/mixins/tab-focus.less +9 -9
  164. package/src/bootstrap/less/mixins/table-row.less +44 -44
  165. package/src/bootstrap/less/mixins/text-emphasis.less +9 -9
  166. package/src/bootstrap/less/mixins/text-overflow.less +8 -8
  167. package/src/bootstrap/less/mixins/vendor-prefixes.less +227 -227
  168. package/src/bootstrap/less/mixins.less +40 -40
  169. package/src/bootstrap/less/modals.less +151 -151
  170. package/src/bootstrap/less/navbar.less +660 -660
  171. package/src/bootstrap/less/normalize.less +424 -424
  172. package/src/bootstrap/less/pagination.less +89 -89
  173. package/src/bootstrap/less/panels.less +275 -275
  174. package/src/bootstrap/less/popovers.less +131 -131
  175. package/src/bootstrap/less/print.less +101 -101
  176. package/src/bootstrap/less/progress-bars.less +87 -87
  177. package/src/bootstrap/less/responsive-embed.less +35 -35
  178. package/src/bootstrap/less/responsive-utilities.less +194 -194
  179. package/src/bootstrap/less/scaffolding.less +161 -161
  180. package/src/bootstrap/less/theme.less +291 -291
  181. package/src/bootstrap/less/thumbnails.less +36 -36
  182. package/src/bootstrap/less/tooltip.less +102 -102
  183. package/src/bootstrap/less/type.less +303 -303
  184. package/src/bootstrap/less/utilities.less +55 -55
  185. package/src/bootstrap/less/wells.less +29 -29
  186. package/src/components/FileUpload.vue +696 -696
  187. package/src/components/Hello.vue +39 -39
  188. package/src/components/LeftTree.vue +27 -27
  189. package/src/components/android/AreaPlan.vue +567 -567
  190. package/src/components/android/AttendanceTally.vue +116 -116
  191. package/src/components/android/Blank.vue +10 -10
  192. package/src/components/android/CheckUnplanPage.vue +56 -56
  193. package/src/components/android/Checker.vue +12 -12
  194. package/src/components/android/CheckerAnnual.vue +81 -81
  195. package/src/components/android/CheckerAvarta.vue +82 -82
  196. package/src/components/android/EquipmentInspection.vue +348 -348
  197. package/src/components/android/FootprintMap.vue +120 -120
  198. package/src/components/android/HiddentroubleInvestigation.vue +192 -192
  199. package/src/components/android/MasterMain.vue +77 -77
  200. package/src/components/android/Menu.vue +132 -132
  201. package/src/components/android/PaperAlarm.vue +85 -85
  202. package/src/components/android/PaperDeviceNoncivil.vue +214 -214
  203. package/src/components/android/PlumberAnnual.vue +83 -83
  204. package/src/components/android/PlumberAnnualDetail.vue +65 -65
  205. package/src/components/android/PlumberMonthly.vue +84 -84
  206. package/src/components/android/PostMap.vue +83 -83
  207. package/src/components/android/QueryCheckHistory.vue +122 -122
  208. package/src/components/android/QueryCheckHistoryItem.vue +62 -62
  209. package/src/components/android/RepairMain.vue +60 -60
  210. package/src/components/android/Repairman.vue +12 -12
  211. package/src/components/android/SafecheckOrderV.vue +2291 -2291
  212. package/src/components/android/StationMaster.vue +12 -12
  213. package/src/components/defects/DefectModal.vue +101 -101
  214. package/src/components/defects/DevicesAndItem.vue +39 -39
  215. package/src/components/issueplan/IssuePlanMain.vue +23 -23
  216. package/src/components/notice/NoticeForm.vue +100 -100
  217. package/src/components/notice/NoticeIssue.vue +20 -20
  218. package/src/components/paper/PicViewer.vue +18 -18
  219. package/src/components/phonestate/MonthlyTraffic.vue +66 -66
  220. package/src/components/phonestate/MonthlyTrafficRouter.vue +15 -15
  221. package/src/components/phonestate/PostMap.vue +82 -82
  222. package/src/components/querycheckpaper/PaperItem.vue +59 -59
  223. package/src/components/userfile/MeterFile.vue +145 -145
  224. package/src/components/userfile/MeterModify.vue +46 -46
  225. package/src/components/userfileaudit/MeterAuditFile.vue +129 -129
  226. package/src/filiale/dexin/android/AreaPlan.vue +567 -567
  227. package/src/filiale/dexin/android.js +21 -21
  228. package/src/filiale/qingjian/pc/NewCheckpaper.vue +1 -0
  229. package/src/filiale/siyang/android/SafecheckDevices.vue +1302 -1302
  230. package/src/filiale/siyang/android/SafecheckUserInfo.vue +849 -849
  231. package/src/filiale/wenxi/android/SafecheckOrderV.vue +2682 -2682
  232. package/src/filiale/wuan/android/SafecheckOrderV.vue +2242 -2242
  233. package/src/filiale/wuan/android/SafecheckUserInfo.vue +655 -655
  234. package/src/filiale/wuan/pc/NewCheckpaper.vue +1184 -1184
  235. package/src/plugins/LoadData.js +10 -10
  236. package/src/plugins/LoadParams.js +24 -24
  237. package/src/stores/wxconfig.js +10 -10
  238. package/src/utils/getNowDate.js +33 -33
  239. package/test/e2e/custom-assertions/elementCount.js +26 -26
  240. package/test/e2e/nightwatch.conf.js +40 -40
  241. package/test/e2e/runner.js +30 -30
  242. package/test/e2e/specs/test.js +13 -13
  243. package/test/unit/.eslintrc +5 -5
  244. package/test/unit/TestUtil.js +62 -62
  245. package/test/unit/context.html +20 -20
  246. package/test/unit/index.js +13 -13
@@ -1,1184 +1,1184 @@
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
- div::-webkit-scrollbar {
22
- width: 0 !important;
23
- height: 0 !important;
24
- }
25
-
26
- div{
27
- -ms-overflow-style: none;
28
- overflow: -moz-scrollbars-none;
29
- }
30
- .divmask {
31
- pointer-events: none;
32
- }
33
- .app-header {
34
- border-radius: 50%;
35
- background: rgba(73, 158, 223, 0.4);
36
- color: #FFF;
37
- padding: 20px;
38
- text-align: center;
39
- font-size: 1.2em;
40
- z-index: 10;
41
- opacity:0.5;
42
- bottom: 50px;
43
- margin-top: -20px;
44
- position: absolute;
45
- top: 10%;
46
- right: 2%;
47
- height: 8%;
48
- }
49
- </style>
50
-
51
- <template>
52
- <div class="basic-main" style="height: 100%">
53
- <div class="page-header app-header auto" style="padding: 15px;margin-right: 10px;right: 0%;height: 7%">
54
- <div @click="back()">
55
- <img src="../../../assets/back.png" style="margin: 0px"/>
56
- </div>
57
- </div>
58
- <work-busy :is-busy="loading"></work-busy>
59
- <div class="container-fluid" style="overflow: scroll">
60
- <div class="row">
61
- <div class="col-md-6" style="margin-right: 2%;height: 100%;overflow: scroll">
62
- <div style="width: 95%;margin-left: 5%" >
63
- <table class="table table-striped table-bordered" v-for="config in deviceconfig2">
64
- <thead v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
65
- <tr>
66
- <th style="text-align: center" >{{config.checkname}}</th>
67
- </tr>
68
- </thead>
69
- <tbody v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
70
- <tr v-for="dev in config.items">
71
- <td v-if="dev.type!='text'">
72
- <div class="row">
73
- <div class="col-md-8" style="text-align: center;">
74
- <label ><button-link type="button" class="btn btn-link" @click="showpicture(config.checkname,dev.lname)" :style="isred(config.checkname,dev.lname)?'color:red':'color:black'">{{dev.lname}}
75
- </button-link></label>
76
- </div>
77
- <div class="col-md-4" style="text-align: center" >
78
- <label style="font-weight: normal" v-if="dev.type!='picture'">{{getDeviceValue(config.checkname,dev.lname)}}</label>
79
- <label style="font-weight: normal" v-if="dev.type=='picture'"><div v-show="getDevicePath(config.checkname,dev.lname)"><button-link style="color: black" type="button" class="btn btn-link" @click="showpath(getDevicePath(config.checkname,dev.lname),dev.lname)">查看照片
80
- </button-link></div></label>
81
- </div>
82
- </div>
83
- </td>
84
- <td v-if="dev.type==='text'">
85
- <label style="width: 100%;text-align: center">{{dev.lname}}</label>
86
- </td>
87
- </tr>
88
- </tbody>
89
- </table>
90
- </div>
91
- </div>
92
- <div class style="width: 1%;height: 100%;background-color: #F1F8FF;float: left;"></div>
93
- <div class="col-md-5" style="margin-left: 2%;height: 100%;overflow: scroll">
94
- <div style="width: 100%;margin: auto" >
95
- <table class="table table-striped table-bordered" style="margin-bottom: 6px">
96
- <thead>
97
- <tr>
98
- <th colspan="6" style="text-align: center" >用户基本信息</th>
99
- </tr>
100
- </thead>
101
- <tbody>
102
- <tr>
103
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户编号:</td>
104
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{paperdata.f_userinfo_code}}</td>
105
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户名称:</td>
106
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{paperdata.f_user_name}}</td>
107
- </tr>
108
- <tr>
109
- <td style="text-align: center;border: #E9E9E9 solid 1px">证件号码:</td>
110
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_idnumber }}</td>
111
- <td style="text-align: center;border: #E9E9E9 solid 1px">用户类型:</td>
112
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_check_type }}</td>
113
- </tr>
114
- <tr>
115
- <td style="text-align: center;border: #E9E9E9 solid 1px">用户电话:</td>
116
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_user_phone }}</td>
117
- <td style="text-align: center;border: #E9E9E9 solid 1px">区 / 县:</td>
118
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_area }}</td>
119
- </tr>
120
- <tr>
121
- <td style="text-align: center;border: #E9E9E9 solid 1px">街 道:</td>
122
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_street }}</td>
123
- <td style="text-align: center;border: #E9E9E9 solid 1px">楼 号:</td>
124
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_building }}</td>
125
- </tr>
126
- <tr>
127
- <td style="text-align: center;border: #E9E9E9 solid 1px">单 元:</td>
128
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_unit }}</td>
129
- <td style="text-align: center;border: #E9E9E9 solid 1px">楼 层:</td>
130
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_floor }}</td>
131
- </tr>
132
- <tr>
133
- <td style="text-align: center;border: #E9E9E9 solid 1px">门 牌 号 :</td>
134
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_room }}</td>
135
- <td style="text-align: center;border: #E9E9E9 solid 1px">用户性质:</td>
136
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_userproperties }}</td>
137
- </tr>
138
- <tr>
139
- <td style="text-align: center;border: #E9E9E9 solid 1px">备注信息:</td>
140
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_comments }}</td>
141
- <td style="text-align: center;border: #E9E9E9 solid 1px">小区名称:</td>
142
- <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_residential_area }}</td>
143
- </tr>
144
- <tr>
145
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px">详细住址:</td>
146
- <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_address }}</td>
147
- </tr>
148
- </tbody>
149
- </table>
150
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
151
- <thead>
152
- <tr> <th colspan="4" style="text-align: center">用户安检概况</th></tr>
153
- </thead>
154
- <tbody>
155
- <tr>
156
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
157
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
158
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
159
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
160
- </tr>
161
- <tr>
162
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
163
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_entry_status }}</td>
164
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%" >燃气使用:</td>
165
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_usegas }}</td>
166
- </tr>
167
- <tr >
168
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">用户满意度:</td>
169
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{ paperdata.f_client_evaluation }}</td>
170
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">安检结果:</td>
171
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{ ajresult }}</td>
172
- </tr>
173
- <tr>
174
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">备注:</td>
175
- <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
176
- {{paperdata.f_repair_approved_note }}
177
- </td>
178
- </tr>
179
- <tr>
180
- <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">隐患详情:</td>
181
- <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
182
- <span v-for="deviceCollect in deviceCollects">
183
- <span class="li-font">
184
- {{deviceCollect.name}}:{{deviceCollect.value}}&nbsp;&nbsp;&nbsp;
185
- </span>
186
- <br>
187
- <span v-if="deviceCollect.value == '有隐患'">
188
- <lable>
189
- 隐患:
190
- </lable>
191
- <span class="li-font" v-for="val in deviceCollect.devices">
192
- {{val}}&nbsp;&nbsp;&nbsp;
193
- </span><br>
194
- </span>
195
-
196
- </span>
197
- </td>
198
- </tr>
199
-
200
- </tbody>
201
- </table>
202
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status!='入户'">
203
- <thead>
204
- <tr> <th colspan="4" style="text-align: center">用户安检概况</th></tr>
205
- </thead>
206
- <tbody>
207
- <tr>
208
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
209
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
210
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
211
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
212
- </tr>
213
- <tr>
214
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
215
- <td colspan="2" style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_entry_status }}</td>
216
- <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%" ><button-link style="color: black" type="button" class="btn btn-link" @click="showpicture2()">{{dev.lname}}
217
- 查看{{data.f_entry_status}}照片</button-link></td>
218
- </tr>
219
-
220
- </tbody>
221
- </table>
222
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
223
- <thead>
224
- <tr> <th style="text-align: center">总体安检照片</th></tr>
225
- </thead>
226
- <tbody> <tr>
227
- <td style="margin: auto;text-align: center">
228
- <div class="container" style="max-width: 550px;background: #FFFFFF">
229
- <div class="img" v-for="img in paperdata.f_overall_imgs">
230
- <img-self-safe :src="img.f_overall_path" style="float: left" width="150" height="200"></img-self-safe>
231
- </div>
232
- </div>
233
-
234
-
235
- </td>
236
-
237
- </tr></tbody>
238
- </table>
239
- <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
240
- <thead>
241
- <tr> <th style="text-align: center">用户签名照片</th></tr>
242
- </thead>
243
- <tbody> <tr>
244
- <td style="margin: auto;text-align: center">
245
- <div class="container" style="max-width: 500px;background: #FFFFFF">
246
- <div class="img" style="float: none">
247
- <img-self-safe :src="paperdata.f_sign_path" width="486" height="300"></img-self-safe>
248
- </div>
249
-
250
- </div>
251
-
252
-
253
- </td>
254
-
255
- </tr></tbody>
256
- </table>
257
- </div>
258
- </div>
259
- </div>
260
- </div>
261
- </div>
262
- <modal :show.sync="imgshow" v-ref:modal backdrop="true">
263
- <header slot="modal-header" class="modal-header">
264
- {{picturename}}
265
- </header>
266
- <article slot="modal-body" class="modal-body">
267
- <div class="from-group">
268
- <div class="row">
269
- <div class="col-md-6">
270
- <img-self-safe v-if="showimg1" :src="showimg1" width="300" height="400"></img-self-safe>
271
- </div><div class="col-md-6">
272
- <img-self-safe v-if="showimg2" :src="showimg2" width="300" height="400"></img-self-safe>
273
- </div>
274
- </div>
275
- </div>
276
- </article>
277
- <footer slot="modal-footer" class="modal-footer" v-show="false">
278
- <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
279
- </footer>
280
- </modal>
281
- <modal :show.sync="imgshow2" v-ref:modal backdrop="true">
282
- <header slot="modal-header" class="modal-header">
283
- {{paperdata.f_entry_status}}照片
284
- </header>
285
- <article slot="modal-body" class="modal-body">
286
- <div class="from-group">
287
- <div class="row">
288
- <div class="col-md-6">
289
- <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'" :src="showimg3" width="300" height="400"></img-self-safe>
290
- </div>
291
- <div class="col-md-6">
292
- <img-self-plus v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer1_path"
293
- :src="showimg5" width="282"
294
- height="400"></img-self-plus>
295
- </div>
296
- <div class="col-md-6">
297
- <img-self-plus v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer2_path"
298
- :src="showimg6" width="282"
299
- height="400"></img-self-plus>
300
- </div>
301
- <div class="col-md-6">
302
- <img-self-safe v-if="this.paperdata.f_entry_status=='拒检'" :src="showimg4" width="300" height="400"></img-self-safe>
303
- </div>
304
- </div>
305
- </div>
306
- </article>
307
- <footer slot="modal-footer" class="modal-footer" v-show="false">
308
- <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
309
- </footer>
310
- </modal>
311
- </template>
312
-
313
- <script>
314
- // import PaperUserm from './PaperUserm'
315
- // import PaperStatem from './PaperStatem'
316
- // import Devicesm from './Devicesm'
317
- // import PaperFeedbackm from './PaperFeedbackm'
318
- import ObjConfig from '../../../utils/GerJsonObjectConfig'
319
- import RadioGroup from 'vue-client/src/vue-strap/src/radioGroup'
320
- import Radio from 'vue-client/src/vue-strap/src/radioBtn'
321
- import Vue from 'vue'
322
- import * as Util from '../../Util'
323
- import {jsonSort} from '../../../utils/LdapHelper'
324
- import {HttpResetClass} from "vue-client";
325
- let asyncReady = async function (self) {
326
- // 获取配置信息
327
- try {
328
- let res= await new HttpResetClass().load('post','rs/sql/tel_singleTable_OrderBy',{data: {
329
- items: 'f_dir',
330
- tablename: 't_organization',
331
- condition: `id = '${self.item.f_filialeid}'`,
332
- orderitem: 'id'
333
- }})/*.then(res=>{*/
334
- //tag
335
- //tag)
336
- if (!res.data[0].f_dir){
337
- this.$showMessage("该公司无组织目录,无法获取配置文件,请联系管理员确认")
338
- }else{
339
- //this.f_dir=res.data[0].f_dir
340
- try {
341
- let res1=await new HttpResetClass().load('GET',`/safecheck/rs/vue/DevicesConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {},{resolveMsg: '获取居民配置项成功!', rejectMsg: '获取居民配置项出错!'})/*.then(res=>{*/
342
- //tag
343
- //this.safeConfig["民用配置项"]=Object.assign({},res.data)
344
- Vue.config.safecheck.DevicesConfig=res1.data
345
- /*})*/
346
- let res2=await new HttpResetClass().load('GET',`/safecheck/rs/vue/DevicesSetConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {},{resolveMsg: '获取非居民配置项成功!', rejectMsg: '获取非居民配置项出错!'})/*.then(res=>{*/
347
- //tag
348
- //this.safeConfig["非民用配置项"]=Object.assign({},res.data)
349
- Vue.config.safecheck.DevicesSetConfig=res2.data
350
- /*}).then(res=> {
351
- })*/
352
-
353
- }catch (e) {
354
- this.$showMessage("获取配置文件失败"+e)
355
- }
356
- }
357
- } catch (error) {
358
- // 忽略704,文件找不到异常R
359
- if (error.status !== 704) {
360
- throw error
361
- }
362
- }
363
- }
364
- export default {
365
- title: '安检单',
366
- props: ['f_plan_id', 'item', 'role'],
367
- data() {
368
- return {
369
- data: {
370
- f_devices: [],
371
- f_defect_content:''
372
- },
373
- paperdata:{},
374
- picturename:'隐患照片',
375
- defectDevice:{},
376
- hasDevice:false,
377
- deviceCollect:{},
378
- deviceCollects:[],
379
- isshow:false,
380
- ajresult:'',
381
- loading:true,
382
- imgshow:false,
383
- imgshow2:false,
384
- isUpload:false,
385
- livedispose:'',
386
- showimg1:'',
387
- showimg2:'',
388
- showimg3:'',
389
- showimg4:'',
390
- showimg5: '',
391
- showimg6: '',
392
- startClick:false, //开始安检按钮是否可点击
393
- isStrat: false, //是否开始安检
394
- checkResult:{},//查询结果
395
- newcheckResult:{},
396
- timer: null,
397
- showModal: false,
398
- pic_to_be_viewed: '',
399
- showBack:true,
400
- devices: [],
401
- devicesAll:[],
402
- configAJ:[],
403
- configRQ:[],
404
- deviceconfig:{},
405
- deviceconfig2:[],
406
- f_devices : [],
407
- config: {
408
- "燃气表":{
409
- "checkmust":true,
410
- "index":1,
411
- "items":{
412
- //"燃气表照片":{"index":1,"type":"picture","remark":"(拍摄清晰的表具编号、字轮数、剩余气量等)"},
413
- "基表编号":{"index":1,"type":"string","readonly":true},
414
- "气表型号":{"index":2,"type":"string","readonly":true},
415
- "气表品牌":{"index":3,"type":"string","readonly":true},
416
- "进气方向":{"index":4,"type":"string","readonly":true},
417
- // "初始表底":{"index":5,"type":"number","isshow":false,"readonly":true},
418
- "上期表读数":{"index":5,"type":"number","readonly":true,isshow:false},
419
- "累购气量":{"index":6,"type":"number","readonly":true},
420
- "已用气量":{"index":7,"type":"number","checkmust": true},//基表数
421
- "剩余气量":{"index":8,"type":"number","checkmust": true},//累购-已用
422
- //显示屏数 --实际剩余气量
423
- "气量异常差值":{"index":9,"type":"number","readonly": true}
424
- }
425
- // 注意,配置项的index必须与上面的固定配置保持'顺序'
426
- }
427
- },
428
- //金额
429
- config2: {
430
- "燃气表":{
431
- "checkmust":true,
432
- "index":1,
433
- "items":{
434
- //"燃气表照片":{"index":1,"type":"picture","remark":"(拍摄清晰的表具编号、字轮数、剩余气量等)"},
435
- "基表编号":{"index":1,"type":"string","readonly":true},
436
- "气表型号":{"index":2,"type":"string","readonly":true},
437
- "气表品牌":{"index":3,"type":"string","readonly":true},
438
- "进气方向":{"index":4,"type":"string","readonly":true},
439
- // "初始表底":{"index":5,"type":"number","isshow":false,"readonly":true},
440
- "上期表读数":{"index":5,"type":"number","readonly":true,isshow:false},
441
- "累购金额":{"index":6,"type":"number","readonly":true},
442
- "已用金额":{"index":7,"type":"number","checkmust": true},
443
- //显示屏数 --实际剩余气量
444
- "剩余金额":{"index":8,"type":"number","checkmust": true},
445
- "金额异常差值":{"index":9,"type":"number","readonly": true}
446
- }
447
- }
448
- },
449
- }
450
- },
451
- components: {
452
- RadioGroup,
453
- Radio,
454
- },
455
- computed: {
456
-
457
- selector: {
458
- get() {
459
- return 'paper-state'
460
- },
461
- set(val) {
462
- if(this.isStrat){
463
- //;
464
- this.$goto(val, {userinfo:this.data}, 'paper-router')
465
- }else{
466
- this.$showMessage('未开始安检!')
467
- }
468
- }
469
- },
470
- actionEnabled: {
471
- get() {
472
- return this.role == 'inspect'
473
- }
474
- }
475
- },
476
- methods: {
477
- devicesCollect(){
478
- // //tag
479
- //tag
480
- //tag)
481
- //tag)
482
- //tag
483
-
484
- this.deviceCollects = []
485
- let checkResult = '正常'
486
- this.result = '正常'
487
- let codata = JSON.parse(JSON.stringify(this.data))
488
- //tag)
489
- for(let device in this.data){
490
- let f_device_type
491
- if(device.startsWith("device")){
492
- for(let item in this.data[device]) {
493
- if(this.data[device].length > 1 ){
494
- let j = Number.parseInt(item)+1
495
- f_device_type = `${this.data[device][item].f_device_type}${j}`
496
- }else{
497
- f_device_type = this.data[device][item].f_device_type
498
- }
499
- // //tag
500
- let deviceInfos = []
501
- for(let i in this.data[device][item].f_items){
502
- let defects = ''
503
- let items = this.data[device][item].f_items[i]
504
- if ((items.type === 'selector' || items.type === 'radio' || items.type === 'checkbox') && items.f_item_value != null && items.f_item_value instanceof Array){
505
- for (let i in items.f_item_value) {
506
- let f_item_value = items.f_item_value[i]
507
-
508
- //tag)
509
- //tag)
510
- //tag)
511
- //tag)
512
- if (!this.config[this.data[device][item].f_device_type].items[items.f_item_name]){
513
- continue
514
- }
515
- let options = this.config[this.data[device][item].f_device_type].items[items.f_item_name].options
516
- for (let option in options) {
517
- if (options[option].data == f_item_value) {
518
- if (options[option].isdefect == 'true' || options[option].isdefect == true) {
519
- checkResult = '有隐患'
520
- this.result = '有隐患'
521
- defects=`${defects}:${options[option].data}/`
522
- // let level = options[option].level
523
- }
524
- }
525
- }
526
- //tag)
527
- }
528
- if(defects != ''){
529
- deviceInfos.push(`${items.f_item_name}${defects.substring(0, defects.length - 1)}`)
530
- }
531
- }else if(items.type === 'stringp'){
532
- checkResult = '有隐患'
533
- this.result = '有隐患'
534
- deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
535
- }else if(items.f_item_name == '金额异常差值'){
536
- var deviation = this.$appdata.getSingleValue('金额异常差值允许误差')
537
- //tag
538
- if(parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN"){
539
- if(parseFloat(items.f_item_value[0])>parseFloat(deviation) || parseFloat(items.f_item_value[0])<parseFloat(deviation)*-1){
540
- checkResult = '有隐患'
541
- this.result = '有隐患'
542
- deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
543
- }
544
- }
545
- }else if(items.f_item_name == '气量异常差值'){
546
- var deviation = this.$appdata.getSingleValue('气量异常差值允许误差')
547
- //tag
548
- if(parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN"){
549
- if(parseFloat(items.f_item_value[0])>parseFloat(deviation) || parseFloat(items.f_item_value[0])<parseFloat(deviation)*-1){
550
- checkResult = '有隐患'
551
- this.result = '有隐患'
552
- deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
553
- }
554
- }
555
- }
556
- //tag)
557
- //tag
558
- //tag
559
- if (items.type === 'selector') {
560
- items.selected = []
561
- } else if (items.type === 'inputSelector') {
562
- items.selected = ''
563
- }
564
- }
565
-
566
-
567
- //tag
568
- this.$set('deviceCollect.name',f_device_type)
569
- this.$set('deviceCollect.value',checkResult)
570
- this.$set('deviceCollect.devices',deviceInfos)
571
- //tag)
572
- if (this.deviceCollect.name){
573
- //tag
574
- this.deviceCollects.push(JSON.parse(JSON.stringify(this.deviceCollect)))
575
- }
576
-
577
- checkResult = '正常'
578
- this.deviceCollect = {}
579
- }
580
- }
581
- }
582
- if(this.deviceCollects.length>0){
583
- this.hasDevice = true
584
- }
585
- this.ajresult=JSON.parse(this.data.f_defect_content).result
586
- this.showimg3=this.data.f_noanswer_path
587
- this.showimg5 = this.data.f_noanswer1_path
588
- this.showimg6 = this.data.f_noanswer2_path
589
- this.showimg4=this.data.f_rejectcheck_path
590
- this.paperdata=this.data
591
- this.loading=false
592
- },
593
- imgclose(){
594
- this.imgshow=false
595
- },
596
- putDevices() {
597
- ////tag
598
- this.$set('data.approve', "true")
599
- this.$set('data.writeback', "false")
600
- if (Vue.config.safecheck.ApproveConfig != undefined) {
601
- if (Vue.config.safecheck.ApproveConfig.approve != undefined) {
602
- this.$set('data.approve', Vue.config.safecheck.ApproveConfig.approve)
603
- }
604
- if (Vue.config.safecheck.ApproveConfig.writeback != undefined) {
605
- this.$set('data.writeback', Vue.config.safecheck.ApproveConfig.writeback)
606
- }
607
- if (Vue.config.safecheck.ApproveConfig.livedispose != undefined) {
608
- this.livedispose = Vue.config.safecheck.ApproveConfig.livedispose
609
- }
610
- }
611
- //tag
612
-
613
- //tag)
614
- if(!this.item.f_safecheck_type){
615
- this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType['年度普检'][this.item.f_check_type]])
616
- }else{
617
- if (Vue.config.safecheck.DevicesConfig != undefined)
618
- this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType[this.item.f_safecheck_type][this.item.f_check_type]])
619
- }
620
- //遍历安检项配置
621
- for (let i in this.config) {
622
- //取得安检项索引值
623
- let n = this.config[i].index
624
- this.devices[n - 1] = {device: i, n: n, checkmust: this.config[i].checkmust}
625
- this.$set('data.' + 'device' + n, [])
626
- let items = []
627
- for (let it in this.config[i].items) {
628
- //赋值下拉选项
629
- if (this.config[i].items[it].type == 'selector') {
630
- for (let op in this.config[i].items[it].options)
631
- if (this.config[i].items[it].options[op].isdefault == true) {
632
- items.push({
633
- f_defect_level: this.config[i].items[it].options[op].level,
634
- f_is_defect: this.config[i].items[it].options[op].isdefect,
635
- f_item_name: it,
636
- f_item_value: this.config[i].items[it].options[op].data,
637
- f_path: "",
638
- type: "selector"
639
- })
640
- }
641
- }
642
- }
643
- n = n + 1
644
- }
645
-
646
- },
647
- showpath(val1,val2){
648
- //tag
649
- //tag
650
- if (val1){
651
- this.showimg1=val1
652
- this.picturename=val2
653
- this.imgshow=true
654
- }
655
- },
656
- showpicture(val1,val2){
657
- //tag
658
- if (val2=='气量异常差值'||val2=='金额异常差值'){
659
- return
660
- }
661
- for (let i = 0; i <this.devicesAll.length; i++) {
662
- for (let j = 0; j < this.devicesAll[i].length; j++) {
663
- if (this.devicesAll[i][j].f_device_type==val1){
664
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
665
- if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
666
- if (!this.devicesAll[i][j].f_items[k].f_is_defect){
667
- return false
668
- }else{
669
- this.showimg1=this.devicesAll[i][j].f_items[k].f_path
670
- this.showimg2=this.devicesAll[i][j].f_items[k].f_second_path
671
- this.picturename='隐患照片'
672
- this.imgshow=true
673
- return true
674
- }
675
- }
676
- }
677
-
678
- }
679
- }
680
- }
681
- },
682
- isred(val1,val2){
683
- //tag
684
- if (val2=='气量异常差值'||val2=='金额异常差值'){
685
- return
686
- }
687
- for (let i = 0; i <this.devicesAll.length; i++) {
688
- for (let j = 0; j < this.devicesAll[i].length; j++) {
689
- if (this.devicesAll[i][j].f_device_type==val1){
690
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
691
- if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
692
- if (!this.devicesAll[i][j].f_items[k].f_is_defect){
693
- return false
694
- }else{
695
- return true
696
- }
697
- }
698
- }
699
-
700
- }
701
- }
702
- }
703
- },
704
- showpicture2(){
705
- this.imgshow2=true
706
- },
707
- getDeviceValue(val1,val2){
708
- if (val2=='是否有隐患'){
709
- return this.ajresult=='正常'?'否':'是'
710
- }
711
- for (let i = 0; i <this.devicesAll.length; i++) {
712
- for (let j = 0; j < this.devicesAll[i].length; j++) {
713
- if (this.devicesAll[i][j].f_device_type==val1){
714
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
715
- if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
716
- if(this.devicesAll[i][j].f_items[k].f_item_lists[0]){
717
- return this.devicesAll[i][j].f_items[k].f_item_lists[0].f_item_value
718
- }
719
- }
720
- }
721
-
722
- }
723
- }
724
- }
725
-
726
- },
727
- getDevicePath(val1,val2){
728
- for (let i = 0; i <this.devicesAll.length; i++) {
729
- for (let j = 0; j < this.devicesAll[i].length; j++) {
730
- if (this.devicesAll[i][j].f_device_type==val1){
731
- for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
732
- if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
733
- return this.devicesAll[i][j].f_items[k].f_path
734
- }
735
- }
736
-
737
- }
738
- }
739
- }
740
-
741
- },
742
- getDeviceAll(){
743
- let keyall= Object.keys(this.data)
744
- for (let i = 0; i < keyall.length; i++) {
745
- //tag)
746
- if (keyall[i].startsWith('device') && keyall[i] !='deviceundefined'){
747
- this.devicesAll.push(this.data[keyall[i]])
748
- //tag
749
- }
750
- }
751
- //tag
752
- //tag)
753
- this.devicesCollect()
754
-
755
- },
756
-
757
- back(){
758
- if (this.role == 'inspect') {
759
- if(!this.isStrat){
760
- this.$back()
761
- return
762
- }else{
763
- this.savePaper(true).then(()=>{
764
- this.$back()
765
- this.isStrat = false
766
- })
767
- }
768
- }else{
769
- this.$back()
770
- }
771
- },
772
- checkIsStart(){
773
- alert('asdad')
774
- return
775
- },
776
-
777
- viewPic(fileName) {
778
- //tag
779
- if(this.role == 'view') {
780
- if(!fileName.endsWith('nopic.png')) {
781
- this.pic_to_be_viewed = fileName
782
- this.showModal = true
783
- }
784
- } else {
785
- HostApp.viewPic(fileName)
786
- }
787
- },
788
- tick() {
789
- this.timer = null
790
- this.data.f_offsite_time = Util.toStandardTimeString()
791
- this.timer = window.setTimeout(this.tick, 1000)
792
- },
793
- getRepairState() {
794
- let repaired = true
795
- this.data.f_defects.forEach((defect) => {
796
- repaired = repaired & (defect.f_ratification == '已处理')
797
- })
798
- return repaired
799
- },
800
- verifyRepairDefects() {
801
- this.data.f_repair_date = Util.toStandardTimeString()
802
- this.data.f_repaired = this.getRepairState() ? '已修' : '在修'
803
- },
804
- genuineSave(saveOnly) {
805
- HostApp.__this__.save(saveOnly)
806
- if(!saveOnly)
807
- HostApp.__this__.disableTimer()
808
- HostApp.__callback__ = null
809
- HostApp.__this__ = null
810
- },
811
- setUrgency() {
812
- this.data.f_defect_urgency = 'Z'
813
- let that = this
814
- this.data.f_defects.forEach(function(defect) {
815
- if(that.data.f_defect_urgency > defect.f_defect_level.charAt(0))
816
- that.data.f_defect_urgency = defect.f_defect_level.charAt(0)
817
- })
818
- if(this.data.f_defect_urgency == 'Z')
819
- this.data.f_defect_urgency = null
820
- },
821
- disableTimer() {
822
- if(this.timer) {
823
- window.clearTimeout(this.timer)
824
- this.timer = null
825
- }
826
- },
827
- loaded(paper) {
828
- if(!paper.hasOwnProperty('id')) {
829
- this.$showMessage("该安检单在手机上已经不存在,可能是卸载过程序。可以进入重新安检,或返回安检计划。")
830
- this.init()
831
- } else {
832
- Util.booleanFilter(paper)
833
- HostApp.__this__.$set('data', paper)
834
- HostApp.__this__.$goto('paper-state', {}, 'paper-router')
835
- // 如果打回重检则重新计时
836
- //tag
837
- if(HostApp.__this__.role == 'inspect'
838
- && HostApp.__this__.data.f_approved
839
- && HostApp.__this__.data.f_approved == '打回') {
840
- //tag
841
- HostApp.__this__.data.f_onsite_time = Util.toStandardTimeString()
842
- HostApp.__this__.tick()
843
- }
844
- }
845
- HostApp.__callback__ = null
846
- HostApp.__this__ = null
847
- },
848
- S4() {
849
- return (((1+Math.random())*0x10000)|0).toString(16).substring(1);
850
- },
851
- init () {
852
- this.data.f_noplan_item_id = this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()
853
- this.data.ename = Vue.user.ename
854
- this.data.f_outlets = Vue.user.f_parentname
855
- this.data.f_meetunit = Vue.user.orgpathnames
856
- this.data.orgpathstr = Vue.user.orgpathstr
857
- this.data.f_check_item_id = this.item.id
858
- this.data.f_check_plan_id = this.f_plan_id
859
- this.data.f_checker_id = Vue.user.id
860
- this.data.f_checker_name = Vue.user.name
861
- this.data.f_check_type = this.item.f_user_type
862
- this.data.f_subcompany = this.item.f_subcompany
863
- this.data.f_approved = this.item.f_approved
864
- this.data.f_repair_approved = this.item.f_repair_approved
865
- this.data.f_no_checkplan = this.item.f_no_checkplan
866
- this.data.f_approved = this.item.f_approved
867
- this.data.f_filialeid = this.item.f_filialeid
868
- this.data.f_orgstr = this.item.f_orgstr
869
- this.data.version = this.item.version
870
- this.$set('data.f_meters', this.item.f_plan_meters)
871
- this.$set('data.f_userinfo_code', this.item.f_userinfo_code)
872
- // 安检状态
873
- this.$set('data.f_entry_status', '入户')
874
- this.$set('data.f_usegas', '已使用')
875
- this.$set('data.f_state',this.item.f_state)
876
- // 用户信息
877
- this.$set('data.f_user_name', this.item.f_user_name)
878
- this.$set('data.f_user_phone', this.item.f_user_phone)
879
- this.$set('data.f_userinfoid', this.item.f_userinfoid)
880
- this.$set('data.f_address', this.item.f_address)
881
- this.$set('data.f_card_id', this.item.f_card_id)
882
- this.$set('data.f_area', this.item.f_area)
883
- this.$set('data.f_street', this.item.f_street)
884
- this.$set('data.f_room',this.item.f_room)
885
- this.$set('data.f_building', this.item.f_building)
886
- this.$set('data.f_unit',this.item.f_unit)
887
- this.$set('data.f_floor', this.item.f_floor)
888
- this.$set('data.f_residential_area' , this.item.f_residential_area)
889
- this.$set('data.f_idnumber', this.item.f_idnumber)
890
- this.$set('data.f_comments', this.item.f_comments)
891
- this.$set('data.f_userproperties', this.item.f_userproperties)
892
- // 处置方式
893
- this.$set('data.f_no_gas_device', false)
894
- this.$set('data.f_close_valve', false)
895
- this.$set('data.f_unload_battery', false)
896
- if (this.data.f_check_item_id == '' && this.item.f_no_checkplan == '无计划安检') {
897
- this.data.f_check_item_id = this.data.f_noplan_item_id
898
- }
899
-
900
- //房屋结构
901
- // this.$set('data.f_room_style', '多层')
902
- //供暖方式
903
- // this.$set('data.f_heating_style', '热力公司集中供暖')
904
- if(this.item.f_plan_meters) {
905
- for (let de in this.devices) {
906
- this.$set('data.device' + this.devices[de].n, [])
907
- for (let i = 0; i < this.item.f_plan_meters.length; i++) {
908
- if(this.item.f_plan_meters[i].f_meter_type) {
909
- if (this.devices[de].device == "燃气表" && this.item.f_plan_meters[i].f_meter_type.indexOf('机表') > 0) {
910
- delete this.config['燃气表']['items']['累计购气量']
911
- this.data['device' + this.devices[de].n].push({
912
- f_device_type: "燃气表",
913
- f_items: [{
914
- f_defect_level: null,
915
- f_device_id: "",
916
- f_is_defect: "",
917
- f_item_name: "表品牌",
918
- f_item_value: this.item.f_plan_meters[i].f_aliasname,
919
- f_path: "",
920
- type: "string"
921
- },
922
- {
923
- f_defect_level: null,
924
- f_device_id: "",
925
- f_is_defect: "",
926
- f_item_name: "位置",
927
- f_item_value: this.item.f_plan_meters[i].f_weizhi,
928
- f_path: "",
929
- type: "selector"
930
- },
931
- {
932
- f_defect_level: null,
933
- f_device_id: "",
934
- f_is_defect: "",
935
- f_item_name: "表号",
936
- f_item_value: this.item.f_plan_meters[i].f_meter_no,
937
- f_path: "",
938
- type: "number"
939
- },
940
- {
941
- f_defect_level: null,
942
- f_device_id: "",
943
- f_is_defect: "",
944
- f_item_name: "表封号",
945
- f_item_value: this.item.f_plan_meters[i].f_metertitles,
946
- f_path: "",
947
- type: "number"
948
- },
949
- {
950
- f_defect_level: null,
951
- f_device_id: "",
952
- f_is_defect: "",
953
- f_item_name: "表型号",
954
- f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
955
- f_path: "",
956
- type: "selector"
957
- },
958
- {
959
- f_defect_level: null,
960
- f_device_id: "",
961
- f_is_defect: "",
962
- f_item_name: "表底数",
963
- f_item_value: this.item.f_plan_meters[i].f_prior_reading,
964
- f_path: "",
965
- type: "number"
966
- }
967
- ]
968
- })
969
- } else if (this.devices[de].device == "燃气表") {
970
- delete this.config['燃气表']['items']['表底数']
971
- this.data['device' + this.devices[de].n].push({
972
- f_device_type: "燃气表",
973
- f_items: [{
974
- f_defect_level: null,
975
- f_device_id: "",
976
- f_is_defect: "",
977
- f_item_name: "表品牌",
978
- f_item_value: this.item.f_plan_meters[i].f_aliasname,
979
- f_path: "",
980
- type: "string"
981
- },
982
- {
983
- f_defect_level: null,
984
- f_device_id: "",
985
- f_is_defect: "",
986
- f_item_name: "位置",
987
- f_item_value: this.item.f_plan_meters[i].f_weizhi,
988
- f_path: "",
989
- type: "selector"
990
- },
991
- {
992
- f_defect_level: null,
993
- f_device_id: "",
994
- f_is_defect: "",
995
- f_item_name: "表号",
996
- f_item_value: this.item.f_plan_meters[i].f_meter_no,
997
- f_path: "",
998
- type: "number"
999
- },
1000
- {
1001
- f_defect_level: null,
1002
- f_device_id: "",
1003
- f_is_defect: "",
1004
- f_item_name: "表封号",
1005
- f_item_value: this.item.f_plan_meters[i].f_metertitles,
1006
- f_path: "",
1007
- type: "number"
1008
- },
1009
- {
1010
- f_defect_level: null,
1011
- f_device_id: "",
1012
- f_is_defect: "",
1013
- f_item_name: "表型号",
1014
- f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1015
- f_path: "",
1016
- type: "selector"
1017
- },
1018
- {
1019
- f_defect_level: null,
1020
- f_device_id: "",
1021
- f_is_defect: "",
1022
- f_item_name: "累计购气量",
1023
- f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1024
- f_path: "",
1025
- type: "number"
1026
- }
1027
- ]
1028
- })
1029
- }
1030
- }
1031
- }
1032
- }
1033
- }
1034
-
1035
- this.$goto('paper-state', {}, 'paper-router')
1036
- },
1037
- extend(initalObj, finalObj) {
1038
- var obj = finalObj || {};
1039
- for (var i in initalObj) {
1040
- var prop = initalObj[i];
1041
-
1042
- // 避免相互引用对象导致死循环,如initalObj.a = initalObj的情况
1043
- if (prop === obj) {
1044
- continue;
1045
- }
1046
-
1047
- if (typeof prop === 'object') {
1048
- if (obj[i]) {
1049
- this.extend(obj[i], prop)
1050
- } else {
1051
- obj[i] = prop;
1052
- }
1053
- }
1054
- }
1055
- return obj;
1056
- },
1057
- //获取当前时间
1058
- getNowFormatDate(){
1059
- var date = new Date();
1060
- var seperator1 = "-";
1061
- var seperator2 = ":";
1062
- var month = date.getMonth() + 1;
1063
- var strDate = date.getDate();
1064
- if (month >= 1 && month <= 9) {
1065
- month = "0" + month;
1066
- }
1067
- if (strDate >= 0 && strDate <= 9) {
1068
- strDate = "0" + strDate;
1069
- }
1070
- var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
1071
- + " " + date.getHours() + seperator2 + date.getMinutes()
1072
- + seperator2 + date.getSeconds();
1073
- return currentdate;
1074
- }
1075
- },
1076
- ready() {
1077
- this.putDevices()
1078
- if (this.item.f_state != '未检' || this.item.f_no_checkplan == '无计划安检') {
1079
- if (this.role != 'inspect') {
1080
- let that = this
1081
- let id
1082
- if (this.role == 'view') {
1083
- id = this.item.id
1084
- } else if (this.role == 'androidview') {
1085
- id = this.item.f_paper_id
1086
- }
1087
- this.$resetpost(`rs/path/getUserinfomation`, {data: {condition: `id = '${id}'`}}).then((respanse) => {
1088
- //tag
1089
- if (respanse.data.length != 0) {
1090
- // 包含 其它 特殊处理的数组
1091
- // 对应位置
1092
-
1093
- //tag
1094
-
1095
- that.data = Object.assign(that.data, respanse.data[0])
1096
- if (respanse.data[0].f_devices) {
1097
- for (let da in that.devices) {
1098
- that.$set('data.device' + that.devices[da].n, [])
1099
- }
1100
- respanse.data[0].f_devices.forEach((item) => {
1101
- for (let de in that.devices) {
1102
- if (that.devices[de].device == item.f_device_type) {
1103
- item.f_items.forEach((f_item) => {
1104
- //tag
1105
- //tag
1106
- let itemValues = []
1107
- f_item.f_item_lists.forEach((tempItem) => {
1108
- //tag
1109
- if (tempItem.f_item_value !== 'null') {
1110
- itemValues.push(tempItem.f_item_value)
1111
- }
1112
- })
1113
- f_item.f_item_value = itemValues
1114
- })
1115
- that.data['device' + that.devices[de].n].push({
1116
- f_device_type: item.f_device_type,
1117
- f_items: item.f_items
1118
- })
1119
- }
1120
- }
1121
- })
1122
- }
1123
- Util.replaceFalse(that.data)
1124
- Util.booleanFilter(that.data)
1125
- if (this.role == 'view') {
1126
- Util.ratifyPics(that.data)
1127
- Util.ratifyPics(that.picture)
1128
- } else {
1129
- Util.androidRatifyPics(that.data, this.$androidUtil.getProxyUrl())
1130
- }
1131
- //tag
1132
- }
1133
- // this.$goto('paper-message-blank', {userinfo:this.data,devices:this.devices,config:this.config,role:this.role}, 'self')
1134
- this.isshow = true
1135
- asyncReady(this).then(() => {
1136
- //tag
1137
- //tag)
1138
- if (this.data.f_check_type=='民用'){
1139
- this.deviceconfig=Vue.config.safecheck.DevicesConfig
1140
- //tag)
1141
- }else if (this.data.f_check_type=='非民用'){
1142
- this.deviceconfig=Vue.config.safecheck.DevicesSetConfig
1143
- //tag)
1144
- }
1145
- if (this.data.f_collection_type=='按气量'){
1146
- let aaa=Object.assign({},this.config["燃气表"])
1147
- this.deviceconfig["燃气表"]=aaa
1148
- //tag)
1149
- }else{
1150
- let aaa=Object.assign({},this.config2["燃气表"])
1151
- this.deviceconfig["燃气表"]=aaa
1152
- //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1153
- //tag)
1154
- }
1155
- this.deviceconfig2=ObjConfig.getObjConfig(this.deviceconfig)
1156
- this.deviceconfig2[0].items=jsonSort(this.deviceconfig2[0].items,"index")
1157
- this.deviceconfig2[1].items=jsonSort(this.deviceconfig2[1].items,"index")
1158
- this.deviceconfig2=jsonSort(this.deviceconfig2,"index")
1159
- this.getDeviceAll()
1160
-
1161
-
1162
- })
1163
- }
1164
- ).catch(
1165
- (respanse) => {
1166
- //tag
1167
- alert('查找安检单失败')
1168
- })
1169
- }
1170
- }
1171
-
1172
- },
1173
- watch:{
1174
- // 'isUpload'(val){
1175
- // //tag
1176
- // }
1177
- },
1178
- destroyed() {
1179
- //tag
1180
- this.disableTimer()
1181
- }
1182
- }
1183
-
1184
- </script>
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
+ div::-webkit-scrollbar {
22
+ width: 0 !important;
23
+ height: 0 !important;
24
+ }
25
+
26
+ div{
27
+ -ms-overflow-style: none;
28
+ overflow: -moz-scrollbars-none;
29
+ }
30
+ .divmask {
31
+ pointer-events: none;
32
+ }
33
+ .app-header {
34
+ border-radius: 50%;
35
+ background: rgba(73, 158, 223, 0.4);
36
+ color: #FFF;
37
+ padding: 20px;
38
+ text-align: center;
39
+ font-size: 1.2em;
40
+ z-index: 10;
41
+ opacity:0.5;
42
+ bottom: 50px;
43
+ margin-top: -20px;
44
+ position: absolute;
45
+ top: 10%;
46
+ right: 2%;
47
+ height: 8%;
48
+ }
49
+ </style>
50
+
51
+ <template>
52
+ <div class="basic-main" style="height: 100%">
53
+ <div class="page-header app-header auto" style="padding: 15px;margin-right: 10px;right: 0%;height: 7%">
54
+ <div @click="back()">
55
+ <img src="../../../assets/back.png" style="margin: 0px"/>
56
+ </div>
57
+ </div>
58
+ <work-busy :is-busy="loading"></work-busy>
59
+ <div class="container-fluid" style="overflow: scroll">
60
+ <div class="row">
61
+ <div class="col-md-6" style="margin-right: 2%;height: 100%;overflow: scroll">
62
+ <div style="width: 95%;margin-left: 5%" >
63
+ <table class="table table-striped table-bordered" v-for="config in deviceconfig2">
64
+ <thead v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
65
+ <tr>
66
+ <th style="text-align: center" >{{config.checkname}}</th>
67
+ </tr>
68
+ </thead>
69
+ <tbody v-show="!(config.checkname!='燃气表'&&paperdata.f_entry_status!='入户')">
70
+ <tr v-for="dev in config.items">
71
+ <td v-if="dev.type!='text'">
72
+ <div class="row">
73
+ <div class="col-md-8" style="text-align: center;">
74
+ <label ><button-link type="button" class="btn btn-link" @click="showpicture(config.checkname,dev.lname)" :style="isred(config.checkname,dev.lname)?'color:red':'color:black'">{{dev.lname}}
75
+ </button-link></label>
76
+ </div>
77
+ <div class="col-md-4" style="text-align: center" >
78
+ <label style="font-weight: normal" v-if="dev.type!='picture'">{{getDeviceValue(config.checkname,dev.lname)}}</label>
79
+ <label style="font-weight: normal" v-if="dev.type=='picture'"><div v-show="getDevicePath(config.checkname,dev.lname)"><button-link style="color: black" type="button" class="btn btn-link" @click="showpath(getDevicePath(config.checkname,dev.lname),dev.lname)">查看照片
80
+ </button-link></div></label>
81
+ </div>
82
+ </div>
83
+ </td>
84
+ <td v-if="dev.type==='text'">
85
+ <label style="width: 100%;text-align: center">{{dev.lname}}</label>
86
+ </td>
87
+ </tr>
88
+ </tbody>
89
+ </table>
90
+ </div>
91
+ </div>
92
+ <div class style="width: 1%;height: 100%;background-color: #F1F8FF;float: left;"></div>
93
+ <div class="col-md-5" style="margin-left: 2%;height: 100%;overflow: scroll">
94
+ <div style="width: 100%;margin: auto" >
95
+ <table class="table table-striped table-bordered" style="margin-bottom: 6px">
96
+ <thead>
97
+ <tr>
98
+ <th colspan="6" style="text-align: center" >用户基本信息</th>
99
+ </tr>
100
+ </thead>
101
+ <tbody>
102
+ <tr>
103
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户编号:</td>
104
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{paperdata.f_userinfo_code}}</td>
105
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">用户名称:</td>
106
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{paperdata.f_user_name}}</td>
107
+ </tr>
108
+ <tr>
109
+ <td style="text-align: center;border: #E9E9E9 solid 1px">证件号码:</td>
110
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_idnumber }}</td>
111
+ <td style="text-align: center;border: #E9E9E9 solid 1px">用户类型:</td>
112
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_check_type }}</td>
113
+ </tr>
114
+ <tr>
115
+ <td style="text-align: center;border: #E9E9E9 solid 1px">用户电话:</td>
116
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_user_phone }}</td>
117
+ <td style="text-align: center;border: #E9E9E9 solid 1px">区 / 县:</td>
118
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_area }}</td>
119
+ </tr>
120
+ <tr>
121
+ <td style="text-align: center;border: #E9E9E9 solid 1px">街 道:</td>
122
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_street }}</td>
123
+ <td style="text-align: center;border: #E9E9E9 solid 1px">楼 号:</td>
124
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_building }}</td>
125
+ </tr>
126
+ <tr>
127
+ <td style="text-align: center;border: #E9E9E9 solid 1px">单 元:</td>
128
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_unit }}</td>
129
+ <td style="text-align: center;border: #E9E9E9 solid 1px">楼 层:</td>
130
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_floor }}</td>
131
+ </tr>
132
+ <tr>
133
+ <td style="text-align: center;border: #E9E9E9 solid 1px">门 牌 号 :</td>
134
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_room }}</td>
135
+ <td style="text-align: center;border: #E9E9E9 solid 1px">用户性质:</td>
136
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_userproperties }}</td>
137
+ </tr>
138
+ <tr>
139
+ <td style="text-align: center;border: #E9E9E9 solid 1px">备注信息:</td>
140
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_comments }}</td>
141
+ <td style="text-align: center;border: #E9E9E9 solid 1px">小区名称:</td>
142
+ <td style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_residential_area }}</td>
143
+ </tr>
144
+ <tr>
145
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px">详细住址:</td>
146
+ <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px">{{ paperdata.f_address }}</td>
147
+ </tr>
148
+ </tbody>
149
+ </table>
150
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
151
+ <thead>
152
+ <tr> <th colspan="4" style="text-align: center">用户安检概况</th></tr>
153
+ </thead>
154
+ <tbody>
155
+ <tr>
156
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
157
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
158
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
159
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
160
+ </tr>
161
+ <tr>
162
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
163
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_entry_status }}</td>
164
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%" >燃气使用:</td>
165
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_usegas }}</td>
166
+ </tr>
167
+ <tr >
168
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">用户满意度:</td>
169
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{ paperdata.f_client_evaluation }}</td>
170
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">安检结果:</td>
171
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">{{ ajresult }}</td>
172
+ </tr>
173
+ <tr>
174
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">备注:</td>
175
+ <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
176
+ {{paperdata.f_repair_approved_note }}
177
+ </td>
178
+ </tr>
179
+ <tr>
180
+ <td colspan="1" style="text-align: center;border: #E9E9E9 solid 1px;">隐患详情:</td>
181
+ <td colspan="3" style="text-align: center;border: #E9E9E9 solid 1px;word-wrap:break-word;word-break:break-all;width:87%">
182
+ <span v-for="deviceCollect in deviceCollects">
183
+ <span class="li-font">
184
+ {{deviceCollect.name}}:{{deviceCollect.value}}&nbsp;&nbsp;&nbsp;
185
+ </span>
186
+ <br>
187
+ <span v-if="deviceCollect.value == '有隐患'">
188
+ <lable>
189
+ 隐患:
190
+ </lable>
191
+ <span class="li-font" v-for="val in deviceCollect.devices">
192
+ {{val}}&nbsp;&nbsp;&nbsp;
193
+ </span><br>
194
+ </span>
195
+
196
+ </span>
197
+ </td>
198
+ </tr>
199
+
200
+ </tbody>
201
+ </table>
202
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status!='入户'">
203
+ <thead>
204
+ <tr> <th colspan="4" style="text-align: center">用户安检概况</th></tr>
205
+ </thead>
206
+ <tbody>
207
+ <tr>
208
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">到达时间:</td>
209
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_onsite_time }}</td>
210
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">离开时间:</td>
211
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_offsite_time }}</td>
212
+ </tr>
213
+ <tr>
214
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%">入户状态:</td>
215
+ <td colspan="2" style="text-align: center;border: #E9E9E9 solid 1px;width: 33%">{{ paperdata.f_entry_status }}</td>
216
+ <td style="text-align: center;border: #E9E9E9 solid 1px;width: 17%" ><button-link style="color: black" type="button" class="btn btn-link" @click="showpicture2()">{{dev.lname}}
217
+ 查看{{data.f_entry_status}}照片</button-link></td>
218
+ </tr>
219
+
220
+ </tbody>
221
+ </table>
222
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
223
+ <thead>
224
+ <tr> <th style="text-align: center">总体安检照片</th></tr>
225
+ </thead>
226
+ <tbody> <tr>
227
+ <td style="margin: auto;text-align: center">
228
+ <div class="container" style="max-width: 550px;background: #FFFFFF">
229
+ <div class="img" v-for="img in paperdata.f_overall_imgs">
230
+ <img-self-safe :src="img.f_overall_path" style="float: left" width="150" height="200"></img-self-safe>
231
+ </div>
232
+ </div>
233
+
234
+
235
+ </td>
236
+
237
+ </tr></tbody>
238
+ </table>
239
+ <table class="table table-striped table-bordered" v-show="paperdata.f_entry_status=='入户'">
240
+ <thead>
241
+ <tr> <th style="text-align: center">用户签名照片</th></tr>
242
+ </thead>
243
+ <tbody> <tr>
244
+ <td style="margin: auto;text-align: center">
245
+ <div class="container" style="max-width: 500px;background: #FFFFFF">
246
+ <div class="img" style="float: none">
247
+ <img-self-safe :src="paperdata.f_sign_path" width="486" height="300"></img-self-safe>
248
+ </div>
249
+
250
+ </div>
251
+
252
+
253
+ </td>
254
+
255
+ </tr></tbody>
256
+ </table>
257
+ </div>
258
+ </div>
259
+ </div>
260
+ </div>
261
+ </div>
262
+ <modal :show.sync="imgshow" v-ref:modal backdrop="true">
263
+ <header slot="modal-header" class="modal-header">
264
+ {{picturename}}
265
+ </header>
266
+ <article slot="modal-body" class="modal-body">
267
+ <div class="from-group">
268
+ <div class="row">
269
+ <div class="col-md-6">
270
+ <img-self-safe v-if="showimg1" :src="showimg1" width="300" height="400"></img-self-safe>
271
+ </div><div class="col-md-6">
272
+ <img-self-safe v-if="showimg2" :src="showimg2" width="300" height="400"></img-self-safe>
273
+ </div>
274
+ </div>
275
+ </div>
276
+ </article>
277
+ <footer slot="modal-footer" class="modal-footer" v-show="false">
278
+ <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
279
+ </footer>
280
+ </modal>
281
+ <modal :show.sync="imgshow2" v-ref:modal backdrop="true">
282
+ <header slot="modal-header" class="modal-header">
283
+ {{paperdata.f_entry_status}}照片
284
+ </header>
285
+ <article slot="modal-body" class="modal-body">
286
+ <div class="from-group">
287
+ <div class="row">
288
+ <div class="col-md-6">
289
+ <img-self-safe v-if="this.paperdata.f_entry_status=='到访不遇'" :src="showimg3" width="300" height="400"></img-self-safe>
290
+ </div>
291
+ <div class="col-md-6">
292
+ <img-self-plus v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer1_path"
293
+ :src="showimg5" width="282"
294
+ height="400"></img-self-plus>
295
+ </div>
296
+ <div class="col-md-6">
297
+ <img-self-plus v-if="this.paperdata.f_entry_status=='到访不遇'&& this.paperdata.f_noanswer2_path"
298
+ :src="showimg6" width="282"
299
+ height="400"></img-self-plus>
300
+ </div>
301
+ <div class="col-md-6">
302
+ <img-self-safe v-if="this.paperdata.f_entry_status=='拒检'" :src="showimg4" width="300" height="400"></img-self-safe>
303
+ </div>
304
+ </div>
305
+ </div>
306
+ </article>
307
+ <footer slot="modal-footer" class="modal-footer" v-show="false">
308
+ <button type="button" class="btn btn-success" @click='imgclose'>关闭</button>
309
+ </footer>
310
+ </modal>
311
+ </template>
312
+
313
+ <script>
314
+ // import PaperUserm from './PaperUserm'
315
+ // import PaperStatem from './PaperStatem'
316
+ // import Devicesm from './Devicesm'
317
+ // import PaperFeedbackm from './PaperFeedbackm'
318
+ import ObjConfig from '../../../utils/GerJsonObjectConfig'
319
+ import RadioGroup from 'vue-client/src/vue-strap/src/radioGroup'
320
+ import Radio from 'vue-client/src/vue-strap/src/radioBtn'
321
+ import Vue from 'vue'
322
+ import * as Util from '../../Util'
323
+ import {jsonSort} from '../../../utils/LdapHelper'
324
+ import {HttpResetClass} from "vue-client";
325
+ let asyncReady = async function (self) {
326
+ // 获取配置信息
327
+ try {
328
+ let res= await new HttpResetClass().load('post','rs/sql/tel_singleTable_OrderBy',{data: {
329
+ items: 'f_dir',
330
+ tablename: 't_organization',
331
+ condition: `id = '${self.item.f_filialeid}'`,
332
+ orderitem: 'id'
333
+ }})/*.then(res=>{*/
334
+ //tag
335
+ //tag)
336
+ if (!res.data[0].f_dir){
337
+ this.$showMessage("该公司无组织目录,无法获取配置文件,请联系管理员确认")
338
+ }else{
339
+ //this.f_dir=res.data[0].f_dir
340
+ try {
341
+ let res1=await new HttpResetClass().load('GET',`/safecheck/rs/vue/DevicesConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {},{resolveMsg: '获取居民配置项成功!', rejectMsg: '获取居民配置项出错!'})/*.then(res=>{*/
342
+ //tag
343
+ //this.safeConfig["民用配置项"]=Object.assign({},res.data)
344
+ Vue.config.safecheck.DevicesConfig=res1.data
345
+ /*})*/
346
+ let res2=await new HttpResetClass().load('GET',`/safecheck/rs/vue/DevicesSetConfig.json?folderName=phonevues&orgDir=${res.data[0].f_dir}`, {},{resolveMsg: '获取非居民配置项成功!', rejectMsg: '获取非居民配置项出错!'})/*.then(res=>{*/
347
+ //tag
348
+ //this.safeConfig["非民用配置项"]=Object.assign({},res.data)
349
+ Vue.config.safecheck.DevicesSetConfig=res2.data
350
+ /*}).then(res=> {
351
+ })*/
352
+
353
+ }catch (e) {
354
+ this.$showMessage("获取配置文件失败"+e)
355
+ }
356
+ }
357
+ } catch (error) {
358
+ // 忽略704,文件找不到异常R
359
+ if (error.status !== 704) {
360
+ throw error
361
+ }
362
+ }
363
+ }
364
+ export default {
365
+ title: '安检单',
366
+ props: ['f_plan_id', 'item', 'role'],
367
+ data() {
368
+ return {
369
+ data: {
370
+ f_devices: [],
371
+ f_defect_content:''
372
+ },
373
+ paperdata:{},
374
+ picturename:'隐患照片',
375
+ defectDevice:{},
376
+ hasDevice:false,
377
+ deviceCollect:{},
378
+ deviceCollects:[],
379
+ isshow:false,
380
+ ajresult:'',
381
+ loading:true,
382
+ imgshow:false,
383
+ imgshow2:false,
384
+ isUpload:false,
385
+ livedispose:'',
386
+ showimg1:'',
387
+ showimg2:'',
388
+ showimg3:'',
389
+ showimg4:'',
390
+ showimg5: '',
391
+ showimg6: '',
392
+ startClick:false, //开始安检按钮是否可点击
393
+ isStrat: false, //是否开始安检
394
+ checkResult:{},//查询结果
395
+ newcheckResult:{},
396
+ timer: null,
397
+ showModal: false,
398
+ pic_to_be_viewed: '',
399
+ showBack:true,
400
+ devices: [],
401
+ devicesAll:[],
402
+ configAJ:[],
403
+ configRQ:[],
404
+ deviceconfig:{},
405
+ deviceconfig2:[],
406
+ f_devices : [],
407
+ config: {
408
+ "燃气表":{
409
+ "checkmust":true,
410
+ "index":1,
411
+ "items":{
412
+ //"燃气表照片":{"index":1,"type":"picture","remark":"(拍摄清晰的表具编号、字轮数、剩余气量等)"},
413
+ "基表编号":{"index":1,"type":"string","readonly":true},
414
+ "气表型号":{"index":2,"type":"string","readonly":true},
415
+ "气表品牌":{"index":3,"type":"string","readonly":true},
416
+ "进气方向":{"index":4,"type":"string","readonly":true},
417
+ // "初始表底":{"index":5,"type":"number","isshow":false,"readonly":true},
418
+ "上期表读数":{"index":5,"type":"number","readonly":true,isshow:false},
419
+ "累购气量":{"index":6,"type":"number","readonly":true},
420
+ "已用气量":{"index":7,"type":"number","checkmust": true},//基表数
421
+ "剩余气量":{"index":8,"type":"number","checkmust": true},//累购-已用
422
+ //显示屏数 --实际剩余气量
423
+ "气量异常差值":{"index":9,"type":"number","readonly": true}
424
+ }
425
+ // 注意,配置项的index必须与上面的固定配置保持'顺序'
426
+ }
427
+ },
428
+ //金额
429
+ config2: {
430
+ "燃气表":{
431
+ "checkmust":true,
432
+ "index":1,
433
+ "items":{
434
+ //"燃气表照片":{"index":1,"type":"picture","remark":"(拍摄清晰的表具编号、字轮数、剩余气量等)"},
435
+ "基表编号":{"index":1,"type":"string","readonly":true},
436
+ "气表型号":{"index":2,"type":"string","readonly":true},
437
+ "气表品牌":{"index":3,"type":"string","readonly":true},
438
+ "进气方向":{"index":4,"type":"string","readonly":true},
439
+ // "初始表底":{"index":5,"type":"number","isshow":false,"readonly":true},
440
+ "上期表读数":{"index":5,"type":"number","readonly":true,isshow:false},
441
+ "累购金额":{"index":6,"type":"number","readonly":true},
442
+ "已用金额":{"index":7,"type":"number","checkmust": true},
443
+ //显示屏数 --实际剩余气量
444
+ "剩余金额":{"index":8,"type":"number","checkmust": true},
445
+ "金额异常差值":{"index":9,"type":"number","readonly": true}
446
+ }
447
+ }
448
+ },
449
+ }
450
+ },
451
+ components: {
452
+ RadioGroup,
453
+ Radio,
454
+ },
455
+ computed: {
456
+
457
+ selector: {
458
+ get() {
459
+ return 'paper-state'
460
+ },
461
+ set(val) {
462
+ if(this.isStrat){
463
+ //;
464
+ this.$goto(val, {userinfo:this.data}, 'paper-router')
465
+ }else{
466
+ this.$showMessage('未开始安检!')
467
+ }
468
+ }
469
+ },
470
+ actionEnabled: {
471
+ get() {
472
+ return this.role == 'inspect'
473
+ }
474
+ }
475
+ },
476
+ methods: {
477
+ devicesCollect(){
478
+ // //tag
479
+ //tag
480
+ //tag)
481
+ //tag)
482
+ //tag
483
+
484
+ this.deviceCollects = []
485
+ let checkResult = '正常'
486
+ this.result = '正常'
487
+ let codata = JSON.parse(JSON.stringify(this.data))
488
+ //tag)
489
+ for(let device in this.data){
490
+ let f_device_type
491
+ if(device.startsWith("device")){
492
+ for(let item in this.data[device]) {
493
+ if(this.data[device].length > 1 ){
494
+ let j = Number.parseInt(item)+1
495
+ f_device_type = `${this.data[device][item].f_device_type}${j}`
496
+ }else{
497
+ f_device_type = this.data[device][item].f_device_type
498
+ }
499
+ // //tag
500
+ let deviceInfos = []
501
+ for(let i in this.data[device][item].f_items){
502
+ let defects = ''
503
+ let items = this.data[device][item].f_items[i]
504
+ if ((items.type === 'selector' || items.type === 'radio' || items.type === 'checkbox') && items.f_item_value != null && items.f_item_value instanceof Array){
505
+ for (let i in items.f_item_value) {
506
+ let f_item_value = items.f_item_value[i]
507
+
508
+ //tag)
509
+ //tag)
510
+ //tag)
511
+ //tag)
512
+ if (!this.config[this.data[device][item].f_device_type].items[items.f_item_name]){
513
+ continue
514
+ }
515
+ let options = this.config[this.data[device][item].f_device_type].items[items.f_item_name].options
516
+ for (let option in options) {
517
+ if (options[option].data == f_item_value) {
518
+ if (options[option].isdefect == 'true' || options[option].isdefect == true) {
519
+ checkResult = '有隐患'
520
+ this.result = '有隐患'
521
+ defects=`${defects}:${options[option].data}/`
522
+ // let level = options[option].level
523
+ }
524
+ }
525
+ }
526
+ //tag)
527
+ }
528
+ if(defects != ''){
529
+ deviceInfos.push(`${items.f_item_name}${defects.substring(0, defects.length - 1)}`)
530
+ }
531
+ }else if(items.type === 'stringp'){
532
+ checkResult = '有隐患'
533
+ this.result = '有隐患'
534
+ deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
535
+ }else if(items.f_item_name == '金额异常差值'){
536
+ var deviation = this.$appdata.getSingleValue('金额异常差值允许误差')
537
+ //tag
538
+ if(parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN"){
539
+ if(parseFloat(items.f_item_value[0])>parseFloat(deviation) || parseFloat(items.f_item_value[0])<parseFloat(deviation)*-1){
540
+ checkResult = '有隐患'
541
+ this.result = '有隐患'
542
+ deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
543
+ }
544
+ }
545
+ }else if(items.f_item_name == '气量异常差值'){
546
+ var deviation = this.$appdata.getSingleValue('气量异常差值允许误差')
547
+ //tag
548
+ if(parseFloat(items.f_item_value[0]).toString() != "NaN" && parseFloat(deviation).toString() != "NaN"){
549
+ if(parseFloat(items.f_item_value[0])>parseFloat(deviation) || parseFloat(items.f_item_value[0])<parseFloat(deviation)*-1){
550
+ checkResult = '有隐患'
551
+ this.result = '有隐患'
552
+ deviceInfos.push(`${items.f_item_name}:${items.f_item_value[0]}`)
553
+ }
554
+ }
555
+ }
556
+ //tag)
557
+ //tag
558
+ //tag
559
+ if (items.type === 'selector') {
560
+ items.selected = []
561
+ } else if (items.type === 'inputSelector') {
562
+ items.selected = ''
563
+ }
564
+ }
565
+
566
+
567
+ //tag
568
+ this.$set('deviceCollect.name',f_device_type)
569
+ this.$set('deviceCollect.value',checkResult)
570
+ this.$set('deviceCollect.devices',deviceInfos)
571
+ //tag)
572
+ if (this.deviceCollect.name){
573
+ //tag
574
+ this.deviceCollects.push(JSON.parse(JSON.stringify(this.deviceCollect)))
575
+ }
576
+
577
+ checkResult = '正常'
578
+ this.deviceCollect = {}
579
+ }
580
+ }
581
+ }
582
+ if(this.deviceCollects.length>0){
583
+ this.hasDevice = true
584
+ }
585
+ this.ajresult=JSON.parse(this.data.f_defect_content).result
586
+ this.showimg3=this.data.f_noanswer_path
587
+ this.showimg5 = this.data.f_noanswer1_path
588
+ this.showimg6 = this.data.f_noanswer2_path
589
+ this.showimg4=this.data.f_rejectcheck_path
590
+ this.paperdata=this.data
591
+ this.loading=false
592
+ },
593
+ imgclose(){
594
+ this.imgshow=false
595
+ },
596
+ putDevices() {
597
+ ////tag
598
+ this.$set('data.approve', "true")
599
+ this.$set('data.writeback', "false")
600
+ if (Vue.config.safecheck.ApproveConfig != undefined) {
601
+ if (Vue.config.safecheck.ApproveConfig.approve != undefined) {
602
+ this.$set('data.approve', Vue.config.safecheck.ApproveConfig.approve)
603
+ }
604
+ if (Vue.config.safecheck.ApproveConfig.writeback != undefined) {
605
+ this.$set('data.writeback', Vue.config.safecheck.ApproveConfig.writeback)
606
+ }
607
+ if (Vue.config.safecheck.ApproveConfig.livedispose != undefined) {
608
+ this.livedispose = Vue.config.safecheck.ApproveConfig.livedispose
609
+ }
610
+ }
611
+ //tag
612
+
613
+ //tag)
614
+ if(!this.item.f_safecheck_type){
615
+ this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType['年度普检'][this.item.f_check_type]])
616
+ }else{
617
+ if (Vue.config.safecheck.DevicesConfig != undefined)
618
+ this.config = this.extend(this.config, Vue.config.safecheck[Vue.config.safecheck.SafecheckType[this.item.f_safecheck_type][this.item.f_check_type]])
619
+ }
620
+ //遍历安检项配置
621
+ for (let i in this.config) {
622
+ //取得安检项索引值
623
+ let n = this.config[i].index
624
+ this.devices[n - 1] = {device: i, n: n, checkmust: this.config[i].checkmust}
625
+ this.$set('data.' + 'device' + n, [])
626
+ let items = []
627
+ for (let it in this.config[i].items) {
628
+ //赋值下拉选项
629
+ if (this.config[i].items[it].type == 'selector') {
630
+ for (let op in this.config[i].items[it].options)
631
+ if (this.config[i].items[it].options[op].isdefault == true) {
632
+ items.push({
633
+ f_defect_level: this.config[i].items[it].options[op].level,
634
+ f_is_defect: this.config[i].items[it].options[op].isdefect,
635
+ f_item_name: it,
636
+ f_item_value: this.config[i].items[it].options[op].data,
637
+ f_path: "",
638
+ type: "selector"
639
+ })
640
+ }
641
+ }
642
+ }
643
+ n = n + 1
644
+ }
645
+
646
+ },
647
+ showpath(val1,val2){
648
+ //tag
649
+ //tag
650
+ if (val1){
651
+ this.showimg1=val1
652
+ this.picturename=val2
653
+ this.imgshow=true
654
+ }
655
+ },
656
+ showpicture(val1,val2){
657
+ //tag
658
+ if (val2=='气量异常差值'||val2=='金额异常差值'){
659
+ return
660
+ }
661
+ for (let i = 0; i <this.devicesAll.length; i++) {
662
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
663
+ if (this.devicesAll[i][j].f_device_type==val1){
664
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
665
+ if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
666
+ if (!this.devicesAll[i][j].f_items[k].f_is_defect){
667
+ return false
668
+ }else{
669
+ this.showimg1=this.devicesAll[i][j].f_items[k].f_path
670
+ this.showimg2=this.devicesAll[i][j].f_items[k].f_second_path
671
+ this.picturename='隐患照片'
672
+ this.imgshow=true
673
+ return true
674
+ }
675
+ }
676
+ }
677
+
678
+ }
679
+ }
680
+ }
681
+ },
682
+ isred(val1,val2){
683
+ //tag
684
+ if (val2=='气量异常差值'||val2=='金额异常差值'){
685
+ return
686
+ }
687
+ for (let i = 0; i <this.devicesAll.length; i++) {
688
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
689
+ if (this.devicesAll[i][j].f_device_type==val1){
690
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
691
+ if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
692
+ if (!this.devicesAll[i][j].f_items[k].f_is_defect){
693
+ return false
694
+ }else{
695
+ return true
696
+ }
697
+ }
698
+ }
699
+
700
+ }
701
+ }
702
+ }
703
+ },
704
+ showpicture2(){
705
+ this.imgshow2=true
706
+ },
707
+ getDeviceValue(val1,val2){
708
+ if (val2=='是否有隐患'){
709
+ return this.ajresult=='正常'?'否':'是'
710
+ }
711
+ for (let i = 0; i <this.devicesAll.length; i++) {
712
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
713
+ if (this.devicesAll[i][j].f_device_type==val1){
714
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
715
+ if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
716
+ if(this.devicesAll[i][j].f_items[k].f_item_lists[0]){
717
+ return this.devicesAll[i][j].f_items[k].f_item_lists[0].f_item_value
718
+ }
719
+ }
720
+ }
721
+
722
+ }
723
+ }
724
+ }
725
+
726
+ },
727
+ getDevicePath(val1,val2){
728
+ for (let i = 0; i <this.devicesAll.length; i++) {
729
+ for (let j = 0; j < this.devicesAll[i].length; j++) {
730
+ if (this.devicesAll[i][j].f_device_type==val1){
731
+ for (let k = 0; k < this.devicesAll[i][j].f_items.length; k++) {
732
+ if (this.devicesAll[i][j].f_items[k].f_item_name==val2){
733
+ return this.devicesAll[i][j].f_items[k].f_path
734
+ }
735
+ }
736
+
737
+ }
738
+ }
739
+ }
740
+
741
+ },
742
+ getDeviceAll(){
743
+ let keyall= Object.keys(this.data)
744
+ for (let i = 0; i < keyall.length; i++) {
745
+ //tag)
746
+ if (keyall[i].startsWith('device') && keyall[i] !='deviceundefined'){
747
+ this.devicesAll.push(this.data[keyall[i]])
748
+ //tag
749
+ }
750
+ }
751
+ //tag
752
+ //tag)
753
+ this.devicesCollect()
754
+
755
+ },
756
+
757
+ back(){
758
+ if (this.role == 'inspect') {
759
+ if(!this.isStrat){
760
+ this.$back()
761
+ return
762
+ }else{
763
+ this.savePaper(true).then(()=>{
764
+ this.$back()
765
+ this.isStrat = false
766
+ })
767
+ }
768
+ }else{
769
+ this.$back()
770
+ }
771
+ },
772
+ checkIsStart(){
773
+ alert('asdad')
774
+ return
775
+ },
776
+
777
+ viewPic(fileName) {
778
+ //tag
779
+ if(this.role == 'view') {
780
+ if(!fileName.endsWith('nopic.png')) {
781
+ this.pic_to_be_viewed = fileName
782
+ this.showModal = true
783
+ }
784
+ } else {
785
+ HostApp.viewPic(fileName)
786
+ }
787
+ },
788
+ tick() {
789
+ this.timer = null
790
+ this.data.f_offsite_time = Util.toStandardTimeString()
791
+ this.timer = window.setTimeout(this.tick, 1000)
792
+ },
793
+ getRepairState() {
794
+ let repaired = true
795
+ this.data.f_defects.forEach((defect) => {
796
+ repaired = repaired & (defect.f_ratification == '已处理')
797
+ })
798
+ return repaired
799
+ },
800
+ verifyRepairDefects() {
801
+ this.data.f_repair_date = Util.toStandardTimeString()
802
+ this.data.f_repaired = this.getRepairState() ? '已修' : '在修'
803
+ },
804
+ genuineSave(saveOnly) {
805
+ HostApp.__this__.save(saveOnly)
806
+ if(!saveOnly)
807
+ HostApp.__this__.disableTimer()
808
+ HostApp.__callback__ = null
809
+ HostApp.__this__ = null
810
+ },
811
+ setUrgency() {
812
+ this.data.f_defect_urgency = 'Z'
813
+ let that = this
814
+ this.data.f_defects.forEach(function(defect) {
815
+ if(that.data.f_defect_urgency > defect.f_defect_level.charAt(0))
816
+ that.data.f_defect_urgency = defect.f_defect_level.charAt(0)
817
+ })
818
+ if(this.data.f_defect_urgency == 'Z')
819
+ this.data.f_defect_urgency = null
820
+ },
821
+ disableTimer() {
822
+ if(this.timer) {
823
+ window.clearTimeout(this.timer)
824
+ this.timer = null
825
+ }
826
+ },
827
+ loaded(paper) {
828
+ if(!paper.hasOwnProperty('id')) {
829
+ this.$showMessage("该安检单在手机上已经不存在,可能是卸载过程序。可以进入重新安检,或返回安检计划。")
830
+ this.init()
831
+ } else {
832
+ Util.booleanFilter(paper)
833
+ HostApp.__this__.$set('data', paper)
834
+ HostApp.__this__.$goto('paper-state', {}, 'paper-router')
835
+ // 如果打回重检则重新计时
836
+ //tag
837
+ if(HostApp.__this__.role == 'inspect'
838
+ && HostApp.__this__.data.f_approved
839
+ && HostApp.__this__.data.f_approved == '打回') {
840
+ //tag
841
+ HostApp.__this__.data.f_onsite_time = Util.toStandardTimeString()
842
+ HostApp.__this__.tick()
843
+ }
844
+ }
845
+ HostApp.__callback__ = null
846
+ HostApp.__this__ = null
847
+ },
848
+ S4() {
849
+ return (((1+Math.random())*0x10000)|0).toString(16).substring(1);
850
+ },
851
+ init () {
852
+ this.data.f_noplan_item_id = this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()+""+this.S4()
853
+ this.data.ename = Vue.user.ename
854
+ this.data.f_outlets = Vue.user.f_parentname
855
+ this.data.f_meetunit = Vue.user.orgpathnames
856
+ this.data.orgpathstr = Vue.user.orgpathstr
857
+ this.data.f_check_item_id = this.item.id
858
+ this.data.f_check_plan_id = this.f_plan_id
859
+ this.data.f_checker_id = Vue.user.id
860
+ this.data.f_checker_name = Vue.user.name
861
+ this.data.f_check_type = this.item.f_user_type
862
+ this.data.f_subcompany = this.item.f_subcompany
863
+ this.data.f_approved = this.item.f_approved
864
+ this.data.f_repair_approved = this.item.f_repair_approved
865
+ this.data.f_no_checkplan = this.item.f_no_checkplan
866
+ this.data.f_approved = this.item.f_approved
867
+ this.data.f_filialeid = this.item.f_filialeid
868
+ this.data.f_orgstr = this.item.f_orgstr
869
+ this.data.version = this.item.version
870
+ this.$set('data.f_meters', this.item.f_plan_meters)
871
+ this.$set('data.f_userinfo_code', this.item.f_userinfo_code)
872
+ // 安检状态
873
+ this.$set('data.f_entry_status', '入户')
874
+ this.$set('data.f_usegas', '已使用')
875
+ this.$set('data.f_state',this.item.f_state)
876
+ // 用户信息
877
+ this.$set('data.f_user_name', this.item.f_user_name)
878
+ this.$set('data.f_user_phone', this.item.f_user_phone)
879
+ this.$set('data.f_userinfoid', this.item.f_userinfoid)
880
+ this.$set('data.f_address', this.item.f_address)
881
+ this.$set('data.f_card_id', this.item.f_card_id)
882
+ this.$set('data.f_area', this.item.f_area)
883
+ this.$set('data.f_street', this.item.f_street)
884
+ this.$set('data.f_room',this.item.f_room)
885
+ this.$set('data.f_building', this.item.f_building)
886
+ this.$set('data.f_unit',this.item.f_unit)
887
+ this.$set('data.f_floor', this.item.f_floor)
888
+ this.$set('data.f_residential_area' , this.item.f_residential_area)
889
+ this.$set('data.f_idnumber', this.item.f_idnumber)
890
+ this.$set('data.f_comments', this.item.f_comments)
891
+ this.$set('data.f_userproperties', this.item.f_userproperties)
892
+ // 处置方式
893
+ this.$set('data.f_no_gas_device', false)
894
+ this.$set('data.f_close_valve', false)
895
+ this.$set('data.f_unload_battery', false)
896
+ if (this.data.f_check_item_id == '' && this.item.f_no_checkplan == '无计划安检') {
897
+ this.data.f_check_item_id = this.data.f_noplan_item_id
898
+ }
899
+
900
+ //房屋结构
901
+ // this.$set('data.f_room_style', '多层')
902
+ //供暖方式
903
+ // this.$set('data.f_heating_style', '热力公司集中供暖')
904
+ if(this.item.f_plan_meters) {
905
+ for (let de in this.devices) {
906
+ this.$set('data.device' + this.devices[de].n, [])
907
+ for (let i = 0; i < this.item.f_plan_meters.length; i++) {
908
+ if(this.item.f_plan_meters[i].f_meter_type) {
909
+ if (this.devices[de].device == "燃气表" && this.item.f_plan_meters[i].f_meter_type.indexOf('机表') > 0) {
910
+ delete this.config['燃气表']['items']['累计购气量']
911
+ this.data['device' + this.devices[de].n].push({
912
+ f_device_type: "燃气表",
913
+ f_items: [{
914
+ f_defect_level: null,
915
+ f_device_id: "",
916
+ f_is_defect: "",
917
+ f_item_name: "表品牌",
918
+ f_item_value: this.item.f_plan_meters[i].f_aliasname,
919
+ f_path: "",
920
+ type: "string"
921
+ },
922
+ {
923
+ f_defect_level: null,
924
+ f_device_id: "",
925
+ f_is_defect: "",
926
+ f_item_name: "位置",
927
+ f_item_value: this.item.f_plan_meters[i].f_weizhi,
928
+ f_path: "",
929
+ type: "selector"
930
+ },
931
+ {
932
+ f_defect_level: null,
933
+ f_device_id: "",
934
+ f_is_defect: "",
935
+ f_item_name: "表号",
936
+ f_item_value: this.item.f_plan_meters[i].f_meter_no,
937
+ f_path: "",
938
+ type: "number"
939
+ },
940
+ {
941
+ f_defect_level: null,
942
+ f_device_id: "",
943
+ f_is_defect: "",
944
+ f_item_name: "表封号",
945
+ f_item_value: this.item.f_plan_meters[i].f_metertitles,
946
+ f_path: "",
947
+ type: "number"
948
+ },
949
+ {
950
+ f_defect_level: null,
951
+ f_device_id: "",
952
+ f_is_defect: "",
953
+ f_item_name: "表型号",
954
+ f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
955
+ f_path: "",
956
+ type: "selector"
957
+ },
958
+ {
959
+ f_defect_level: null,
960
+ f_device_id: "",
961
+ f_is_defect: "",
962
+ f_item_name: "表底数",
963
+ f_item_value: this.item.f_plan_meters[i].f_prior_reading,
964
+ f_path: "",
965
+ type: "number"
966
+ }
967
+ ]
968
+ })
969
+ } else if (this.devices[de].device == "燃气表") {
970
+ delete this.config['燃气表']['items']['表底数']
971
+ this.data['device' + this.devices[de].n].push({
972
+ f_device_type: "燃气表",
973
+ f_items: [{
974
+ f_defect_level: null,
975
+ f_device_id: "",
976
+ f_is_defect: "",
977
+ f_item_name: "表品牌",
978
+ f_item_value: this.item.f_plan_meters[i].f_aliasname,
979
+ f_path: "",
980
+ type: "string"
981
+ },
982
+ {
983
+ f_defect_level: null,
984
+ f_device_id: "",
985
+ f_is_defect: "",
986
+ f_item_name: "位置",
987
+ f_item_value: this.item.f_plan_meters[i].f_weizhi,
988
+ f_path: "",
989
+ type: "selector"
990
+ },
991
+ {
992
+ f_defect_level: null,
993
+ f_device_id: "",
994
+ f_is_defect: "",
995
+ f_item_name: "表号",
996
+ f_item_value: this.item.f_plan_meters[i].f_meter_no,
997
+ f_path: "",
998
+ type: "number"
999
+ },
1000
+ {
1001
+ f_defect_level: null,
1002
+ f_device_id: "",
1003
+ f_is_defect: "",
1004
+ f_item_name: "表封号",
1005
+ f_item_value: this.item.f_plan_meters[i].f_metertitles,
1006
+ f_path: "",
1007
+ type: "number"
1008
+ },
1009
+ {
1010
+ f_defect_level: null,
1011
+ f_device_id: "",
1012
+ f_is_defect: "",
1013
+ f_item_name: "表型号",
1014
+ f_item_value: this.item.f_plan_meters[i].f_diaphgram_size,
1015
+ f_path: "",
1016
+ type: "selector"
1017
+ },
1018
+ {
1019
+ f_defect_level: null,
1020
+ f_device_id: "",
1021
+ f_is_defect: "",
1022
+ f_item_name: "累计购气量",
1023
+ f_item_value: this.item.f_plan_meters[i].f_prior_reading,
1024
+ f_path: "",
1025
+ type: "number"
1026
+ }
1027
+ ]
1028
+ })
1029
+ }
1030
+ }
1031
+ }
1032
+ }
1033
+ }
1034
+
1035
+ this.$goto('paper-state', {}, 'paper-router')
1036
+ },
1037
+ extend(initalObj, finalObj) {
1038
+ var obj = finalObj || {};
1039
+ for (var i in initalObj) {
1040
+ var prop = initalObj[i];
1041
+
1042
+ // 避免相互引用对象导致死循环,如initalObj.a = initalObj的情况
1043
+ if (prop === obj) {
1044
+ continue;
1045
+ }
1046
+
1047
+ if (typeof prop === 'object') {
1048
+ if (obj[i]) {
1049
+ this.extend(obj[i], prop)
1050
+ } else {
1051
+ obj[i] = prop;
1052
+ }
1053
+ }
1054
+ }
1055
+ return obj;
1056
+ },
1057
+ //获取当前时间
1058
+ getNowFormatDate(){
1059
+ var date = new Date();
1060
+ var seperator1 = "-";
1061
+ var seperator2 = ":";
1062
+ var month = date.getMonth() + 1;
1063
+ var strDate = date.getDate();
1064
+ if (month >= 1 && month <= 9) {
1065
+ month = "0" + month;
1066
+ }
1067
+ if (strDate >= 0 && strDate <= 9) {
1068
+ strDate = "0" + strDate;
1069
+ }
1070
+ var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
1071
+ + " " + date.getHours() + seperator2 + date.getMinutes()
1072
+ + seperator2 + date.getSeconds();
1073
+ return currentdate;
1074
+ }
1075
+ },
1076
+ ready() {
1077
+ this.putDevices()
1078
+ if (this.item.f_state != '未检' || this.item.f_no_checkplan == '无计划安检') {
1079
+ if (this.role != 'inspect') {
1080
+ let that = this
1081
+ let id
1082
+ if (this.role == 'view') {
1083
+ id = this.item.id
1084
+ } else if (this.role == 'androidview') {
1085
+ id = this.item.f_paper_id
1086
+ }
1087
+ this.$resetpost(`rs/path/getUserinfomation`, {data: {condition: `id = '${id}'`}}).then((respanse) => {
1088
+ //tag
1089
+ if (respanse.data.length != 0) {
1090
+ // 包含 其它 特殊处理的数组
1091
+ // 对应位置
1092
+
1093
+ //tag
1094
+
1095
+ that.data = Object.assign(that.data, respanse.data[0])
1096
+ if (respanse.data[0].f_devices) {
1097
+ for (let da in that.devices) {
1098
+ that.$set('data.device' + that.devices[da].n, [])
1099
+ }
1100
+ respanse.data[0].f_devices.forEach((item) => {
1101
+ for (let de in that.devices) {
1102
+ if (that.devices[de].device == item.f_device_type) {
1103
+ item.f_items.forEach((f_item) => {
1104
+ //tag
1105
+ //tag
1106
+ let itemValues = []
1107
+ f_item.f_item_lists.forEach((tempItem) => {
1108
+ //tag
1109
+ if (tempItem.f_item_value !== 'null') {
1110
+ itemValues.push(tempItem.f_item_value)
1111
+ }
1112
+ })
1113
+ f_item.f_item_value = itemValues
1114
+ })
1115
+ that.data['device' + that.devices[de].n].push({
1116
+ f_device_type: item.f_device_type,
1117
+ f_items: item.f_items
1118
+ })
1119
+ }
1120
+ }
1121
+ })
1122
+ }
1123
+ Util.replaceFalse(that.data)
1124
+ Util.booleanFilter(that.data)
1125
+ if (this.role == 'view') {
1126
+ Util.ratifyPics(that.data)
1127
+ Util.ratifyPics(that.picture)
1128
+ } else {
1129
+ Util.androidRatifyPics(that.data, this.$androidUtil.getProxyUrl())
1130
+ }
1131
+ //tag
1132
+ }
1133
+ // this.$goto('paper-message-blank', {userinfo:this.data,devices:this.devices,config:this.config,role:this.role}, 'self')
1134
+ this.isshow = true
1135
+ asyncReady(this).then(() => {
1136
+ //tag
1137
+ //tag)
1138
+ if (this.data.f_check_type=='民用'){
1139
+ this.deviceconfig=Vue.config.safecheck.DevicesConfig
1140
+ //tag)
1141
+ }else if (this.data.f_check_type=='非民用'){
1142
+ this.deviceconfig=Vue.config.safecheck.DevicesSetConfig
1143
+ //tag)
1144
+ }
1145
+ if (this.data.f_collection_type=='按气量'){
1146
+ let aaa=Object.assign({},this.config["燃气表"])
1147
+ this.deviceconfig["燃气表"]=aaa
1148
+ //tag)
1149
+ }else{
1150
+ let aaa=Object.assign({},this.config2["燃气表"])
1151
+ this.deviceconfig["燃气表"]=aaa
1152
+ //this.deviceconfig["燃气表"]=this.config2["燃气表"]
1153
+ //tag)
1154
+ }
1155
+ this.deviceconfig2=ObjConfig.getObjConfig(this.deviceconfig)
1156
+ this.deviceconfig2[0].items=jsonSort(this.deviceconfig2[0].items,"index")
1157
+ this.deviceconfig2[1].items=jsonSort(this.deviceconfig2[1].items,"index")
1158
+ this.deviceconfig2=jsonSort(this.deviceconfig2,"index")
1159
+ this.getDeviceAll()
1160
+
1161
+
1162
+ })
1163
+ }
1164
+ ).catch(
1165
+ (respanse) => {
1166
+ //tag
1167
+ alert('查找安检单失败')
1168
+ })
1169
+ }
1170
+ }
1171
+
1172
+ },
1173
+ watch:{
1174
+ // 'isUpload'(val){
1175
+ // //tag
1176
+ // }
1177
+ },
1178
+ destroyed() {
1179
+ //tag
1180
+ this.disableTimer()
1181
+ }
1182
+ }
1183
+
1184
+ </script>