manage-client 3.2.259 → 3.2.260

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.
@@ -1,466 +1,467 @@
1
- <template>
2
- <div id="unit" class="flex-row">
3
- <div class="basic-main">
4
- <div class="flex" v-if="!show">
5
- <criteria-paged :model="model" v-ref:paged>
6
- <criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:cri>
7
- <div novalidate class="form-horizontal select-overspread container-fluid auto" partial >
8
- <div class="row">
9
- <div class="col-sm-2">
10
- <label class="font_normal_body">&emsp;&emsp;公司</label>
11
- <right-tree @re-res="$parent.$parent.getorg"
12
- :initresid='$parent.$parent.org'></right-tree>
13
- </div>
14
- <div class="col-sm-2 ">
15
- <label for="f_gasproperties"class="font_normal_body">用气性质</label>
16
- <v-select id="f_gasproperties"
17
- style="width:60%"
18
- v-model="model.f_gasproperties"
19
- placeholder='用气性质'
20
- :value.sync="model.f_gasproperties"
21
- :options='$parent.$parent.gasproperties'
22
- condition="f_gasproperties = '{}'"
23
- close-on-select >
24
- </v-select>
25
- </div>
26
- <div class="col-sm-2" >
27
- <label for="f_user_state" class="font_normal_body">客户状态</label>
28
- <v-select :value.sync="model.f_user_state"
29
- v-model="model.f_user_state"
30
- :options='$parent.$parent.userstate' placeholder='请选择'
31
- condition="f_user_state = '{}'"
32
- close-on-select></v-select>
33
- </div>
34
- <div class="col-sm-2 flex-row" style="white-space: nowrap">
35
- <label class="font_normal_body">未购天数</label>
36
- <div class="row">
37
- <input type="text" style="width:30%" class="input_search" v-model="model.diffdaymin"
38
- condition="diffday >= {} " placeholder="">
39
- <label class="font_normal_body"> ≤ x ≤ </label>
40
- <input type="text" style="width:30%" class="input_search" v-model="model.diffdaymax"
41
- condition="diffday <= {} " placeholder="">
42
- </div>
43
-
44
- </div>
45
-
46
- <div class="span" style="float:right;">
47
- <button class="btn button_search" @click="search()">查询</button>
48
- <button class="btn button_clear" @click="$parent.$parent.clear()">清空</button>
49
- <export-excel :data="$parent.$parent.getCondition"
50
- :field="$parent.$parent.getfield"
51
- :footer="$parent.$parent.footer"
52
- :header="$parent.$parent.other"
53
- sqlurl="rs/logic/exportfile"
54
- sql-name="inspectListNew"
55
- template-name='用户稽查导出' :choose-col="true"></export-excel>
56
- <print-data :model="$parent.model" :field="$parent.$parent.getfield" :defaultfield="$parent.$parent.defaultfield" print-name="稽查查询打印" :sumsmodel="$parent.$parent.sumsmodel" ></print-data>
57
- <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>
58
-
59
- </div>
60
- </div>
61
- <div class="row" v-show="$parent.$parent.criteriaShow">
62
- <div class="col-sm-2 form-group">
63
- <label class="font_normal_body">起始时间</label>
64
- <datepicker id="startDate" placeholder="起始时间"
65
- v-model="model.startDate"
66
- style="width:60%"
67
- :value.sync="model.startDate"
68
- :disabled-days-of-Week="[]"
69
- :format="'yyyy-MM-dd'"
70
- :show-reset-button="reset">
71
- </datepicker>
72
- </div>
73
- <div class="col-sm-2 form-group">
74
- <label class="font_normal_body">截止时间</label>
75
- <datepicker id="endDate" placeholder="截止时间"
76
- v-model="model.endDate"
77
- style="width:60%"
78
- :value.sync="model.endDate"
79
- :disabled-days-of-Week="[]"
80
- :format="'yyyy-MM-dd'"
81
- :show-reset-button="reset">
82
- </datepicker>
83
- </div>
84
- <div class="col-sm-2 form-group">
85
- <label class="font_normal_body">小区名称</label>
86
- <input type="text" style="width:60%" class="input_search" v-model="model.f_residential_area"
87
- condition="f_residential_area like '%{}%'" placeholder="小区名称">
88
- </div>
89
- <div class="col-sm-2 form-group">
90
- <label for="f_table_state" class="font_normal_body">&emsp;表状态</label>
91
- <v-select id="f_table_state"
92
- style="width:60%"
93
- v-model="model.f_table_state"
94
- placeholder='表状态'
95
- :value.sync="model.f_table_state"
96
- :options='$parent.$parent.tablestate'
97
- condition="f_table_state = '{}'"
98
- close-on-select >
99
- </v-select>
100
- </div>
101
- <div class="col-sm-2 form-group" >
102
- <label class="font_normal_body">总购次数</label>
103
- <!-- <label class="font_normal_body" v-else>抄表次数</label>-->
104
- <input type="text" style="width:23%" class="input_search" v-model="model.cishumin"
105
- condition="cishu >= {} " placeholder="">
106
- <label class="font_normal_body"> ≤ x ≤ </label>
107
- <input type="text" style="width:23%" class="input_search" v-model="model.cishumax"
108
- condition="cishu <= {} " placeholder="">
109
- </div>
110
- <div class="col-sm-2 form-group">
111
- <label class="font_normal_body" >总购气量</label>
112
- <!-- <label class="font_normal_body" v-if="$parent.$parent.meter_classify === '机表'">总用气量</label>-->
113
- <label class="font_normal_body" v-if="$parent.$parent.meter_classify === '物联网表'">总购金额</label>
114
- <input type="text" style="width:23%" class="input_search" v-model="model.pregasmin"
115
- condition="pregas >= {} " placeholder="">
116
- <label class="font_normal_body"> ≤ x ≤ </label>
117
- <input type="text" style="width:23%" class="input_search" v-model="model.pregasmax"
118
- condition="pregas <= {} " placeholder="">
119
- </div>
120
- <div class="col-sm-2 form-group">
121
- <label class="font_normal_body">总购金额</label>
122
- <input type="text" style="width:23%" class="input_search" v-model="model.pregasmin"
123
- condition="collection >= {} " placeholder="">
124
- <label class="font_normal_body"> ≤ x ≤ </label>
125
- <input type="text" style="width:23%" class="input_search" v-model="model.pregasmax"
126
- condition="collection <= {} " placeholder="">
127
- </div>
128
-
129
- <div class="col-sm-2 form-group">
130
- <label class="font_normal_body">&emsp;&emsp;表号</label>
131
- <input type="text" style="width:60%" class="input_search" v-model="model.f_meternumber"
132
- condition="f_meternumber = '{}'" placeholder='表号'>
133
- </div>
134
- <div class="col-sm-2 form-group">
135
- <label class="font_normal_body">用户类型</label>
136
- <v-select :value.sync="model.f_user_type"
137
- @change="$parent.$parent.userTypeChange()"
138
- :options='$parent.$parent.usertypes' placeholder='请选择' v-model="model.f_user_type"
139
- condition="f_user_type = '{}'"
140
- close-on-select></v-select>
141
- </div>
142
-
143
- <div class="col-sm-2 form-group">
144
- <label class="font_normal_body">客户名称</label>
145
- <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
146
- condition="f_user_name like '%{}%'" placeholder="客户名称">
147
- </div>
148
- <div class="col-sm-2 form-group">
149
- <label class="font_normal_body">客户编号</label>
150
- <input type="text" style="width:60%" class="input_search" v-model="model.f_userinfo_code"
151
- condition="f_userinfo_code = '{}' " placeholder="客户编号">
152
- </div>
153
- <div class="col-sm-2 form-group">
154
- <label class="font_normal_body" title="旧客户编号">档案编号</label>
155
- <input type="text" style="width:60%" class="input_search" v-model="model.f_olduserinfo_code"
156
- condition="f_olduserinfo_code = '{}' " placeholder="档案编号">
157
- </div>
158
- <div class="col-sm-2 form-group">
159
- <label class="font_normal_body">客户地址</label>
160
- <input type="text" style="width:60%" class="input_search" v-model="model.f_address"
161
- condition="f_address like '%{}%'" placeholder='客户地址'>
162
- </div>
163
- <div class="col-sm-2 form-group">
164
- <label class="font_normal_body">客户电话</label>
165
- <input type="text" style="width:60%" class="input_search" v-model="model.f_user_phone"
166
- condition="f_user_phone like '%{}%'" placeholder="客户电话">
167
- </div>
168
- <div class="col-sm-2 form-group">
169
- <label for="startDate" class="font_normal_body">建档开始</label>
170
- <datepicker id="createFileStartDate" placeholder="建档开始日期"
171
- v-model="model.createFileStartDate"
172
- style="width:60%"
173
- :value.sync="model.createFileStartDate"
174
- :format="'yyyy-MM-dd'"
175
- :show-reset-button="true"
176
- condition="f_createfile_date >= '{} 00:00:00'">
177
- </datepicker>
178
- </div>
179
- <div class="col-sm-2 form-group">
180
- <label for="startDate" class="font_normal_body">建档结束</label>
181
- <datepicker id="createFileEndDate" placeholder="建档结束日期" style="width:60%"
182
- v-model="model.createFileEndDate"
183
- :value.sync="model.createFileEndDate"
184
- :format="'yyyy-MM-dd'"
185
- :show-reset-button="true"
186
- condition="f_createfile_date <= '{} 23:59:59'">
187
- </datepicker>
188
- </div>
189
-
190
- </div>
191
-
192
- </div>
193
- </criteria>
194
- <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid>
195
- <template partial='head'>
196
- <tr>
197
- <th><nobr>序号</nobr></th>
198
- <th><nobr>客户名称</nobr></th>
199
- <th><nobr>客户地址</nobr></th>
200
- <th><nobr>客户编号</nobr></th>
201
- <th><nobr>客户电话</nobr></th>
202
- <th><nobr>档案编号</nobr></th>
203
- <th><nobr>表号</nobr></th>
204
- <th><nobr>客户状态</nobr></th>
205
- <th><nobr>建档日期</nobr></th>
206
- <th><nobr>用户类型</nobr></th>
207
- <th><nobr>用气性质</nobr></th>
208
- <th><nobr>表具状态</nobr></th>
209
- <th><nobr>气表品牌</nobr></th>
210
- <th><nobr>气价名称</nobr></th>
211
- <th><nobr>最后购气日期</nobr></th>
212
- <th><nobr>总购气次数</nobr></th>
213
- <!-- <th v-show="$parent.$parent.$parent.meter_classify === '机表'"><nobr>总抄表次数</nobr></th>-->
214
-
215
- <th><nobr>总购气量</nobr></th>
216
- <th><nobr>总购金额</nobr></th>
217
- <!-- <th v-show="$parent.$parent.$parent.meter_classify === '机表'"><nobr>总用气量</nobr></th>-->
218
-
219
- <th><nobr>累计未购气天数</nobr></th>
220
- <!-- <th v-show="$parent.$parent.$parent.meter_classify === '机表'"><nobr>累计未抄表天数</nobr></th>-->
221
- <th><nobr>组织机构</nobr></th>
222
- </tr>
223
- </template>
224
- <template partial='body'>
225
- <td style="text-align: center;"><nobr>{{$index+1}}</nobr></td>
226
- <th style="text-align: center;"><nobr>{{row.f_user_name}}</nobr></th>
227
- <th style="text-align: center;"><nobr>{{row.f_address}}</nobr></th>
228
- <td style="text-align: center;"><nobr>
229
- <span @click="$parent.$parent.$parent.showmsg(row)"><a>{{row.f_userinfo_code}}</a></span>
230
- </nobr> </td>
231
- <td style="text-align: center;"><nobr>{{row.f_user_phone}}</nobr></td>
232
- <td style="text-align: center;"><nobr>{{row.f_olduserinfo_code}}</nobr></td>
233
- <td style="text-align: center;"><nobr>{{row.f_meternumber}}</nobr></td>
234
- <th style="text-align: center;"><nobr>{{row.f_user_state}}</nobr></th>
235
- <th style="text-align: center;"><nobr>{{row.f_createfile_date}}</nobr></th>
236
- <th style="text-align: center;"><nobr>{{row.f_user_type}}</nobr></th>
237
- <th style="text-align: center;"><nobr>{{row.f_gasproperties}}</nobr></th>
238
- <th style="text-align: center;"><nobr>{{row.f_table_state}}</nobr></th>
239
- <th style="text-align: center;"><nobr>{{row.f_meter_brand}}</nobr></th>
240
- <th style="text-align: center;"><nobr>{{row.f_price_name}}</nobr></th>
241
- <th style="text-align: center;"><nobr>{{row.delivery_date}}</nobr></th>
242
-
243
- <th style="text-align: center;"><nobr>{{row.cishu}}</nobr></th>
244
- <th style="text-align: center;"><nobr>{{row.pregas}}</nobr></th>
245
- <th style="text-align: center;"><nobr>{{row.collection}}</nobr></th>
246
- <th style="text-align: center;"><nobr>{{row.diffday}}</nobr></th>
247
- <th style="text-align: center;"><nobr>{{row.f_orgname}}</nobr></th>
248
- </template>
249
- </data-grid>
250
- </criteria-paged>
251
- <table class="table-hover">
252
- <tr style="position: relative;" class="table-bordered">
253
- <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;color: #5CB95C;font-weight: bold">汇总信息</td>
254
- <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">总购气量合计:&emsp;&emsp;{{sumsmodel.pregas}}</td>
255
- <!-- <td v-if="meter_classify === '机表'" style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">总抄表气量合计:&emsp;&emsp;{{sumsmodel.pregas}}</td>-->
256
- <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">总购金额合计:&emsp;&emsp;{{sumsmodel.collection}}</td>
257
- </tr>
258
- </table>
259
- </div>
260
- <div class="flex" v-if="show">
261
- <user-info-detail-manage-new :f_userinfo_id="rowdata.f_userinfo_id" @cancel-main="cancel"></user-info-detail-manage-new>
262
- </div>
263
- </div></div>
264
- </template>
265
- <script>
266
- /**
267
- *用户档案查询列表以及添加操作组件
268
- */
269
- import { PagedList } from 'vue-client'
270
- import Vue from 'vue'
271
- import plugin from 'system-clients/src/plugins/GetLoginInfoService'
272
-
273
- let readySomething = async function (self) {
274
-
275
- self.$refs.paged.$refs.cri.model.endDate = self.$login.toStandardDateString()
276
-
277
- // await self.$refs.paged.$refs.cri.search()
278
- self.sumsmodel = self.$refs.paged.$refs.grid.model.sums
279
- }
280
- export default {
281
- title: '客户稽查',
282
- data () {
283
- return {
284
- other:[],
285
- footer:[],
286
- org:[this.$login.f.orgid],
287
- criteriaShow: false,
288
- // meter_classify:'卡表',
289
- filialeNameStr: null,
290
- filialeCodeStr: `and f_orgid = ${this.$login.f.orgid}`,
291
- userid: this.$login.f.id,
292
- source: `tool.getFullTree(this.getRights().where(row.getType() == $organization$))`,
293
- getfield:{"f_userinfo_code":"客户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号","f_user_name":"客户名称",
294
- "f_user_state":"客户状态","f_user_phone":"客户电话","f_address":"客户地址","f_createfile_date":"建档日期","f_user_type":"用户类型",
295
- "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
296
- "delivery_date":"最后购气日期","cishu":"总购气次数","pregas":"总购气量","collection":"总购金额",
297
- "diffday":"未购气总天数"},
298
- model: new PagedList('rs/sql/inspectListNew', 50,{startDate:'this.model.startDate',endDate:'this.model.endDate'},{pregas: 0,collection: 0}),
299
- rows: null,
300
- //orgid:'',
301
- show:false,
302
- // sqlName:'inspectList',
303
- rowdata:{},
304
- sumsmodel: {},
305
- config: {
306
- defaultPrint: ['f_userinfo_code','f_user_id']
307
- },
308
- defaultfield: [],
309
- }
310
- },
311
- watch:{
312
- // meter_classify(val){
313
- // if (val === '卡表') {
314
- // this.model.url = this.url = 'rs/sql/inspectList'
315
- // this.sqlName = 'inspectList'
316
- // this.getfield = {"f_userinfo_code":"客户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号",
317
- // "f_user_name":"客户名称","f_user_state":"客户状态","f_user_phone":"客户电话","f_address":"客户地址",
318
- // "f_createfile_date":"建档日期","f_user_type":"用户类型",
319
- // "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
320
- // "delivery_date":"最后购气日期","cishu":"总购气次数","pregas":"总购气量",
321
- // "diffday":"累计未购气天数"}
322
- // }else if (val === '机表') {
323
- // this.model.url = this.url = 'rs/sql/handinspectList'
324
- // this.sqlName = 'handinspectList'
325
- // this.getfield = {"f_userinfo_code":"客户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号",
326
- // "f_user_name":"客户名称","f_user_state":"客户状态","f_user_phone":"客户电话","f_address":"客户地址",
327
- // "f_createfile_date":"建档日期","f_user_type":"用户类型",
328
- // "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
329
- // "delivery_date":"最后抄表日期","cishu":"总抄表次数","pregas":"抄表气量",
330
- // "diffday":"累计未抄表天数"}
331
- // } else if (val === '物联网表') {
332
- // this.model.url = this.url = 'rs/sql/getWebMeterList'
333
- // this.sqlName = 'getWebMeterList'
334
- // this.getfield = {"f_userinfo_code":"客户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号",
335
- // "f_user_name":"客户名称","f_user_state":"客户状态","f_user_phone":"客户电话","f_address":"客户地址",
336
- // "f_createfile_date":"建档日期", "f_user_type":"用户类型",
337
- // "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
338
- // "delivery_date":"最后购气日期","cishu":"总购气次数","pregas":"总购金额",
339
- // "diffday":"累计未购气天数"}
340
- // }
341
- // this.clear()
342
- // this.model.rows = []
343
- // for(let key in this.model.sums){
344
- // this.model.sums[key] = 0
345
- // }
346
-
347
- // },
348
- sumsmodel:{
349
- handler: function(val) {
350
- this.getotherfooter();
351
- },
352
- deep: true
353
- }
354
- },
355
- ready () {
356
-
357
- readySomething(this).then(() => {
358
- this.$emit('ready')
359
- }).catch((error) => {
360
- this.$emit('error', error)
361
- })
362
- },
363
- methods: {
364
- getotherfooter(){
365
- // this.$refs.paged.$refs.cri.$refs.exports.otherData=[];
366
- // this.$refs.paged.$refs.cri.$refs.exports.footerData=[];
367
- this.other=[];
368
- this.footer=[];
369
- let exportdata = this.getCondition;
370
- let otherInData=[];
371
- otherInData.push(`导出时间: ${this.$login.toStandardTimeString()}`);
372
- let footerData=[],exportfield=this.getfield;
373
- footerData.push("合计");
374
- let self = this;
375
- for(var field in self.sumsmodel){
376
- footerData.push(`${exportfield[field]}合计:${self.sumsmodel[field]}`);
377
- }
378
- this.footer.push(footerData);
379
- this.other.push(otherInData);
380
- },
381
- getorg (obj) {
382
- if(obj.resids.length>0){
383
- this.filialeCodeStr =" and f_orgid in " + plugin.convertToIn(obj.resids)
384
- }
385
- else{
386
- this.filialeCodeStr= " and f_orgid = " + this.$login.f.orgid
387
- }
388
- },
389
- userTypeChange () {
390
- this.gasproperties=[]
391
- if(this.$refs.paged.$refs.cri.model !==null) {
392
- this.$refs.paged.$refs.cri.model.f_gasproperties=''
393
- this.gasproperties = this.$appdata.getParam(this.$refs.paged.$refs.cri.model.f_user_type[0])
394
- }
395
- else{
396
- this.gasproperties =[{label: '全部', value: ''}]
397
- }
398
- },
399
-
400
- cancel() {
401
- this.show = false
402
- },
403
- showmsg(obj){
404
- this.rowdata=obj
405
- this.show=true
406
- },
407
- search () {
408
- this.$refs.paged.$refs.cri.search()
409
- },
410
- selfSearch (args) {
411
- args.condition = args.condition+ ` ${this.filialeCodeStr}`
412
- this.model.search(args.condition, args.model)
413
- },
414
- hidden(){
415
- this.criteriaShow = !this.criteriaShow
416
- },
417
- clear(){
418
- Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
419
- if(key != 'startDate' && key != 'endDate')
420
- this.$refs.paged.$refs.cri.model[key] = []
421
- })
422
- this.$refs.paged.$refs.cri.model.startDate = this.$login.toStandardDateString()
423
- this.$refs.paged.$refs.cri.model.endDate = this.$login.toStandardDateString()
424
- }
425
- },
426
- computed: {
427
- gasproperties() {
428
- return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('用气性质')]
429
- },
430
- usertypes() {
431
- return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('用户类型')]
432
- },
433
- userstate() {
434
- return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('客户状态')]
435
- },
436
- tablestate () {
437
- return [{label: '全部', value: ''}, ...this.$appdata.getParam('气表状态')]
438
- },
439
- // f_meter_classify(){
440
- // return [{label: '机表', value: '机表'},{label: '卡表', value: '卡表'},{label: '物联网表', value: '物联网表'}]
441
- // // return [{label: '卡表', value: '卡表'}]
442
- // },
443
-
444
- getCondition () {
445
- let result = {
446
- condition: '',
447
- diffDay:' 1=1 ',
448
- startDate: this.$refs.paged.$refs.cri.model.startDate,
449
- endDate: this.$refs.paged.$refs.cri.model.endDate
450
- }
451
- result.condition = this.$refs.paged.$refs.cri.condition + this.filialeCodeStr
452
-
453
- return result
454
- }
455
- }
456
- }
457
- </script>
458
- <style media="screen">
459
- .divtext {
460
- min-width: 50px;
461
- max-width: 200px;
462
- border: 1px solid green;
463
- display: inline-block;
464
- }
465
- </style>
466
-
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div class="basic-main">
4
+ <div class="flex" v-if="!show">
5
+ <criteria-paged :model="model" v-ref:paged>
6
+ <criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:cri>
7
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial >
8
+ <div class="row">
9
+ <div class="col-sm-2">
10
+ <label class="font_normal_body">&emsp;&emsp;公司</label>
11
+ <right-tree @re-res="$parent.$parent.getorg"
12
+ :initresid='$parent.$parent.org'></right-tree>
13
+ </div>
14
+ <div class="col-sm-2 form-group">
15
+ <label class="font_normal_body">用户名称</label>
16
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
17
+ condition="f_user_name like '%{}%'" placeholder="用户名称">
18
+ </div>
19
+ <div class="col-sm-2 form-group">
20
+ <label class="font_normal_body">用户地址</label>
21
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_address"
22
+ condition="f_address like '%{}%'" placeholder='用户地址'>
23
+ </div>
24
+ <div class="col-sm-2 flex-row" style="white-space: nowrap">
25
+ <label class="font_normal_body">未购天数</label>
26
+ <div class="row">
27
+ <input type="text" style="width:30%" class="input_search" v-model="model.diffdaymin"
28
+ condition="diffday >= {} " placeholder="">
29
+ <label class="font_normal_body"> ≤ x ≤ </label>
30
+ <input type="text" style="width:30%" class="input_search" v-model="model.diffdaymax"
31
+ condition="diffday <= {} " placeholder="">
32
+ </div>
33
+
34
+ </div>
35
+
36
+ <div class="span" style="float:right;">
37
+ <button class="btn button_search" @click="search()">查询</button>
38
+ <button class="btn button_clear" @click="$parent.$parent.clear()">清空</button>
39
+ <export-excel :data="$parent.$parent.getCondition"
40
+ :field="$parent.$parent.getfield"
41
+ :footer="$parent.$parent.footer"
42
+ :header="$parent.$parent.other"
43
+ sqlurl="rs/logic/exportfile"
44
+ sql-name="inspectListNew"
45
+ template-name='用户稽查导出' :choose-col="true"></export-excel>
46
+ <print-data :model="$parent.model" :field="$parent.$parent.getfield" :defaultfield="$parent.$parent.defaultfield" print-name="稽查查询打印" :sumsmodel="$parent.$parent.sumsmodel" ></print-data>
47
+ <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>
48
+
49
+ </div>
50
+ </div>
51
+ <div class="row" v-show="$parent.$parent.criteriaShow">
52
+ <div class="col-sm-2 form-group">
53
+ <label class="font_normal_body">起始时间</label>
54
+ <datepicker id="startDate" placeholder="起始时间"
55
+ v-model="model.startDate"
56
+ style="width:60%"
57
+ :value.sync="model.startDate"
58
+ :disabled-days-of-Week="[]"
59
+ :format="'yyyy-MM-dd'"
60
+ :show-reset-button="reset">
61
+ </datepicker>
62
+ </div>
63
+ <div class="col-sm-2 form-group">
64
+ <label class="font_normal_body">截止时间</label>
65
+ <datepicker id="endDate" placeholder="截止时间"
66
+ v-model="model.endDate"
67
+ style="width:60%"
68
+ :value.sync="model.endDate"
69
+ :disabled-days-of-Week="[]"
70
+ :format="'yyyy-MM-dd'"
71
+ :show-reset-button="reset">
72
+ </datepicker>
73
+ </div>
74
+ <div class="col-sm-2 ">
75
+ <label for="f_gasproperties"class="font_normal_body">用气性质</label>
76
+ <v-select id="f_gasproperties"
77
+ style="width:60%"
78
+ v-model="model.f_gasproperties"
79
+ placeholder='用气性质'
80
+ :value.sync="model.f_gasproperties"
81
+ :options='$parent.$parent.gasproperties'
82
+ condition="f_gasproperties = '{}'"
83
+ close-on-select >
84
+ </v-select>
85
+ </div>
86
+ <div class="col-sm-2" >
87
+ <label for="f_user_state" class="font_normal_body">用户状态</label>
88
+ <v-select :value.sync="model.f_user_state"
89
+ v-model="model.f_user_state"
90
+ :options='$parent.$parent.userstate' placeholder='请选择'
91
+ condition="f_user_state = '{}'"
92
+ close-on-select></v-select>
93
+ </div>
94
+ <div class="col-sm-2 form-group">
95
+ <label class="font_normal_body">小区名称</label>
96
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_residential_area"
97
+ condition="f_residential_area like '%{}%'" placeholder="小区名称">
98
+ </div>
99
+ <div class="col-sm-2 form-group">
100
+ <label for="f_table_state" class="font_normal_body">&emsp;表状态</label>
101
+ <v-select id="f_table_state"
102
+ style="width:60%"
103
+ v-model="model.f_table_state"
104
+ placeholder='表状态'
105
+ :value.sync="model.f_table_state"
106
+ :options='$parent.$parent.tablestate'
107
+ condition="f_table_state = '{}'"
108
+ close-on-select >
109
+ </v-select>
110
+ </div>
111
+ <div class="col-sm-2 form-group" >
112
+ <label class="font_normal_body">总购次数</label>
113
+ <!-- <label class="font_normal_body" v-else>抄表次数</label>-->
114
+ <input type="text" style="width:23%" class="input_search" v-model="model.cishumin"
115
+ condition="cishu >= {} " placeholder="">
116
+ <label class="font_normal_body"> ≤ x ≤ </label>
117
+ <input type="text" style="width:23%" class="input_search" v-model="model.cishumax"
118
+ condition="cishu <= {} " placeholder="">
119
+ </div>
120
+ <div class="col-sm-2 form-group">
121
+ <label class="font_normal_body" >总购气量</label>
122
+ <!-- <label class="font_normal_body" v-if="$parent.$parent.meter_classify === '机表'">总用气量</label>-->
123
+ <label class="font_normal_body" v-if="$parent.$parent.meter_classify === '物联网表'">总购金额</label>
124
+ <input type="text" style="width:23%" class="input_search" v-model="model.pregasmin"
125
+ condition="pregas >= {} " placeholder="">
126
+ <label class="font_normal_body"> ≤ x ≤ </label>
127
+ <input type="text" style="width:23%" class="input_search" v-model="model.pregasmax"
128
+ condition="pregas <= {} " placeholder="">
129
+ </div>
130
+ <div class="col-sm-2 form-group">
131
+ <label class="font_normal_body">总购金额</label>
132
+ <input type="text" style="width:23%" class="input_search" v-model="model.pregasmin"
133
+ condition="collection >= {} " placeholder="">
134
+ <label class="font_normal_body"> ≤ x ≤ </label>
135
+ <input type="text" style="width:23%" class="input_search" v-model="model.pregasmax"
136
+ condition="collection <= {} " placeholder="">
137
+ </div>
138
+
139
+ <div class="col-sm-2 form-group">
140
+ <label class="font_normal_body">&emsp;&emsp;表号</label>
141
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_meternumber"
142
+ condition="f_meternumber = '{}'" placeholder='表号'>
143
+ </div>
144
+ <div class="col-sm-2 form-group">
145
+ <label class="font_normal_body">用户类型</label>
146
+ <v-select :value.sync="model.f_user_type"
147
+ @change="$parent.$parent.userTypeChange()"
148
+ :options='$parent.$parent.usertypes' placeholder='请选择' v-model="model.f_user_type"
149
+ condition="f_user_type = '{}'"
150
+ close-on-select></v-select>
151
+ </div>
152
+
153
+
154
+ <div class="col-sm-2 form-group">
155
+ <label class="font_normal_body">用户编号</label>
156
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_userinfo_code"
157
+ condition="f_userinfo_code = '{}' " placeholder="用户编号">
158
+ </div>
159
+ <div class="col-sm-2 form-group">
160
+ <label class="font_normal_body" title="旧用户编号">档案编号</label>
161
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_olduserinfo_code"
162
+ condition="f_olduserinfo_code = '{}' " placeholder="档案编号">
163
+ </div>
164
+ <div class="col-sm-2 form-group">
165
+ <label class="font_normal_body">用户电话</label>
166
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_phone"
167
+ condition="f_user_phone like '%{}%'" placeholder="用户电话">
168
+ </div>
169
+ <div class="col-sm-2 form-group">
170
+ <label for="startDate" class="font_normal_body">建档开始</label>
171
+ <datepicker id="createFileStartDate" placeholder="建档开始日期"
172
+ v-model="model.createFileStartDate"
173
+ style="width:60%"
174
+ :value.sync="model.createFileStartDate"
175
+ :format="'yyyy-MM-dd'"
176
+ :show-reset-button="true"
177
+ condition="f_createfile_date >= '{} 00:00:00'">
178
+ </datepicker>
179
+ </div>
180
+ <div class="col-sm-2 form-group">
181
+ <label for="startDate" class="font_normal_body">建档结束</label>
182
+ <datepicker id="createFileEndDate" placeholder="建档结束日期" style="width:60%"
183
+ v-model="model.createFileEndDate"
184
+ :value.sync="model.createFileEndDate"
185
+ :format="'yyyy-MM-dd'"
186
+ :show-reset-button="true"
187
+ condition="f_createfile_date <= '{} 23:59:59'">
188
+ </datepicker>
189
+ </div>
190
+
191
+ </div>
192
+
193
+ </div>
194
+ </criteria>
195
+ <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid>
196
+ <template partial='head'>
197
+ <tr>
198
+ <th><nobr>序号</nobr></th>
199
+ <th><nobr>用户名称</nobr></th>
200
+ <th><nobr>用户地址</nobr></th>
201
+ <th><nobr>用户编号</nobr></th>
202
+ <th><nobr>用户电话</nobr></th>
203
+ <th><nobr>档案编号</nobr></th>
204
+ <th><nobr>表号</nobr></th>
205
+ <th><nobr>用户状态</nobr></th>
206
+ <th><nobr>建档日期</nobr></th>
207
+ <th><nobr>用户类型</nobr></th>
208
+ <th><nobr>用气性质</nobr></th>
209
+ <th><nobr>表具状态</nobr></th>
210
+ <th><nobr>气表品牌</nobr></th>
211
+ <th><nobr>气价名称</nobr></th>
212
+ <th><nobr>最后购气日期</nobr></th>
213
+ <th><nobr>总购气次数</nobr></th>
214
+ <!-- <th v-show="$parent.$parent.$parent.meter_classify === '机表'"><nobr>总抄表次数</nobr></th>-->
215
+
216
+ <th><nobr>总购气量</nobr></th>
217
+ <th><nobr>总购金额</nobr></th>
218
+ <!-- <th v-show="$parent.$parent.$parent.meter_classify === '机表'"><nobr>总用气量</nobr></th>-->
219
+
220
+ <th><nobr>累计未购气天数</nobr></th>
221
+ <!-- <th v-show="$parent.$parent.$parent.meter_classify === '机表'"><nobr>累计未抄表天数</nobr></th>-->
222
+ <th><nobr>组织机构</nobr></th>
223
+ </tr>
224
+ </template>
225
+ <template partial='body'>
226
+ <td style="text-align: center;"><nobr>{{$index+1}}</nobr></td>
227
+ <th style="text-align: center;"><nobr>{{row.f_user_name}}</nobr></th>
228
+ <th style="text-align: center;"><nobr>{{row.f_address}}</nobr></th>
229
+ <td style="text-align: center;"><nobr>
230
+ <span @click="$parent.$parent.$parent.showmsg(row)"><a>{{row.f_userinfo_code}}</a></span>
231
+ </nobr> </td>
232
+ <td style="text-align: center;"><nobr>{{row.f_user_phone}}</nobr></td>
233
+ <td style="text-align: center;"><nobr>{{row.f_olduserinfo_code}}</nobr></td>
234
+ <td style="text-align: center;"><nobr>{{row.f_meternumber}}</nobr></td>
235
+ <th style="text-align: center;"><nobr>{{row.f_user_state}}</nobr></th>
236
+ <th style="text-align: center;"><nobr>{{row.f_createfile_date}}</nobr></th>
237
+ <th style="text-align: center;"><nobr>{{row.f_user_type}}</nobr></th>
238
+ <th style="text-align: center;"><nobr>{{row.f_gasproperties}}</nobr></th>
239
+ <th style="text-align: center;"><nobr>{{row.f_table_state}}</nobr></th>
240
+ <th style="text-align: center;"><nobr>{{row.f_meter_brand}}</nobr></th>
241
+ <th style="text-align: center;"><nobr>{{row.f_price_name}}</nobr></th>
242
+ <th style="text-align: center;"><nobr>{{row.delivery_date}}</nobr></th>
243
+
244
+ <th style="text-align: center;"><nobr>{{row.cishu}}</nobr></th>
245
+ <th style="text-align: center;"><nobr>{{row.pregas}}</nobr></th>
246
+ <th style="text-align: center;"><nobr>{{row.collection}}</nobr></th>
247
+ <th style="text-align: center;"><nobr>{{row.diffday}}</nobr></th>
248
+ <th style="text-align: center;"><nobr>{{row.f_orgname}}</nobr></th>
249
+ </template>
250
+ </data-grid>
251
+ </criteria-paged>
252
+ <table class="table-hover">
253
+ <tr style="position: relative;" class="table-bordered">
254
+ <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;color: #5CB95C;font-weight: bold">汇总信息</td>
255
+ <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">总购气量合计:&emsp;&emsp;{{sumsmodel.pregas}}</td>
256
+ <!-- <td v-if="meter_classify === '机表'" style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">总抄表气量合计:&emsp;&emsp;{{sumsmodel.pregas}}</td>-->
257
+ <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">总购金额合计:&emsp;&emsp;{{sumsmodel.collection}}</td>
258
+ </tr>
259
+ </table>
260
+ </div>
261
+ <div class="flex" v-if="show">
262
+ <user-info-detail-manage-new :f_userinfo_id="rowdata.f_userinfo_id" @cancel-main="cancel"></user-info-detail-manage-new>
263
+ </div>
264
+ </div></div>
265
+ </template>
266
+ <script>
267
+ /**
268
+ *用户档案查询列表以及添加操作组件
269
+ */
270
+ import { PagedList } from 'vue-client'
271
+ import Vue from 'vue'
272
+ import plugin from 'system-clients/src/plugins/GetLoginInfoService'
273
+
274
+ let readySomething = async function (self) {
275
+
276
+ self.$refs.paged.$refs.cri.model.endDate = self.$login.toStandardDateString()
277
+
278
+ // await self.$refs.paged.$refs.cri.search()
279
+ self.sumsmodel = self.$refs.paged.$refs.grid.model.sums
280
+ }
281
+ export default {
282
+ title: '用户稽查',
283
+ data () {
284
+ return {
285
+ other:[],
286
+ footer:[],
287
+ org:[this.$login.f.orgid],
288
+ criteriaShow: false,
289
+ // meter_classify:'卡表',
290
+ filialeNameStr: null,
291
+ filialeCodeStr: `and f_orgid = ${this.$login.f.orgid}`,
292
+ userid: this.$login.f.id,
293
+ source: `tool.getFullTree(this.getRights().where(row.getType() == $organization$))`,
294
+ getfield:{"f_userinfo_code":"用户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号","f_user_name":"用户名称",
295
+ "f_user_state":"用户状态","f_user_phone":"用户电话","f_address":"用户地址","f_createfile_date":"建档日期","f_user_type":"用户类型",
296
+ "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
297
+ "delivery_date":"最后购气日期","cishu":"总购气次数","pregas":"总购气量","collection":"总购金额",
298
+ "diffday":"未购气总天数"},
299
+ model: new PagedList('rs/sql/inspectListNew', 50,{startDate:'this.model.startDate',endDate:'this.model.endDate'},{pregas: 0,collection: 0}),
300
+ rows: null,
301
+ //orgid:'',
302
+ show:false,
303
+ // sqlName:'inspectList',
304
+ rowdata:{},
305
+ sumsmodel: {},
306
+ config: {
307
+ defaultPrint: ['f_userinfo_code','f_user_id']
308
+ },
309
+ defaultfield: [],
310
+ }
311
+ },
312
+ watch:{
313
+ // meter_classify(val){
314
+ // if (val === '卡表') {
315
+ // this.model.url = this.url = 'rs/sql/inspectList'
316
+ // this.sqlName = 'inspectList'
317
+ // this.getfield = {"f_userinfo_code":"用户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号",
318
+ // "f_user_name":"用户名称","f_user_state":"用户状态","f_user_phone":"用户电话","f_address":"用户地址",
319
+ // "f_createfile_date":"建档日期","f_user_type":"用户类型",
320
+ // "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
321
+ // "delivery_date":"最后购气日期","cishu":"总购气次数","pregas":"总购气量",
322
+ // "diffday":"累计未购气天数"}
323
+ // }else if (val === '机表') {
324
+ // this.model.url = this.url = 'rs/sql/handinspectList'
325
+ // this.sqlName = 'handinspectList'
326
+ // this.getfield = {"f_userinfo_code":"用户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号",
327
+ // "f_user_name":"用户名称","f_user_state":"用户状态","f_user_phone":"用户电话","f_address":"用户地址",
328
+ // "f_createfile_date":"建档日期","f_user_type":"用户类型",
329
+ // "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
330
+ // "delivery_date":"最后抄表日期","cishu":"总抄表次数","pregas":"抄表气量",
331
+ // "diffday":"累计未抄表天数"}
332
+ // } else if (val === '物联网表') {
333
+ // this.model.url = this.url = 'rs/sql/getWebMeterList'
334
+ // this.sqlName = 'getWebMeterList'
335
+ // this.getfield = {"f_userinfo_code":"用户编号","f_olduserinfo_code":"档案编号","f_meternumber":"表号",
336
+ // "f_user_name":"用户名称","f_user_state":"用户状态","f_user_phone":"用户电话","f_address":"用户地址",
337
+ // "f_createfile_date":"建档日期", "f_user_type":"用户类型",
338
+ // "f_gasproperties":"用气性质","f_table_state":"表具状态","f_meter_brand":"气表品牌","f_price_name":"气价名称",
339
+ // "delivery_date":"最后购气日期","cishu":"总购气次数","pregas":"总购金额",
340
+ // "diffday":"累计未购气天数"}
341
+ // }
342
+ // this.clear()
343
+ // this.model.rows = []
344
+ // for(let key in this.model.sums){
345
+ // this.model.sums[key] = 0
346
+ // }
347
+
348
+ // },
349
+ sumsmodel:{
350
+ handler: function(val) {
351
+ this.getotherfooter();
352
+ },
353
+ deep: true
354
+ }
355
+ },
356
+ ready () {
357
+
358
+ readySomething(this).then(() => {
359
+ this.$emit('ready')
360
+ }).catch((error) => {
361
+ this.$emit('error', error)
362
+ })
363
+ },
364
+ methods: {
365
+ getotherfooter(){
366
+ // this.$refs.paged.$refs.cri.$refs.exports.otherData=[];
367
+ // this.$refs.paged.$refs.cri.$refs.exports.footerData=[];
368
+ this.other=[];
369
+ this.footer=[];
370
+ let exportdata = this.getCondition;
371
+ let otherInData=[];
372
+ otherInData.push(`导出时间: ${this.$login.toStandardTimeString()}`);
373
+ let footerData=[],exportfield=this.getfield;
374
+ footerData.push("合计");
375
+ let self = this;
376
+ for(var field in self.sumsmodel){
377
+ footerData.push(`${exportfield[field]}合计:${self.sumsmodel[field]}`);
378
+ }
379
+ this.footer.push(footerData);
380
+ this.other.push(otherInData);
381
+ },
382
+ getorg (obj) {
383
+ if(obj.resids.length>0){
384
+ this.filialeCodeStr =" and f_orgid in " + plugin.convertToIn(obj.resids)
385
+ }
386
+ else{
387
+ this.filialeCodeStr= " and f_orgid = " + this.$login.f.orgid
388
+ }
389
+ },
390
+ userTypeChange () {
391
+ this.gasproperties=[]
392
+ if(this.$refs.paged.$refs.cri.model !==null) {
393
+ this.$refs.paged.$refs.cri.model.f_gasproperties=''
394
+ this.gasproperties = this.$appdata.getParam(this.$refs.paged.$refs.cri.model.f_user_type[0])
395
+ }
396
+ else{
397
+ this.gasproperties =[{label: '全部', value: ''}]
398
+ }
399
+ },
400
+
401
+ cancel() {
402
+ this.show = false
403
+ },
404
+ showmsg(obj){
405
+ this.rowdata=obj
406
+ this.show=true
407
+ },
408
+ search () {
409
+ this.$refs.paged.$refs.cri.search()
410
+ },
411
+ selfSearch (args) {
412
+ args.condition = args.condition+ ` ${this.filialeCodeStr}`
413
+ this.model.search(args.condition, args.model)
414
+ },
415
+ hidden(){
416
+ this.criteriaShow = !this.criteriaShow
417
+ },
418
+ clear(){
419
+ Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
420
+ if(key != 'startDate' && key != 'endDate')
421
+ this.$refs.paged.$refs.cri.model[key] = []
422
+ })
423
+ this.$refs.paged.$refs.cri.model.startDate = this.$login.toStandardDateString()
424
+ this.$refs.paged.$refs.cri.model.endDate = this.$login.toStandardDateString()
425
+ }
426
+ },
427
+ computed: {
428
+ gasproperties() {
429
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('用气性质')]
430
+ },
431
+ usertypes() {
432
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('用户类型')]
433
+ },
434
+ userstate() {
435
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('用户状态')]
436
+ },
437
+ tablestate () {
438
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('气表状态')]
439
+ },
440
+ // f_meter_classify(){
441
+ // return [{label: '机表', value: '机表'},{label: '卡表', value: '卡表'},{label: '物联网表', value: '物联网表'}]
442
+ // // return [{label: '卡表', value: '卡表'}]
443
+ // },
444
+
445
+ getCondition () {
446
+ let result = {
447
+ condition: '',
448
+ diffDay:' 1=1 ',
449
+ startDate: this.$refs.paged.$refs.cri.model.startDate,
450
+ endDate: this.$refs.paged.$refs.cri.model.endDate
451
+ }
452
+ result.condition = this.$refs.paged.$refs.cri.condition + this.filialeCodeStr
453
+
454
+ return result
455
+ }
456
+ }
457
+ }
458
+ </script>
459
+ <style media="screen">
460
+ .divtext {
461
+ min-width: 50px;
462
+ max-width: 200px;
463
+ border: 1px solid green;
464
+ display: inline-block;
465
+ }
466
+ </style>
467
+