sale-client 3.5.140 → 3.5.141

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sale-client",
3
- "version": "3.5.140",
3
+ "version": "3.5.141",
4
4
  "description": "收费模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -45,7 +45,7 @@
45
45
  <div class="form-group col-sm-3">
46
46
  <label class="font_normal_body">表&emsp;&emsp;号</label>
47
47
  <input type="text" class="input_search" style="width:60%" style="width:60%" v-model="model.f_meternumber" placeholder='表号'
48
- condition="f_meternumber like '%{}%'">
48
+ condition="u.f_meternumber like '%{}%'">
49
49
  </div>
50
50
 
51
51
  <!--<div class="form-group col-sm-4">-->
@@ -0,0 +1,783 @@
1
+ <template>
2
+ <div class="flex-row">
3
+ <div class="basic-main" :class="{'basic-main':!selectRow,'binary-left':selectRow}" style="height: 98%;">
4
+ <div class="span">
5
+ <criteria-paged :model='model' v-ref:paged>
6
+ <criteria :model='model' partial='criteria' v-ref:criteria @condition-changed='$parent.search'>
7
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
8
+ <div class="row">
9
+ <res-select-group :initres="$parent.$parent.initres" :show-component="['company','department','operator','slicearea']" @re-res="$parent.$parent.getRes" v-ref:sel></res-select-group>
10
+ <div class="span" style="float:right">
11
+ <button v-if="$parent.$parent.importMeterNumber === '开关阀导入表号'" class="button_new" style="margin-right: 10px" @click="$parent.$parent.showUploadCodeCondition()">导入表号</button>
12
+ <import-excel v-if="$parent.$parent.batchImport === '批量开关阀导入'" template-name="批量开关阀导入Excel模板" logic-name="importBatchValue" import-json="importBatchValue.json"></import-excel>
13
+ <button class="button_search button_spacing" @click="search()" v-el:cba>查询</button>
14
+ <button class="button_clear button_spacing" @click="$parent.$parent.clearmsg">清空</button>
15
+ <label class="font_normal_body" v-if="!$parent.$parent.excelTable">超过十万条限制导出</label>
16
+ <export-excel v-if="$parent.$parent.excelTable"
17
+ class="auto"
18
+ :data="{condition: $parent.$parent.condition}"
19
+ :field="$parent.$parent.getfield"
20
+ sqlurl="rs/logic/saleExport" sql-name="iot_getOpertionList"
21
+ template-name='指令下发'
22
+ :choose-col="true"></export-excel>
23
+ <button class="button_search button_spacing" @click="$parent.$parent.showModal('开阀')">开阀</button>
24
+ <button class="button_search button_spacing" @click="$parent.$parent.showModal('权限关阀')">权限关阀</button>
25
+ <button class="button_search button_spacing" @click="$parent.$parent.showModal('关阀')">关阀</button>
26
+
27
+ <button class="button_search button_spacing" v-if="$parent.$parent.jurisdiction.includes('自动阀控')" v-show="$parent.$parent.famenShow1==='关闭'" @click="$parent.$parent.openzdkf('开启')">开启自动阀控 </button>
28
+
29
+ <button class="button_search button_spacing" v-if="$parent.$parent.jurisdiction.includes('自动阀控')" v-show="$parent.$parent.famenShow1==='开启'" @click="$parent.$parent.openzdkf('关闭')">关闭自动阀控 </button>
30
+
31
+ <!--<button class="button_search" style="width: max-content" @click="$parent.$parent.setRunParam">批量设置参数-->
32
+ <!--</button>-->
33
+ <div style="float: right" class="button_spacing" :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}" @click="$parent.$parent.hidden()"></div>
34
+ </div>
35
+ </div>
36
+ <div class="row" v-show="$parent.$parent.criteriaShow">
37
+ <div class="col-sm-2 ">
38
+ <label class="font_normal_body">表&nbsp;钢&nbsp;号&nbsp;</label>
39
+ <input @keyup.enter="search" style="width:60%" type="text" class="input_search"
40
+ v-model="model.f_meternumber"
41
+ placeholder='表钢号'
42
+ condition="f_meternumber like '%{}%'"
43
+ >
44
+ </div>
45
+ <div class="col-sm-2 ">
46
+ <label class="font_normal_body">客户编号</label>
47
+ <input @keyup.enter="search" style="width:60%" type="text" class="input_search "
48
+ v-model="model.f_userinfo_code"
49
+ placeholder='客户号'
50
+ condition="f_userinfo_code like '%{}%'"
51
+ >
52
+ </div>
53
+ <div class="col-sm-2 ">
54
+ <label class="font_normal_body">客户姓名</label>
55
+ <input @keyup.enter="search" style="width:60%" type="text" class="input_search"
56
+ v-model="model.f_user_name"
57
+ placeholder='客户姓名'
58
+ condition="f_user_name like '%{}%'"
59
+ >
60
+ </div>
61
+
62
+ <div class="col-sm-2 ">
63
+ <label class="font_normal_body">用气地址</label>
64
+ <input @keyup.enter="search" style="width:60%" type="text" class="input_search "
65
+ v-model="model.f_address"
66
+ placeholder='用气地址'
67
+ :size="model.f_address ? model.f_address.length : 6"
68
+ condition="f_address like '%{}%'"
69
+ >
70
+ </div>
71
+ <div class="col-sm-2 ">
72
+ <label class="font_normal_body">小&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;区</label>
73
+ <v-select :value.sync="model.f_residential_area"
74
+ class="select_list select"
75
+ v-model="model.f_residential_area"
76
+ style="width: 60%"
77
+ multiple
78
+ condition="f_residential_area in {}"
79
+ :options='$parent.$parent.residentialArea' placeholder='选择小区'
80
+ close-on-select>
81
+
82
+ </v-select>
83
+ </div>
84
+
85
+ <div class="col-sm-2 ">
86
+ <label class="font_normal_body">客户类型</label>
87
+ <v-select style="width:60%"
88
+ placeholder='客户类型'
89
+ value-single="true"
90
+ :value.sync="model.f_user_type"
91
+ v-model="model.f_user_type"
92
+
93
+ :options='$parent.$parent.userType'
94
+ close-on-select condition="f_user_type ='{}'">
95
+ </v-select>
96
+ </div>
97
+ <div class="col-sm-2 ">
98
+ <label class="font_normal_body">用气性质</label>
99
+ <v-select style="width:60%"
100
+ placeholder='用气性质'
101
+ value-single="true"
102
+ :value.sync="model.f_gasproperties"
103
+ v-model="model.f_gasproperties"
104
+ :options='$parent.$parent.Gasproperties'
105
+ close-on-select condition="f_gasproperties ='{}'">
106
+ </v-select>
107
+ </div>
108
+ <div class="col-sm-2 ">
109
+ <label class="font_normal_body">气表品牌</label>
110
+ <v-select style="width:60%"
111
+ placeholder='气表品牌'
112
+ :value.sync="model.f_meter_brand"
113
+ v-model="model.f_meter_brand"
114
+ :options='$parent.$parent.meterbrand'
115
+ close-on-select
116
+ >
117
+ </v-select>
118
+ </div>
119
+ <!--<div class="col-sm-3 ">
120
+ <label class="font_normal_body">指令状态</label>
121
+ <v-select style="width:60%" :value.sync="model.f_instruct_state" v-model="model.f_instruct_state"
122
+ placeholder='指令状态'
123
+ :options='$parent.$parent.instructState'
124
+ close-on-select
125
+ condition="f_instruct_state = '{}'"></v-select>
126
+ </div>-->
127
+ <!-- <div class="col-sm-3 ">-->
128
+ <!-- <label class="font_normal_body" style="word-break:keep-all;">安装时间</label>-->
129
+ <!-- <datepicker style="width:60%"-->
130
+ <!-- placeholder="起始时间"-->
131
+ <!-- :value.sync="model.f_start_date"-->
132
+ <!-- v-model="model.f_start_date"-->
133
+ <!-- :format="'yyyy-MM-dd HH:mm:ss'"-->
134
+ <!-- condition="f_gas_date > '{}'"-->
135
+ <!-- ></datepicker>-->
136
+ <!-- </div>-->
137
+ <!-- <div class="col-sm-3 ">-->
138
+ <!-- <label class="font_normal_body" style="word-break:keep-all;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;至&nbsp;&nbsp;&nbsp;</label>-->
139
+ <!-- <datepicker placeholder="结束时间"-->
140
+ <!-- style="width:60%"-->
141
+ <!-- :value.sync="model.f_end_date"-->
142
+ <!-- v-model="model.f_end_date"-->
143
+ <!-- :format="'yyyy-MM-dd HH:mm:ss'"-->
144
+ <!-- condition="f_gas_date < '{}'"-->
145
+ <!-- ></datepicker>-->
146
+ <!-- </div>-->
147
+ <div class="col-sm-2 ">
148
+ <label class="font_normal_body">阀门状态</label>
149
+ <!-- @change="$parent.$parent.changeShow"-->
150
+ <v-select style="width:60%" :value.sync="model.f_valvestate" v-model="model.f_valvestate"
151
+ placeholder='全部'
152
+ :options='$parent.$parent.valvestate'
153
+ close-on-select
154
+ condition="f_valvestate = '{}'"></v-select>
155
+ </div>
156
+ <div class="col-sm-2 ">
157
+ <label class="font_normal_body">阀控状态</label>
158
+ <!-- @change="$parent.$parent.changeShow1"-->
159
+ <v-select style="width:60%" :value.sync="model.f_network_valve" v-model="model.f_network_valve"
160
+ placeholder='全部'
161
+ :options='$parent.$parent.f_network_valve'
162
+ close-on-select
163
+ condition="f_network_valve = '{}'"
164
+ ></v-select>
165
+ </div>
166
+ </div>
167
+ </div>
168
+ </criteria>
169
+ <data-grid :model="model" partial='list' v-ref:grid class="list_area table_sy">
170
+ <template partial='head'>
171
+ <tr>
172
+ <th style="text-align:center">
173
+ <nobr>全选</nobr>
174
+ <input @keyup.enter="search" style="width:60%" type="checkbox" v-model='checked1' :checked="$parent.$parent.$parent.checked1"
175
+ @click="$parent.$parent.$parent.checkedALL()">
176
+ </th>
177
+ <th style="text-align:center">
178
+ <nobr>组织机构</nobr>
179
+ </th>
180
+ <th style="text-align:center">
181
+ <nobr>客户号</nobr>
182
+ </th>
183
+ <th style="text-align:center">
184
+ <nobr>客户类型</nobr>
185
+ </th>
186
+ <th style="text-align:center">
187
+ <nobr>用气性质</nobr>
188
+ </th>
189
+ <th style="text-align:center">
190
+ <nobr>客户姓名</nobr>
191
+ </th>
192
+ <th style="text-align:center">
193
+ <nobr>用气地址</nobr>
194
+ </th>
195
+ <th style="text-align:center">
196
+ <nobr>小区</nobr>
197
+ </th>
198
+ <th style="text-align:center">
199
+ <nobr>片区</nobr>
200
+ </th>
201
+ <th style="text-align:center">
202
+ <nobr>安装时间</nobr>
203
+ </th>
204
+ <th style="text-align:center;color:#3c763d">
205
+ <nobr>表钢号</nobr>
206
+ </th>
207
+ <th style="text-align:center">
208
+ <nobr>气表品牌</nobr>
209
+ </th>
210
+ <th style="text-align:center">
211
+ <nobr>表编号</nobr>
212
+ </th>
213
+ <th style="text-align:center">
214
+ <nobr>气表型号</nobr>
215
+ </th>
216
+ <th style="text-align:center">
217
+ <nobr>阀门状态</nobr>
218
+ </th>
219
+ <th style="text-align:center">
220
+ <nobr>阀控状态</nobr>
221
+ </th>
222
+ <!--<th style="text-align:center">
223
+ <nobr>指令状态</nobr>
224
+ </th>-->
225
+
226
+ </tr>
227
+ </template>
228
+ <template partial='body' partial='list' v-ref:grid >
229
+ <tr>
230
+ <td style="text-align:center">
231
+ <input @keyup.enter="search" style="width:60%" type="checkbox" checked="checked" name="opertioninput"
232
+ @click="$parent.$parent.$parent.checked(row)"></td>
233
+ <td style="text-align:center">
234
+ <nobr>{{row.f_orgname}}</nobr>
235
+ </td>
236
+ <td style="text-align:center">
237
+ <nobr>{{row.f_userinfo_code}}</nobr>
238
+ </td>
239
+ <td style="text-align:center">
240
+ <nobr>{{row.f_user_type}}</nobr>
241
+ </td>
242
+ <td style="text-align:center">
243
+ <nobr>{{row.f_gasproperties}}</nobr>
244
+ </td>
245
+ <td style="text-align:center">
246
+ <nobr>{{row.f_user_name}}</nobr>
247
+ </td>
248
+ <td>
249
+ <nobr>{{row.f_address}}</nobr>
250
+ </td>
251
+ <td>
252
+ <nobr>{{row.f_residential_area}}</nobr>
253
+ </td>
254
+ <td>
255
+ <nobr>{{row.f_zones}}</nobr>
256
+ </td>
257
+ <td style="text-align:center">
258
+ <nobr>{{row.f_gas_date}}</nobr>
259
+ </td>
260
+ <td style="text-align:center">
261
+ <nobr>{{row.f_meternumber}}</nobr>
262
+ </td>
263
+ <td style="text-align:center">
264
+ <nobr>{{row.f_meter_brand}}</nobr>
265
+ </td>
266
+ <td style="text-align:center">{{row.f_userfiles_id}}</td>
267
+ <td style="text-align:center">
268
+ <nobr>{{row.f_meter_style}}</nobr>
269
+ </td>
270
+ <td style="text-align:center">
271
+ <nobr>{{row.f_valvestate}}</nobr>
272
+ </td>
273
+ <td style="text-align:center">
274
+ <nobr>{{row.f_network_valve}}</nobr>
275
+ </td>
276
+ <!--<td style="text-align:center">
277
+ <nobr>{{row.f_instruct_state}}</nobr>
278
+ </td>-->
279
+ </tr>
280
+ </template>
281
+ <template partial='foot'></template>
282
+ </data-grid>
283
+ </criteria-paged>
284
+ </div>
285
+ </div>
286
+ <modal :show.sync="batchMeterShow" width="570px" title="文件导入" v-ref:modal large backdrop="false">
287
+ <article slot="modal-body" class="modal-body">
288
+ <file-upload class="my-file-uploader col-sm-9" name="meterNUmberUploadFile" action="rs/file/uploadFile" tagname="确定" multiple v-ref:file></file-upload>
289
+ </article>
290
+ <footer slot="modal-footer" class="modal-footer">
291
+ </footer>
292
+ </modal>
293
+ <div style="height: 98%;width: 40%" class="binary-right" v-if="selectRow">
294
+ <sale-web-meter-operate v-if="selectRow" :row="selectRow" @research = research()></sale-web-meter-operate>
295
+ </div>
296
+ </div>
297
+ <modal :show.sync="isShowUserException" >
298
+ <header slot="modal-header" class="modal-header">
299
+ <button type="button" class="close" @click="close()"><span>&times;</span></button>
300
+ <h4 class="modal-title" align="center">{{val1}}申请备注</h4>
301
+ </header>
302
+ <article slot="modal-body" class="modal-body">
303
+ <div style="padding-left: 8px" v-if="val1=='设置参数'">
304
+ <label class="font_normal_body">参数类型</label>
305
+ <v-select style="width:60%"
306
+ placeholder='参数类型'
307
+ :value.sync="parameterType"
308
+ v-model="parameterType"
309
+ :options='parameterTypeList'
310
+ close-on-select>
311
+ </v-select>
312
+ </div>
313
+ <div class="form-group " style="padding-left: 8px">
314
+ <label class="font_normal_body">申请原因:</label>
315
+ <textarea class="search_area" v-model="f_beizhu" rows="10" cols="75" placeholder="备注信息"></textarea>
316
+ </div>
317
+ </article>
318
+ <footer slot="modal-footer" class="modal-footer">
319
+ <button type="button" class="btn btn-success btn-ln fr" @click='addApprovalValve()'>提交</button>
320
+ <button type="button" class="btn btn-info btn-ln fr" @click='close()'>取消</button>
321
+ </footer>
322
+ </modal>
323
+ </template>
324
+
325
+ <script>
326
+ import {PagedList} from 'vue-client'
327
+ import Vue from 'vue'
328
+ import * as Util from '../../../../../Util'
329
+ import {HttpResetClass} from 'vue-client'
330
+ import axios from 'axios'
331
+
332
+ let fun = (json) => {
333
+ let array = []
334
+ array.push({label: '无', value: undefined})
335
+ for (let i = 0; i < json.length; i++) {
336
+ if (json[i] == null) {
337
+ continue
338
+ }
339
+ array.push({label: json[i], value: json[i]})
340
+ }
341
+ return array
342
+ }
343
+ let readyGen = async function (self) {
344
+ await self.$LoadParams.loadParam()
345
+ self.initQueryParam()
346
+ self.getaddress()
347
+ }
348
+ export default {
349
+ title: '批量开关阀',
350
+ name: 'WebMeterBatchOperationValve',
351
+ data () {
352
+ return {
353
+ famenShow: '', // 是否展示开关阀门按钮
354
+ famenShow1: '', // 阀控状态
355
+ meterbrand: [],
356
+ model: new PagedList('rs/sql/iot_getOpertionList', 20),
357
+ searchshow: false,
358
+ criteriaShow: false,
359
+ condition: '',
360
+ orgcondition: ' and f_orgid = ' + this.$login.f.orgid,
361
+ isShowUserException: false,
362
+ val1: '',
363
+ f_beizhu: '',
364
+ batchImport: '',
365
+ Gasusertype: [],
366
+ Gasproperties: [],
367
+ metermodel: [],
368
+ checked1: true,
369
+ residentialArea: [],
370
+ WarningType: [
371
+ {label: '全部', value: ''}
372
+ ],
373
+ selectRow: '',
374
+ initres: {
375
+ org: [this.$login.f.orgid],
376
+ dep: [],
377
+ user: []
378
+ },
379
+ styles: false,
380
+ excelTable: true,
381
+ getfield: {
382
+ 'f_orgname': '组织机构',
383
+ 'f_userinfo_code': '客户号',
384
+ 'f_user_type': '客户类型',
385
+ 'f_gasproperties': '用气性质',
386
+ 'f_user_name': '客户姓名',
387
+ 'f_address': '用气地址',
388
+ 'f_residential_area': '小区',
389
+ 'f_zones': '片区',
390
+ 'f_gas_date': '安装时间',
391
+ 'f_meternumber': '表钢号',
392
+ 'f_meter_brand': '气表品牌',
393
+ 'f_userfiles_id': '表编号',
394
+ 'f_meter_style': '气表型号',
395
+ 'f_valvestate': '阀门状态'
396
+
397
+ },
398
+ obj: {
399
+ userid: this.$login.f.id,
400
+ source: `tool.getFullTree(this.getRights().where(row.getType() == $organization$))`,
401
+ res: this.$login.f.f_fengongsi,
402
+ resids: this.$login.f.orgid
403
+ },
404
+ // 开关阀权限
405
+ valveLimit: false,
406
+ uploadCodeCondition: '', // 导入表号条件
407
+ batchMeterShow: '', // 导入表号弹框
408
+ importMeterNumber: '', // 开关阀导入权限
409
+ // 设置参数权限
410
+ Setarameterermissions: false,
411
+ parameterType: '',
412
+ map: new Map()
413
+ }
414
+ },
415
+ ready () {
416
+ // this.valveLimit = this.$login.r.includes('开关阀权限')
417
+ // this.Setarameterermissions = this.$login.r.includes('设置参数权限')
418
+ this.$refs.paged.$refs.criteria.model.f_start_date = Util.toStandardDateString() + ' 00:00:00'
419
+ this.$refs.paged.$refs.criteria.model.f_end_date = Util.toStandardDateString() + ' 23:59:59'
420
+ this.$refs.paged.$refs.criteria.search()
421
+ // 初始化气表品牌下拉框
422
+ readyGen(this)
423
+ this.getAuthority()
424
+ },
425
+ events: {
426
+ 'dblclick' (row) {
427
+ console.log('看看这个row', row)
428
+ this.selectRow = row
429
+ },
430
+ 'onFileUpload': async function (file, res) {
431
+ this.iswork = true
432
+ let param = {
433
+ filepath: res.f_downloadpath,
434
+ importJson: this.importJson,
435
+ logicName: this.logicName,
436
+ f_operator: this.$login.f.name,
437
+ f_operatorid: this.$login.f.id,
438
+ f_orgid: this.$login.f.orgid,
439
+ f_orgname: this.$login.f.orgs,
440
+ f_depid: this.$login.f.depids,
441
+ f_depname: this.$login.f.deps
442
+ }
443
+ this.batchMeterShow = false
444
+ let self = this
445
+ try {
446
+ await axios.post('rs/logic/importData',
447
+ {data: param}, {timeout: 10 * 60 * 1000}).then((res) => {
448
+ if (res.data) {
449
+ this.uploadCodeCondition = self.convertToIn(res.data.dataArr)
450
+ this.uploadCodeCondition = ' and f_meternumber in' + this.uploadCodeCondition
451
+ }
452
+ })
453
+ } catch (error) {
454
+ if (error.response) {
455
+ if (error.response.status == 500) {
456
+ this.$showAlert('服务繁忙,请重试!!!', 'danger', 3000)
457
+ } else if (error.response.status == 404) {
458
+ this.$showAlert('服务运行中,请耐心等待后进行重试!!', 'danger', 3000)
459
+ } else {
460
+ this.$showAlert(error.response.data, 'danger', 2000)
461
+ }
462
+ console.log(error.response.data)
463
+ console.log(error.response.status)
464
+ console.log(error.response.headers)
465
+ } else if (error.request) {
466
+ console.log(error.request)
467
+ this.$showAlert(error.request, 'danger', 2000)
468
+ } else {
469
+ console.log('Error', error.message)
470
+ this.$showAlert(error.message, 'danger', 2000)
471
+ }
472
+ this.iswork = false
473
+ }
474
+ this.batchShow = false
475
+ }
476
+ },
477
+ methods: {
478
+ // 数组转in
479
+ convertToIn (val) {
480
+ let temp = ''
481
+ if (val instanceof Array) {
482
+ if (val.length >= 1) {
483
+ temp = '('
484
+ val.forEach((res) => {
485
+ temp += `'${res}',`
486
+ })
487
+ temp = temp.substr(0, temp.length - 1) + ')'
488
+ }
489
+ }
490
+ return temp
491
+ },
492
+ showUploadCodeCondition () {
493
+ this.batchMeterShow = true
494
+ },
495
+ getAuthority () {
496
+ if (this.$login.r.find(value => value == '批量开关阀导入')) {
497
+ this.batchImport = '批量开关阀导入'
498
+ }
499
+ if (this.$login.r.find(value => value == '开关阀导入表号')) {
500
+ this.importMeterNumber = '开关阀导入表号'
501
+ }
502
+ },
503
+ research () {
504
+ this.selectRow = null
505
+ this.$refs.paged.$refs.criteria.search()
506
+ },
507
+ async getaddress () {
508
+ let HttpReset = new HttpResetClass()
509
+ var data = await HttpReset.load('POST', 'rs/sql/manage_getarealist', {
510
+ data: {
511
+ condition: `1=1 and s.f_orgid = '${this.$login.f.orgid}'`
512
+ }
513
+ }, {resolveMsg: null, rejectMsg: '获取小区失败!'})
514
+ console.log('小区', data)
515
+ let house = []
516
+ for (let row of data.data) {
517
+ house.push({label: row.f_residential_area, value: row.f_residential_area})
518
+ }
519
+ this.residentialArea = house
520
+ },
521
+
522
+ initQueryParam () {
523
+ let arr = []
524
+ this.$GetSaleParam.getGasbrand().forEach((item) => {
525
+ let temp = {}
526
+ temp.label = item.label
527
+ temp.value = item.value
528
+ arr.push(temp)
529
+ })
530
+
531
+ this.meterbrand = [{label: '全部', value: ''}, ...arr]
532
+ },
533
+ hidden () {
534
+ this.criteriaShow = !this.criteriaShow
535
+ },
536
+ async search (args) {
537
+ args.condition = `${args.condition} ` + this.orgcondition
538
+ if (this.$refs.paged.$refs.criteria.model.f_meter_brand) {
539
+ if (this.$refs.paged.$refs.criteria.model.f_meter_brand.length > 0) {
540
+ args.condition = `${args.condition} ` + `and f_gasbrand_id = ${this.$refs.paged.$refs.criteria.model.f_meter_brand[0].id}`
541
+ }
542
+ }
543
+ args.condition = `${args.condition} ` + this.uploadCodeCondition
544
+ this.condition = args.condition
545
+ await this.model.search(args.condition, args.model)
546
+
547
+ console.log(this.model.rows)
548
+ console.log(this.model)
549
+ if (this.$refs.paged.$refs.grid.model.rows.length === 0) {
550
+ this.famenShow = ''
551
+ this.famenShow1 = ''
552
+ } else {
553
+ this.famenShow = this.$refs.paged.$refs.criteria.model.f_valvestate[0]
554
+ this.famenShow1 = this.$refs.paged.$refs.criteria.model.f_network_valve[0]
555
+ }
556
+ },
557
+ mapset (array) {
558
+ this.map.clear()
559
+ for (let i = 0; i < array.length; i++) {
560
+ let userid = array[i].f_userfiles_id
561
+ let alias = array[i].f_alias
562
+ let userinfoid = array[i].f_userinfo_id
563
+ let f_orgname = array[i].f_orgname
564
+ let f_orgid = array[i].f_orgid
565
+ let f_meternumber = array[i].f_meternumber
566
+ this.map.set(userid, {id: null, f_user_id: userid, f_alias: alias, f_userinfo_id: userinfoid, f_orgname: f_orgname, f_orgid: f_orgid, f_meternumber: f_meternumber})
567
+ }
568
+ },
569
+ back () {
570
+ this.$parent.msg = ''
571
+ },
572
+ clearmsg () {
573
+ this.$refs.paged.$refs.criteria.model = {}
574
+ // 清空表号
575
+ this.uploadCodeCondition = ''
576
+ },
577
+ clickshow () {
578
+ this.searchshow = !this.searchshow
579
+ },
580
+ getRes (obj) {
581
+ this.orgcondition = obj
582
+ },
583
+ checkedALL () {
584
+ this.checked1 = !this.checked1
585
+ let box = document.getElementsByName('opertioninput')
586
+ for (var i = 0; i < box.length; i++) {
587
+ box[i].checked = this.checked1
588
+ }
589
+ },
590
+ checked (val) {
591
+ let userid = val.f_userfiles_id
592
+ if (this.map.has(userid)) {
593
+ this.map.delete(userid)
594
+ } else {
595
+ this.map.set(userid, {id: null, f_user_id: userid, f_alias: val.f_alias, f_userinfo_id: val.f_userinfo_id, f_orgname: val.f_orgname, f_orgid: val.f_orgid, f_meternumber: val.f_meternumber})
596
+ }
597
+ },
598
+ showModal (val) {
599
+ this.val1 = val
600
+ this.isShowUserException = true
601
+ },
602
+ openzdkf (val) {
603
+ let data = {
604
+ condition: this.condition,
605
+ type: val
606
+ }
607
+ let resolveMsg = ''
608
+ let rejectMsg = ''
609
+ if (val == '开启') {
610
+ resolveMsg = '开启自动阀控成功'
611
+ rejectMsg = '开启自动阀控失败'
612
+ } else {
613
+ resolveMsg = '关闭自动阀控成功'
614
+ rejectMsg = '关闭自动阀控失败'
615
+ }
616
+ this.$resetpost('rs/logic/zdfkall', data, {resolveMsg: resolveMsg, rejectMsg: rejectMsg })
617
+ },
618
+ close () {
619
+ this.isShowUserException = false
620
+ },
621
+ addApprovalValve () {
622
+ let valve = this.val1
623
+ let array = []
624
+ this.map.forEach((value, key, map) => {
625
+ array.push(map.get(key))
626
+ })
627
+ if (valve == '设置参数') {
628
+ if (this.parameterType == '') {
629
+ return
630
+ }
631
+ this.approvalValveControl(valve, this.parameterType[0], array)// parameterType【0】设置运行参数
632
+ } else {
633
+ this.approvalValveControl('阀门控制', valve, array)
634
+ console.log('进入阀门控制')
635
+ }
636
+ this.isShowUserException = false
637
+ },
638
+ setRunParam () {
639
+ this.val1 = '设置参数'
640
+ this.isShowUserException = true
641
+ },
642
+
643
+ approvalValveControl (f_apply_type, f_apply_value, array) {
644
+ console.log('进入阀门指令提交')
645
+ console.log(array)
646
+ let load = new HttpResetClass()
647
+ let self = this
648
+ load.load('POST', 'rs/logic/iot_instructUpdateAndDelect',
649
+ {data: {
650
+ data1: {
651
+ f_apply_type: f_apply_type,
652
+ userid: array,
653
+ nowDate: new Date(),
654
+ f_apply_value: f_apply_value,
655
+ f_apply_beizhu: this.f_beizhu,
656
+ f_apply_operator: Vue.$login.f.name
657
+ },
658
+ data2: {
659
+ userid: array,
660
+ instructtype: f_apply_type,
661
+ isOpen: f_apply_value,
662
+ f_instruct_state: '待发送',
663
+ inputtor: Vue.$login.f.name
664
+ }
665
+ }
666
+ }).then((res) => {
667
+ let count = res.data.count
668
+ let str = `执行完成,总共执行了${array.length}户的申请操作`
669
+ self.$showMessage(str)
670
+ }).catch((res) => {
671
+ this.$showMessage('执行失败,具体失败原因请查看后台日志文件!本次操作已被回滚!')
672
+ })
673
+ }
674
+ /* operationValve(array,valve,instructtype) {
675
+ console.log("批量操作array======", array)
676
+ console.log("批量操作valve======", valve)
677
+ console.log("批量操作 Vue.$login.f.name======", Vue.$login.f.name)
678
+ let load = new HttpResetClass()
679
+ load.load('POST', 'rs/logic/setParameter',
680
+ {data:{
681
+ userid: array,
682
+ instructtype: instructtype,
683
+ isOpen:valve,
684
+ f_instruct_state:'待审核',
685
+ inputtor: Vue.$login.f.name
686
+ }}, {rejectMsg: null, resolveMsg: null}).then((res) => {
687
+ let count = array.length;
688
+ console.log("批量操作 Vue.$login.f.name======", Vue.$login.f.name)
689
+ }).catch((res) => {
690
+ this.$showMessage("执行失败,具体失败原因请查看后台日志文件!本次操作已被回滚!")
691
+ })
692
+ } */
693
+ },
694
+ computed: {
695
+ /* WarningType() {
696
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('气表品牌')]
697
+ }, */
698
+ /* Warningstyle() {
699
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('燃气表型号')]
700
+ }, */
701
+
702
+ MeterTypes () {
703
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('气表类型')]
704
+ },
705
+ TableStates () {
706
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('气表状态')]
707
+ },
708
+ Gasproperties () {
709
+ let rs = []
710
+ if (this.model.model.f_user_type) {
711
+ rs = this.$appdata.getParam(this.model.model.f_user_type[0])
712
+ }
713
+ return rs
714
+ },
715
+ // 界面细节权限
716
+ jurisdiction () {
717
+ console.log('抄表界面细节', this.$login.r)
718
+ return this.$login.r ? this.$login.r : []
719
+ },
720
+ parameterTypeList () {
721
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('设置参数')]
722
+ },
723
+ signtype1 () {
724
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('标记名称')]
725
+ },
726
+ parameterState () {
727
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('标记状态')]
728
+ },
729
+ userType () {
730
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('用户类型')]
731
+ },
732
+ userfilesState () {
733
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('上报状态')]
734
+ },
735
+ valvestate () {
736
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('阀门状态')]
737
+ },
738
+ f_network_valve () {
739
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('阀控状态')]
740
+ },
741
+ instructState () {
742
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('指令状态')]
743
+ }
744
+ },
745
+ watch: {
746
+ 'model.pageIndex' () {
747
+ this.checked1 = false
748
+ this.mapset(this.model.rows)
749
+ this.checkedALL()
750
+ },
751
+ 'model.rows' () {
752
+ this.checked1 = false
753
+ this.mapset(this.model.rows)
754
+ this.checkedALL()
755
+ },
756
+ 'checked1' (val) {
757
+ if (val) {
758
+ this.mapset(this.model.rows)
759
+ } else {
760
+ this.map.clear()
761
+ }
762
+ }
763
+ }
764
+ }
765
+ </script>
766
+
767
+ <style scoped>
768
+ .PanelTR {
769
+ width: 100%;
770
+ height: 40px;
771
+ }
772
+
773
+ .PanelTD {
774
+ width: 5%;
775
+ }
776
+
777
+ .btn-relative {
778
+ position: relative;
779
+ left: 25px;
780
+ top: 15px;
781
+ }
782
+ </style>
783
+
@@ -22,7 +22,10 @@ let specialComp = {
22
22
 
23
23
  // 清零
24
24
  'reset-meter': (resolve) => { require(['./components/newchangemeter/ResetMeter'], resolve) },
25
- 'user-info-detail-manage-new': (resolve) => { require(['./components/common/userinfo_detail/UserInfoDetailManageNew'], resolve) }
25
+
26
+ 'user-info-detail-manage-new': (resolve) => { require(['./components/common/userinfo_detail/UserInfoDetailManageNew'], resolve) },
27
+ // 物联网 批量开关阀
28
+ 'sale-web-meter-batch-operation-valve':(resolve) => { require(['./components/common/userinfo_detail/WebMeterBatchOperationValve'], resolve) }
26
29
 
27
30
  }
28
31
  exports.specialComp = specialComp
@@ -39,7 +39,7 @@
39
39
  <div style="text-align:right;">
40
40
  <!-- <button class="button_search" v-show="row.f_print_state === null" @click="ignitionSheet()">生成点火单</button>-->
41
41
  <!-- <button class="button_search" v-show="row.f_print_state === null" @click="schedule()">生成流程单</button>-->
42
- <button class="button_search" @click="confirm()" :disabled="!(essentialInfo )">确认
42
+ <button class="button_search" @click="confirm()" :disabled="!(essentialInfo && ableConfirm)">确认
43
43
  </button>
44
44
  <button class="button_search" style="width: max-content" v-if="haslimit" @click="limitClick">限购配置</button>
45
45
  <button class="button_clear" @click="cancel()">取消</button>
@@ -148,6 +148,7 @@ export default {
148
148
  showfiles: false,
149
149
  // 子组件验证
150
150
  essentialInfo: false,
151
+ ableConfirm: true,
151
152
  meterInfo: false,
152
153
  printflag: false,
153
154
  // 地址相关属性
@@ -279,6 +280,7 @@ export default {
279
280
  // }
280
281
  },
281
282
  confirm () {
283
+ this.ableConfirm = false
282
284
  this.data.addressinfo.f_address = this.$refs.useressential.addressinfo.f_address
283
285
  this.data.addressinfo.id = this.$refs.useressential.addressinfo.id
284
286
  this.data.oldaddressinfo = this.oldAddress
@@ -295,12 +297,14 @@ export default {
295
297
  this.$FileManageService.fileSave(this.$FileManageService.fileSaveBefore(this.data)).then((res) => {
296
298
  this.savePrintSheet(res.data.result[0])
297
299
  this.$dispatch('success')
300
+ this.ableConfirm = true
298
301
  }).catch((error) => {
299
302
  if (error.status === 603) {
300
303
  this.$error('重复提交')
301
304
  return
302
305
  }
303
306
  this.$dispatch('error', '档案保存', this.data, error)
307
+ this.ableConfirm = true
304
308
  })
305
309
  },
306
310
  convertBase64ToBlob (base64String) {