safecheck-client 3.0.35-gongyi-5 → 3.0.35-gongyi-7

Sign up to get free protection for your applications and to get access to all the features.
@@ -238,6 +238,17 @@
238
238
  close-on-select
239
239
  condition="{}"></v-select>
240
240
 
241
+ </div>
242
+ <div class="col-sm-2 form-group" style="margin-top: 0px">
243
+
244
+ <label class="font_normal_body">抄&ensp;表&ensp;员</label>
245
+ <v-select :value.sync="model.f_inputtor" v-model='model.f_inputtor'
246
+ :value-single="true" style="width: 60%"
247
+ class="select_list select"
248
+ :options='$parent.$parent.meterReader' placeholder='抄&ensp;表&ensp;员'
249
+ close-on-select
250
+ condition="f_inputtor ='{}'"></v-select>
251
+
241
252
  </div>
242
253
  <div class="form-group col-sm-2" style="width: auto;margin-top:8px;float: right" v-if="$parent.$parent.permission === 'c1'">
243
254
 
@@ -446,6 +457,7 @@ export default {
446
457
  "f_check_book_name":'所属安检册'
447
458
  },
448
459
  checkBooks: [],
460
+ meterReader:[],
449
461
  f_orgid: '',
450
462
  bookAll: false,
451
463
  bookCheckedAll:false,
@@ -489,7 +501,7 @@ export default {
489
501
 
490
502
  }
491
503
  },
492
- props:['permission'],
504
+ props:['f_check_book_name'],
493
505
  computed: {
494
506
  getgasbrand(){
495
507
  let ops=[{label:'全部',value:''}]
@@ -522,6 +534,30 @@ export default {
522
534
  }
523
535
  },
524
536
  methods: {
537
+ async getmeterreader(){
538
+ this.meterReader=[]
539
+ let http=new HttpResetClass()
540
+ let getMeterReader = await http.load('pOST',`rs/sql/safe_singleTable_OrderBy`,{
541
+ data:{
542
+ items:'f_inputtor',
543
+ tablename: 't_userfiles',
544
+ condition:`f_orgid = '${this.$login.f.orgid}' and f_inputtor is not null ` + ` group by f_inputtor`,
545
+ orderitem: 'f_inputtor'
546
+ }
547
+ },{resolveMsg:null,rejectMsg:"获取抄表员失败"}).then(res =>{
548
+ this.meterReader = res.data.map(item=>{
549
+ console.log('打印item',item)
550
+ return{
551
+ label : item.f_inputtor,
552
+ value : item.f_inputtor
553
+ }
554
+
555
+ })
556
+ this.meterReader.unshift({label:'全部',value:''})
557
+ }
558
+
559
+ )
560
+ },
525
561
  //片区获取
526
562
  async getSliceArea() {
527
563
  let http = new HttpResetClass()
@@ -923,6 +959,7 @@ export default {
923
959
  ready () {
924
960
  // 获取片区
925
961
  this.getSliceArea()
962
+ this.getmeterreader()
926
963
  // 获取营收气表参数
927
964
  this.setConList()
928
965
  if (this.permission === 'c1'){
@@ -1,122 +1,125 @@
1
- <template>
2
- <div style="width: 100%;height: 100%">
3
- <div class="col-sm-6 form-group" style="margin-bottom: 0px">
4
- <label class="font_normal_body">公&emsp;&emsp;司</label>
5
- <right-tree-safe :width="leftWidth" @re-res="getRes"></right-tree-safe>
6
- </div>
7
- <div class="col-sm-6 form-group" style="margin-bottom: 0px">
8
- <label class="font_normal_body">{{roleLable}}</label>
9
- <v-select :value="changeval" v-model='changeval'
10
- :value-single="!valueMultiple"
11
- class="select_list select"
12
- :options='users' :placeholder='roleName'
13
- close-on-select
14
- :multiple="valueMultiple"
15
- :width="rightWidth"
16
- @change="valuechange">
17
- </v-select>
18
- </div>
19
- </div>
20
- </template>
21
-
22
- <script>
23
- import {HttpResetClass} from 'vue-client'
24
- export default {
25
- name: "RoleSelector",
26
- props: {
27
- valueMultiple: {
28
- type: Boolean,
29
- default: false
30
- },
31
- roleName: {
32
- type: String,
33
- default: '安检员'
34
- },
35
- roleLable: {
36
- type: String,
37
- default: '安检员'
38
- },
39
- leftWidth: {
40
- type: String,
41
- default: '60%'
42
- },
43
- rightWidth: {
44
- type: String,
45
- default: '60%'
46
- },
47
- value: {
48
- default: ''
49
- }
50
- },
51
- data() {
52
- return {
53
- source: `tool.getChildrenOfResName($${this.roleName}$)`,
54
- allUsers: [],
55
- users: [],
56
- resids: [],
57
- changeval: ''
58
- }
59
- },
60
- watch: {
61
- 'value' (val) {
62
- if (val) {
63
- this.changeval = val
64
- }
65
- }
66
- },
67
- ready () {
68
- let http = new HttpResetClass()
69
- http.load('POST', '/rs/search', {data: {source: this.source, userid: this.$login.f.id}}, {resolveMsg: null, rejectMsg: null})
70
- .then(res => {
71
- console.log('res-->' + JSON.stringify(res))
72
- this.allUsers = res.data
73
- this.filterUser(this.resids)
74
-
75
- })
76
- },
77
- methods: {
78
- valuechange(val){
79
- this.changeval = val
80
- if(this.valueMultiple){
81
- if(val&&val.length > 0){
82
- var valuesele = `(`
83
- for (var i= 0;i<val.length;i++) {
84
- valuesele += `'${val[i]}',`
85
- }
86
- this.value = valuesele.substring(0,valuesele.length -1 ) + ')'
87
- }else{
88
- this.value = ''
89
- }
90
- }else{
91
- this.value = val
92
- }
93
- },
94
- getRes(obj) {
95
- this.resids = obj.resids
96
- console.log(this.resids)
97
- this.filterUser(this.resids)
98
- this.$dispatch('re-res',obj)
99
- },
100
- filterUser(resids) {
101
- // 处理第一次进入页面值异常问题
102
- if(resids.length > 0 && typeof resids[0] == "object"){
103
- resids = resids[0]
104
- }
105
- this.users = []
106
- this.allUsers.forEach(user => {
107
- if (resids.indexOf(user.orgid) != -1) {
108
- this.users.push({label: user.name, value: user.name})
109
- }
110
- })
111
- if(this.users.length > 0){
112
- this.users = [{label: '全部', value: ''},...this.users]
113
- }
114
- console.log(this.users)
115
- }
116
- }
117
- }
118
- </script>
119
-
120
- <style scoped>
121
-
122
- </style>
1
+ <template>
2
+ <div style="width: 100%;height: 100%">
3
+ <div class="col-sm-6 form-group" style="margin-bottom: 0px">
4
+ <label class="font_normal_body">公&emsp;&emsp;司</label>
5
+ <right-tree-safe :width="leftWidth" @re-res="getRes"></right-tree-safe>
6
+ </div>
7
+ <div class="col-sm-6 form-group" style="margin-bottom: 0px">
8
+ <label class="font_normal_body">{{roleLable}}</label>
9
+ <v-select :value="changeval" v-model='changeval'
10
+ :value-single="!valueMultiple"
11
+ class="select_list select"
12
+ :options='users' :placeholder='roleName'
13
+ close-on-select
14
+ :multiple="valueMultiple"
15
+ :width="rightWidth"
16
+ @change="valuechange">
17
+ </v-select>
18
+ </div>
19
+ </div>
20
+ </template>
21
+
22
+ <script>
23
+ import {HttpResetClass} from 'vue-client'
24
+ export default {
25
+ name: "RoleSelector",
26
+ props: {
27
+ valueMultiple: {
28
+ type: Boolean,
29
+ default: false
30
+ },
31
+ roleName: {
32
+ type: String,
33
+ default: '安检员'
34
+ },
35
+ roleLable: {
36
+ type: String,
37
+ default: '安检员'
38
+ },
39
+ leftWidth: {
40
+ type: String,
41
+ default: '60%'
42
+ },
43
+ rightWidth: {
44
+ type: String,
45
+ default: '60%'
46
+ },
47
+ value: {
48
+ default: ''
49
+ }
50
+ },
51
+ data() {
52
+ return {
53
+ source: `tool.getChildrenOfResName($${this.roleName}$)`,
54
+ allUsers: [],
55
+ users: [],
56
+ resids: [],
57
+ changeval: ''
58
+ }
59
+ },
60
+ watch: {
61
+ 'value' (val) {
62
+ if (val) {
63
+ this.changeval = val
64
+ }
65
+ }
66
+ },
67
+ ready () {
68
+ let http = new HttpResetClass()
69
+ http.load('POST', '/rs/search', {data: {source: this.source, userid: this.$login.f.id}}, {resolveMsg: null, rejectMsg: null})
70
+ .then(res => {
71
+ console.log('res-->' + JSON.stringify(res))
72
+ this.allUsers = res.data
73
+ this.filterUser(this.resids)
74
+
75
+ })
76
+ },
77
+ methods: {
78
+ valuechange(val){
79
+ if(typeof val =='object' && val.hasOwnProperty('isTrusted')){
80
+ return
81
+ }
82
+ this.changeval = val
83
+ if(this.valueMultiple){
84
+ if(val&&val.length > 0){
85
+ var valuesele = `(`
86
+ for (var i= 0;i<val.length;i++) {
87
+ valuesele += `'${val[i]}',`
88
+ }
89
+ this.value = valuesele.substring(0,valuesele.length -1 ) + ')'
90
+ }else{
91
+ this.value = ''
92
+ }
93
+ }else{
94
+ this.value = val
95
+ }
96
+ },
97
+ getRes(obj) {
98
+ this.resids = obj.resids
99
+ console.log(this.resids)
100
+ this.filterUser(this.resids)
101
+ this.$dispatch('re-res',obj)
102
+ },
103
+ filterUser(resids) {
104
+ // 处理第一次进入页面值异常问题
105
+ if(resids.length > 0 && typeof resids[0] == "object"){
106
+ resids = resids[0]
107
+ }
108
+ this.users = []
109
+ this.allUsers.forEach(user => {
110
+ if (resids.indexOf(user.orgid) != -1) {
111
+ this.users.push({label: user.name, value: user.name})
112
+ }
113
+ })
114
+ if(this.users.length > 0){
115
+ this.users = [{label: '全部', value: ''},...this.users]
116
+ }
117
+ console.log(this.users)
118
+ }
119
+ }
120
+ }
121
+ </script>
122
+
123
+ <style scoped>
124
+
125
+ </style>
@@ -275,7 +275,17 @@
275
275
  >
276
276
  </v-select>
277
277
  </div>
278
+ <div class="col-sm-2 form-group" style="margin-top: 0px">
278
279
 
280
+ <label class="font_normal_body">抄&ensp;表&ensp;员</label>
281
+ <v-select :value.sync="model.f_inputtor" v-model='model.f_inputtor'
282
+ :value-single="true" style="width: 60%"
283
+ class="select_list select"
284
+ :options='$parent.$parent.meterReader' placeholder='抄&ensp;表&ensp;员'
285
+ close-on-select
286
+ condition="uf.f_inputtor ='{}'"></v-select>
287
+
288
+ </div>
279
289
  </div>
280
290
  </div>
281
291
  <div slot="modal-footer" class="modal-footer" style="text-align: center">
@@ -367,6 +377,7 @@
367
377
  opt:[{label:"测试",value:"测试"}],
368
378
  showCondtion:false,
369
379
  userTypes:[],//用户类型
380
+ meterReader:[], //抄表员
370
381
  userStates:[],//用户状态
371
382
  gasproperties:[],//用气性质
372
383
  meter_classifys:[],//气表类型
@@ -393,8 +404,34 @@
393
404
  //this.$refs.paged.$refs.criteria.model.f_hasHousehold='未入户'
394
405
  this.setConList()
395
406
  this.loadpage()
407
+ this.getmeterreader()
396
408
  },
397
409
  methods: {
410
+ async getmeterreader(){
411
+ this.meterReader=[]
412
+ let http=new HttpResetClass()
413
+ let getMeterReader = await http.load('pOST',`rs/sql/safe_singleTable_OrderBy`,{
414
+ data:{
415
+ items:'f_inputtor',
416
+ tablename: 't_userfiles',
417
+ condition:`f_orgid = '${this.$login.f.orgid}' and f_inputtor is not null ` + ` group by f_inputtor`,
418
+ orderitem: 'f_inputtor'
419
+ }
420
+ },{resolveMsg:null,rejectMsg:"获取抄表员失败"}).then(res =>{
421
+ this.meterReader = res.data.map(item=>{
422
+ console.log('打印item',item)
423
+ return{
424
+ label : item.f_inputtor,
425
+ value : item.f_inputtor
426
+ }
427
+
428
+ })
429
+ this.meterReader.unshift({label:'全部',value:''})
430
+ }
431
+
432
+ )
433
+ },
434
+
398
435
  loadpage(){
399
436
  this.select_search()
400
437
  this.Mreadibook()
@@ -456,9 +456,7 @@
456
456
  <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_checker_name }}</td>
457
457
  <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_last_check_date }}</td>
458
458
  <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_last_check_state }}</td>
459
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">
460
- {{row.f_last_check_result }}
461
- </td>
459
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{row.f_last_check_result }}</td>
462
460
  </template>
463
461
  </data-grid>
464
462
  </criteria-paged>
@@ -506,7 +504,7 @@ export default {
506
504
 
507
505
  },
508
506
  excelHeaders: {
509
- //用户编号 用户名称 用户电话 安检次数 用户类型 小区名称 地址 安检日期 安检状态 安检结果
507
+ //用户编号 用户名称 用户电话 安检次数 用户类型 小区名称 地址 安检日期 安检状态 安检结果 气表类型 安装位置 房屋类型
510
508
 
511
509
  'f_userinfo_code': '用户编号',
512
510
  'f_user_name': '用户名称',
@@ -519,7 +517,10 @@ export default {
519
517
  'f_address': '地址',
520
518
  'f_last_check_date': '安检日期',
521
519
  'f_last_check_state': '安检状态',
522
- 'f_last_check_result': '安检结果'
520
+ 'f_last_check_result': '安检结果',
521
+ 'f_position':'安装位置',
522
+ 'F_METER_CLASSIFY':'机表类型',
523
+ 'f_house_type':'房屋类型',
523
524
  },
524
525
  model: new PagedList('rs/sql/根据安检员查询用户档案', 20, {
525
526
  orderitem: "'f_last_check_date'",
@@ -138,9 +138,11 @@
138
138
  <input type="checkbox" id="f_checker_name" value="f_checker_name" v-model="$parent.$parent.nameForSql"/>
139
139
  <label for="f_checker_name">安检员</label>
140
140
  <input type="checkbox" id="f_dep" value="f_dep" v-model="$parent.$parent.nameForSql"/>
141
- <label for="f_plan_name">安检科室</label>
141
+ <label for="f_dep">安检科室</label>
142
142
  <input type="checkbox" id="f_user_number" value="f_user_number" v-model="$parent.$parent.nameForSql"/>
143
- <label for="f_checker_name">档案数量</label>
143
+ <label for="f_user_number">档案数量</label>
144
+ <input type="checkbox" id="f_user_type" value="f_user_type" v-model="$parent.$parent.nameForSql"/>
145
+ <label for="f_user_type">用户类型</label>
144
146
  </div>
145
147
  </div>
146
148
  </div>
@@ -159,6 +161,7 @@
159
161
  <th v-if="$parent.$parent.$parent.nameForSql.includes('f_checker_name')"><nobr>安检员</nobr></th>
160
162
  <th v-if="$parent.$parent.$parent.nameForSql.includes('f_dep')"><nobr>安检科室</nobr></th>
161
163
  <th v-if="$parent.$parent.$parent.nameForSql.includes('f_user_number')"><nobr>档案数量</nobr></th>
164
+ <th v-if="$parent.$parent.$parent.nameForSql.includes('f_user_type')"><nobr>用户类型</nobr></th>
162
165
  <th>
163
166
  <nobr>计划总数</nobr>
164
167
  </th>
@@ -198,6 +201,7 @@
198
201
  <td style="text-align:center" :class="{'td-0':row.f_checker_name==undefined,'td-1':model.rows.length!=($index+1)&&row.f_checker_name.indexOf('*&')==-1,'td-2':model.rows.length!=($index+1)&&row.f_checker_name.indexOf('*&')!=-1,'td-3':model.rows.length==($index+1)&&row.f_checker_name.indexOf('*&')!=-1,'td-4':model.rows.length==($index+1)&&row.f_checker_name.indexOf('*&')==-1}" v-if="$parent.$parent.$parent.nameForSql.includes('f_checker_name')">{{row.f_checker_name.indexOf('*&')!=-1?'':row.f_checker_name}}</td>
199
202
  <td style="text-align:center" v-if="$parent.$parent.$parent.nameForSql.includes('f_dep')">{{row.f_dep}}</td>
200
203
  <td style="text-align:center" v-if="$parent.$parent.$parent.nameForSql.includes('f_user_number')">{{row.f_user_number}}</td>
204
+ <td style="text-align:center" v-if="$parent.$parent.$parent.nameForSql.includes('f_user_type')">{{row.f_user_type}}</td>
201
205
  <td style="text-align:center">{{row.f_plan_total}}</td>
202
206
  <td style="text-align:center">{{row.f_weijian}}</td>
203
207
  <td style="text-align:center"><nobr>{{row.f_yijian}}</nobr></td>
@@ -319,6 +323,8 @@
319
323
  this.exportExcelField.f_checker_name='小区名称'
320
324
  }if (ff==='f_user_number') {
321
325
  this.exportExcelField.f_checker_name='档案数量'
326
+ }if (ff==='f_user_type'){
327
+ this.exportExcelField.f_user_type='用户类型'
322
328
  }
323
329
  }
324
330
  },
@@ -372,6 +378,9 @@
372
378
  if(this.f_dep){
373
379
  args.condition += ` and f_dep = '${this.f_dep}'`
374
380
  }
381
+ if(this.f_user_type){
382
+ args.condition += ` and f_user_type = '${this.f_user_type}'`
383
+ }
375
384
  this.model.f_bv=this.$refs.paged.$refs.cri.model.f_bv?this.$refs.paged.$refs.cri.model.f_bv:''
376
385
  this.model.f_rh=this.$refs.paged.$refs.cri.model.f_rh?this.$refs.paged.$refs.cri.model.f_rh:''
377
386
  this.$refs.paged.$refs.grid.$el.scrollTop = 0
@@ -386,7 +395,7 @@
386
395
 
387
396
  // 拼接groupName1
388
397
  getGroupName1 () {
389
- var temp=['f_plan_month','f_no_checkplan','f_residential_area','f_plan_name','f_checker_name','f_dep','f_user_number']
398
+ var temp=['f_plan_month','f_no_checkplan','f_residential_area','f_plan_name','f_checker_name','f_dep','f_user_number','f_user_type']
390
399
  var newtemp=[]
391
400
 
392
401
  for (var i=0;i<temp.length;i++){
@@ -423,7 +432,7 @@
423
432
  }
424
433
  this.listflag=true
425
434
  console.log(this.model.rows)
426
- var temp=['f_plan_month','f_no_checkplan','f_residential_area','f_plan_name','f_checker_name','f_user_number']
435
+ var temp=['f_plan_month','f_no_checkplan','f_residential_area','f_plan_name','f_checker_name','f_user_number','f_user_type']
427
436
  var newtemp=[]
428
437
  for (var i=0;i<temp.length;i++){
429
438
  for (var j=0;j<this.nameForSql.length;j++){
@@ -147,7 +147,7 @@
147
147
  'f_address':'用户地址',
148
148
  'f_state':'是否已检',
149
149
  'f_entry_status':'安检状态',
150
- 'f_offsite_time':'安检时间',
150
+ 'f_upload_date':'安检时间',
151
151
  'f_defect_content':'隐患状态',
152
152
  'f_check_number':'上报条数'
153
153
  }