safecheck-client 3.0.39-73 → 3.0.39-74

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 (40) hide show
  1. package/package.json +1 -1
  2. package/src/App.vue +31 -26
  3. package/src/components/android/rejectInspecCheck.vue +322 -322
  4. package/src/components/pc/RoleSelector.vue +172 -172
  5. package/src/components/rongcheng/AddPlanItem.vue +344 -344
  6. package/src/components/rongcheng/CheckCurrentCreate.vue +1081 -1081
  7. package/src/components/rongcheng/PaperDefectMain.vue +828 -828
  8. package/src/filiale/BFshiye/android/AndroidDefectDeal.vue +652 -652
  9. package/src/filiale/BFshiye/pc/DefectListNew.vue +637 -637
  10. package/src/filiale/BFshiye/pc/NewCheckpaper.vue +1962 -1962
  11. package/src/filiale/BFshiye/pc/checkUserList.vue +772 -772
  12. package/src/filiale/BFshiye/pc.js +17 -17
  13. package/src/filiale/baiyin/android/SafecheckUserInfo.vue +775 -775
  14. package/src/filiale/baiyin/android.js +12 -12
  15. package/src/filiale/dexin/pc/PaperList.vue +840 -840
  16. package/src/filiale/qingjian/android/PhoneUpUserinfo.vue +1357 -1357
  17. package/src/filiale/qingjian/android/SafecheckUserInfo.vue +823 -823
  18. package/src/filiale/qingjian/pc/NewCheckpaper.vue +1919 -1919
  19. package/src/filiale/rongchuang/android/PhoneUpUserinfo.vue +1262 -1262
  20. package/src/filiale/rongchuang/pc/checkPlanList.vue +398 -398
  21. package/src/filiale/rongchuang/pc.js +18 -18
  22. package/src/filiale/siyang/android/PhoneInsurancePurchaseDetail.vue +532 -532
  23. package/src/filiale/tongchuan/android/PhoneUpUserinfo.vue +1340 -1340
  24. package/src/filiale/wensu/android/SafecheckOrderV.vue +2444 -2444
  25. package/src/filiale/wensu/android/SafecheckUserInfo.vue +712 -712
  26. package/src/filiale/wensu/pc/CheckSearchUser.vue +1251 -1251
  27. package/src/filiale/yangchunboneng/android/CurrentCreate.vue +1191 -1191
  28. package/src/filiale/yangchunboneng/android/SafecheckUserInfo.vue +913 -913
  29. package/src/filiale/yangchunboneng/android.js +21 -21
  30. package/src/filiale/yangchunboneng/pc/CheckBookList.vue +353 -353
  31. package/src/filiale/yangchunboneng/pc/CheckSearchUser.vue +1197 -1197
  32. package/src/filiale/yangchunboneng/pc/HiddenSituation.vue +171 -171
  33. package/src/filiale/yangchunboneng/pc/PaperDefectMain.vue +1112 -1112
  34. package/src/filiale/yangchunboneng/pc/PaperList.vue +757 -757
  35. package/src/filiale/yangchunboneng/pc/SelectCheckPlan.vue +331 -331
  36. package/src/filiale/yangchunboneng/pc.js +29 -29
  37. package/src/main.js +1 -1
  38. package/src/rongcheng.js +319 -319
  39. package/src/safecheck-android.js +316 -316
  40. package/yarn-error.log +0 -140
@@ -1,1357 +1,1357 @@
1
- <template>
2
- <work-busy :is-busy="excessive"></work-busy>
3
- <div style="height: 100%">
4
- <div class="panel auto">
5
- <div class="panel-heading" @click="selectVal('基本信息')" style="background-color: #ffffff">
6
- <span class="spanboder">
7
- <img src="../../../assets/person.png" style="width: 22px;margin-right: 8px;">基本信息
8
- <img class="butt3" :src="imgback('基本信息')">
9
- </span>
10
- </div>
11
- <div class="panel-body " id="upuserinfo_sel" v-show="headername=='基本信息'">
12
- <div class="row auto" style="margin: 5px 0">
13
- <label class="righttxt">用户编号:</label>
14
- <input type="text" class="form-control rightipt" v-model="userinfo.baseinfo.base.f_userinfo_code" readonly/>
15
- </div>
16
- <div class="row auto" style="margin: 5px 0">
17
- <label class="righttxt">用户名称:</label><input type="text" class="form-control rightipt"
18
- v-model="userinfo.baseinfo.base.f_user_name" readonly/>
19
- </div>
20
- <div class="row auto" style="margin: 5px 0">
21
- <label class="righttxt">用户状态:</label><input type="text" class="form-control rightipt" readonly
22
- v-model="userinfo.baseinfo.base.f_user_state"/>
23
- </div>
24
- <div class="row auto" style="margin: 5px 0">
25
- <label class="righttxt">用户电话:</label><input type="text" class="form-control rightipt"
26
- v-model="userinfo.baseinfo.base.f_user_phone"/>
27
- </div>
28
- <div class="row auto" style="margin: 5px 0">
29
- <label class="righttxt">租户姓名:</label><input type="text" class="form-control rightipt"
30
- v-model="userinfo.baseinfo.base.f_rent_name"/>
31
- </div>
32
- <div class="row auto" style="margin: 5px 0">
33
- <label class="righttxt">租户电话:</label><input type="text" class="form-control rightipt"
34
- v-model="userinfo.baseinfo.base.f_zuhu_phone"/>
35
- </div>
36
- <div class="row auto" style="margin: 5px 0">
37
- <label class="righttxt">建档日期:</label><input type="text" class="form-control rightipt"
38
- v-model="userinfo.baseinfo.base.f_createfile_date" readonly/>
39
- </div>
40
- <!-- <div class="row auto" style="margin: 5px 0">
41
- <label class="righttxt">开户日期:</label><input type="text" class="form-control rightipt" v-model="userinfo.baseinfo.base.f_open_date" readonly />
42
- </div>-->
43
- <div class="row auto" style="margin: 5px 0">
44
- <label class="righttxt">地址类型:</label>
45
- <div class="rightipt" style="display: flex;justify-content: space-around;margin-top: 5px">
46
- <div><input type="radio" v-model="addressType" name="addressType" @change="changeAddressType"
47
- id="phone_addressType1" value="普通地址"/><label style="font-weight: normal;padding-left: 2px"
48
- for="phone_addressType1">普通地址</label></div>
49
- <div><input type="radio" v-model="addressType" name="addressType" @change="changeAddressType"
50
- id="phone_addressType2" value="特殊地址"/><label style="font-weight: normal;padding-left: 2px"
51
- for="phone_addressType2">特殊地址</label></div>
52
- </div>
53
-
54
- </div>
55
- <div class="row auto" style="margin: 5px 0">
56
- <label class="righttxt">经度:</label>
57
- <input readonly type="text" class="form-control rightipt" v-model="userinfo.addressinfo.f_lng"/>
58
- </div>
59
- <div class="row auto" style="margin: 5px 0">
60
- <label class="righttxt">纬度:</label>
61
- <input readonly type="text" class="form-control rightipt" v-model="userinfo.addressinfo.f_lat"/>
62
- <div style="margin-left: 10px;" @click="getLocation">
63
- <img src="../../../assets/定位.png" alt="定位" style="width: 24px; height: 24px; cursor: pointer;" />
64
- </div>
65
- </div>
66
- <div class="row auto" style="margin: 5px 0">
67
- <label class="righttxt">地区类型:</label>
68
- <!--<input type="text" style="width: 75%;float:right" class="form-control" v-model="row.f_devices_type" />-->
69
- <input type="text" class="form-control rightipt" readonly v-model="userinfo.addressinfo.f_iscity"/>
70
- <!--<v-select :value.sync="userinfo.addressinfo.f_iscity" class="input-font" style="margin-left: 5%;"
71
- :width="'60%'"
72
- :disabled="true"
73
- v-model="userinfo.addressinfo.f_iscity"
74
- :options='cityTypes' placeholder='地区类型' close-on-select clear-button value-single ></v-select>-->
75
- </div>
76
- <div class="row auto" style="margin: 5px 0">
77
- <label class="righttxt">省&ensp;市&ensp;区:</label>
78
- <!--<input type="text" style="width: 75%;float:right" class="form-control" v-model="row.f_devices_type" />-->
79
- <!--<input type="text" class="form-control rightipt" readonly v-model="userinfo.addressinfo.f_pcd" />-->
80
- <v-select :value.sync="selectPcd" class="input-font" style="margin-left: 5%;"
81
- :width="'60%'"
82
- v-model="selectPcd"
83
- :options='pcds' placeholder='请选择省市区' close-on-select clear-button value-single
84
- @change="pcd_change()"></v-select>
85
- </div>
86
- <div class="row auto" style="margin: 5px 0">
87
- <label class="righttxt">街道名称:</label>
88
- <!--<input type="text" readonly class="form-control rightipt" v-model="userinfo.addressinfo.f_street" />-->
89
- <v-select :value.sync="selectStreet" class="input-font" style="margin-left: 5%;"
90
- :width="'60%'"
91
- v-model="selectStreet"
92
- :options='streets' placeholder='请选择街道' close-on-select clear-button value-single
93
- @change="street_change()"></v-select>
94
- </div>
95
- <div class="row auto" style="margin: 5px 0">
96
- <label class="righttxt">集收单位:</label>
97
- <!--<input type="text" readonly class="form-control rightipt" v-model="userinfo.addressinfo.f_residential_area" />-->
98
- <v-select :value.sync="selectArea" class="input-font" style="margin-left: 5%;"
99
- :width="'60%'"
100
- v-model="selectArea"
101
- :timeout="500"
102
- @select-search="select_search"
103
- :options='area' placeholder='请选择集收单位' close-on-select clear-button value-single
104
- @change="area_change()"></v-select>
105
- </div>
106
- <!--<div class="row auto" style="margin: 5px 0" v-show="addressType=='特殊地址'">
107
- <label class="righttxt">集收单位:</label>
108
- &lt;!&ndash;<input type="text" readonly class="form-control rightipt" v-model="userinfo.addressinfo.f_residential_area" />&ndash;&gt;
109
- <v-select :value.sync="selectArea" class="input-font" style="margin-left: 5%;"
110
- :width="'60%'"
111
- v-model="selectArea"
112
- @select-search="select_search"
113
- :options='area' placeholder='请选择集收单位' close-on-select clear-button value-single @change="area_changeTC()"></v-select>
114
- </div>-->
115
- <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
116
- <label class="righttxt">楼&ensp;&ensp;&ensp;&ensp;号:</label><input type="text" @change="changeNewAddress"
117
- class="form-control rightipt"
118
- v-model="userinfo.addressinfo.f_building"/>
119
- </div>
120
- <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
121
- <label class="righttxt">单&ensp;&ensp;&ensp;&ensp;元:</label><input type="text" @change="changeNewAddress"
122
- class="form-control rightipt"
123
- v-model="userinfo.addressinfo.f_unit"/>
124
- </div>
125
- <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
126
- <label class="righttxt">楼&ensp;&ensp;&ensp;&ensp;层:</label><input type="text" @change="changeNewAddress"
127
- class="form-control rightipt"
128
- v-model="userinfo.addressinfo.f_floor"/>
129
- </div>
130
- <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
131
- <label class="righttxt">门&ensp;牌&ensp;号:</label><input type="text" @change="changeNewAddress"
132
- class="form-control rightipt"
133
- v-model="userinfo.addressinfo.f_room"/>
134
- </div>
135
- <div class="row auto" style="margin: 5px 0">
136
- <label class="righttxt">详细地址:</label><input type="text" class="form-control rightipt" readonly
137
- v-model="userinfo_old.addressinfo.f_address"/>
138
- </div>
139
- <div class="row auto" style="margin: 5px 0">
140
- <label class="righttxt">新&ensp;地&ensp;址:</label>
141
- <!--<input type="text" class="form-control rightipt" readonly v-model="getaddress()" />-->
142
- <textarea :readonly="addressType=='普通地址'" class="form-control rightipt" : style="height: 80px"
143
- v-model="userinfo.addressinfo.f_address"></textarea>
144
- </div>
145
-
146
- <!--<div class="row auto" style="margin: 5px 0" v-show="addressType=='特殊地址'">
147
- <label class="righttxt">新&ensp;地&ensp;址:</label>&lt;!&ndash;<input type="text" class="form-control rightipt" v-model="userinfo.addressinfo.f_address" />&ndash;&gt;
148
- <textarea class="form-control rightipt" style="height: 80px" v-model="getAddressTS"></textarea>
149
- </div>-->
150
-
151
- <div class="row auto" style="margin: 5px 0">
152
- <label class="righttxt">备&ensp;&ensp;&ensp;&ensp;注:</label><textarea class="form-control rightipt"
153
- style="height: 150px"
154
- v-model="userinfo.addressinfo.f_comments"></textarea>
155
- <!--<input type="text" class="form-control rightipt" v-model="userinfo.baseinfo.base.f_remark" />-->
156
- </div>
157
- </div>
158
- </div>
159
- <div class="panel auto">
160
- <div class="panel-heading" @click="selectVal('表具信息')" style="background-color: #ffffff">
161
- <span class="spanboder">
162
- <img src="../../../assets/person.png" style="width: 22px;margin-right: 8px;">表具信息
163
- <img class="butt3" :src="imgback('表具信息')">
164
- </span>
165
- </div>
166
- <div class="panel-body " v-show="headername=='表具信息'">
167
- <div class="row auto" style="margin: 5px 0">
168
- <label class="righttxt">表&ensp;&ensp;&ensp;&ensp;号:</label>
169
- <input type="text"
170
- :readonly="(userinfo.meterinfo[0].f_meter_classify!='机表' && userinfo.meterinfo[0].f_meter_classify!='金额卡表'&&userinfo.meterinfo[0].f_meter_classify!='气量卡表')"
171
- class="form-control rightipt"
172
- style="width: 45%" v-model="userinfo.meterinfo[0].f_meternumber"/>
173
- <button type="button"
174
- :disabled="!(userinfo.meterinfo[0].f_meter_classify=='机表' || userinfo.meterinfo[0].f_meter_classify=='金额卡表' || userinfo.meterinfo[0].f_meter_classify=='气量卡表')"
175
- name="button" class="btn btn-primary" style="width: 15%" @click="scan">扫码
176
- </button>
177
- </div>
178
-
179
- <!--<div class="row auto" style="margin: 5px 0" v-if="userinfo.meterinfo[0].f_meter_classify=='机表'">
180
- <div class="auto">
181
- <div class="panel" style="padding: 0px 15px 5px 10px;">
182
- <div class="panel-body panel-self" style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
183
- <div class="row" style="height: 240px;">
184
- <div class="col-sm-4">
185
- <img-self :src="f_meterno_path" alt="表号照片" width="150" height="200"></img-self>
186
- </div>
187
- </div>
188
- <div class="row text-right div-photo" :class="style__">
189
- <button type="button" name="button" class="btn btn-primary btn-photo" @click="takePic('f_meterno_path', '表号照片')">拍照</button>
190
- <img src="../../../assets/remove.png" :class="style__" @click="delfile('f_meterno_path', this.f_meterno_path)" style="width: 25%;"></img>
191
- </div>
192
- </div>
193
- </div>
194
- </div>
195
- </div>-->
196
- <div class="row auto" style="margin: 5px 0">
197
- <label class="righttxt">通&ensp;气&ensp;人:</label>
198
- <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_gas_person"/>
199
- </div>
200
- <div class="row auto" style="margin: 5px 0">
201
- <label class="righttxt">通气时间:</label>
202
- <datepicker class="rightipt"
203
- :value.sync="userinfo.meterinfo[0].f_gas_date"
204
- v-model="userinfo.meterinfo[0].f_gas_date"
205
- :disabled-days-of-Week="[]"
206
- :format="'yyyy-MM-dd'"
207
- :show-reset-button="reset">
208
- </datepicker>
209
- </div>
210
- <div class="row auto" style="margin: 5px 0" v-show="showBox">
211
- <label class="righttxt">调&ensp;压&ensp;箱:</label>
212
- <v-select class="rightipt"
213
- :value.sync="userinfo.meterinfo[0].f_adjustable_id"
214
- v-model="userinfo.meterinfo[0].f_adjustable_id"
215
- placeholder='请选择'
216
- :width='wid'
217
- readonly
218
- :options="boxOptions"
219
- close-on-select value-single></v-select>
220
- </div>
221
- <div class="row auto" style="margin: 5px 0">
222
- <label class="righttxt">是否直通:</label>
223
- <v-select
224
- :value.sync="userinfo.meterinfo[0].f_if_direct"
225
- class="input-font"
226
- style="margin-left: 5%;"
227
- :width="'60%'"
228
- v-model="userinfo.meterinfo[0].f_if_direct"
229
- :options='directOptions'
230
- placeholder='是否直通'
231
- close-on-select
232
- clear-button
233
- value-single>
234
- </v-select>
235
- </div>
236
- <div class="row auto" style="margin: 5px 0">
237
- <label class="righttxt">表&ensp;封&ensp;号:</label>
238
- <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_metertitles"/>
239
- </div>
240
- <div class="row auto" style="margin: 5px 0">
241
- <label class="righttxt">表&ensp;位&ensp;置:</label>
242
- <!--<input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_position" readonly/>-->
243
- <v-select class="rightipt" :value.sync="userinfo.meterinfo[0].f_position"
244
- v-model="userinfo.meterinfo[0].f_position"
245
- placeholder='请选择'
246
- :width='wid'
247
- readonly
248
- :options="wz_types"
249
- close-on-select value-single></v-select>
250
- </div>
251
- <div class="row auto" style="margin: 5px 0">
252
- <label class="righttxt">表&ensp;&ensp;&ensp;&ensp;向:</label>
253
- <!--<input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_position" readonly/>-->
254
- <v-select class="rightipt" :value.sync="userinfo.meterinfo[0].f_aroundmeter"
255
- v-model="userinfo.meterinfo[0].f_aroundmeter"
256
- placeholder='请选择'
257
- :width='wid'
258
- readonly
259
- :options="aroundmeters"
260
- close-on-select value-single></v-select>
261
- </div>
262
- <div class="row auto" style="margin: 5px 0">
263
- <label class="righttxt">气表类型:</label>
264
- <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_meter_classify" readonly/>
265
- </div>
266
- <div class="row auto" style="margin: 5px 0">
267
- <label class="righttxt">现场表具型号:</label>
268
- <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_xc_meter_style"/>
269
- </div>
270
- <div class="row auto" style="margin: 5px 0">
271
- <label class="righttxt">表前阀状态:</label>
272
- <!--<input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_position" readonly/>-->
273
- <v-select class="rightipt" :value.sync="userinfo.meterinfo[0].f_bqf_state"
274
- v-model="userinfo.meterinfo[0].f_bqf_state"
275
- placeholder='请选择'
276
- :width='wid'
277
- readonly
278
- :options="bqf_states"
279
- close-on-select value-single></v-select>
280
- </div>
281
- <!-- <div class="row auto" style="margin: 5px 0">
282
- <div style="display: flex;justify-content: center;">
283
- <button v-if="userinfo.meterinfo[0].f_meter_classify=='机表'" class="col-sm-3 btn btn-primary" @click="upUserState()">机表关阀停用</button>
284
- </div>
285
- </div>-->
286
- </div>
287
- </div>
288
- <div class="panel auto">
289
- <div class="panel-heading" @click="selectVal('设备信息')" style="background-color: #ffffff">
290
-
291
- <span class="spanboder"><img src="../../../assets/list.png" style="width: 22px;margin-right: 8px;">设备信息<img
292
- class="butt3" :src="imgback('设备信息')"></span>
293
- </div>
294
- <div class="panel-body" v-show="headername=='设备信息'">
295
- <div class="row" v-for="row in model"
296
- style="border:2px solid #A2C2EB; border-top:10px solid #A2C2EB; box-shadow: #00b3ee;margin-bottom: 10px">
297
- <div class="row auto" style="margin: 5px 0">
298
- <label class="righttxt">设备类型:</label>
299
- <!--<input type="text" class="form-control rightipt" readonly v-model="row.f_devices_type" />-->
300
- <v-select class="rightipt" :value.sync="row.f_devices_type"
301
- v-model="row.f_devices_type"
302
- placeholder='请选择'
303
- :width='wid'
304
- readonly
305
- :options="devices_types"
306
- close-on-select value-single></v-select>
307
- </div>
308
- <div class="row auto" style="margin: 5px 0">
309
- <label class="righttxt">设备品牌:</label>
310
- <!-- <v-select class="rightipt" :value.sync="row.f_brand"
311
- v-model="row.f_brand"
312
- placeholder='请选择'
313
- :width='wid'
314
- readonly
315
- :options="deviceBrandOption[row.f_devices_type]"
316
- close-on-select value-single></v-select>-->
317
- <input type="text" class="form-control rightipt"
318
- v-model="row.f_brand"/>
319
- </div>
320
- <div class="row auto" style="margin: 5px 0">
321
- <label class="righttxt">设备型号:</label><input type="text" class="form-control rightipt"
322
- v-model="row.f_devices_model"/>
323
- </div>
324
- <div class="row auto" style="margin: 5px 0">
325
- <label class="righttxt">生产日期:</label>
326
- <!--<input type="text" class="form-control rightipt" v-model="row.f_make_date" />-->
327
- <datepicker class="rightipt"
328
- :value.sync="row.f_make_date"
329
- v-model="row.f_make_date"
330
- :disabled-days-of-Week="[]"
331
- :format="'yyyy-MM-dd'"
332
- :show-reset-button="reset" readonly="readonly">
333
- </datepicker>
334
- </div>
335
- <div class="row auto" style="margin: 5px 0">
336
- <label class="righttxt">使用年限:</label><input type="number" class="form-control rightipt"
337
- v-model="row.f_service_life"/>
338
- </div>
339
- <!-- <div class="row auto" style="margin: 5px 0">
340
- <label class="righttxt">到期日期:</label>
341
- &lt;!&ndash;<input type="text" class="form-control rightipt" v-model="row.f_expire_date" />&ndash;&gt;
342
- <datepicker class="rightipt"
343
- :value.sync="row.f_expire_date"
344
- v-model="row.f_expire_date"
345
- :disabled-days-of-Week="[]"
346
- :format="'yyyy-MM-dd'"
347
- :show-reset-button="reset" readonly="readonly">
348
- </datepicker>
349
- </div>-->
350
- <div class="row auto" style="margin: 5px 0">
351
- <label class="righttxt">安&ensp;装&ensp;人:</label><input type="text" class="form-control rightipt"
352
- v-model="row.f_input_person"/>
353
- </div>
354
- <div class="row auto" style="margin: 5px 0">
355
- <label class="righttxt">安装日期:</label>
356
- <!--<input type="text" class="form-control rightipt" v-model="row.f_input_date" />-->
357
- <datepicker class="rightipt"
358
- :value.sync="row.f_input_date"
359
- v-model="row.f_input_date"
360
- :disabled-days-of-Week="[]"
361
- :format="'yyyy-MM-dd'"
362
- :show-reset-button="reset" readonly="readonly">
363
- </datepicker>
364
- </div>
365
- <div class="row auto" style="margin: 5px 0">
366
- <label class="righttxt">设备数量:</label><input type="number" class="form-control rightipt"
367
- v-model="row.f_devices_num"/>
368
- </div>
369
- <div class="row auto" style="margin: 5px 0">
370
- <label class="righttxt">管道类型:</label><input type="text" class="form-control rightipt" v-model="row.f_pipe_type" />
371
- </div>
372
- <!--<div class="row auto" style="margin: 5px 0">
373
- <label class="righttxt">设备状态:</label><input type="text" class="form-control rightipt" readonly v-model="row.f_userinfodevices_state" />
374
- </div>-->
375
- <!--<div class="row auto" style="margin: 5px 0">
376
- <label class="righttxt">购买方式:</label><input type="text" class="form-control rightipt" readonly v-model="row.watchpurchase" />
377
- </div>-->
378
- <div style="display: flex;justify-content: center;margin-bottom: 3px"
379
- v-if="$index>this.userinfo_old.devicesinfo.length-1 || this.userinfo_old.devicesinfo.length==0">
380
- <button class="btn btn-warning" @click="delDevices($index)">删除设备</button>
381
- </div>
382
- </div>
383
- <div style="display: flex;justify-content: space-around;">
384
- <button class="col-sm-3 btn btn-primary" @click="addDevices($index)">新增设备</button>
385
- </div>
386
- </div>
387
- </div>
388
- <div class="panel auto">
389
- <div class="panel-body">
390
- <div style="display: flex;justify-content: center;">
391
- <button class="col-sm-3 btn btn-primary" :disabled="enable"
392
- @click="isNeedAudit ? editUserInfo() : editUserInfoNoAudit()">{{ isNeedAudit ? '上传审核' : '上传' }}
393
- </button>
394
- </div>
395
- </div>
396
- </div>
397
- </div>
398
- </template>
399
-
400
- <script>
401
- import {HttpResetClass} from 'vue-client'
402
- import * as Util from "../../../components/Util";
403
- import Vue from 'vue'
404
-
405
- export default {
406
- title: '设备查看',
407
- data() {
408
- return {
409
- model: [],
410
- show: false,
411
- row: Object,
412
- userinfo: Object,
413
- userinfo_old: Object,
414
- wid: "60%",
415
- aroundmeters: [],
416
- devices_types: [],
417
- pipe_types: [{label: '橡胶管', value: '橡胶管'}, {label: '波纹管', value: '波纹管'}, {label: '钢管', value: '钢管'}],
418
- wz_types: [],
419
- cityTypes: [{label: '市区', value: '市区'}, {label: '城镇', value: '城镇'}],
420
- bqf_states: [{label: '开阀', value: '开阀'}, {label: '关阀', value: '关阀'}],
421
- pcds: [],
422
- streets: [],
423
- update: false,
424
- headername: '基本信息',
425
- excessive: false,
426
- area: [],
427
- enable: false,
428
- f_meterno_path: Vue.nopic,
429
- selectArea: {id: ''},
430
- selectPcd: {id: ''},
431
- selectStreet: {id: ''},
432
- changemeterno: false,//是否修改了机表表号
433
- approveChange: false,//是否需要进行信息变更审核
434
- newAddress: '',
435
- addressType: '',
436
- //需要审核的字段
437
- checkField: {
438
- checkUserinfoField: [
439
- 'f_user_name'
440
- ],
441
- checkUserFilesField: [
442
- 'f_meternumber'
443
- ],
444
- checkAddressField: [
445
- 'f_pcd_id',
446
- 'f_street_id',
447
- 'f_residential_area_id',
448
- 'f_building',
449
- 'f_unit',
450
- 'f_floor',
451
- 'f_room',
452
- 'f_slice_area',
453
- 'f_special',
454
- 'f_address'
455
- ],
456
- },
457
- boxOptions: [],
458
- showBox: false,
459
- directOptions: [{label: '是', value: '是'}, {label: '否', value: '否'}],
460
- deviceBrandOption: {},
461
- isNeedAudit: this.$appdata.getSingleValue('信息变更是否需要审核') == 'false' ? false : true,
462
- detailedAddress:'',
463
- administrativeDivision:''
464
-
465
- }
466
- },
467
- props: {
468
- user: {
469
- type: Object
470
- },
471
- f_userinfo_id: '',
472
- f_source: ''
473
- },
474
- methods: {
475
- getLocation(){
476
- const location = HostApp.getDetailAddress()
477
- const longitude = HostApp.getPreference('longitude')
478
- const latitude = HostApp.getPreference('latitude')
479
-
480
- new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
481
- data: {
482
- items: "*",
483
- tablename: "t_user_address",
484
- orderitem: "id",
485
- condition: `f_lng='${longitude.data}' and f_lat='${latitude.data}' `
486
- }
487
- }, {resolveMsg: null, rejectMsg: null}).then((res) => {
488
- //tag)
489
- if (res.data.length > 0) {
490
- this.$showMessage('存在相同的经纬度,请重新定位!', ['confirm', 'cancel'])
491
- }else{
492
- this.userinfo.addressinfo.f_lng=longitude.data
493
- this.userinfo.addressinfo.f_lat=latitude.data
494
- this.userinfo.addressinfo.f_address=location.data
495
- const parsed = this.parseAddress(location.data);
496
- console.log('行政区划部分:', parsed.administrativeDivision);
497
- this.selectPcd.f_pcd=parsed.administrativeDivision
498
- this.selectPcd.id=1
499
- console.log('详细地址部分:', parsed.detailedAddress)
500
- this.detailedAddress=parsed.detailedAddress
501
- }
502
- })
503
- },
504
- parseAddress(address) {
505
- // 匹配省市区县的正则表达式
506
- const regex = /^(.*?(?:省|自治区|直辖市)?(?:[A-Za-z\u4e00-\u9fa5]*?(?:市))?(?:[A-Za-z\u4e00-\u9fa5]*?(?:区|县|市))?)((?:[A-Za-z\u4e00-\u9fa5\d]|.)*)$/;
507
-
508
- const match = address.match(regex);
509
- if (match) {
510
- return {
511
- administrativeDivision: match[1].trim(),
512
- detailedAddress: match[2].trim()
513
- };
514
- } else {
515
- // 备用方案:通过常见后缀分割
516
- const splitIndex = this.findAdministrativeBoundary(address);
517
- if (splitIndex > 0) {
518
- return {
519
- administrativeDivision: address.substring(0, splitIndex),
520
- detailedAddress: address.substring(splitIndex)
521
- };
522
- }
523
- }
524
- // 如果无法分割,返回默认值
525
- return {
526
- administrativeDivision: address,
527
- detailedAddress: ''
528
- };
529
- },
530
- findAdministrativeBoundary(address) {
531
- // 常见的行政区划后缀
532
- const suffixes = ['区', '县', '市'];
533
- // 从后往前查找第一个匹配的后缀
534
- for (let i = address.length - 1; i >= 0; i--) {
535
- for (let suffix of suffixes) {
536
- if (address[i] === suffix &&
537
- (i < address.length - 1)) {
538
- return i + 1;
539
- }
540
- }
541
- }
542
- return -1;
543
- },
544
- scan() {
545
- HostApp.__this__ = this,
546
- HostApp.scanCode({callback: "javascript:HostApp.__this__.getCode();"})
547
- },
548
- getCode() {
549
- var datapa = HostApp.getCode().data;
550
- //tag
551
- this.userinfo.meterinfo[0].f_meternumber = datapa
552
- },
553
- //数据检查
554
- checkVal() {
555
- //检查一些必要信息是否未填
556
- this.approveChange = false
557
- this.changemeterno = false
558
- let checked = {ischeck: true, msg: ''}
559
- //tag
560
- //tag
561
- //tag
562
- if (!this.userinfo.baseinfo.base.f_user_name) {
563
- checked = {ischeck: false, msg: '请输入用户名称!'}
564
- }
565
- if (!this.selectPcd.id) {
566
- checked = {ischeck: false, msg: '请选择省市区!'}
567
- }
568
- if (!this.userinfo.addressinfo.f_address) {
569
- checked = {ischeck: false, msg: '新地址不能为空!'}
570
- }
571
- if (this.addressType == '普通地址') {
572
- if (!this.selectArea.id) {
573
- checked = {ischeck: false, msg: '请选择集收单位!'}
574
- }
575
- if (!this.userinfo.addressinfo.f_room) {
576
- checked = {ischeck: false, msg: '新输入门牌号!'}
577
- }
578
- if (!this.selectStreet.id) {
579
- checked = {ischeck: false, msg: '请选择街道!'}
580
- }
581
- }
582
- if (this.userinfo.meterinfo[0].f_meter_classify == '机表' && this.userinfo_old.meterinfo[0].f_meternumber) {
583
-
584
- //tag
585
- //tag
586
- if (this.userinfo.meterinfo[0].f_meternumber) {
587
- if (this.userinfo.meterinfo[0].f_meternumber != this.userinfo_old.meterinfo[0].f_meternumber) {
588
- if (!this.f_meterno_path || this.f_meterno_path == Vue.nopic) {
589
- checked = {ischeck: false, msg: '请拍摄表号照片!'}
590
- } else {
591
- //用来标识当前有修改机表表号,后台需要进行照片上传
592
- this.changemeterno = true
593
- }
594
- }
595
- } else {
596
- checked = {ischeck: false, msg: '请输入表号!'}
597
- }
598
- }
599
- //检查本次修改信息中是否包含需要审核的内容
600
- for (let check in this.checkField) {
601
- //tag
602
- if (typeof check != 'function') {
603
- for (let i = 0; i < this.checkField[check].length; i++) {
604
- //tag
605
- if (check == 'checkUserinfoField') {
606
- //tag
607
- //tag
608
- if (this.userinfo.baseinfo.base[this.checkField[check][i]] != this.userinfo_old.baseinfo.base[this.checkField[check][i]]) {
609
- //tag
610
- this.approveChange = true
611
- }
612
- } else if (check == 'checkUserFilesField') {
613
- //tag
614
- //tag
615
- if (this.userinfo.meterinfo[0][this.checkField[check][i]] != this.userinfo_old.meterinfo[0][this.checkField[check][i]]) {
616
- //tag
617
- this.approveChange = true
618
- }
619
- } else if (check == 'checkAddressField') {
620
- //tag
621
- //tag
622
- if (this.userinfo.addressinfo[this.checkField[check][i]] != this.userinfo_old.addressinfo[this.checkField[check][i]]) {
623
- //tag
624
- this.approveChange = true
625
- }
626
- }
627
- }
628
- }
629
- }
630
- //tag
631
- return checked
632
- },
633
- select_search(text) {
634
- //tag
635
- if (this.selectStreet.id) {
636
- let pcdText = text ? `and f_street_id=${this.selectStreet.id} and f_residential_area like '%${text}%'` : `and f_street_id=${this.selectStreet.id}`
637
- new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
638
- data: {
639
- items: "*",
640
- tablename: "t_area",
641
- orderitem: "id",
642
- condition: `f_orgid = '${Vue.user.orgid}' ${pcdText} `
643
- }
644
- }, {resolveMsg: null, rejectMsg: null}).then((res) => {
645
- //tag)
646
- if (res.data.length > 0) {
647
- this.area = []
648
- res.data.forEach((result) => {
649
- this.area.push({label: result.f_residential_area, value: result})
650
- })
651
- }
652
- })
653
- } else {
654
- this.area = []
655
- }
656
- },
657
- cameraCallBack(prop, fileName) {
658
- HostApp.__this__.$set(prop, fileName + '?' + Math.random())
659
- //tag
660
- HostApp.__callback__ = null
661
- HostApp.__this__ = null
662
- },
663
- takePic(prop, title) {
664
- HostApp.__callback__ = this.cameraCallBack
665
- HostApp.__this__ = this
666
- //tag
667
- let fileName
668
- if (!this[prop] || this[prop].includes("nopic.png")) {
669
- fileName = Util.guid() + '-' + prop + '.jpg'
670
- } else {
671
- fileName = Util.getFileName(this[prop])
672
- }
673
- HostApp._open_a_page({
674
- type: 'boomerang',
675
- page: 'com.aofeng.hybrid.android.peripheral.CameraActivity',
676
- param: {
677
- file: fileName,
678
- requestCode: 111,
679
- callback: 'javascript:HostApp.__callback__("' + prop + '", "%s");',
680
- watermark: title + '\t时间:' + Util.toStandardTimeString() + '\t' + Vue.user.name
681
- }
682
- })
683
- },
684
- delfile(prop, fileName) {
685
- if (fileName == Vue.nopic)
686
- return
687
- else {
688
- HostApp.delfile(fileName)
689
- this[prop] = Vue.nopic
690
- }
691
- },
692
- editUserInfoNoAudit() {
693
- let checked = this.checkVal()
694
- if (!checked.ischeck) {
695
- this.$showMessage(checked.msg)
696
- return
697
- }
698
- for (let i = 0; i < this.model.length; i++) {
699
- this.model[i].f_user_id = this.userinfo.meterinfo[0].f_user_id
700
- }
701
- this.$showMessage('确定是否修改上传用户信息?', ['confirm', 'cancel']).then((res) => {
702
- if (res === 'confirm') {
703
- this.userinfo.addressinfo.f_residential_area = this.selectArea.f_residential_area ? this.selectArea.f_residential_area : ''
704
- this.userinfo.addressinfo.f_residential_area_id = this.selectArea.id ? this.selectArea.id : ''
705
- this.userinfo.addressinfo.f_slice_area = this.selectArea.f_slice_area ? this.selectArea.f_slice_area : ''
706
- this.excessive = true
707
- let address = {}
708
- address.f_lng=this.userinfo.addressinfo.f_lng
709
- address.f_lat=this.userinfo.addressinfo.f_lat
710
- address.f_filialeid = this.userinfo.addressinfo.f_filialeid
711
- address.f_pcd = this.selectPcd.f_pcd
712
- address.f_pcd_id = this.selectPcd.id
713
- address.f_street = this.selectStreet.f_street
714
- address.f_street_id = this.selectStreet.id
715
- address.f_slice_area = ''
716
- address.f_slice_area_id = ''
717
- address.f_residential_area = this.selectArea.f_residential_area ? '' : this.selectArea.f_residential_area
718
- address.f_residential_area_id = this.selectArea.id
719
- address.f_room = this.userinfo.addressinfo.f_room
720
- address.f_floor = this.userinfo.addressinfo.f_floor
721
- address.f_unit = this.userinfo.addressinfo.f_unit
722
- address.f_building = this.userinfo.addressinfo.f_building
723
- address.f_address = this.userinfo.addressinfo.f_address
724
- address.f_comments = this.userinfo.addressinfo.f_comments
725
- address.id = this.userinfo_old.addressinfo.id
726
- address.oldid = this.userinfo_old.addressinfo.id
727
- let userinfoms = Object.assign({}, this.userinfo_old.baseinfo.base)
728
- // userinfoms.f_user_name=row.f_user_name
729
- userinfoms.f_user_phone = this.userinfo.baseinfo.base.f_user_phone
730
- userinfoms.f_rent_name = this.userinfo.baseinfo.base.f_rent_name
731
- userinfoms.f_zuhu_phone = this.userinfo.baseinfo.base.f_zuhu_phone
732
- userinfoms.f_operator_record = Vue.user.name
733
- userinfoms.f_operatorid_record = Vue.user.id
734
- // userinfoms.f_remark = this.userinfo.baseinfo.base.f_remark
735
- userinfoms.f_orgid_record = Vue.user.orgid
736
- userinfoms.f_orgname_record = Vue.user.orgs
737
- userinfoms.f_depid_record = Vue.user.depids
738
- userinfoms.f_depname_record = Vue.user.deps
739
- this.userinfo_old.meterinfo[0].f_gas_person = this.userinfo.meterinfo[0].f_gas_person
740
- this.userinfo_old.meterinfo[0].f_gas_date = this.userinfo.meterinfo[0].f_gas_date
741
- this.userinfo_old.meterinfo[0].f_adjustable_id = this.userinfo.meterinfo[0].f_adjustable_id
742
- this.userinfo_old.meterinfo[0].f_metertitles = this.userinfo.meterinfo[0].f_metertitles
743
- this.userinfo_old.meterinfo[0].f_position = this.userinfo.meterinfo[0].f_position
744
- this.userinfo_old.meterinfo[0].f_aroundmeter = this.userinfo.meterinfo[0].f_aroundmeter
745
- this.userinfo_old.meterinfo[0].f_bqf_state = this.userinfo.meterinfo[0].f_bqf_state
746
- this.userinfo_old.meterinfo[0].f_if_direct = this.userinfo.meterinfo[0].f_if_direct
747
- this.userinfo_old.meterinfo[0].f_meternumber = this.userinfo.meterinfo[0].f_meternumber
748
- this.userinfo_old.meterinfo[0].f_xc_meter_style = this.userinfo.meterinfo[0].f_xc_meter_style
749
- userinfoms.userfiles = []
750
- this.userinfo_old.meterinfo[0].devicesinfo = this.model
751
- userinfoms.userfiles.push(this.userinfo_old.meterinfo[0])
752
- console.log(address)
753
- new HttpResetClass().load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/fileSave`, {
754
- data: {
755
- userinfo: userinfoms,
756
- modifyReason: this.f_source ? `${this.f_source}维护档案信息` : '',
757
- address: address
758
- }
759
- }, {resolveMsg: null, rejectMsg: null}).then((res1) => {
760
- if (res1.data.status == 200) {
761
- let data = this.userinfo.addressinfo
762
- data.f_address = this.userinfo.addressinfo.f_address ? this.userinfo.addressinfo.f_address : this.userinfo_old.addressinfo.f_address
763
- data.f_operator = Vue.user.name
764
- new HttpResetClass().load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/address_updateuseraddress`, {data: data}).then((res2) => {
765
- this.$showMessage("修改用户信息成功!")
766
- }).catch(error => {
767
- this.$showMessage("修改用户信息!")
768
- })
769
- this.$showMessage("修改用户信息成功!")
770
- this.enable = true
771
- this.excessive = false
772
- }
773
- }).catch((msg) => {
774
- this.$showMessage("修改用户信息失败,请检查手机网络状况!")
775
- this.excessive = false
776
- })
777
- }
778
- })
779
- },
780
- editUserInfo() {
781
- let checked = this.checkVal()
782
- if (!checked.ischeck) {
783
- this.$showMessage(checked.msg)
784
- return
785
- }
786
- this.$showMessage('确定是否修改上传审核用户信息?', ['confirm', 'cancel']).then((res) => {
787
- if (res === 'confirm') {
788
- this.userinfo.addressinfo.f_residential_area = this.selectArea.f_residential_area ? this.selectArea.f_residential_area : ''
789
- this.userinfo.addressinfo.f_residential_area_id = this.selectArea.id ? this.selectArea.id : ''
790
- this.userinfo.addressinfo.f_slice_area = this.selectArea.f_slice_area ? this.selectArea.f_slice_area : ''
791
- this.excessive = true
792
- let address = {}
793
- address.f_filialeid = this.userinfo.addressinfo.f_filialeid
794
- address.f_pcd = this.selectPcd.f_pcd
795
- address.f_pcd_id = this.selectPcd.id
796
- address.f_street = this.selectStreet.f_street
797
- address.f_street_id = this.selectStreet.id
798
- address.f_slice_area = ''
799
- address.f_slice_area_id = ''
800
- address.f_residential_area = this.selectArea.f_residential_area ? '' : this.selectArea.f_residential_area
801
- address.f_residential_area_id = this.selectArea.id
802
- address.f_room = this.userinfo.addressinfo.f_room
803
- address.f_floor = this.userinfo.addressinfo.f_floor
804
- address.f_unit = this.userinfo.addressinfo.f_unit
805
- address.f_building = this.userinfo.addressinfo.f_building
806
- address.f_address = this.userinfo.addressinfo.f_address
807
- address.f_comments = this.userinfo.addressinfo.f_comments
808
- address.id = this.userinfo_old.addressinfo.id
809
- address.oldid = this.userinfo_old.addressinfo.id
810
- let userinfoms = Object.assign({}, this.userinfo_old.baseinfo.base)
811
- //userinfoms.f_user_name=row.f_user_name
812
- userinfoms.f_user_phone = this.userinfo.baseinfo.base.f_user_phone
813
- userinfoms.f_rent_name = this.userinfo.baseinfo.base.f_rent_name
814
- userinfoms.f_zuhu_phone = this.userinfo.baseinfo.base.f_zuhu_phone
815
- userinfoms.f_operator_record = Vue.user.name
816
- userinfoms.f_operatorid_record = Vue.user.id
817
- // userinfoms.f_remark = this.userinfo.baseinfo.base.f_remark
818
- userinfoms.f_orgid_record = Vue.user.orgid
819
- userinfoms.f_orgname_record = Vue.user.orgs
820
- userinfoms.f_depid_record = Vue.user.depids
821
- userinfoms.f_depname_record = Vue.user.deps
822
- this.userinfo_old.meterinfo[0].f_gas_person = this.userinfo.meterinfo[0].f_gas_person
823
- this.userinfo_old.meterinfo[0].f_gas_date = this.userinfo.meterinfo[0].f_gas_date
824
- this.userinfo_old.meterinfo[0].f_adjustable_id = this.userinfo.meterinfo[0].f_adjustable_id
825
- this.userinfo_old.meterinfo[0].f_metertitles = this.userinfo.meterinfo[0].f_metertitles
826
- this.userinfo_old.meterinfo[0].f_position = this.userinfo.meterinfo[0].f_position
827
- this.userinfo_old.meterinfo[0].f_aroundmeter = this.userinfo.meterinfo[0].f_aroundmeter
828
- this.userinfo_old.meterinfo[0].f_bqf_state = this.userinfo.meterinfo[0].f_bqf_state
829
- this.userinfo_old.meterinfo[0].f_if_direct = this.userinfo.meterinfo[0].f_if_direct
830
- this.userinfo_old.meterinfo[0].f_meternumber = this.userinfo.meterinfo[0].f_meternumber
831
- this.userinfo_old.meterinfo[0].f_xc_meter_style = this.userinfo.meterinfo[0].f_xc_meter_style
832
- userinfoms.userfiles = []
833
- this.userinfo_old.meterinfo[0].devicesinfo = this.model
834
- userinfoms.userfiles.push(this.userinfo_old.meterinfo[0])
835
- //tag)
836
- console.log(address,'dizhi')
837
- console.log(userinfoms,'dangan')
838
- new HttpResetClass().load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/fileSave`, {
839
- data: {
840
- userinfo: userinfoms,
841
- modifyReason: this.f_source ? `${this.f_source}维护档案信息` : '',
842
- address: address
843
- }
844
- }, {resolveMsg: null, rejectMsg: null}).then((res1) => {
845
- //tag+res1.data.status)
846
- if (res1.data.status == 200) {
847
- //本次修改信息包含需要审核信息
848
- if (this.approveChange) {
849
- //tag
850
- let res2 = this.$androidUtil.bzLogic('safe_upUserinfoApprove', {
851
- row: {
852
- f_time: Util.toStandardTimeString(),
853
- f_modifier: Vue.user.name,//Vue.user.name
854
- f_modifier_id: Vue.user.id,//Vue.user.id
855
- f_modify_type: '用户档案',
856
- f_userinfoid: this.userinfo.baseinfo.base.f_userinfo_id,
857
- f_userinfo_code: this.userinfo.baseinfo.base.f_userinfo_code,
858
- f_approved: '未审核',
859
- filialestr: Vue.user.orgid,//Vue.user.orgid
860
- version: 1,
861
- f_user_name: this.userinfo.baseinfo.base.f_user_name,
862
- f_user_phone: this.userinfo.baseinfo.base.f_user_phone,
863
- f_street: this.userinfo.addressinfo.f_street,
864
- f_building: this.userinfo.addressinfo.f_building,
865
- f_unit: this.userinfo.addressinfo.f_unit,
866
- f_floor: this.userinfo.addressinfo.f_floor,
867
- f_room: this.userinfo.addressinfo.f_room,
868
- f_building_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_building_suffix,
869
- f_unit_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_unit_suffix,
870
- f_floor_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_floor_suffix,
871
- f_room_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_room_suffix,
872
- f_residential_area: this.userinfo.addressinfo.f_residential_area,
873
- f_address: this.userinfo.addressinfo.f_address,
874
- f_comments: this.userinfo.addressinfo.f_comments,
875
- f_pcd: this.userinfo.addressinfo.f_pcd,
876
- f_pcd_id: this.userinfo.addressinfo.f_pcd_id,
877
- f_street_id: this.userinfo.addressinfo.f_street_id,
878
- f_residential_area_id: this.userinfo.addressinfo.f_residential_area_id,
879
- f_used_name: this.userinfo.baseinfo.base.f_used_name,
880
- f_rent_phone: this.userinfo.baseinfo.base.f_rent_phone,
881
- f_slice_area: this.userinfo.addressinfo.f_slice_area,
882
- // f_remark: this.userinfo.baseinfo.base.f_remark,
883
- f_source: this.f_source,
884
- f_meterno_path: this.f_meterno_path,
885
- f_iscity: this.userinfo.addressinfo.f_iscity,
886
- f_special: this.userinfo.addressinfo.f_special,
887
- f_meternumber: this.userinfo.meterinfo[0].f_meternumber,
888
- changemeterno: this.changemeterno
889
- },
890
- tablename: 't_modify_userinfo'
891
- })
892
- //tag)
893
- if (res2.code == 200) {
894
- this.$showMessage("变更用户信息成功,需要审核的信息已提交审核,等待管理员处理!")
895
- this.enable = true
896
- this.excessive = false
897
- } else {
898
- this.$showMessage("上传审核信息失败,请检查图片和网络状况是否正常!")
899
- this.excessive = false
900
- }
901
- } else {
902
- this.$showMessage("修改用户信息成功!")
903
- this.enable = true
904
- this.excessive = false
905
- }
906
-
907
- }
908
- }).catch((msg) => {
909
- this.$showMessage("修改用户信息失败,请检查手机网络状况!")
910
- this.excessive = false
911
- })
912
-
913
- }
914
- })
915
- },
916
- imgback(header) {
917
- if (this.headername == header) {
918
- return require('../../../assets/xiangxia1.png')
919
- } else {
920
- return require('../../../assets/xiangyou1.png')
921
- }
922
- this.headername = header
923
- },
924
- selectVal(header) {
925
- if (this.headername == header) {
926
- this.headername = ''
927
- } else {
928
- this.headername = header
929
- }
930
-
931
- },
932
- changeNewAddress() {
933
- this.userinfo.addressinfo.f_address = this.addressType == '普通地址' ? this.getAddress : this.getAddressTS
934
- },
935
- area_change() {
936
- //tag
937
- this.userinfo.addressinfo.f_residential_area = this.selectArea.f_residential_area
938
- this.userinfo.addressinfo.f_residential_area_id = this.selectArea.id
939
- this.userinfo.addressinfo.f_slice_area = this.selectArea.f_slice_area
940
- this.changeNewAddress()
941
- //this.userinfo.addressinfo.f_residential_area=this.f_residential_area.f_residential_area
942
- },
943
- async street_change() {
944
- //tag
945
- if (this.selectStreet.id) {
946
- //如果街道改变--给街道赋值!
947
- this.userinfo.addressinfo.f_street = this.selectStreet.f_street
948
- this.userinfo.addressinfo.f_street_id = this.selectStreet.id
949
- this.userinfo.addressinfo.f_iscity = this.selectStreet.f_iscity
950
- //清空当前选中小区的值
951
- this.userinfo.addressinfo.f_residential_area = ''
952
- this.userinfo.addressinfo.f_residential_area_id = ''
953
- this.userinfo.addressinfo.f_slice_area = ''
954
- this.selectArea = {id: ''}
955
- this.area = []
956
- let pcdText = ` and f_street_id=${this.selectStreet.id}`
957
- let res = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
958
- data: {
959
- items: "*",
960
- tablename: "t_area",
961
- orderitem: "id",
962
- condition: `f_orgid = '${Vue.user.orgid}' ${pcdText} `
963
- }
964
- }, {resolveMsg: null, rejectMsg: null})
965
- ////tag)
966
- res.data.forEach((result) => {
967
- this.area.push({label: result.f_residential_area, value: result})
968
- })
969
- } else {
970
- this.area = []
971
- }
972
-
973
- this.changeNewAddress()
974
- },
975
- async pcd_change() {
976
- //tag
977
- if (this.selectPcd.id) {
978
- //tag
979
- //如果省市区改变-重新赋值
980
- this.userinfo.addressinfo.f_pcd = this.selectPcd.f_pcd
981
- this.userinfo.addressinfo.f_pcd_id = this.selectPcd.id
982
- //清空 选中的街道和集收单位
983
- this.selectStreet = {id: ''}
984
- this.userinfo.addressinfo.f_street = ''
985
- this.userinfo.addressinfo.f_street_id = ''
986
- this.userinfo.addressinfo.f_iscity = ''
987
- this.selectArea = {id: ''}
988
- this.userinfo.addressinfo.f_residential_area = ''
989
- this.userinfo.addressinfo.f_residential_area_id = ''
990
- this.userinfo.addressinfo.f_slice_area = ''
991
- this.streets = []
992
- let pcdText = `and f_pcd_id=${this.selectPcd.id}`
993
- let streetlist = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
994
- data: {
995
- items: "*",
996
- tablename: "t_street",
997
- orderitem: "id",
998
- condition: `f_orgid = '${Vue.user.orgid}' ${pcdText}`
999
- }
1000
- }, {resolveMsg: null, rejectMsg: null})
1001
- streetlist.data.forEach((result) => {
1002
- this.streets.push({label: result.f_street, value: result})
1003
- })
1004
- } else {
1005
- this.streets = []
1006
- }
1007
- this.changeNewAddress()
1008
- },
1009
- upUserState() {
1010
- //tag)
1011
- if (this.userinfo.meterinfo[0].f_table_state == '正常') {
1012
- let data = {
1013
- f_userfiles_id: {
1014
- f_userfiles_id: this.userinfo.meterinfo[0].f_userfiles_id,
1015
- f_table_state: '停用',
1016
- version: this.userinfo.meterinfo[0].version
1017
- },
1018
- f_userfile_id: this.userinfo.meterinfo[0].f_userfiles_id,
1019
- f_user_id: this.userinfo.meterinfo[0].f_user_id,
1020
- f_userinfo_id: this.userinfo.meterinfo[0].f_userinfo_id,
1021
- f_user_name: this.userinfo.baseinfo.base.f_user_name,
1022
- f_comments: '安检时发现问题关闭阀门',
1023
- f_othereason: '',
1024
- f_operat_type: '停用',
1025
- f_describe: `${Vue.user.name}对客户${this.userinfo.baseinfo.base.f_user_name}进行表具停用操作`,
1026
- f_state: '有效',
1027
- f_operator: Vue.user.name,//${Vue.$login.f.name}
1028
- f_operatorid: Vue.user.id,
1029
- f_orgid: Vue.user.orgid,
1030
- f_orgname: Vue.user.orgs,
1031
- f_depid: Vue.user.depids,
1032
- f_depname: Vue.user.deps,
1033
- f_zoneid: Vue.user.zoneid,
1034
- f_zones: Vue.user.zones
1035
- }
1036
- new HttpResetClass().load('post', `${this.$androidUtil.getProxyUrl()}/rs/entity/t_disable`,
1037
- data, {resolveMsg: null, rejectMsg: null}).then((row) => {
1038
- this.$showMessage('已成功关阀停气!')
1039
- this.userinfo.meterinfo[0].f_table_state = '停用'
1040
- })
1041
- } else {
1042
- this.$showMessage('该用户已被关阀停用,请勿重复操作!')
1043
- }
1044
-
1045
- },
1046
- addDevices() {
1047
- //Vue.user.name
1048
- let obj = {
1049
- "f_operator": Vue.user.name,
1050
- "f_picture": null,
1051
- "f_pipe_type": null,
1052
- "f_pipeinstall_date": null,
1053
- "f_pipe_connection": null,
1054
- "f_expire_date": null,
1055
- "f_pipeexpire_date": null,
1056
- "f_comments": null,
1057
- "f_operate_date": Util.toStandardTimeString(),
1058
- "f_operatorid": Vue.user.id,
1059
- "f_devices_num": null,
1060
- "f_process_id": null,
1061
- "f_devices_type": null,
1062
- "f_make_date": null,
1063
- "f_input_date": null,
1064
- "f_state": "有效",
1065
- "f_brand": null,
1066
- "f_devices_model": null,
1067
- "f_devices_no": null,
1068
- "img": {"content": null, "filename": null}
1069
- }
1070
- this.model.push(obj)
1071
- },
1072
- delDevices(idx) {
1073
- //tag
1074
- this.$showMessage('删除后不可恢复,确认删除吗?', ['confirm', 'cancel']).then((res) => {
1075
- if (res === 'confirm') {
1076
- this.model.splice(idx, 1)
1077
- }
1078
- })
1079
- },
1080
- async getAreaList(text) {
1081
- if (this.selectStreet.id) {
1082
- this.area = []
1083
- let pcdText = text ? `and f_street_id=${this.selectStreet.id} and f_residential_area like '%${text}%'` : `and f_street_id=${this.selectStreet.id}`
1084
- let res = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1085
- data: {
1086
- items: "*",
1087
- tablename: "t_area",
1088
- orderitem: "id",
1089
- condition: `f_orgid = '${Vue.user.orgid}' ${pcdText}`
1090
- }
1091
- }, {resolveMsg: null, rejectMsg: null})
1092
- ////tag)
1093
- res.data.forEach((result) => {
1094
- this.area.push({label: result.f_residential_area, value: result})
1095
- })
1096
- //tag
1097
- this.area.push({
1098
- label: this.userinfo.addressinfo.f_residential_area,
1099
- value: {
1100
- id: this.userinfo.addressinfo.f_residential_area_id,
1101
- f_residential_area: this.userinfo.addressinfo.f_residential_area
1102
- }
1103
- })
1104
- } else {
1105
- this.area = []
1106
- }
1107
-
1108
- },
1109
- async getStreetList() {
1110
- if (this.selectPcd.id) {
1111
- //tag
1112
- this.streets = []
1113
- let pcdText = `and f_pcd_id=${this.selectPcd.id}`
1114
- let streetlist = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1115
- data: {
1116
- items: "*",
1117
- tablename: "t_street",
1118
- orderitem: "id",
1119
- condition: `f_orgid = '${Vue.user.orgid}' ${pcdText}`
1120
- }
1121
- }, {resolveMsg: null, rejectMsg: null})
1122
- streetlist.data.forEach((result) => {
1123
- //如果第一次进来有地址id 就拿下地址区域
1124
- if (this.selectStreet.id && this.selectStreet.id == result.id) {
1125
- //tag)
1126
- this.userinfo.addressinfo.f_iscity = result.f_iscity
1127
- }
1128
- this.streets.push({label: result.f_street, value: result})
1129
- })
1130
- } else {
1131
- this.streets = []
1132
- }
1133
- },
1134
- changeAddressType(val) {
1135
- //tag
1136
- if (this.addressType == '普通地址') {
1137
- this.userinfo.addressinfo.f_special = null
1138
- } else if (this.addressType == '特殊地址') {
1139
- this.userinfo.addressinfo.f_special = 1
1140
- this.userinfo.addressinfo.f_building = null
1141
- this.userinfo.addressinfo.f_unit = null
1142
- this.userinfo.addressinfo.f_floor = null
1143
- this.userinfo.addressinfo.f_room = null
1144
- }
1145
- this.changeNewAddress()
1146
- }
1147
-
1148
- },
1149
- computed: {
1150
- getAddress() {
1151
- return (this.userinfo.addressinfo.f_pcd ? this.userinfo.addressinfo.f_pcd : '') +
1152
- (this.userinfo.addressinfo.f_street ? this.userinfo.addressinfo.f_street : '') +
1153
- (this.userinfo.addressinfo.f_residential_area ? this.userinfo.addressinfo.f_residential_area : '') +
1154
- (this.userinfo.addressinfo.f_building ? this.userinfo.addressinfo.f_building + (this.userinfo.addressinfo.f_building_suffix ? this.userinfo.addressinfo.f_building_suffix : '') : '') +
1155
- (this.userinfo.addressinfo.f_unit ? this.userinfo.addressinfo.f_unit + (this.userinfo.addressinfo.f_unit_suffix ? this.userinfo.addressinfo.f_unit_suffix : '') : '') +
1156
- (this.userinfo.addressinfo.f_floor ? this.userinfo.addressinfo.f_floor + (this.userinfo.addressinfo.f_floor_suffix ? this.userinfo.addressinfo.f_floor_suffix : '') : '') +
1157
- (this.userinfo.addressinfo.f_room ? this.userinfo.addressinfo.f_room + (this.userinfo.addressinfo.f_room_suffix ? this.userinfo.addressinfo.f_room_suffix : '') : '')
1158
- },
1159
- getAddressTS() {
1160
- return (this.userinfo.addressinfo.f_pcd ? this.userinfo.addressinfo.f_pcd : '') +
1161
- (this.userinfo.addressinfo.f_street ? this.userinfo.addressinfo.f_street : '') +
1162
- (this.userinfo.addressinfo.f_residential_area ? this.userinfo.addressinfo.f_residential_area : '')+
1163
- (this.detailedAddress ? this.detailedAddress: '')
1164
- }
1165
- },
1166
- watch: {
1167
-
1168
- /*'selectPcd.id' (val) {
1169
- //tag
1170
- if(this.selectPcd.id){
1171
- this.getStreetList()
1172
- }
1173
- },
1174
- 'selectStreet.id' (val) {
1175
- //tag
1176
- if(this.selectStreet.id){
1177
- this.getAreaList()
1178
- }
1179
- }*/
1180
- },
1181
- async ready() {
1182
- /*//tag)
1183
-
1184
- //tag)
1185
- //tag)*/
1186
- //this.f_userinfo_id=1102260
1187
- //this.f_userinfo_id=1997541
1188
- if (!this.f_userinfo_id) {
1189
- this.$showMessage("未检测到用户!")
1190
- this.enable = true
1191
- return
1192
- }
1193
- try {
1194
-
1195
- this.devices_types = Vue.$appdata.getParam('设备类型')
1196
- console.log('this.devices_types=', JSON.stringify(this.devices_types))
1197
- for (const devices_type of this.devices_types) {
1198
- console.log('Vue.$appdata.getParam(`档案设备信息-${devices_type.label}品牌`)=', JSON.stringify(Vue.$appdata.getParam(`档案设备信息-${devices_type.label}品牌`)))
1199
- this.deviceBrandOption[devices_type.label] = Vue.$appdata.getParam(`档案设备信息-${devices_type.label}品牌`) || []
1200
- }
1201
- console.log('this.deviceBrandOption=', JSON.stringify(this.deviceBrandOption))
1202
- this.wz_types = Vue.$appdata.getParam('安装位置')
1203
- this.aroundmeters = Vue.$appdata.getParam('左右表')
1204
-
1205
- ////tag)
1206
- this.excessive = true
1207
- //Vue.user.orgid ${this.f_userinfo_id} 10101 ${Vue.user.orgid}
1208
-
1209
- let pcdlist = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1210
- data: {
1211
- items: "*",
1212
- tablename: "t_pcd",
1213
- orderitem: "id",
1214
- condition: `f_orgid = '${Vue.user.orgid}'`
1215
- }
1216
- }, {resolveMsg: null, rejectMsg: null})
1217
- //tag)
1218
- pcdlist.data.forEach((result) => {
1219
- this.pcds.push({label: result.f_pcd, value: result})
1220
- })
1221
- ////tag)
1222
- let res = await new HttpResetClass().load('post', `${this.$androidUtil.getProxyUrl()}/rs/logic/filemanage_getFilesDetail`, {
1223
- //f_userinfo_code:'12381344',
1224
- f_userinfo_id: this.f_userinfo_id
1225
- }, {resolveMsg: null, rejectMsg: null})
1226
- //tag
1227
- //tag
1228
- this.userinfo = res.data
1229
- this.userinfo_old = JSON.parse(JSON.stringify(res.data))
1230
- this.model = this.userinfo.meterinfo[0].devicesinfo
1231
- this.selectArea.id = this.userinfo.addressinfo.f_residential_area_id
1232
- this.selectPcd.id = this.userinfo.addressinfo.f_pcd_id
1233
- this.selectPcd.f_pcd = this.userinfo.addressinfo.f_pcd
1234
- this.selectStreet.id = this.userinfo.addressinfo.f_street_id
1235
- this.selectStreet.f_street = this.userinfo.addressinfo.f_street
1236
- await this.getStreetList()
1237
- await this.getAreaList()
1238
- this.excessive = false
1239
- this.addressType = this.userinfo.addressinfo.f_special == 1 ? '特殊地址' : '普通地址'
1240
- //this.userinfo.addressinfo.f_special=1
1241
- //tag
1242
- } catch (e) {
1243
- this.excessive = false
1244
- this.enable = true
1245
- this.$showMessage('获取用户信息出错,请检查网络状况!')
1246
- }
1247
- new HttpResetClass().load('get', `${this.$androidUtil.getProxyUrl()}/rs/vue/UserAddress.json`, {data: {}}, {
1248
- resolveMsg: null,
1249
- rejectMsg: null
1250
- }).then((addressUnit) => {
1251
- //tag
1252
- //tag
1253
- //tag
1254
- //tag
1255
- this.userinfo.addressinfo.f_building_suffix = addressUnit.data.f_building_suffix
1256
- this.userinfo.addressinfo.f_unit_suffix = addressUnit.data.f_unit_suffix
1257
- this.userinfo.addressinfo.f_floor_suffix = addressUnit.data.f_floor_suffix
1258
- this.userinfo.addressinfo.f_room_suffix = addressUnit.data.f_room_suffix
1259
- }).catch((msg) => {
1260
- //tag)
1261
- })
1262
- this.showBox = this.$appdata.getSingleValue('档案审核是否显示调压箱') == '是' ? true : false
1263
- console.log(this.showBox)
1264
- if (this.showBox) {
1265
- // 获取调压箱
1266
- new HttpResetClass().load('post', `${this.$androidUtil.getProxyUrl()}/rs/sql/adjustableboxQuery`, {data: {condition: '1 = 1'}}, {
1267
- resolveMsg: null,
1268
- rejectMsg: null
1269
- }).then((res) => {
1270
- const boxOptions = []
1271
- for (const data of res.data) {
1272
- const one = {
1273
- label: data.f_adjustable_id + data.f_adjustable_name,
1274
- value: Number(data.id)
1275
- }
1276
- boxOptions.push(one)
1277
- }
1278
- this.boxOptions = JSON.parse(JSON.stringify(boxOptions))
1279
- console.log(this.boxOptions)
1280
- }).catch((msg) => {
1281
- //tag)
1282
- })
1283
- }
1284
- }
1285
- }
1286
- </script>
1287
- <style lang="less" scoped>
1288
- .butt3 {
1289
- float: right;
1290
- width: 12px;
1291
- margin: 1% 2% 0 0;
1292
- }
1293
-
1294
- .rightipt {
1295
- width: 60%;
1296
- float: left;
1297
- margin-left: 5%;
1298
- }
1299
-
1300
- .righttxt {
1301
- border: none;
1302
- margin-left: 5px;
1303
- /*border-left: 5px solid #A2C2EB;*/
1304
- float: left;
1305
- width: 25%;
1306
- margin-bottom: 3px;
1307
- text-align: left;
1308
- word-wrap: break-word;
1309
- white-space: normal;
1310
- }
1311
-
1312
- .tit1 {
1313
- /*background: #ffffff url('../../../assets/用户姓名.png') no-repeat fixed center;*/
1314
- background-image: url('../../../assets/用户姓名.png');
1315
- background-repeat: no-repeat;
1316
- background-position: center;
1317
- }
1318
-
1319
- .spanboder {
1320
- border-bottom: 2px solid #499edf;
1321
- padding-bottom: 8px
1322
- }
1323
-
1324
- #upuserinfo_sel /deep/ ul {
1325
- width: 100% !important;
1326
- left: 0 !important;
1327
- }
1328
-
1329
- .btn-photo {
1330
- border: 0;
1331
- border-radius: 7px;
1332
- background-color: #7dc1f4;
1333
- font: 15px PingFang-SC-Bold;
1334
- height: 20%;
1335
- }
1336
-
1337
- .panel-self {
1338
- border-radius: 10px;
1339
- border: 1px solid #499EDF;
1340
- background-color: #F8F8F8;
1341
- }
1342
-
1343
- .div-photo {
1344
- width: auto;
1345
- height: auto;
1346
- /* margin-top: 10px; */
1347
- position: absolute;
1348
- bottom: 10px;
1349
- right: 10px;
1350
- }
1351
- </style>
1352
- <style lang="less">
1353
- #upuserinfo_sel ul {
1354
- width: 100% !important;
1355
- left: 0 !important;
1356
- }
1357
- </style>
1
+ <template>
2
+ <work-busy :is-busy="excessive"></work-busy>
3
+ <div style="height: 100%">
4
+ <div class="panel auto">
5
+ <div class="panel-heading" @click="selectVal('基本信息')" style="background-color: #ffffff">
6
+ <span class="spanboder">
7
+ <img src="../../../assets/person.png" style="width: 22px;margin-right: 8px;">基本信息
8
+ <img class="butt3" :src="imgback('基本信息')">
9
+ </span>
10
+ </div>
11
+ <div class="panel-body " id="upuserinfo_sel" v-show="headername=='基本信息'">
12
+ <div class="row auto" style="margin: 5px 0">
13
+ <label class="righttxt">用户编号:</label>
14
+ <input type="text" class="form-control rightipt" v-model="userinfo.baseinfo.base.f_userinfo_code" readonly/>
15
+ </div>
16
+ <div class="row auto" style="margin: 5px 0">
17
+ <label class="righttxt">用户名称:</label><input type="text" class="form-control rightipt"
18
+ v-model="userinfo.baseinfo.base.f_user_name" readonly/>
19
+ </div>
20
+ <div class="row auto" style="margin: 5px 0">
21
+ <label class="righttxt">用户状态:</label><input type="text" class="form-control rightipt" readonly
22
+ v-model="userinfo.baseinfo.base.f_user_state"/>
23
+ </div>
24
+ <div class="row auto" style="margin: 5px 0">
25
+ <label class="righttxt">用户电话:</label><input type="text" class="form-control rightipt"
26
+ v-model="userinfo.baseinfo.base.f_user_phone"/>
27
+ </div>
28
+ <div class="row auto" style="margin: 5px 0">
29
+ <label class="righttxt">租户姓名:</label><input type="text" class="form-control rightipt"
30
+ v-model="userinfo.baseinfo.base.f_rent_name"/>
31
+ </div>
32
+ <div class="row auto" style="margin: 5px 0">
33
+ <label class="righttxt">租户电话:</label><input type="text" class="form-control rightipt"
34
+ v-model="userinfo.baseinfo.base.f_zuhu_phone"/>
35
+ </div>
36
+ <div class="row auto" style="margin: 5px 0">
37
+ <label class="righttxt">建档日期:</label><input type="text" class="form-control rightipt"
38
+ v-model="userinfo.baseinfo.base.f_createfile_date" readonly/>
39
+ </div>
40
+ <!-- <div class="row auto" style="margin: 5px 0">
41
+ <label class="righttxt">开户日期:</label><input type="text" class="form-control rightipt" v-model="userinfo.baseinfo.base.f_open_date" readonly />
42
+ </div>-->
43
+ <div class="row auto" style="margin: 5px 0">
44
+ <label class="righttxt">地址类型:</label>
45
+ <div class="rightipt" style="display: flex;justify-content: space-around;margin-top: 5px">
46
+ <div><input type="radio" v-model="addressType" name="addressType" @change="changeAddressType"
47
+ id="phone_addressType1" value="普通地址"/><label style="font-weight: normal;padding-left: 2px"
48
+ for="phone_addressType1">普通地址</label></div>
49
+ <div><input type="radio" v-model="addressType" name="addressType" @change="changeAddressType"
50
+ id="phone_addressType2" value="特殊地址"/><label style="font-weight: normal;padding-left: 2px"
51
+ for="phone_addressType2">特殊地址</label></div>
52
+ </div>
53
+
54
+ </div>
55
+ <div class="row auto" style="margin: 5px 0">
56
+ <label class="righttxt">经度:</label>
57
+ <input readonly type="text" class="form-control rightipt" v-model="userinfo.addressinfo.f_lng"/>
58
+ </div>
59
+ <div class="row auto" style="margin: 5px 0">
60
+ <label class="righttxt">纬度:</label>
61
+ <input readonly type="text" class="form-control rightipt" v-model="userinfo.addressinfo.f_lat"/>
62
+ <div style="margin-left: 10px;" @click="getLocation">
63
+ <img src="../../../assets/定位.png" alt="定位" style="width: 24px; height: 24px; cursor: pointer;" />
64
+ </div>
65
+ </div>
66
+ <div class="row auto" style="margin: 5px 0">
67
+ <label class="righttxt">地区类型:</label>
68
+ <!--<input type="text" style="width: 75%;float:right" class="form-control" v-model="row.f_devices_type" />-->
69
+ <input type="text" class="form-control rightipt" readonly v-model="userinfo.addressinfo.f_iscity"/>
70
+ <!--<v-select :value.sync="userinfo.addressinfo.f_iscity" class="input-font" style="margin-left: 5%;"
71
+ :width="'60%'"
72
+ :disabled="true"
73
+ v-model="userinfo.addressinfo.f_iscity"
74
+ :options='cityTypes' placeholder='地区类型' close-on-select clear-button value-single ></v-select>-->
75
+ </div>
76
+ <div class="row auto" style="margin: 5px 0">
77
+ <label class="righttxt">省&ensp;市&ensp;区:</label>
78
+ <!--<input type="text" style="width: 75%;float:right" class="form-control" v-model="row.f_devices_type" />-->
79
+ <!--<input type="text" class="form-control rightipt" readonly v-model="userinfo.addressinfo.f_pcd" />-->
80
+ <v-select :value.sync="selectPcd" class="input-font" style="margin-left: 5%;"
81
+ :width="'60%'"
82
+ v-model="selectPcd"
83
+ :options='pcds' placeholder='请选择省市区' close-on-select clear-button value-single
84
+ @change="pcd_change()"></v-select>
85
+ </div>
86
+ <div class="row auto" style="margin: 5px 0">
87
+ <label class="righttxt">街道名称:</label>
88
+ <!--<input type="text" readonly class="form-control rightipt" v-model="userinfo.addressinfo.f_street" />-->
89
+ <v-select :value.sync="selectStreet" class="input-font" style="margin-left: 5%;"
90
+ :width="'60%'"
91
+ v-model="selectStreet"
92
+ :options='streets' placeholder='请选择街道' close-on-select clear-button value-single
93
+ @change="street_change()"></v-select>
94
+ </div>
95
+ <div class="row auto" style="margin: 5px 0">
96
+ <label class="righttxt">集收单位:</label>
97
+ <!--<input type="text" readonly class="form-control rightipt" v-model="userinfo.addressinfo.f_residential_area" />-->
98
+ <v-select :value.sync="selectArea" class="input-font" style="margin-left: 5%;"
99
+ :width="'60%'"
100
+ v-model="selectArea"
101
+ :timeout="500"
102
+ @select-search="select_search"
103
+ :options='area' placeholder='请选择集收单位' close-on-select clear-button value-single
104
+ @change="area_change()"></v-select>
105
+ </div>
106
+ <!--<div class="row auto" style="margin: 5px 0" v-show="addressType=='特殊地址'">
107
+ <label class="righttxt">集收单位:</label>
108
+ &lt;!&ndash;<input type="text" readonly class="form-control rightipt" v-model="userinfo.addressinfo.f_residential_area" />&ndash;&gt;
109
+ <v-select :value.sync="selectArea" class="input-font" style="margin-left: 5%;"
110
+ :width="'60%'"
111
+ v-model="selectArea"
112
+ @select-search="select_search"
113
+ :options='area' placeholder='请选择集收单位' close-on-select clear-button value-single @change="area_changeTC()"></v-select>
114
+ </div>-->
115
+ <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
116
+ <label class="righttxt">楼&ensp;&ensp;&ensp;&ensp;号:</label><input type="text" @change="changeNewAddress"
117
+ class="form-control rightipt"
118
+ v-model="userinfo.addressinfo.f_building"/>
119
+ </div>
120
+ <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
121
+ <label class="righttxt">单&ensp;&ensp;&ensp;&ensp;元:</label><input type="text" @change="changeNewAddress"
122
+ class="form-control rightipt"
123
+ v-model="userinfo.addressinfo.f_unit"/>
124
+ </div>
125
+ <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
126
+ <label class="righttxt">楼&ensp;&ensp;&ensp;&ensp;层:</label><input type="text" @change="changeNewAddress"
127
+ class="form-control rightipt"
128
+ v-model="userinfo.addressinfo.f_floor"/>
129
+ </div>
130
+ <div class="row auto" style="margin: 5px 0" v-show="addressType=='普通地址'">
131
+ <label class="righttxt">门&ensp;牌&ensp;号:</label><input type="text" @change="changeNewAddress"
132
+ class="form-control rightipt"
133
+ v-model="userinfo.addressinfo.f_room"/>
134
+ </div>
135
+ <div class="row auto" style="margin: 5px 0">
136
+ <label class="righttxt">详细地址:</label><input type="text" class="form-control rightipt" readonly
137
+ v-model="userinfo_old.addressinfo.f_address"/>
138
+ </div>
139
+ <div class="row auto" style="margin: 5px 0">
140
+ <label class="righttxt">新&ensp;地&ensp;址:</label>
141
+ <!--<input type="text" class="form-control rightipt" readonly v-model="getaddress()" />-->
142
+ <textarea :readonly="addressType=='普通地址'" class="form-control rightipt" : style="height: 80px"
143
+ v-model="userinfo.addressinfo.f_address"></textarea>
144
+ </div>
145
+
146
+ <!--<div class="row auto" style="margin: 5px 0" v-show="addressType=='特殊地址'">
147
+ <label class="righttxt">新&ensp;地&ensp;址:</label>&lt;!&ndash;<input type="text" class="form-control rightipt" v-model="userinfo.addressinfo.f_address" />&ndash;&gt;
148
+ <textarea class="form-control rightipt" style="height: 80px" v-model="getAddressTS"></textarea>
149
+ </div>-->
150
+
151
+ <div class="row auto" style="margin: 5px 0">
152
+ <label class="righttxt">备&ensp;&ensp;&ensp;&ensp;注:</label><textarea class="form-control rightipt"
153
+ style="height: 150px"
154
+ v-model="userinfo.addressinfo.f_comments"></textarea>
155
+ <!--<input type="text" class="form-control rightipt" v-model="userinfo.baseinfo.base.f_remark" />-->
156
+ </div>
157
+ </div>
158
+ </div>
159
+ <div class="panel auto">
160
+ <div class="panel-heading" @click="selectVal('表具信息')" style="background-color: #ffffff">
161
+ <span class="spanboder">
162
+ <img src="../../../assets/person.png" style="width: 22px;margin-right: 8px;">表具信息
163
+ <img class="butt3" :src="imgback('表具信息')">
164
+ </span>
165
+ </div>
166
+ <div class="panel-body " v-show="headername=='表具信息'">
167
+ <div class="row auto" style="margin: 5px 0">
168
+ <label class="righttxt">表&ensp;&ensp;&ensp;&ensp;号:</label>
169
+ <input type="text"
170
+ :readonly="(userinfo.meterinfo[0].f_meter_classify!='机表' && userinfo.meterinfo[0].f_meter_classify!='金额卡表'&&userinfo.meterinfo[0].f_meter_classify!='气量卡表')"
171
+ class="form-control rightipt"
172
+ style="width: 45%" v-model="userinfo.meterinfo[0].f_meternumber"/>
173
+ <button type="button"
174
+ :disabled="!(userinfo.meterinfo[0].f_meter_classify=='机表' || userinfo.meterinfo[0].f_meter_classify=='金额卡表' || userinfo.meterinfo[0].f_meter_classify=='气量卡表')"
175
+ name="button" class="btn btn-primary" style="width: 15%" @click="scan">扫码
176
+ </button>
177
+ </div>
178
+
179
+ <!--<div class="row auto" style="margin: 5px 0" v-if="userinfo.meterinfo[0].f_meter_classify=='机表'">
180
+ <div class="auto">
181
+ <div class="panel" style="padding: 0px 15px 5px 10px;">
182
+ <div class="panel-body panel-self" style="background-color: #F8F8F8;width: 100%;height: 260px;position: relative">
183
+ <div class="row" style="height: 240px;">
184
+ <div class="col-sm-4">
185
+ <img-self :src="f_meterno_path" alt="表号照片" width="150" height="200"></img-self>
186
+ </div>
187
+ </div>
188
+ <div class="row text-right div-photo" :class="style__">
189
+ <button type="button" name="button" class="btn btn-primary btn-photo" @click="takePic('f_meterno_path', '表号照片')">拍照</button>
190
+ <img src="../../../assets/remove.png" :class="style__" @click="delfile('f_meterno_path', this.f_meterno_path)" style="width: 25%;"></img>
191
+ </div>
192
+ </div>
193
+ </div>
194
+ </div>
195
+ </div>-->
196
+ <div class="row auto" style="margin: 5px 0">
197
+ <label class="righttxt">通&ensp;气&ensp;人:</label>
198
+ <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_gas_person"/>
199
+ </div>
200
+ <div class="row auto" style="margin: 5px 0">
201
+ <label class="righttxt">通气时间:</label>
202
+ <datepicker class="rightipt"
203
+ :value.sync="userinfo.meterinfo[0].f_gas_date"
204
+ v-model="userinfo.meterinfo[0].f_gas_date"
205
+ :disabled-days-of-Week="[]"
206
+ :format="'yyyy-MM-dd'"
207
+ :show-reset-button="reset">
208
+ </datepicker>
209
+ </div>
210
+ <div class="row auto" style="margin: 5px 0" v-show="showBox">
211
+ <label class="righttxt">调&ensp;压&ensp;箱:</label>
212
+ <v-select class="rightipt"
213
+ :value.sync="userinfo.meterinfo[0].f_adjustable_id"
214
+ v-model="userinfo.meterinfo[0].f_adjustable_id"
215
+ placeholder='请选择'
216
+ :width='wid'
217
+ readonly
218
+ :options="boxOptions"
219
+ close-on-select value-single></v-select>
220
+ </div>
221
+ <div class="row auto" style="margin: 5px 0">
222
+ <label class="righttxt">是否直通:</label>
223
+ <v-select
224
+ :value.sync="userinfo.meterinfo[0].f_if_direct"
225
+ class="input-font"
226
+ style="margin-left: 5%;"
227
+ :width="'60%'"
228
+ v-model="userinfo.meterinfo[0].f_if_direct"
229
+ :options='directOptions'
230
+ placeholder='是否直通'
231
+ close-on-select
232
+ clear-button
233
+ value-single>
234
+ </v-select>
235
+ </div>
236
+ <div class="row auto" style="margin: 5px 0">
237
+ <label class="righttxt">表&ensp;封&ensp;号:</label>
238
+ <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_metertitles"/>
239
+ </div>
240
+ <div class="row auto" style="margin: 5px 0">
241
+ <label class="righttxt">表&ensp;位&ensp;置:</label>
242
+ <!--<input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_position" readonly/>-->
243
+ <v-select class="rightipt" :value.sync="userinfo.meterinfo[0].f_position"
244
+ v-model="userinfo.meterinfo[0].f_position"
245
+ placeholder='请选择'
246
+ :width='wid'
247
+ readonly
248
+ :options="wz_types"
249
+ close-on-select value-single></v-select>
250
+ </div>
251
+ <div class="row auto" style="margin: 5px 0">
252
+ <label class="righttxt">表&ensp;&ensp;&ensp;&ensp;向:</label>
253
+ <!--<input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_position" readonly/>-->
254
+ <v-select class="rightipt" :value.sync="userinfo.meterinfo[0].f_aroundmeter"
255
+ v-model="userinfo.meterinfo[0].f_aroundmeter"
256
+ placeholder='请选择'
257
+ :width='wid'
258
+ readonly
259
+ :options="aroundmeters"
260
+ close-on-select value-single></v-select>
261
+ </div>
262
+ <div class="row auto" style="margin: 5px 0">
263
+ <label class="righttxt">气表类型:</label>
264
+ <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_meter_classify" readonly/>
265
+ </div>
266
+ <div class="row auto" style="margin: 5px 0">
267
+ <label class="righttxt">现场表具型号:</label>
268
+ <input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_xc_meter_style"/>
269
+ </div>
270
+ <div class="row auto" style="margin: 5px 0">
271
+ <label class="righttxt">表前阀状态:</label>
272
+ <!--<input type="text" class="form-control rightipt" v-model="userinfo.meterinfo[0].f_position" readonly/>-->
273
+ <v-select class="rightipt" :value.sync="userinfo.meterinfo[0].f_bqf_state"
274
+ v-model="userinfo.meterinfo[0].f_bqf_state"
275
+ placeholder='请选择'
276
+ :width='wid'
277
+ readonly
278
+ :options="bqf_states"
279
+ close-on-select value-single></v-select>
280
+ </div>
281
+ <!-- <div class="row auto" style="margin: 5px 0">
282
+ <div style="display: flex;justify-content: center;">
283
+ <button v-if="userinfo.meterinfo[0].f_meter_classify=='机表'" class="col-sm-3 btn btn-primary" @click="upUserState()">机表关阀停用</button>
284
+ </div>
285
+ </div>-->
286
+ </div>
287
+ </div>
288
+ <div class="panel auto">
289
+ <div class="panel-heading" @click="selectVal('设备信息')" style="background-color: #ffffff">
290
+
291
+ <span class="spanboder"><img src="../../../assets/list.png" style="width: 22px;margin-right: 8px;">设备信息<img
292
+ class="butt3" :src="imgback('设备信息')"></span>
293
+ </div>
294
+ <div class="panel-body" v-show="headername=='设备信息'">
295
+ <div class="row" v-for="row in model"
296
+ style="border:2px solid #A2C2EB; border-top:10px solid #A2C2EB; box-shadow: #00b3ee;margin-bottom: 10px">
297
+ <div class="row auto" style="margin: 5px 0">
298
+ <label class="righttxt">设备类型:</label>
299
+ <!--<input type="text" class="form-control rightipt" readonly v-model="row.f_devices_type" />-->
300
+ <v-select class="rightipt" :value.sync="row.f_devices_type"
301
+ v-model="row.f_devices_type"
302
+ placeholder='请选择'
303
+ :width='wid'
304
+ readonly
305
+ :options="devices_types"
306
+ close-on-select value-single></v-select>
307
+ </div>
308
+ <div class="row auto" style="margin: 5px 0">
309
+ <label class="righttxt">设备品牌:</label>
310
+ <!-- <v-select class="rightipt" :value.sync="row.f_brand"
311
+ v-model="row.f_brand"
312
+ placeholder='请选择'
313
+ :width='wid'
314
+ readonly
315
+ :options="deviceBrandOption[row.f_devices_type]"
316
+ close-on-select value-single></v-select>-->
317
+ <input type="text" class="form-control rightipt"
318
+ v-model="row.f_brand"/>
319
+ </div>
320
+ <div class="row auto" style="margin: 5px 0">
321
+ <label class="righttxt">设备型号:</label><input type="text" class="form-control rightipt"
322
+ v-model="row.f_devices_model"/>
323
+ </div>
324
+ <div class="row auto" style="margin: 5px 0">
325
+ <label class="righttxt">生产日期:</label>
326
+ <!--<input type="text" class="form-control rightipt" v-model="row.f_make_date" />-->
327
+ <datepicker class="rightipt"
328
+ :value.sync="row.f_make_date"
329
+ v-model="row.f_make_date"
330
+ :disabled-days-of-Week="[]"
331
+ :format="'yyyy-MM-dd'"
332
+ :show-reset-button="reset" readonly="readonly">
333
+ </datepicker>
334
+ </div>
335
+ <div class="row auto" style="margin: 5px 0">
336
+ <label class="righttxt">使用年限:</label><input type="number" class="form-control rightipt"
337
+ v-model="row.f_service_life"/>
338
+ </div>
339
+ <!-- <div class="row auto" style="margin: 5px 0">
340
+ <label class="righttxt">到期日期:</label>
341
+ &lt;!&ndash;<input type="text" class="form-control rightipt" v-model="row.f_expire_date" />&ndash;&gt;
342
+ <datepicker class="rightipt"
343
+ :value.sync="row.f_expire_date"
344
+ v-model="row.f_expire_date"
345
+ :disabled-days-of-Week="[]"
346
+ :format="'yyyy-MM-dd'"
347
+ :show-reset-button="reset" readonly="readonly">
348
+ </datepicker>
349
+ </div>-->
350
+ <div class="row auto" style="margin: 5px 0">
351
+ <label class="righttxt">安&ensp;装&ensp;人:</label><input type="text" class="form-control rightipt"
352
+ v-model="row.f_input_person"/>
353
+ </div>
354
+ <div class="row auto" style="margin: 5px 0">
355
+ <label class="righttxt">安装日期:</label>
356
+ <!--<input type="text" class="form-control rightipt" v-model="row.f_input_date" />-->
357
+ <datepicker class="rightipt"
358
+ :value.sync="row.f_input_date"
359
+ v-model="row.f_input_date"
360
+ :disabled-days-of-Week="[]"
361
+ :format="'yyyy-MM-dd'"
362
+ :show-reset-button="reset" readonly="readonly">
363
+ </datepicker>
364
+ </div>
365
+ <div class="row auto" style="margin: 5px 0">
366
+ <label class="righttxt">设备数量:</label><input type="number" class="form-control rightipt"
367
+ v-model="row.f_devices_num"/>
368
+ </div>
369
+ <div class="row auto" style="margin: 5px 0">
370
+ <label class="righttxt">管道类型:</label><input type="text" class="form-control rightipt" v-model="row.f_pipe_type" />
371
+ </div>
372
+ <!--<div class="row auto" style="margin: 5px 0">
373
+ <label class="righttxt">设备状态:</label><input type="text" class="form-control rightipt" readonly v-model="row.f_userinfodevices_state" />
374
+ </div>-->
375
+ <!--<div class="row auto" style="margin: 5px 0">
376
+ <label class="righttxt">购买方式:</label><input type="text" class="form-control rightipt" readonly v-model="row.watchpurchase" />
377
+ </div>-->
378
+ <div style="display: flex;justify-content: center;margin-bottom: 3px"
379
+ v-if="$index>this.userinfo_old.devicesinfo.length-1 || this.userinfo_old.devicesinfo.length==0">
380
+ <button class="btn btn-warning" @click="delDevices($index)">删除设备</button>
381
+ </div>
382
+ </div>
383
+ <div style="display: flex;justify-content: space-around;">
384
+ <button class="col-sm-3 btn btn-primary" @click="addDevices($index)">新增设备</button>
385
+ </div>
386
+ </div>
387
+ </div>
388
+ <div class="panel auto">
389
+ <div class="panel-body">
390
+ <div style="display: flex;justify-content: center;">
391
+ <button class="col-sm-3 btn btn-primary" :disabled="enable"
392
+ @click="isNeedAudit ? editUserInfo() : editUserInfoNoAudit()">{{ isNeedAudit ? '上传审核' : '上传' }}
393
+ </button>
394
+ </div>
395
+ </div>
396
+ </div>
397
+ </div>
398
+ </template>
399
+
400
+ <script>
401
+ import {HttpResetClass} from 'vue-client'
402
+ import * as Util from "../../../components/Util";
403
+ import Vue from 'vue'
404
+
405
+ export default {
406
+ title: '设备查看',
407
+ data() {
408
+ return {
409
+ model: [],
410
+ show: false,
411
+ row: Object,
412
+ userinfo: Object,
413
+ userinfo_old: Object,
414
+ wid: "60%",
415
+ aroundmeters: [],
416
+ devices_types: [],
417
+ pipe_types: [{label: '橡胶管', value: '橡胶管'}, {label: '波纹管', value: '波纹管'}, {label: '钢管', value: '钢管'}],
418
+ wz_types: [],
419
+ cityTypes: [{label: '市区', value: '市区'}, {label: '城镇', value: '城镇'}],
420
+ bqf_states: [{label: '开阀', value: '开阀'}, {label: '关阀', value: '关阀'}],
421
+ pcds: [],
422
+ streets: [],
423
+ update: false,
424
+ headername: '基本信息',
425
+ excessive: false,
426
+ area: [],
427
+ enable: false,
428
+ f_meterno_path: Vue.nopic,
429
+ selectArea: {id: ''},
430
+ selectPcd: {id: ''},
431
+ selectStreet: {id: ''},
432
+ changemeterno: false,//是否修改了机表表号
433
+ approveChange: false,//是否需要进行信息变更审核
434
+ newAddress: '',
435
+ addressType: '',
436
+ //需要审核的字段
437
+ checkField: {
438
+ checkUserinfoField: [
439
+ 'f_user_name'
440
+ ],
441
+ checkUserFilesField: [
442
+ 'f_meternumber'
443
+ ],
444
+ checkAddressField: [
445
+ 'f_pcd_id',
446
+ 'f_street_id',
447
+ 'f_residential_area_id',
448
+ 'f_building',
449
+ 'f_unit',
450
+ 'f_floor',
451
+ 'f_room',
452
+ 'f_slice_area',
453
+ 'f_special',
454
+ 'f_address'
455
+ ],
456
+ },
457
+ boxOptions: [],
458
+ showBox: false,
459
+ directOptions: [{label: '是', value: '是'}, {label: '否', value: '否'}],
460
+ deviceBrandOption: {},
461
+ isNeedAudit: this.$appdata.getSingleValue('信息变更是否需要审核') == 'false' ? false : true,
462
+ detailedAddress:'',
463
+ administrativeDivision:''
464
+
465
+ }
466
+ },
467
+ props: {
468
+ user: {
469
+ type: Object
470
+ },
471
+ f_userinfo_id: '',
472
+ f_source: ''
473
+ },
474
+ methods: {
475
+ getLocation(){
476
+ const location = HostApp.getDetailAddress()
477
+ const longitude = HostApp.getPreference('longitude')
478
+ const latitude = HostApp.getPreference('latitude')
479
+
480
+ new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
481
+ data: {
482
+ items: "*",
483
+ tablename: "t_user_address",
484
+ orderitem: "id",
485
+ condition: `f_lng='${longitude.data}' and f_lat='${latitude.data}' `
486
+ }
487
+ }, {resolveMsg: null, rejectMsg: null}).then((res) => {
488
+ //tag)
489
+ if (res.data.length > 0) {
490
+ this.$showMessage('存在相同的经纬度,请重新定位!', ['confirm', 'cancel'])
491
+ }else{
492
+ this.userinfo.addressinfo.f_lng=longitude.data
493
+ this.userinfo.addressinfo.f_lat=latitude.data
494
+ this.userinfo.addressinfo.f_address=location.data
495
+ const parsed = this.parseAddress(location.data);
496
+ console.log('行政区划部分:', parsed.administrativeDivision);
497
+ this.selectPcd.f_pcd=parsed.administrativeDivision
498
+ this.selectPcd.id=1
499
+ console.log('详细地址部分:', parsed.detailedAddress)
500
+ this.detailedAddress=parsed.detailedAddress
501
+ }
502
+ })
503
+ },
504
+ parseAddress(address) {
505
+ // 匹配省市区县的正则表达式
506
+ const regex = /^(.*?(?:省|自治区|直辖市)?(?:[A-Za-z\u4e00-\u9fa5]*?(?:市))?(?:[A-Za-z\u4e00-\u9fa5]*?(?:区|县|市))?)((?:[A-Za-z\u4e00-\u9fa5\d]|.)*)$/;
507
+
508
+ const match = address.match(regex);
509
+ if (match) {
510
+ return {
511
+ administrativeDivision: match[1].trim(),
512
+ detailedAddress: match[2].trim()
513
+ };
514
+ } else {
515
+ // 备用方案:通过常见后缀分割
516
+ const splitIndex = this.findAdministrativeBoundary(address);
517
+ if (splitIndex > 0) {
518
+ return {
519
+ administrativeDivision: address.substring(0, splitIndex),
520
+ detailedAddress: address.substring(splitIndex)
521
+ };
522
+ }
523
+ }
524
+ // 如果无法分割,返回默认值
525
+ return {
526
+ administrativeDivision: address,
527
+ detailedAddress: ''
528
+ };
529
+ },
530
+ findAdministrativeBoundary(address) {
531
+ // 常见的行政区划后缀
532
+ const suffixes = ['区', '县', '市'];
533
+ // 从后往前查找第一个匹配的后缀
534
+ for (let i = address.length - 1; i >= 0; i--) {
535
+ for (let suffix of suffixes) {
536
+ if (address[i] === suffix &&
537
+ (i < address.length - 1)) {
538
+ return i + 1;
539
+ }
540
+ }
541
+ }
542
+ return -1;
543
+ },
544
+ scan() {
545
+ HostApp.__this__ = this,
546
+ HostApp.scanCode({callback: "javascript:HostApp.__this__.getCode();"})
547
+ },
548
+ getCode() {
549
+ var datapa = HostApp.getCode().data;
550
+ //tag
551
+ this.userinfo.meterinfo[0].f_meternumber = datapa
552
+ },
553
+ //数据检查
554
+ checkVal() {
555
+ //检查一些必要信息是否未填
556
+ this.approveChange = false
557
+ this.changemeterno = false
558
+ let checked = {ischeck: true, msg: ''}
559
+ //tag
560
+ //tag
561
+ //tag
562
+ if (!this.userinfo.baseinfo.base.f_user_name) {
563
+ checked = {ischeck: false, msg: '请输入用户名称!'}
564
+ }
565
+ if (!this.selectPcd.id) {
566
+ checked = {ischeck: false, msg: '请选择省市区!'}
567
+ }
568
+ if (!this.userinfo.addressinfo.f_address) {
569
+ checked = {ischeck: false, msg: '新地址不能为空!'}
570
+ }
571
+ if (this.addressType == '普通地址') {
572
+ if (!this.selectArea.id) {
573
+ checked = {ischeck: false, msg: '请选择集收单位!'}
574
+ }
575
+ if (!this.userinfo.addressinfo.f_room) {
576
+ checked = {ischeck: false, msg: '新输入门牌号!'}
577
+ }
578
+ if (!this.selectStreet.id) {
579
+ checked = {ischeck: false, msg: '请选择街道!'}
580
+ }
581
+ }
582
+ if (this.userinfo.meterinfo[0].f_meter_classify == '机表' && this.userinfo_old.meterinfo[0].f_meternumber) {
583
+
584
+ //tag
585
+ //tag
586
+ if (this.userinfo.meterinfo[0].f_meternumber) {
587
+ if (this.userinfo.meterinfo[0].f_meternumber != this.userinfo_old.meterinfo[0].f_meternumber) {
588
+ if (!this.f_meterno_path || this.f_meterno_path == Vue.nopic) {
589
+ checked = {ischeck: false, msg: '请拍摄表号照片!'}
590
+ } else {
591
+ //用来标识当前有修改机表表号,后台需要进行照片上传
592
+ this.changemeterno = true
593
+ }
594
+ }
595
+ } else {
596
+ checked = {ischeck: false, msg: '请输入表号!'}
597
+ }
598
+ }
599
+ //检查本次修改信息中是否包含需要审核的内容
600
+ for (let check in this.checkField) {
601
+ //tag
602
+ if (typeof check != 'function') {
603
+ for (let i = 0; i < this.checkField[check].length; i++) {
604
+ //tag
605
+ if (check == 'checkUserinfoField') {
606
+ //tag
607
+ //tag
608
+ if (this.userinfo.baseinfo.base[this.checkField[check][i]] != this.userinfo_old.baseinfo.base[this.checkField[check][i]]) {
609
+ //tag
610
+ this.approveChange = true
611
+ }
612
+ } else if (check == 'checkUserFilesField') {
613
+ //tag
614
+ //tag
615
+ if (this.userinfo.meterinfo[0][this.checkField[check][i]] != this.userinfo_old.meterinfo[0][this.checkField[check][i]]) {
616
+ //tag
617
+ this.approveChange = true
618
+ }
619
+ } else if (check == 'checkAddressField') {
620
+ //tag
621
+ //tag
622
+ if (this.userinfo.addressinfo[this.checkField[check][i]] != this.userinfo_old.addressinfo[this.checkField[check][i]]) {
623
+ //tag
624
+ this.approveChange = true
625
+ }
626
+ }
627
+ }
628
+ }
629
+ }
630
+ //tag
631
+ return checked
632
+ },
633
+ select_search(text) {
634
+ //tag
635
+ if (this.selectStreet.id) {
636
+ let pcdText = text ? `and f_street_id=${this.selectStreet.id} and f_residential_area like '%${text}%'` : `and f_street_id=${this.selectStreet.id}`
637
+ new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
638
+ data: {
639
+ items: "*",
640
+ tablename: "t_area",
641
+ orderitem: "id",
642
+ condition: `f_orgid = '${Vue.user.orgid}' ${pcdText} `
643
+ }
644
+ }, {resolveMsg: null, rejectMsg: null}).then((res) => {
645
+ //tag)
646
+ if (res.data.length > 0) {
647
+ this.area = []
648
+ res.data.forEach((result) => {
649
+ this.area.push({label: result.f_residential_area, value: result})
650
+ })
651
+ }
652
+ })
653
+ } else {
654
+ this.area = []
655
+ }
656
+ },
657
+ cameraCallBack(prop, fileName) {
658
+ HostApp.__this__.$set(prop, fileName + '?' + Math.random())
659
+ //tag
660
+ HostApp.__callback__ = null
661
+ HostApp.__this__ = null
662
+ },
663
+ takePic(prop, title) {
664
+ HostApp.__callback__ = this.cameraCallBack
665
+ HostApp.__this__ = this
666
+ //tag
667
+ let fileName
668
+ if (!this[prop] || this[prop].includes("nopic.png")) {
669
+ fileName = Util.guid() + '-' + prop + '.jpg'
670
+ } else {
671
+ fileName = Util.getFileName(this[prop])
672
+ }
673
+ HostApp._open_a_page({
674
+ type: 'boomerang',
675
+ page: 'com.aofeng.hybrid.android.peripheral.CameraActivity',
676
+ param: {
677
+ file: fileName,
678
+ requestCode: 111,
679
+ callback: 'javascript:HostApp.__callback__("' + prop + '", "%s");',
680
+ watermark: title + '\t时间:' + Util.toStandardTimeString() + '\t' + Vue.user.name
681
+ }
682
+ })
683
+ },
684
+ delfile(prop, fileName) {
685
+ if (fileName == Vue.nopic)
686
+ return
687
+ else {
688
+ HostApp.delfile(fileName)
689
+ this[prop] = Vue.nopic
690
+ }
691
+ },
692
+ editUserInfoNoAudit() {
693
+ let checked = this.checkVal()
694
+ if (!checked.ischeck) {
695
+ this.$showMessage(checked.msg)
696
+ return
697
+ }
698
+ for (let i = 0; i < this.model.length; i++) {
699
+ this.model[i].f_user_id = this.userinfo.meterinfo[0].f_user_id
700
+ }
701
+ this.$showMessage('确定是否修改上传用户信息?', ['confirm', 'cancel']).then((res) => {
702
+ if (res === 'confirm') {
703
+ this.userinfo.addressinfo.f_residential_area = this.selectArea.f_residential_area ? this.selectArea.f_residential_area : ''
704
+ this.userinfo.addressinfo.f_residential_area_id = this.selectArea.id ? this.selectArea.id : ''
705
+ this.userinfo.addressinfo.f_slice_area = this.selectArea.f_slice_area ? this.selectArea.f_slice_area : ''
706
+ this.excessive = true
707
+ let address = {}
708
+ address.f_lng=this.userinfo.addressinfo.f_lng
709
+ address.f_lat=this.userinfo.addressinfo.f_lat
710
+ address.f_filialeid = this.userinfo.addressinfo.f_filialeid
711
+ address.f_pcd = this.selectPcd.f_pcd
712
+ address.f_pcd_id = this.selectPcd.id
713
+ address.f_street = this.selectStreet.f_street
714
+ address.f_street_id = this.selectStreet.id
715
+ address.f_slice_area = ''
716
+ address.f_slice_area_id = ''
717
+ address.f_residential_area = this.selectArea.f_residential_area ? '' : this.selectArea.f_residential_area
718
+ address.f_residential_area_id = this.selectArea.id
719
+ address.f_room = this.userinfo.addressinfo.f_room
720
+ address.f_floor = this.userinfo.addressinfo.f_floor
721
+ address.f_unit = this.userinfo.addressinfo.f_unit
722
+ address.f_building = this.userinfo.addressinfo.f_building
723
+ address.f_address = this.userinfo.addressinfo.f_address
724
+ address.f_comments = this.userinfo.addressinfo.f_comments
725
+ address.id = this.userinfo_old.addressinfo.id
726
+ address.oldid = this.userinfo_old.addressinfo.id
727
+ let userinfoms = Object.assign({}, this.userinfo_old.baseinfo.base)
728
+ // userinfoms.f_user_name=row.f_user_name
729
+ userinfoms.f_user_phone = this.userinfo.baseinfo.base.f_user_phone
730
+ userinfoms.f_rent_name = this.userinfo.baseinfo.base.f_rent_name
731
+ userinfoms.f_zuhu_phone = this.userinfo.baseinfo.base.f_zuhu_phone
732
+ userinfoms.f_operator_record = Vue.user.name
733
+ userinfoms.f_operatorid_record = Vue.user.id
734
+ // userinfoms.f_remark = this.userinfo.baseinfo.base.f_remark
735
+ userinfoms.f_orgid_record = Vue.user.orgid
736
+ userinfoms.f_orgname_record = Vue.user.orgs
737
+ userinfoms.f_depid_record = Vue.user.depids
738
+ userinfoms.f_depname_record = Vue.user.deps
739
+ this.userinfo_old.meterinfo[0].f_gas_person = this.userinfo.meterinfo[0].f_gas_person
740
+ this.userinfo_old.meterinfo[0].f_gas_date = this.userinfo.meterinfo[0].f_gas_date
741
+ this.userinfo_old.meterinfo[0].f_adjustable_id = this.userinfo.meterinfo[0].f_adjustable_id
742
+ this.userinfo_old.meterinfo[0].f_metertitles = this.userinfo.meterinfo[0].f_metertitles
743
+ this.userinfo_old.meterinfo[0].f_position = this.userinfo.meterinfo[0].f_position
744
+ this.userinfo_old.meterinfo[0].f_aroundmeter = this.userinfo.meterinfo[0].f_aroundmeter
745
+ this.userinfo_old.meterinfo[0].f_bqf_state = this.userinfo.meterinfo[0].f_bqf_state
746
+ this.userinfo_old.meterinfo[0].f_if_direct = this.userinfo.meterinfo[0].f_if_direct
747
+ this.userinfo_old.meterinfo[0].f_meternumber = this.userinfo.meterinfo[0].f_meternumber
748
+ this.userinfo_old.meterinfo[0].f_xc_meter_style = this.userinfo.meterinfo[0].f_xc_meter_style
749
+ userinfoms.userfiles = []
750
+ this.userinfo_old.meterinfo[0].devicesinfo = this.model
751
+ userinfoms.userfiles.push(this.userinfo_old.meterinfo[0])
752
+ console.log(address)
753
+ new HttpResetClass().load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/fileSave`, {
754
+ data: {
755
+ userinfo: userinfoms,
756
+ modifyReason: this.f_source ? `${this.f_source}维护档案信息` : '',
757
+ address: address
758
+ }
759
+ }, {resolveMsg: null, rejectMsg: null}).then((res1) => {
760
+ if (res1.data.status == 200) {
761
+ let data = this.userinfo.addressinfo
762
+ data.f_address = this.userinfo.addressinfo.f_address ? this.userinfo.addressinfo.f_address : this.userinfo_old.addressinfo.f_address
763
+ data.f_operator = Vue.user.name
764
+ new HttpResetClass().load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/address_updateuseraddress`, {data: data}).then((res2) => {
765
+ this.$showMessage("修改用户信息成功!")
766
+ }).catch(error => {
767
+ this.$showMessage("修改用户信息!")
768
+ })
769
+ this.$showMessage("修改用户信息成功!")
770
+ this.enable = true
771
+ this.excessive = false
772
+ }
773
+ }).catch((msg) => {
774
+ this.$showMessage("修改用户信息失败,请检查手机网络状况!")
775
+ this.excessive = false
776
+ })
777
+ }
778
+ })
779
+ },
780
+ editUserInfo() {
781
+ let checked = this.checkVal()
782
+ if (!checked.ischeck) {
783
+ this.$showMessage(checked.msg)
784
+ return
785
+ }
786
+ this.$showMessage('确定是否修改上传审核用户信息?', ['confirm', 'cancel']).then((res) => {
787
+ if (res === 'confirm') {
788
+ this.userinfo.addressinfo.f_residential_area = this.selectArea.f_residential_area ? this.selectArea.f_residential_area : ''
789
+ this.userinfo.addressinfo.f_residential_area_id = this.selectArea.id ? this.selectArea.id : ''
790
+ this.userinfo.addressinfo.f_slice_area = this.selectArea.f_slice_area ? this.selectArea.f_slice_area : ''
791
+ this.excessive = true
792
+ let address = {}
793
+ address.f_filialeid = this.userinfo.addressinfo.f_filialeid
794
+ address.f_pcd = this.selectPcd.f_pcd
795
+ address.f_pcd_id = this.selectPcd.id
796
+ address.f_street = this.selectStreet.f_street
797
+ address.f_street_id = this.selectStreet.id
798
+ address.f_slice_area = ''
799
+ address.f_slice_area_id = ''
800
+ address.f_residential_area = this.selectArea.f_residential_area ? '' : this.selectArea.f_residential_area
801
+ address.f_residential_area_id = this.selectArea.id
802
+ address.f_room = this.userinfo.addressinfo.f_room
803
+ address.f_floor = this.userinfo.addressinfo.f_floor
804
+ address.f_unit = this.userinfo.addressinfo.f_unit
805
+ address.f_building = this.userinfo.addressinfo.f_building
806
+ address.f_address = this.userinfo.addressinfo.f_address
807
+ address.f_comments = this.userinfo.addressinfo.f_comments
808
+ address.id = this.userinfo_old.addressinfo.id
809
+ address.oldid = this.userinfo_old.addressinfo.id
810
+ let userinfoms = Object.assign({}, this.userinfo_old.baseinfo.base)
811
+ //userinfoms.f_user_name=row.f_user_name
812
+ userinfoms.f_user_phone = this.userinfo.baseinfo.base.f_user_phone
813
+ userinfoms.f_rent_name = this.userinfo.baseinfo.base.f_rent_name
814
+ userinfoms.f_zuhu_phone = this.userinfo.baseinfo.base.f_zuhu_phone
815
+ userinfoms.f_operator_record = Vue.user.name
816
+ userinfoms.f_operatorid_record = Vue.user.id
817
+ // userinfoms.f_remark = this.userinfo.baseinfo.base.f_remark
818
+ userinfoms.f_orgid_record = Vue.user.orgid
819
+ userinfoms.f_orgname_record = Vue.user.orgs
820
+ userinfoms.f_depid_record = Vue.user.depids
821
+ userinfoms.f_depname_record = Vue.user.deps
822
+ this.userinfo_old.meterinfo[0].f_gas_person = this.userinfo.meterinfo[0].f_gas_person
823
+ this.userinfo_old.meterinfo[0].f_gas_date = this.userinfo.meterinfo[0].f_gas_date
824
+ this.userinfo_old.meterinfo[0].f_adjustable_id = this.userinfo.meterinfo[0].f_adjustable_id
825
+ this.userinfo_old.meterinfo[0].f_metertitles = this.userinfo.meterinfo[0].f_metertitles
826
+ this.userinfo_old.meterinfo[0].f_position = this.userinfo.meterinfo[0].f_position
827
+ this.userinfo_old.meterinfo[0].f_aroundmeter = this.userinfo.meterinfo[0].f_aroundmeter
828
+ this.userinfo_old.meterinfo[0].f_bqf_state = this.userinfo.meterinfo[0].f_bqf_state
829
+ this.userinfo_old.meterinfo[0].f_if_direct = this.userinfo.meterinfo[0].f_if_direct
830
+ this.userinfo_old.meterinfo[0].f_meternumber = this.userinfo.meterinfo[0].f_meternumber
831
+ this.userinfo_old.meterinfo[0].f_xc_meter_style = this.userinfo.meterinfo[0].f_xc_meter_style
832
+ userinfoms.userfiles = []
833
+ this.userinfo_old.meterinfo[0].devicesinfo = this.model
834
+ userinfoms.userfiles.push(this.userinfo_old.meterinfo[0])
835
+ //tag)
836
+ console.log(address,'dizhi')
837
+ console.log(userinfoms,'dangan')
838
+ new HttpResetClass().load('POST', `${this.$androidUtil.getProxyUrl()}/rs/logic/fileSave`, {
839
+ data: {
840
+ userinfo: userinfoms,
841
+ modifyReason: this.f_source ? `${this.f_source}维护档案信息` : '',
842
+ address: address
843
+ }
844
+ }, {resolveMsg: null, rejectMsg: null}).then((res1) => {
845
+ //tag+res1.data.status)
846
+ if (res1.data.status == 200) {
847
+ //本次修改信息包含需要审核信息
848
+ if (this.approveChange) {
849
+ //tag
850
+ let res2 = this.$androidUtil.bzLogic('safe_upUserinfoApprove', {
851
+ row: {
852
+ f_time: Util.toStandardTimeString(),
853
+ f_modifier: Vue.user.name,//Vue.user.name
854
+ f_modifier_id: Vue.user.id,//Vue.user.id
855
+ f_modify_type: '用户档案',
856
+ f_userinfoid: this.userinfo.baseinfo.base.f_userinfo_id,
857
+ f_userinfo_code: this.userinfo.baseinfo.base.f_userinfo_code,
858
+ f_approved: '未审核',
859
+ filialestr: Vue.user.orgid,//Vue.user.orgid
860
+ version: 1,
861
+ f_user_name: this.userinfo.baseinfo.base.f_user_name,
862
+ f_user_phone: this.userinfo.baseinfo.base.f_user_phone,
863
+ f_street: this.userinfo.addressinfo.f_street,
864
+ f_building: this.userinfo.addressinfo.f_building,
865
+ f_unit: this.userinfo.addressinfo.f_unit,
866
+ f_floor: this.userinfo.addressinfo.f_floor,
867
+ f_room: this.userinfo.addressinfo.f_room,
868
+ f_building_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_building_suffix,
869
+ f_unit_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_unit_suffix,
870
+ f_floor_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_floor_suffix,
871
+ f_room_suffix: this.userinfo.addressinfo.f_special == 1 ? null : this.userinfo.addressinfo.f_room_suffix,
872
+ f_residential_area: this.userinfo.addressinfo.f_residential_area,
873
+ f_address: this.userinfo.addressinfo.f_address,
874
+ f_comments: this.userinfo.addressinfo.f_comments,
875
+ f_pcd: this.userinfo.addressinfo.f_pcd,
876
+ f_pcd_id: this.userinfo.addressinfo.f_pcd_id,
877
+ f_street_id: this.userinfo.addressinfo.f_street_id,
878
+ f_residential_area_id: this.userinfo.addressinfo.f_residential_area_id,
879
+ f_used_name: this.userinfo.baseinfo.base.f_used_name,
880
+ f_rent_phone: this.userinfo.baseinfo.base.f_rent_phone,
881
+ f_slice_area: this.userinfo.addressinfo.f_slice_area,
882
+ // f_remark: this.userinfo.baseinfo.base.f_remark,
883
+ f_source: this.f_source,
884
+ f_meterno_path: this.f_meterno_path,
885
+ f_iscity: this.userinfo.addressinfo.f_iscity,
886
+ f_special: this.userinfo.addressinfo.f_special,
887
+ f_meternumber: this.userinfo.meterinfo[0].f_meternumber,
888
+ changemeterno: this.changemeterno
889
+ },
890
+ tablename: 't_modify_userinfo'
891
+ })
892
+ //tag)
893
+ if (res2.code == 200) {
894
+ this.$showMessage("变更用户信息成功,需要审核的信息已提交审核,等待管理员处理!")
895
+ this.enable = true
896
+ this.excessive = false
897
+ } else {
898
+ this.$showMessage("上传审核信息失败,请检查图片和网络状况是否正常!")
899
+ this.excessive = false
900
+ }
901
+ } else {
902
+ this.$showMessage("修改用户信息成功!")
903
+ this.enable = true
904
+ this.excessive = false
905
+ }
906
+
907
+ }
908
+ }).catch((msg) => {
909
+ this.$showMessage("修改用户信息失败,请检查手机网络状况!")
910
+ this.excessive = false
911
+ })
912
+
913
+ }
914
+ })
915
+ },
916
+ imgback(header) {
917
+ if (this.headername == header) {
918
+ return require('../../../assets/xiangxia1.png')
919
+ } else {
920
+ return require('../../../assets/xiangyou1.png')
921
+ }
922
+ this.headername = header
923
+ },
924
+ selectVal(header) {
925
+ if (this.headername == header) {
926
+ this.headername = ''
927
+ } else {
928
+ this.headername = header
929
+ }
930
+
931
+ },
932
+ changeNewAddress() {
933
+ this.userinfo.addressinfo.f_address = this.addressType == '普通地址' ? this.getAddress : this.getAddressTS
934
+ },
935
+ area_change() {
936
+ //tag
937
+ this.userinfo.addressinfo.f_residential_area = this.selectArea.f_residential_area
938
+ this.userinfo.addressinfo.f_residential_area_id = this.selectArea.id
939
+ this.userinfo.addressinfo.f_slice_area = this.selectArea.f_slice_area
940
+ this.changeNewAddress()
941
+ //this.userinfo.addressinfo.f_residential_area=this.f_residential_area.f_residential_area
942
+ },
943
+ async street_change() {
944
+ //tag
945
+ if (this.selectStreet.id) {
946
+ //如果街道改变--给街道赋值!
947
+ this.userinfo.addressinfo.f_street = this.selectStreet.f_street
948
+ this.userinfo.addressinfo.f_street_id = this.selectStreet.id
949
+ this.userinfo.addressinfo.f_iscity = this.selectStreet.f_iscity
950
+ //清空当前选中小区的值
951
+ this.userinfo.addressinfo.f_residential_area = ''
952
+ this.userinfo.addressinfo.f_residential_area_id = ''
953
+ this.userinfo.addressinfo.f_slice_area = ''
954
+ this.selectArea = {id: ''}
955
+ this.area = []
956
+ let pcdText = ` and f_street_id=${this.selectStreet.id}`
957
+ let res = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
958
+ data: {
959
+ items: "*",
960
+ tablename: "t_area",
961
+ orderitem: "id",
962
+ condition: `f_orgid = '${Vue.user.orgid}' ${pcdText} `
963
+ }
964
+ }, {resolveMsg: null, rejectMsg: null})
965
+ ////tag)
966
+ res.data.forEach((result) => {
967
+ this.area.push({label: result.f_residential_area, value: result})
968
+ })
969
+ } else {
970
+ this.area = []
971
+ }
972
+
973
+ this.changeNewAddress()
974
+ },
975
+ async pcd_change() {
976
+ //tag
977
+ if (this.selectPcd.id) {
978
+ //tag
979
+ //如果省市区改变-重新赋值
980
+ this.userinfo.addressinfo.f_pcd = this.selectPcd.f_pcd
981
+ this.userinfo.addressinfo.f_pcd_id = this.selectPcd.id
982
+ //清空 选中的街道和集收单位
983
+ this.selectStreet = {id: ''}
984
+ this.userinfo.addressinfo.f_street = ''
985
+ this.userinfo.addressinfo.f_street_id = ''
986
+ this.userinfo.addressinfo.f_iscity = ''
987
+ this.selectArea = {id: ''}
988
+ this.userinfo.addressinfo.f_residential_area = ''
989
+ this.userinfo.addressinfo.f_residential_area_id = ''
990
+ this.userinfo.addressinfo.f_slice_area = ''
991
+ this.streets = []
992
+ let pcdText = `and f_pcd_id=${this.selectPcd.id}`
993
+ let streetlist = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
994
+ data: {
995
+ items: "*",
996
+ tablename: "t_street",
997
+ orderitem: "id",
998
+ condition: `f_orgid = '${Vue.user.orgid}' ${pcdText}`
999
+ }
1000
+ }, {resolveMsg: null, rejectMsg: null})
1001
+ streetlist.data.forEach((result) => {
1002
+ this.streets.push({label: result.f_street, value: result})
1003
+ })
1004
+ } else {
1005
+ this.streets = []
1006
+ }
1007
+ this.changeNewAddress()
1008
+ },
1009
+ upUserState() {
1010
+ //tag)
1011
+ if (this.userinfo.meterinfo[0].f_table_state == '正常') {
1012
+ let data = {
1013
+ f_userfiles_id: {
1014
+ f_userfiles_id: this.userinfo.meterinfo[0].f_userfiles_id,
1015
+ f_table_state: '停用',
1016
+ version: this.userinfo.meterinfo[0].version
1017
+ },
1018
+ f_userfile_id: this.userinfo.meterinfo[0].f_userfiles_id,
1019
+ f_user_id: this.userinfo.meterinfo[0].f_user_id,
1020
+ f_userinfo_id: this.userinfo.meterinfo[0].f_userinfo_id,
1021
+ f_user_name: this.userinfo.baseinfo.base.f_user_name,
1022
+ f_comments: '安检时发现问题关闭阀门',
1023
+ f_othereason: '',
1024
+ f_operat_type: '停用',
1025
+ f_describe: `${Vue.user.name}对客户${this.userinfo.baseinfo.base.f_user_name}进行表具停用操作`,
1026
+ f_state: '有效',
1027
+ f_operator: Vue.user.name,//${Vue.$login.f.name}
1028
+ f_operatorid: Vue.user.id,
1029
+ f_orgid: Vue.user.orgid,
1030
+ f_orgname: Vue.user.orgs,
1031
+ f_depid: Vue.user.depids,
1032
+ f_depname: Vue.user.deps,
1033
+ f_zoneid: Vue.user.zoneid,
1034
+ f_zones: Vue.user.zones
1035
+ }
1036
+ new HttpResetClass().load('post', `${this.$androidUtil.getProxyUrl()}/rs/entity/t_disable`,
1037
+ data, {resolveMsg: null, rejectMsg: null}).then((row) => {
1038
+ this.$showMessage('已成功关阀停气!')
1039
+ this.userinfo.meterinfo[0].f_table_state = '停用'
1040
+ })
1041
+ } else {
1042
+ this.$showMessage('该用户已被关阀停用,请勿重复操作!')
1043
+ }
1044
+
1045
+ },
1046
+ addDevices() {
1047
+ //Vue.user.name
1048
+ let obj = {
1049
+ "f_operator": Vue.user.name,
1050
+ "f_picture": null,
1051
+ "f_pipe_type": null,
1052
+ "f_pipeinstall_date": null,
1053
+ "f_pipe_connection": null,
1054
+ "f_expire_date": null,
1055
+ "f_pipeexpire_date": null,
1056
+ "f_comments": null,
1057
+ "f_operate_date": Util.toStandardTimeString(),
1058
+ "f_operatorid": Vue.user.id,
1059
+ "f_devices_num": null,
1060
+ "f_process_id": null,
1061
+ "f_devices_type": null,
1062
+ "f_make_date": null,
1063
+ "f_input_date": null,
1064
+ "f_state": "有效",
1065
+ "f_brand": null,
1066
+ "f_devices_model": null,
1067
+ "f_devices_no": null,
1068
+ "img": {"content": null, "filename": null}
1069
+ }
1070
+ this.model.push(obj)
1071
+ },
1072
+ delDevices(idx) {
1073
+ //tag
1074
+ this.$showMessage('删除后不可恢复,确认删除吗?', ['confirm', 'cancel']).then((res) => {
1075
+ if (res === 'confirm') {
1076
+ this.model.splice(idx, 1)
1077
+ }
1078
+ })
1079
+ },
1080
+ async getAreaList(text) {
1081
+ if (this.selectStreet.id) {
1082
+ this.area = []
1083
+ let pcdText = text ? `and f_street_id=${this.selectStreet.id} and f_residential_area like '%${text}%'` : `and f_street_id=${this.selectStreet.id}`
1084
+ let res = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1085
+ data: {
1086
+ items: "*",
1087
+ tablename: "t_area",
1088
+ orderitem: "id",
1089
+ condition: `f_orgid = '${Vue.user.orgid}' ${pcdText}`
1090
+ }
1091
+ }, {resolveMsg: null, rejectMsg: null})
1092
+ ////tag)
1093
+ res.data.forEach((result) => {
1094
+ this.area.push({label: result.f_residential_area, value: result})
1095
+ })
1096
+ //tag
1097
+ this.area.push({
1098
+ label: this.userinfo.addressinfo.f_residential_area,
1099
+ value: {
1100
+ id: this.userinfo.addressinfo.f_residential_area_id,
1101
+ f_residential_area: this.userinfo.addressinfo.f_residential_area
1102
+ }
1103
+ })
1104
+ } else {
1105
+ this.area = []
1106
+ }
1107
+
1108
+ },
1109
+ async getStreetList() {
1110
+ if (this.selectPcd.id) {
1111
+ //tag
1112
+ this.streets = []
1113
+ let pcdText = `and f_pcd_id=${this.selectPcd.id}`
1114
+ let streetlist = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1115
+ data: {
1116
+ items: "*",
1117
+ tablename: "t_street",
1118
+ orderitem: "id",
1119
+ condition: `f_orgid = '${Vue.user.orgid}' ${pcdText}`
1120
+ }
1121
+ }, {resolveMsg: null, rejectMsg: null})
1122
+ streetlist.data.forEach((result) => {
1123
+ //如果第一次进来有地址id 就拿下地址区域
1124
+ if (this.selectStreet.id && this.selectStreet.id == result.id) {
1125
+ //tag)
1126
+ this.userinfo.addressinfo.f_iscity = result.f_iscity
1127
+ }
1128
+ this.streets.push({label: result.f_street, value: result})
1129
+ })
1130
+ } else {
1131
+ this.streets = []
1132
+ }
1133
+ },
1134
+ changeAddressType(val) {
1135
+ //tag
1136
+ if (this.addressType == '普通地址') {
1137
+ this.userinfo.addressinfo.f_special = null
1138
+ } else if (this.addressType == '特殊地址') {
1139
+ this.userinfo.addressinfo.f_special = 1
1140
+ this.userinfo.addressinfo.f_building = null
1141
+ this.userinfo.addressinfo.f_unit = null
1142
+ this.userinfo.addressinfo.f_floor = null
1143
+ this.userinfo.addressinfo.f_room = null
1144
+ }
1145
+ this.changeNewAddress()
1146
+ }
1147
+
1148
+ },
1149
+ computed: {
1150
+ getAddress() {
1151
+ return (this.userinfo.addressinfo.f_pcd ? this.userinfo.addressinfo.f_pcd : '') +
1152
+ (this.userinfo.addressinfo.f_street ? this.userinfo.addressinfo.f_street : '') +
1153
+ (this.userinfo.addressinfo.f_residential_area ? this.userinfo.addressinfo.f_residential_area : '') +
1154
+ (this.userinfo.addressinfo.f_building ? this.userinfo.addressinfo.f_building + (this.userinfo.addressinfo.f_building_suffix ? this.userinfo.addressinfo.f_building_suffix : '') : '') +
1155
+ (this.userinfo.addressinfo.f_unit ? this.userinfo.addressinfo.f_unit + (this.userinfo.addressinfo.f_unit_suffix ? this.userinfo.addressinfo.f_unit_suffix : '') : '') +
1156
+ (this.userinfo.addressinfo.f_floor ? this.userinfo.addressinfo.f_floor + (this.userinfo.addressinfo.f_floor_suffix ? this.userinfo.addressinfo.f_floor_suffix : '') : '') +
1157
+ (this.userinfo.addressinfo.f_room ? this.userinfo.addressinfo.f_room + (this.userinfo.addressinfo.f_room_suffix ? this.userinfo.addressinfo.f_room_suffix : '') : '')
1158
+ },
1159
+ getAddressTS() {
1160
+ return (this.userinfo.addressinfo.f_pcd ? this.userinfo.addressinfo.f_pcd : '') +
1161
+ (this.userinfo.addressinfo.f_street ? this.userinfo.addressinfo.f_street : '') +
1162
+ (this.userinfo.addressinfo.f_residential_area ? this.userinfo.addressinfo.f_residential_area : '')+
1163
+ (this.detailedAddress ? this.detailedAddress: '')
1164
+ }
1165
+ },
1166
+ watch: {
1167
+
1168
+ /*'selectPcd.id' (val) {
1169
+ //tag
1170
+ if(this.selectPcd.id){
1171
+ this.getStreetList()
1172
+ }
1173
+ },
1174
+ 'selectStreet.id' (val) {
1175
+ //tag
1176
+ if(this.selectStreet.id){
1177
+ this.getAreaList()
1178
+ }
1179
+ }*/
1180
+ },
1181
+ async ready() {
1182
+ /*//tag)
1183
+
1184
+ //tag)
1185
+ //tag)*/
1186
+ //this.f_userinfo_id=1102260
1187
+ //this.f_userinfo_id=1997541
1188
+ if (!this.f_userinfo_id) {
1189
+ this.$showMessage("未检测到用户!")
1190
+ this.enable = true
1191
+ return
1192
+ }
1193
+ try {
1194
+
1195
+ this.devices_types = Vue.$appdata.getParam('设备类型')
1196
+ console.log('this.devices_types=', JSON.stringify(this.devices_types))
1197
+ for (const devices_type of this.devices_types) {
1198
+ console.log('Vue.$appdata.getParam(`档案设备信息-${devices_type.label}品牌`)=', JSON.stringify(Vue.$appdata.getParam(`档案设备信息-${devices_type.label}品牌`)))
1199
+ this.deviceBrandOption[devices_type.label] = Vue.$appdata.getParam(`档案设备信息-${devices_type.label}品牌`) || []
1200
+ }
1201
+ console.log('this.deviceBrandOption=', JSON.stringify(this.deviceBrandOption))
1202
+ this.wz_types = Vue.$appdata.getParam('安装位置')
1203
+ this.aroundmeters = Vue.$appdata.getParam('左右表')
1204
+
1205
+ ////tag)
1206
+ this.excessive = true
1207
+ //Vue.user.orgid ${this.f_userinfo_id} 10101 ${Vue.user.orgid}
1208
+
1209
+ let pcdlist = await new HttpResetClass().load("POST", `${this.$androidUtil.getProxyUrl()}/rs/sql/safe_singleTable_OrderBy`, {
1210
+ data: {
1211
+ items: "*",
1212
+ tablename: "t_pcd",
1213
+ orderitem: "id",
1214
+ condition: `f_orgid = '${Vue.user.orgid}'`
1215
+ }
1216
+ }, {resolveMsg: null, rejectMsg: null})
1217
+ //tag)
1218
+ pcdlist.data.forEach((result) => {
1219
+ this.pcds.push({label: result.f_pcd, value: result})
1220
+ })
1221
+ ////tag)
1222
+ let res = await new HttpResetClass().load('post', `${this.$androidUtil.getProxyUrl()}/rs/logic/filemanage_getFilesDetail`, {
1223
+ //f_userinfo_code:'12381344',
1224
+ f_userinfo_id: this.f_userinfo_id
1225
+ }, {resolveMsg: null, rejectMsg: null})
1226
+ //tag
1227
+ //tag
1228
+ this.userinfo = res.data
1229
+ this.userinfo_old = JSON.parse(JSON.stringify(res.data))
1230
+ this.model = this.userinfo.meterinfo[0].devicesinfo
1231
+ this.selectArea.id = this.userinfo.addressinfo.f_residential_area_id
1232
+ this.selectPcd.id = this.userinfo.addressinfo.f_pcd_id
1233
+ this.selectPcd.f_pcd = this.userinfo.addressinfo.f_pcd
1234
+ this.selectStreet.id = this.userinfo.addressinfo.f_street_id
1235
+ this.selectStreet.f_street = this.userinfo.addressinfo.f_street
1236
+ await this.getStreetList()
1237
+ await this.getAreaList()
1238
+ this.excessive = false
1239
+ this.addressType = this.userinfo.addressinfo.f_special == 1 ? '特殊地址' : '普通地址'
1240
+ //this.userinfo.addressinfo.f_special=1
1241
+ //tag
1242
+ } catch (e) {
1243
+ this.excessive = false
1244
+ this.enable = true
1245
+ this.$showMessage('获取用户信息出错,请检查网络状况!')
1246
+ }
1247
+ new HttpResetClass().load('get', `${this.$androidUtil.getProxyUrl()}/rs/vue/UserAddress.json`, {data: {}}, {
1248
+ resolveMsg: null,
1249
+ rejectMsg: null
1250
+ }).then((addressUnit) => {
1251
+ //tag
1252
+ //tag
1253
+ //tag
1254
+ //tag
1255
+ this.userinfo.addressinfo.f_building_suffix = addressUnit.data.f_building_suffix
1256
+ this.userinfo.addressinfo.f_unit_suffix = addressUnit.data.f_unit_suffix
1257
+ this.userinfo.addressinfo.f_floor_suffix = addressUnit.data.f_floor_suffix
1258
+ this.userinfo.addressinfo.f_room_suffix = addressUnit.data.f_room_suffix
1259
+ }).catch((msg) => {
1260
+ //tag)
1261
+ })
1262
+ this.showBox = this.$appdata.getSingleValue('档案审核是否显示调压箱') == '是' ? true : false
1263
+ console.log(this.showBox)
1264
+ if (this.showBox) {
1265
+ // 获取调压箱
1266
+ new HttpResetClass().load('post', `${this.$androidUtil.getProxyUrl()}/rs/sql/adjustableboxQuery`, {data: {condition: '1 = 1'}}, {
1267
+ resolveMsg: null,
1268
+ rejectMsg: null
1269
+ }).then((res) => {
1270
+ const boxOptions = []
1271
+ for (const data of res.data) {
1272
+ const one = {
1273
+ label: data.f_adjustable_id + data.f_adjustable_name,
1274
+ value: Number(data.id)
1275
+ }
1276
+ boxOptions.push(one)
1277
+ }
1278
+ this.boxOptions = JSON.parse(JSON.stringify(boxOptions))
1279
+ console.log(this.boxOptions)
1280
+ }).catch((msg) => {
1281
+ //tag)
1282
+ })
1283
+ }
1284
+ }
1285
+ }
1286
+ </script>
1287
+ <style lang="less" scoped>
1288
+ .butt3 {
1289
+ float: right;
1290
+ width: 12px;
1291
+ margin: 1% 2% 0 0;
1292
+ }
1293
+
1294
+ .rightipt {
1295
+ width: 60%;
1296
+ float: left;
1297
+ margin-left: 5%;
1298
+ }
1299
+
1300
+ .righttxt {
1301
+ border: none;
1302
+ margin-left: 5px;
1303
+ /*border-left: 5px solid #A2C2EB;*/
1304
+ float: left;
1305
+ width: 25%;
1306
+ margin-bottom: 3px;
1307
+ text-align: left;
1308
+ word-wrap: break-word;
1309
+ white-space: normal;
1310
+ }
1311
+
1312
+ .tit1 {
1313
+ /*background: #ffffff url('../../../assets/用户姓名.png') no-repeat fixed center;*/
1314
+ background-image: url('../../../assets/用户姓名.png');
1315
+ background-repeat: no-repeat;
1316
+ background-position: center;
1317
+ }
1318
+
1319
+ .spanboder {
1320
+ border-bottom: 2px solid #499edf;
1321
+ padding-bottom: 8px
1322
+ }
1323
+
1324
+ #upuserinfo_sel /deep/ ul {
1325
+ width: 100% !important;
1326
+ left: 0 !important;
1327
+ }
1328
+
1329
+ .btn-photo {
1330
+ border: 0;
1331
+ border-radius: 7px;
1332
+ background-color: #7dc1f4;
1333
+ font: 15px PingFang-SC-Bold;
1334
+ height: 20%;
1335
+ }
1336
+
1337
+ .panel-self {
1338
+ border-radius: 10px;
1339
+ border: 1px solid #499EDF;
1340
+ background-color: #F8F8F8;
1341
+ }
1342
+
1343
+ .div-photo {
1344
+ width: auto;
1345
+ height: auto;
1346
+ /* margin-top: 10px; */
1347
+ position: absolute;
1348
+ bottom: 10px;
1349
+ right: 10px;
1350
+ }
1351
+ </style>
1352
+ <style lang="less">
1353
+ #upuserinfo_sel ul {
1354
+ width: 100% !important;
1355
+ left: 0 !important;
1356
+ }
1357
+ </style>