manage-client 3.2.215 → 3.2.217

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 (31) hide show
  1. package/.gradle/4.4/fileHashes/fileHashes.bin +0 -0
  2. package/.gradle/4.4/fileHashes/fileHashes.lock +0 -0
  3. package/.gradle/7.1/dependencies-accessors/dependencies-accessors.lock +0 -0
  4. package/.gradle/7.1/dependencies-accessors/gc.properties +0 -0
  5. package/.gradle/7.1/executionHistory/executionHistory.bin +0 -0
  6. package/.gradle/7.1/executionHistory/executionHistory.lock +0 -0
  7. package/.gradle/7.1/fileChanges/last-build.bin +0 -0
  8. package/.gradle/7.1/fileHashes/fileHashes.bin +0 -0
  9. package/.gradle/7.1/fileHashes/fileHashes.lock +0 -0
  10. package/.gradle/7.1/gc.properties +0 -0
  11. package/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
  12. package/build/dev-server.js +193 -191
  13. package/package.json +1 -1
  14. package/src/components/sale/filesquery/MeterQuery.vue +607 -627
  15. package/src/filiale/WEINAN/CancellationQuery.vue +526 -526
  16. package/src/filiale/WEINAN/ChargeQuery.vue +800 -800
  17. package/src/filiale/WEINAN/EnableQuery.vue +456 -456
  18. package/src/filiale/WEINAN/StatisticalAnalysis.vue +270 -0
  19. package/src/filiale/WEINAN/UserAddress.vue +655 -655
  20. package/src/filiale/WEINAN/UserAddressChange.vue +58 -58
  21. package/src/filiale/WEINAN/config/exportConfig.js +824 -824
  22. package/src/filiale/WEINAN/sale.js +54 -52
  23. package/src/filiale/jingwei/ChargeQuery.vue +10 -0
  24. package/src/filiale/wuhai/ChargeQuery.vue +2 -2
  25. package/src/filiale/wuhai/OtherChargeQuery.vue +5 -2
  26. package/src/filiale/wuhai/ReportList.vue +26 -2
  27. package/src/filiale/wuhai/config/DefaultPrint.js +6 -0
  28. package/src/filiale/wuhai/config/exportConfig.js +1090 -0
  29. package/src/filiale/wuhai/config/tableConfig.js +54 -0
  30. package/src/filiale/wuhai/webmeterManage.js +1 -1
  31. package/src/main.js +66 -66
@@ -1,526 +1,526 @@
1
- <template>
2
- <div id="unit" class="flex-row">
3
- <div :class="{'basic-main':!useraddressShow,'binary-left':useraddressShow}" @keyup.enter="search">
4
- <div class="flex" v-if="!show">
5
-
6
- <criteria-paged :model="model" v-ref:paged @sort="sort">
7
- <criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:cri>
8
- <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
9
- <div class="row">
10
- <div class="col-sm-2 form-group">
11
- <label for="startDate" class="font_normal_body">开始日期</label>
12
- <datepicker id="startDate" placeholder="开始日期" style="width:60%"
13
- v-model="model.startDate"
14
- :value.sync="model.startDate"
15
- :format="'yyyy-MM-dd HH:mm:ss'"
16
- :show-reset-button="true"
17
- condition="f_operate_date >= '{}'">
18
- </datepicker>
19
- </div>
20
- <div class="col-sm-2 form-group">
21
- <label for="endDate" class="font_normal_body">结束日期</label>
22
- <datepicker id="endDate" placeholder="结束日期" style="width:60%"
23
- v-model="model.endDate"
24
- :value.sync="model.endDate"
25
- :format="'yyyy-MM-dd HH:mm:ss'"
26
- :show-reset-button="true"
27
- condition="f_operate_date <= '{}'">
28
- </datepicker>
29
- </div>
30
- <div class="col-sm-2 form-group">
31
- <label class="font_normal_body">客户编号</label>
32
- <input type="text" style="width:60%" class="input_search" v-model="model.f_userinfo_code"
33
- condition="f_userinfo_code = '{}' " placeholder="客户编号">
34
- </div>
35
- <div class="col-sm-2 form-group" v-show="false">
36
- <label class="font_normal_body" title="旧客户编号">档案编号</label>
37
- <input type="text" style="width:60%" class="input_search" v-model="model.f_olduserinfo_code"
38
- condition="f_olduserinfo_code = '{}' " placeholder="档案编号">
39
- </div>
40
-
41
- <div class="span" style="float:right;">
42
- <button class="button_search button_spacing" @click="search()">查询</button>
43
- <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
44
- <!--<button class="btn btn-default" @click="$parent.$parent.stamp()">打印</button>-->
45
-
46
- <export-excel :data="$parent.$parent.getCondition"
47
- :field="$parent.$parent.getfield"
48
- :header="$parent.$parent.other"
49
- sqlurl="rs/logic/exportfile" sql-name="CancellationQuery" template-name='销户查询导出'
50
- :choose-col="true"></export-excel>
51
- <print-data :sum-field="$parent.$parent.getfield" :model="$parent.model" :field="$parent.$parent.getfield"
52
- :defaultfield="$parent.$parent.defaultfield"
53
- titletable="销户记录"
54
- :sumsmodel="$parent.$parent.sumsmodel"></print-data>
55
- <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>
56
- </div>
57
- </div>
58
-
59
- <div class="row" v-show="$parent.$parent.criteriaShow">
60
- <res-select-group :initres="$parent.$parent.initres" :show-component="$parent.$parent.showCom" @re-res="$parent.$parent.getRes" v-ref:sel></res-select-group>
61
- <div class="col-sm-2 form-group">
62
- <label class="font_normal_body">客户名称</label>
63
- <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
64
- condition=" f_user_name like '%{}%'" placeholder='客户名称'>
65
- </div>
66
- <div class="col-sm-2 form-group" v-show="false">
67
- <label class="font_normal_body">客户地址</label>
68
- <input type="text" style="width:60%" class="input_search" v-model="model.f_address"
69
- condition="f_address like '%{}%'" placeholder='客户地址'>
70
- </div>
71
- <!-- <div class="col-sm-2 form-group">-->
72
- <!-- <label class="font_normal_body">操作类型</label>-->
73
- <!-- <v-select :value.sync="model.f_operat_type"-->
74
- <!-- v-model="model.f_operat_type"-->
75
- <!-- :options='$parent.$parent.operattype' placeholder='请选择'-->
76
- <!-- condition="f_operat_type = '{}'"-->
77
- <!-- close-on-select></v-select>-->
78
- <!-- </div>-->
79
- </div>
80
- </div>
81
- </criteria>
82
- <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid>
83
- <template partial='head'>
84
- <tr>
85
- <th>
86
- <data-order field="f_userinfo_code" name="客户编号"
87
- :order.sync="$parent.$parent.$parent.orderFields.f_userinfo_code"></data-order>
88
- </th>
89
- <th>
90
- <nobr>客户名称</nobr>
91
- </th>
92
- <th>
93
- <nobr>档案编号</nobr>
94
- </th>
95
- <th>
96
- <nobr>客户类型</nobr>
97
- </th>
98
- <th>
99
- <nobr>联系电话</nobr>
100
- </th>
101
- <th>
102
- <data-order field="f_address" name="客户地址"
103
- :order.sync="$parent.$parent.$parent.orderFields.f_address"></data-order>
104
- </th>
105
- <th>
106
- <nobr>表号</nobr>
107
- </th>
108
- <th>
109
- <nobr>销户原因</nobr>
110
- </th>
111
- <th>
112
- <nobr>状态</nobr>
113
- </th>
114
- <th>
115
- <data-order field="f_operate_date" name="销户日期"
116
- :order.sync="$parent.$parent.$parent.orderFields.f_operate_date"></data-order>
117
- </th>
118
- <th>
119
- <nobr>操作类型</nobr>
120
- </th>
121
- <th>
122
- <nobr>人员</nobr>
123
- </th>
124
- <th>
125
- <nobr>部门</nobr>
126
- </th>
127
- <th>
128
- <nobr>公司</nobr>
129
- </th>
130
- <th>
131
- <nobr>操作</nobr>
132
- </th>
133
- <th><nobr>附件</nobr></th>
134
- </tr>
135
- </template>
136
- <template partial='body'>
137
- <td style="text-align: center;">
138
- <nobr>
139
- <span @click="$parent.$parent.$parent.dealmsg(row)"><a>{{row.f_userinfo_code}}</a></span></nobr>
140
- </td>
141
- <td style="text-align: center;">
142
- <nobr>{{row.f_user_name}}</nobr>
143
- </td>
144
- <td style="text-align: center;">
145
- <nobr>{{row.f_olduserinfo_code}}</nobr>
146
- </td>
147
- <td style="text-align: center;">
148
- <nobr>{{row.f_user_type}}</nobr>
149
- </td>
150
- <td style="text-align: center;">
151
- <nobr>{{row.f_user_phone}}</nobr>
152
- </td>
153
- <td style="text-align: center;">
154
- <nobr>{{row.f_address}}</nobr>
155
- </td>
156
- <td style="text-align: center;">
157
- <nobr>{{row.f_meternumber}}</nobr>
158
- </td>
159
- <td style="text-align: center;">
160
- <nobr>{{row.f_comments}}</nobr>
161
- </td>
162
- <td style="text-align: center;">
163
- <nobr>{{row.f_state}}</nobr>
164
- </td>
165
- <td style="text-align: center;">
166
- <nobr>{{row.f_operate_date}}</nobr>
167
- </td>
168
- <td style="text-align: center;">
169
- <nobr>{{row.f_operat_type}}</nobr>
170
- </td>
171
- <td style="text-align: center;">
172
- <nobr>{{row.f_operator}}</nobr>
173
- </td>
174
- <td style="text-align: center;">
175
- <nobr>{{row.f_depname}}</nobr>
176
- </td>
177
- <td style="text-align: center;">
178
- <nobr>{{row.f_orgname}}</nobr>
179
- </td>
180
- <nobr><a href="#" @click="$parent.$parent.$parent.enable(row)">启用</a> | <a href="#" @click="$parent.$parent.$parent.modifyAddress(row)">修改地址</a></nobr>
181
- <td style="text-align: center;" v-else>
182
- </td>
183
- <td style="text-align: center;"><nobr>
184
- <button class="button_search button_spacing width-60" @click.stop="$parent.$parent.$parent.view(row)">查看</button>
185
- </nobr></td>
186
- </template>
187
- <template partial='foot'></template>
188
- </data-grid>
189
- </criteria-paged>
190
- <!-- <table class="table-hover">-->
191
- <!-- <tr style="position: relative" class="table-bordered">-->
192
- <!-- <td-->
193
- <!-- style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;color: #5CB95C;font-weight: bold">-->
194
- <!-- 汇总信息-->
195
- <!-- </td>-->
196
- <!-- <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">合计:&emsp;{{sumsmodel.f_pregas}}</td>-->
197
- <!-- </tr>-->
198
- <!-- </table>-->
199
- </div>
200
- <div class="flex" v-if="show">
201
- <user-info-detail-manage-new :f_userinfo_id="rowdata.f_userinfo_id" @cancel-main="cancel"></user-info-detail-manage-new>
202
- </div>
203
- </div>
204
- <div class="binary-right" v-show="useraddressShow">
205
- <div class="flex">
206
- <user-address v-ref:useraddressmsg
207
- :f_filialeids.sync="f_filialeids"></user-address>
208
-
209
- <user-address-change v-if="addressId" :address_id="addressId"></user-address-change>
210
- </div>
211
- <modal :show.sync="showupload" v-if="showupload" width="80%" style="width:auto;" v-ref:modal middle backdrop="false">
212
- <article slot="modal-body">
213
- <upload :blodid="selected.f_userinfo_id" v-ref:upload isupload="false" takeimg="false" fusetype="销户" :isremark="false" style="width:auto" ></upload>
214
- </article>
215
- <footer slot="modal-footer" class="modal-footer">
216
- </footer>
217
- </modal>
218
- <modal :show.sync="enbaleShow" v-if="enbaleShow" width="50%" style="width:auto;">
219
- <article slot="modal-body" class="modal-body">
220
- <div class="auto">
221
- <validator name='v'>
222
- <form class="form-horizontal">
223
- <p class="bg-info text-center" style="padding: 8px;">启用信息</p>
224
- <div class="form-group" style="margin-top:10px;">
225
- <label for="f_reason" class=" font_normal_body">销户原因:</label>
226
- <input class="input_search" style="width:80%" v-model="enableData.f_comments" disabled="">
227
- </div>
228
- <div class="form-group" style="margin-top:10px;">
229
- <div :class="[$v.f_reason.required ? 'has-error' : 'has-success']">
230
- <label for="f_reason" class=" font_normal_body">启用原因:</label>
231
- <input class="input_search" style="width:80%" v-model="enableData.f_reason" v-validate:f_reason='{required: true }' rows="3" placeholder="请填写原因">
232
- </div>
233
- </div>
234
- </form>
235
- <div style="text-align:right;height:auto;margin-top:30px;margin-right:50px;">
236
- <button class="button_search" @click="confirmEnable()" :disabled='!$v.valid'>确认</button>
237
- <button class="button_clear" @click="clean()">取消</button>
238
- </div>
239
- </validator>
240
- </div>
241
- </article>
242
- <footer slot="modal-footer" class="modal-footer">
243
- </footer>
244
- </modal>
245
- </div>
246
- </template>
247
-
248
- <script>
249
- import {PagedList} from 'vue-client'
250
- import defaultPrint from './config/DefaultPrint'
251
- import exportConfig from './config/exportConfig'
252
-
253
- let readySomething = async function (self) {
254
- self.$refs.paged.$refs.cri.model.startDate = self.data ? self.data.startDate : self.$login.toStandardDateString() + ' 00:00:00'
255
- self.$refs.paged.$refs.cri.model.endDate = self.data ? self.data.endDate : self.$login.toStandardDateString() + ' 23:59:59'
256
- self.defaultfield = [...self.defaultfield, ...self.config.defaultPrint]
257
- // await self.$refs.paged.$refs.cri.search()
258
- //self.$refs.paged.$refs.cri.model.f_sendsuccess = ['有效']
259
- await self.$MagLoadParams.loadParam()
260
-
261
- self.sumsmodel = self.$refs.paged.$refs.grid.model.sums
262
- }
263
- export default {
264
- props:['data'],
265
- title: '销户查询',
266
- data() {
267
- return {
268
- data: {},
269
- other: [],
270
- footer: [],
271
- model: new PagedList('rs/sql/CancellationQuery', 20, {orderitem: this.orderitem?`${this.orderitem}`: " 'f_operate_date desc '"}),
272
- criteriaShow: false,
273
- headData: ["客户编号", "客户名称", "操作人", "操作日期", "销户状态", "销户原因", "同步状态"],
274
- bodyData: ["f_userinfo_id", "f_user_name", "f_operator", "f_operate_date", "f_state", "f_comments", "f_sendsuccess"],
275
- orgCondtionStr: '',
276
- show:false,
277
- f_filialeids: this.$login.f.orgid,
278
- useraddressShow: false,
279
- addressId: '',
280
- rowdata:{},
281
- enableData: {
282
- f_reason: ''
283
- },
284
- enbaleShow: false,
285
- modelval: [],
286
- printshow: false,
287
- all: false,
288
- fields: {},
289
- thead: '',
290
- showupload:false,
291
- config: {
292
- defaultPrint: ['f_userinfo_code', 'f_user_name', 'f_type', 'f_changemeter_fee', 'f_meternumber_old', 'f_meternumber', 'f_change_operator', 'f_state', 'f_operate_date']
293
- },
294
- //排序
295
- orderitem:'f_operate_date desc',
296
- orderFields: {
297
- f_operate_date: 'no'
298
- },
299
- defaultfield: [],
300
- selected:{},
301
- tfoot: '',
302
- initres: {
303
- org:[this.$login.f.orgid],
304
- dep:[],
305
- user:[],
306
- },
307
- //合计数据
308
- sumsmodel: {},
309
- operattype:[{label: '全部', value: ''},{label: '销户', value: '销户'},{label: '销户启用', value: '销户启用'}],
310
- showCom:['company','department','operator']
311
- }
312
- },
313
- ready() {
314
- readySomething(this).then(() => {
315
- this.$emit('ready')
316
- }).catch((error) => {
317
- this.$emit('error', error)
318
- })
319
- },
320
- methods: {
321
- modifyAddress(obj) {
322
- this.addressId=obj.addrid
323
- this.useraddressShow=true
324
- this.$refs.useraddressmsg.cleardara()
325
- this.$refs.useraddressmsg.initdata()
326
- this.$refs.useraddressmsg.usertype=obj.f_user_type
327
- this.$refs.useraddressmsg.operation='modify'
328
- this.$refs.useraddressmsg.onedata='one'
329
- this.$refs.useraddressmsg.model=Object.assign({},this.$refs.useraddressmsg.model,obj)
330
- if(obj.f_special=='1'){
331
- this.$refs.useraddressmsg.usertype = true
332
- }else{
333
- this.$refs.useraddressmsg.usertype = false
334
- }
335
- if (obj.f_slice_area) {
336
- this.$refs.useraddressmsg.model.slice_area = [{
337
- name: this.$refs.useraddressmsg.model.f_slice_area,
338
- code: this.$refs.useraddressmsg.model.f_area_code
339
- }]
340
- }
341
- },
342
- enable(row) {
343
- Object.assign(this.enableData, row)
344
- this.enbaleShow = true
345
- },
346
- confirmEnable() {
347
- let data = {
348
- f_operat_type: '销户启用',
349
- f_describe: `${this.$login.f.name}对客户${this.enableData.f_user_name}进行启用`,
350
- f_user_id: this.enableData.f_user_id,
351
- f_user_name: this.enableData.f_user_name,
352
- f_state: '正常',
353
- f_comments: this.enableData.f_reason,
354
- f_operator: this.$login.f.name,
355
- f_operatorid: this.$login.f.id,
356
- f_orgid: this.$login.f.orgid,
357
- f_orgname: this.$login.f.orgs,
358
- f_depid: this.$login.f.depids,
359
- f_depname: this.$login.f.deps,
360
- f_userinfo_id : this.enableData.f_userinfo_id
361
- }
362
- this.$resetpost('rs/logic/saveSingleCancellation', data, {resolveMsg: '启用成功', rejectMsg: '启用失败'})
363
- },
364
- clean() {
365
- this.enbaleShow = false
366
- },
367
- view(row){
368
- this.showupload = true
369
- this.selected= row
370
- },
371
- getotherfooter() {
372
- // this.$refs.paged.$refs.cri.$refs.exports.otherData=[];
373
- // this.$refs.paged.$refs.cri.$refs.exports.footerData=[];
374
- this.other = [];
375
- this.footer = [];
376
- let exportdata = this.getCondition;
377
- let otherInData = [];
378
- otherInData.push(`导出时间: ${this.$login.toStandardTimeString()}`);
379
- let footerData = [], exportfield = this.getfield;
380
- footerData.push("合计");
381
- let self = this;
382
- for (var field in self.sumsmodel) {
383
- footerData.push(`${exportfield[field]}合计:${self.sumsmodel[field]}`);
384
- }
385
- this.footer.push(footerData);
386
- this.other.push(otherInData);
387
- },
388
- search(){
389
- this.$refs.paged.$refs.cri.search()
390
- },
391
- selfSearch(args) {
392
- if (this.data) {
393
- this.$parent.$parent.$parent.data.startDate=this.$refs.paged.$refs.cri.model.startDate
394
- this.$parent.$parent.$parent.data.endDate=this.$refs.paged.$refs.cri.model.endDate
395
- }
396
- args.condition = `${args.condition}` + this.orgCondtionStr
397
- this.model.search(args.condition, args.model)
398
- this.sumsmodel = this.$refs.paged.$refs.grid.model.sums
399
- },
400
- clear() {
401
- //清空部门和人员
402
- this.$refs.paged.$refs.cri.$refs.sel.$children[1].selectres = []
403
- //部门和人员变为全选
404
- this.$refs.paged.$refs.cri.$refs.sel.$children[1].$children[0].isSelectAll = false
405
- this.$refs.paged.$refs.cri.$refs.sel.$children[2].$children[0].isSelectAll = false
406
- Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
407
- this.$refs.paged.$refs.cri.model[key] = []
408
- })
409
- },
410
- show() {
411
- this.criteriaShow = true
412
- },
413
- hidden() {
414
- this.criteriaShow = !this.criteriaShow
415
- },
416
- getRes(obj) {
417
- this.orgCondtionStr = obj
418
- },
419
- stamp() {
420
- this.all = false
421
- //默认选择要打印的列
422
- this.modelval = defaultPrint.config
423
- this.fields = this.getfield
424
- console.log('所有打印字段', this.fields)
425
- this.printshow = true
426
- this.put()
427
- },
428
- sort (field, rule) {
429
- // 将所有排序方式设为不排序,实现相互排斥
430
- for (let key in this.orderFields) {
431
- if (key === field) {
432
- this.orderFields[key] = rule
433
- } else {
434
- this.orderFields[key] = 'no'
435
- }
436
- }
437
- // 如果新规则不排序,还原为默认排序
438
- if (rule === 'no') {
439
- this.model.paramSource.orderitem = `'${this.orderitem}'`
440
- } else {
441
- this.model.paramSource.orderitem = `'${field} ${rule}'`
442
- }
443
-
444
- this.search()
445
- },
446
-
447
- put() {
448
- // 对Modelval进行排序
449
- this.sortModelval()
450
- this.thead = `<tr><th colspan=${this.modelval.length}>销户查询报表</th></tr><tr>`
451
- for (let key of this.modelval) {
452
- this.thead += '<th>' + this.fields[key] + '</th>'
453
- }
454
- this.thead += '</tr>'
455
- },
456
- cancel() {
457
- this.show = false
458
- },
459
- dealmsg(val) {
460
- console.log('---------------dealmsg')
461
- this.rowdata=val
462
- this.show=true
463
- val.model = this.model.model
464
- this.$dispatch('deal-msg', val)
465
- },
466
- print() {
467
- this.$refs.print.PrintAsFile()
468
- this.printshow = false
469
- },
470
- close() {
471
- this.printshow = false
472
- this.all = false
473
- },
474
- // 对选择的列进行排序
475
- sortModelval() {
476
- let sortModel = []
477
- Object.keys(this.fields).forEach((key) => {
478
- if (this.modelval.includes(key)) {
479
- sortModel.push(key)
480
- }
481
- })
482
- this.modelval = sortModel
483
- console.log('选择的打印的字段', this.modelval)
484
- }
485
- },
486
- watch: {
487
- 'all'(val) {
488
- if (val) {
489
- this.modelval = this.bodyData
490
- } else {
491
- this.modelval = defaultPrint.config
492
- this.put()
493
- }
494
- },
495
- sumsmodel: {
496
- handler: function (val) {
497
- this.getotherfooter();
498
- },
499
- deep: true
500
- },
501
- 'modelval.length'() {
502
- this.put()
503
- },
504
- },
505
- computed: {
506
- getCondition() {
507
- return {condition: `${this.$refs.paged.$refs.cri.condition}` + this.orgCondtionStr,
508
- orderitem: this.orderitem?`${this.orderitem}`: " f_operate_date desc"}
509
- },
510
- getfield() {
511
- return exportConfig.CancellationConfig
512
- }
513
- },
514
- events: {
515
- 'cancel' () {
516
- this.addressId=null
517
- this.useraddressShow = false
518
- },
519
- 'confirm' () {
520
- this.addressId=null
521
- this.useraddressShow = false
522
- this.search()
523
- },
524
- }
525
- }
526
- </script>
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div :class="{'basic-main':!useraddressShow,'binary-left':useraddressShow}" @keyup.enter="search">
4
+ <div class="flex" v-if="!show">
5
+
6
+ <criteria-paged :model="model" v-ref:paged @sort="sort">
7
+ <criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:cri>
8
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
9
+ <div class="row">
10
+ <div class="col-sm-2 form-group">
11
+ <label for="startDate" class="font_normal_body">开始日期</label>
12
+ <datepicker id="startDate" placeholder="开始日期" style="width:60%"
13
+ v-model="model.startDate"
14
+ :value.sync="model.startDate"
15
+ :format="'yyyy-MM-dd HH:mm:ss'"
16
+ :show-reset-button="true"
17
+ condition="f_operate_date >= '{}'">
18
+ </datepicker>
19
+ </div>
20
+ <div class="col-sm-2 form-group">
21
+ <label for="endDate" class="font_normal_body">结束日期</label>
22
+ <datepicker id="endDate" placeholder="结束日期" style="width:60%"
23
+ v-model="model.endDate"
24
+ :value.sync="model.endDate"
25
+ :format="'yyyy-MM-dd HH:mm:ss'"
26
+ :show-reset-button="true"
27
+ condition="f_operate_date <= '{}'">
28
+ </datepicker>
29
+ </div>
30
+ <div class="col-sm-2 form-group">
31
+ <label class="font_normal_body">客户编号</label>
32
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_userinfo_code"
33
+ condition="f_userinfo_code = '{}' " placeholder="客户编号">
34
+ </div>
35
+ <div class="col-sm-2 form-group" v-show="false">
36
+ <label class="font_normal_body" title="旧客户编号">档案编号</label>
37
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_olduserinfo_code"
38
+ condition="f_olduserinfo_code = '{}' " placeholder="档案编号">
39
+ </div>
40
+
41
+ <div class="span" style="float:right;">
42
+ <button class="button_search button_spacing" @click="search()">查询</button>
43
+ <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
44
+ <!--<button class="btn btn-default" @click="$parent.$parent.stamp()">打印</button>-->
45
+
46
+ <export-excel :data="$parent.$parent.getCondition"
47
+ :field="$parent.$parent.getfield"
48
+ :header="$parent.$parent.other"
49
+ sqlurl="rs/logic/exportfile" sql-name="CancellationQuery" template-name='销户查询导出'
50
+ :choose-col="true"></export-excel>
51
+ <print-data :sum-field="$parent.$parent.getfield" :model="$parent.model" :field="$parent.$parent.getfield"
52
+ :defaultfield="$parent.$parent.defaultfield"
53
+ titletable="销户记录"
54
+ :sumsmodel="$parent.$parent.sumsmodel"></print-data>
55
+ <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>
56
+ </div>
57
+ </div>
58
+
59
+ <div class="row" v-show="$parent.$parent.criteriaShow">
60
+ <res-select-group :initres="$parent.$parent.initres" :show-component="$parent.$parent.showCom" @re-res="$parent.$parent.getRes" v-ref:sel></res-select-group>
61
+ <div class="col-sm-2 form-group">
62
+ <label class="font_normal_body">客户名称</label>
63
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
64
+ condition=" f_user_name like '%{}%'" placeholder='客户名称'>
65
+ </div>
66
+ <div class="col-sm-2 form-group" v-show="false">
67
+ <label class="font_normal_body">客户地址</label>
68
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_address"
69
+ condition="f_address like '%{}%'" placeholder='客户地址'>
70
+ </div>
71
+ <!-- <div class="col-sm-2 form-group">-->
72
+ <!-- <label class="font_normal_body">操作类型</label>-->
73
+ <!-- <v-select :value.sync="model.f_operat_type"-->
74
+ <!-- v-model="model.f_operat_type"-->
75
+ <!-- :options='$parent.$parent.operattype' placeholder='请选择'-->
76
+ <!-- condition="f_operat_type = '{}'"-->
77
+ <!-- close-on-select></v-select>-->
78
+ <!-- </div>-->
79
+ </div>
80
+ </div>
81
+ </criteria>
82
+ <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid>
83
+ <template partial='head'>
84
+ <tr>
85
+ <th>
86
+ <data-order field="f_userinfo_code" name="客户编号"
87
+ :order.sync="$parent.$parent.$parent.orderFields.f_userinfo_code"></data-order>
88
+ </th>
89
+ <th>
90
+ <nobr>客户名称</nobr>
91
+ </th>
92
+ <th>
93
+ <nobr>档案编号</nobr>
94
+ </th>
95
+ <th>
96
+ <nobr>客户类型</nobr>
97
+ </th>
98
+ <th>
99
+ <nobr>联系电话</nobr>
100
+ </th>
101
+ <th>
102
+ <data-order field="f_address" name="客户地址"
103
+ :order.sync="$parent.$parent.$parent.orderFields.f_address"></data-order>
104
+ </th>
105
+ <th>
106
+ <nobr>表号</nobr>
107
+ </th>
108
+ <th>
109
+ <nobr>销户原因</nobr>
110
+ </th>
111
+ <th>
112
+ <nobr>状态</nobr>
113
+ </th>
114
+ <th>
115
+ <data-order field="f_operate_date" name="销户日期"
116
+ :order.sync="$parent.$parent.$parent.orderFields.f_operate_date"></data-order>
117
+ </th>
118
+ <th>
119
+ <nobr>操作类型</nobr>
120
+ </th>
121
+ <th>
122
+ <nobr>人员</nobr>
123
+ </th>
124
+ <th>
125
+ <nobr>部门</nobr>
126
+ </th>
127
+ <th>
128
+ <nobr>公司</nobr>
129
+ </th>
130
+ <th>
131
+ <nobr>操作</nobr>
132
+ </th>
133
+ <th><nobr>附件</nobr></th>
134
+ </tr>
135
+ </template>
136
+ <template partial='body'>
137
+ <td style="text-align: center;">
138
+ <nobr>
139
+ <span @click="$parent.$parent.$parent.dealmsg(row)"><a>{{row.f_userinfo_code}}</a></span></nobr>
140
+ </td>
141
+ <td style="text-align: center;">
142
+ <nobr>{{row.f_user_name}}</nobr>
143
+ </td>
144
+ <td style="text-align: center;">
145
+ <nobr>{{row.f_olduserinfo_code}}</nobr>
146
+ </td>
147
+ <td style="text-align: center;">
148
+ <nobr>{{row.f_user_type}}</nobr>
149
+ </td>
150
+ <td style="text-align: center;">
151
+ <nobr>{{row.f_user_phone}}</nobr>
152
+ </td>
153
+ <td style="text-align: center;">
154
+ <nobr>{{row.f_address}}</nobr>
155
+ </td>
156
+ <td style="text-align: center;">
157
+ <nobr>{{row.f_meternumber}}</nobr>
158
+ </td>
159
+ <td style="text-align: center;">
160
+ <nobr>{{row.f_comments}}</nobr>
161
+ </td>
162
+ <td style="text-align: center;">
163
+ <nobr>{{row.f_state}}</nobr>
164
+ </td>
165
+ <td style="text-align: center;">
166
+ <nobr>{{row.f_operate_date}}</nobr>
167
+ </td>
168
+ <td style="text-align: center;">
169
+ <nobr>{{row.f_operat_type}}</nobr>
170
+ </td>
171
+ <td style="text-align: center;">
172
+ <nobr>{{row.f_operator}}</nobr>
173
+ </td>
174
+ <td style="text-align: center;">
175
+ <nobr>{{row.f_depname}}</nobr>
176
+ </td>
177
+ <td style="text-align: center;">
178
+ <nobr>{{row.f_orgname}}</nobr>
179
+ </td>
180
+ <nobr><a href="#" @click="$parent.$parent.$parent.enable(row)">启用</a> | <a href="#" @click="$parent.$parent.$parent.modifyAddress(row)">修改地址</a></nobr>
181
+ <td style="text-align: center;" v-else>
182
+ </td>
183
+ <td style="text-align: center;"><nobr>
184
+ <button class="button_search button_spacing width-60" @click.stop="$parent.$parent.$parent.view(row)">查看</button>
185
+ </nobr></td>
186
+ </template>
187
+ <template partial='foot'></template>
188
+ </data-grid>
189
+ </criteria-paged>
190
+ <!-- <table class="table-hover">-->
191
+ <!-- <tr style="position: relative" class="table-bordered">-->
192
+ <!-- <td-->
193
+ <!-- style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;color: #5CB95C;font-weight: bold">-->
194
+ <!-- 汇总信息-->
195
+ <!-- </td>-->
196
+ <!-- <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">合计:&emsp;{{sumsmodel.f_pregas}}</td>-->
197
+ <!-- </tr>-->
198
+ <!-- </table>-->
199
+ </div>
200
+ <div class="flex" v-if="show">
201
+ <user-info-detail-manage-new :f_userinfo_id="rowdata.f_userinfo_id" @cancel-main="cancel"></user-info-detail-manage-new>
202
+ </div>
203
+ </div>
204
+ <div class="binary-right" v-show="useraddressShow">
205
+ <div class="flex">
206
+ <user-address v-ref:useraddressmsg
207
+ :f_filialeids.sync="f_filialeids"></user-address>
208
+
209
+ <user-address-change v-if="addressId" :address_id="addressId"></user-address-change>
210
+ </div>
211
+ <modal :show.sync="showupload" v-if="showupload" width="80%" style="width:auto;" v-ref:modal middle backdrop="false">
212
+ <article slot="modal-body">
213
+ <upload :blodid="selected.f_userinfo_id" v-ref:upload isupload="false" takeimg="false" fusetype="销户" :isremark="false" style="width:auto" ></upload>
214
+ </article>
215
+ <footer slot="modal-footer" class="modal-footer">
216
+ </footer>
217
+ </modal>
218
+ <modal :show.sync="enbaleShow" v-if="enbaleShow" width="50%" style="width:auto;">
219
+ <article slot="modal-body" class="modal-body">
220
+ <div class="auto">
221
+ <validator name='v'>
222
+ <form class="form-horizontal">
223
+ <p class="bg-info text-center" style="padding: 8px;">启用信息</p>
224
+ <div class="form-group" style="margin-top:10px;">
225
+ <label for="f_reason" class=" font_normal_body">销户原因:</label>
226
+ <input class="input_search" style="width:80%" v-model="enableData.f_comments" disabled="">
227
+ </div>
228
+ <div class="form-group" style="margin-top:10px;">
229
+ <div :class="[$v.f_reason.required ? 'has-error' : 'has-success']">
230
+ <label for="f_reason" class=" font_normal_body">启用原因:</label>
231
+ <input class="input_search" style="width:80%" v-model="enableData.f_reason" v-validate:f_reason='{required: true }' rows="3" placeholder="请填写原因">
232
+ </div>
233
+ </div>
234
+ </form>
235
+ <div style="text-align:right;height:auto;margin-top:30px;margin-right:50px;">
236
+ <button class="button_search" @click="confirmEnable()" :disabled='!$v.valid'>确认</button>
237
+ <button class="button_clear" @click="clean()">取消</button>
238
+ </div>
239
+ </validator>
240
+ </div>
241
+ </article>
242
+ <footer slot="modal-footer" class="modal-footer">
243
+ </footer>
244
+ </modal>
245
+ </div>
246
+ </template>
247
+
248
+ <script>
249
+ import {PagedList} from 'vue-client'
250
+ import defaultPrint from './config/DefaultPrint'
251
+ import exportConfig from './config/exportConfig'
252
+
253
+ let readySomething = async function (self) {
254
+ self.$refs.paged.$refs.cri.model.startDate = self.data ? self.data.startDate : self.$login.toStandardDateString() + ' 00:00:00'
255
+ self.$refs.paged.$refs.cri.model.endDate = self.data ? self.data.endDate : self.$login.toStandardDateString() + ' 23:59:59'
256
+ self.defaultfield = [...self.defaultfield, ...self.config.defaultPrint]
257
+ // await self.$refs.paged.$refs.cri.search()
258
+ //self.$refs.paged.$refs.cri.model.f_sendsuccess = ['有效']
259
+ await self.$MagLoadParams.loadParam()
260
+
261
+ self.sumsmodel = self.$refs.paged.$refs.grid.model.sums
262
+ }
263
+ export default {
264
+ props:['data'],
265
+ title: '销户查询',
266
+ data() {
267
+ return {
268
+ data: {},
269
+ other: [],
270
+ footer: [],
271
+ model: new PagedList('rs/sql/CancellationQuery', 20, {orderitem: this.orderitem?`${this.orderitem}`: " 'f_operate_date desc '"}),
272
+ criteriaShow: false,
273
+ headData: ["客户编号", "客户名称", "操作人", "操作日期", "销户状态", "销户原因", "同步状态"],
274
+ bodyData: ["f_userinfo_id", "f_user_name", "f_operator", "f_operate_date", "f_state", "f_comments", "f_sendsuccess"],
275
+ orgCondtionStr: '',
276
+ show:false,
277
+ f_filialeids: this.$login.f.orgid,
278
+ useraddressShow: false,
279
+ addressId: '',
280
+ rowdata:{},
281
+ enableData: {
282
+ f_reason: ''
283
+ },
284
+ enbaleShow: false,
285
+ modelval: [],
286
+ printshow: false,
287
+ all: false,
288
+ fields: {},
289
+ thead: '',
290
+ showupload:false,
291
+ config: {
292
+ defaultPrint: ['f_userinfo_code', 'f_user_name', 'f_type', 'f_changemeter_fee', 'f_meternumber_old', 'f_meternumber', 'f_change_operator', 'f_state', 'f_operate_date']
293
+ },
294
+ //排序
295
+ orderitem:'f_operate_date desc',
296
+ orderFields: {
297
+ f_operate_date: 'no'
298
+ },
299
+ defaultfield: [],
300
+ selected:{},
301
+ tfoot: '',
302
+ initres: {
303
+ org:[this.$login.f.orgid],
304
+ dep:[],
305
+ user:[],
306
+ },
307
+ //合计数据
308
+ sumsmodel: {},
309
+ operattype:[{label: '全部', value: ''},{label: '销户', value: '销户'},{label: '销户启用', value: '销户启用'}],
310
+ showCom:['company','department','operator']
311
+ }
312
+ },
313
+ ready() {
314
+ readySomething(this).then(() => {
315
+ this.$emit('ready')
316
+ }).catch((error) => {
317
+ this.$emit('error', error)
318
+ })
319
+ },
320
+ methods: {
321
+ modifyAddress(obj) {
322
+ this.addressId=obj.addrid
323
+ this.useraddressShow=true
324
+ this.$refs.useraddressmsg.cleardara()
325
+ this.$refs.useraddressmsg.initdata()
326
+ this.$refs.useraddressmsg.usertype=obj.f_user_type
327
+ this.$refs.useraddressmsg.operation='modify'
328
+ this.$refs.useraddressmsg.onedata='one'
329
+ this.$refs.useraddressmsg.model=Object.assign({},this.$refs.useraddressmsg.model,obj)
330
+ if(obj.f_special=='1'){
331
+ this.$refs.useraddressmsg.usertype = true
332
+ }else{
333
+ this.$refs.useraddressmsg.usertype = false
334
+ }
335
+ if (obj.f_slice_area) {
336
+ this.$refs.useraddressmsg.model.slice_area = [{
337
+ name: this.$refs.useraddressmsg.model.f_slice_area,
338
+ code: this.$refs.useraddressmsg.model.f_area_code
339
+ }]
340
+ }
341
+ },
342
+ enable(row) {
343
+ Object.assign(this.enableData, row)
344
+ this.enbaleShow = true
345
+ },
346
+ confirmEnable() {
347
+ let data = {
348
+ f_operat_type: '销户启用',
349
+ f_describe: `${this.$login.f.name}对客户${this.enableData.f_user_name}进行启用`,
350
+ f_user_id: this.enableData.f_user_id,
351
+ f_user_name: this.enableData.f_user_name,
352
+ f_state: '正常',
353
+ f_comments: this.enableData.f_reason,
354
+ f_operator: this.$login.f.name,
355
+ f_operatorid: this.$login.f.id,
356
+ f_orgid: this.$login.f.orgid,
357
+ f_orgname: this.$login.f.orgs,
358
+ f_depid: this.$login.f.depids,
359
+ f_depname: this.$login.f.deps,
360
+ f_userinfo_id : this.enableData.f_userinfo_id
361
+ }
362
+ this.$resetpost('rs/logic/saveSingleCancellation', data, {resolveMsg: '启用成功', rejectMsg: '启用失败'})
363
+ },
364
+ clean() {
365
+ this.enbaleShow = false
366
+ },
367
+ view(row){
368
+ this.showupload = true
369
+ this.selected= row
370
+ },
371
+ getotherfooter() {
372
+ // this.$refs.paged.$refs.cri.$refs.exports.otherData=[];
373
+ // this.$refs.paged.$refs.cri.$refs.exports.footerData=[];
374
+ this.other = [];
375
+ this.footer = [];
376
+ let exportdata = this.getCondition;
377
+ let otherInData = [];
378
+ otherInData.push(`导出时间: ${this.$login.toStandardTimeString()}`);
379
+ let footerData = [], exportfield = this.getfield;
380
+ footerData.push("合计");
381
+ let self = this;
382
+ for (var field in self.sumsmodel) {
383
+ footerData.push(`${exportfield[field]}合计:${self.sumsmodel[field]}`);
384
+ }
385
+ this.footer.push(footerData);
386
+ this.other.push(otherInData);
387
+ },
388
+ search(){
389
+ this.$refs.paged.$refs.cri.search()
390
+ },
391
+ selfSearch(args) {
392
+ if (this.data) {
393
+ this.$parent.$parent.$parent.data.startDate=this.$refs.paged.$refs.cri.model.startDate
394
+ this.$parent.$parent.$parent.data.endDate=this.$refs.paged.$refs.cri.model.endDate
395
+ }
396
+ args.condition = `${args.condition}` + this.orgCondtionStr
397
+ this.model.search(args.condition, args.model)
398
+ this.sumsmodel = this.$refs.paged.$refs.grid.model.sums
399
+ },
400
+ clear() {
401
+ //清空部门和人员
402
+ this.$refs.paged.$refs.cri.$refs.sel.$children[1].selectres = []
403
+ //部门和人员变为全选
404
+ this.$refs.paged.$refs.cri.$refs.sel.$children[1].$children[0].isSelectAll = false
405
+ this.$refs.paged.$refs.cri.$refs.sel.$children[2].$children[0].isSelectAll = false
406
+ Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
407
+ this.$refs.paged.$refs.cri.model[key] = []
408
+ })
409
+ },
410
+ show() {
411
+ this.criteriaShow = true
412
+ },
413
+ hidden() {
414
+ this.criteriaShow = !this.criteriaShow
415
+ },
416
+ getRes(obj) {
417
+ this.orgCondtionStr = obj
418
+ },
419
+ stamp() {
420
+ this.all = false
421
+ //默认选择要打印的列
422
+ this.modelval = defaultPrint.config
423
+ this.fields = this.getfield
424
+ console.log('所有打印字段', this.fields)
425
+ this.printshow = true
426
+ this.put()
427
+ },
428
+ sort (field, rule) {
429
+ // 将所有排序方式设为不排序,实现相互排斥
430
+ for (let key in this.orderFields) {
431
+ if (key === field) {
432
+ this.orderFields[key] = rule
433
+ } else {
434
+ this.orderFields[key] = 'no'
435
+ }
436
+ }
437
+ // 如果新规则不排序,还原为默认排序
438
+ if (rule === 'no') {
439
+ this.model.paramSource.orderitem = `'${this.orderitem}'`
440
+ } else {
441
+ this.model.paramSource.orderitem = `'${field} ${rule}'`
442
+ }
443
+
444
+ this.search()
445
+ },
446
+
447
+ put() {
448
+ // 对Modelval进行排序
449
+ this.sortModelval()
450
+ this.thead = `<tr><th colspan=${this.modelval.length}>销户查询报表</th></tr><tr>`
451
+ for (let key of this.modelval) {
452
+ this.thead += '<th>' + this.fields[key] + '</th>'
453
+ }
454
+ this.thead += '</tr>'
455
+ },
456
+ cancel() {
457
+ this.show = false
458
+ },
459
+ dealmsg(val) {
460
+ console.log('---------------dealmsg')
461
+ this.rowdata=val
462
+ this.show=true
463
+ val.model = this.model.model
464
+ this.$dispatch('deal-msg', val)
465
+ },
466
+ print() {
467
+ this.$refs.print.PrintAsFile()
468
+ this.printshow = false
469
+ },
470
+ close() {
471
+ this.printshow = false
472
+ this.all = false
473
+ },
474
+ // 对选择的列进行排序
475
+ sortModelval() {
476
+ let sortModel = []
477
+ Object.keys(this.fields).forEach((key) => {
478
+ if (this.modelval.includes(key)) {
479
+ sortModel.push(key)
480
+ }
481
+ })
482
+ this.modelval = sortModel
483
+ console.log('选择的打印的字段', this.modelval)
484
+ }
485
+ },
486
+ watch: {
487
+ 'all'(val) {
488
+ if (val) {
489
+ this.modelval = this.bodyData
490
+ } else {
491
+ this.modelval = defaultPrint.config
492
+ this.put()
493
+ }
494
+ },
495
+ sumsmodel: {
496
+ handler: function (val) {
497
+ this.getotherfooter();
498
+ },
499
+ deep: true
500
+ },
501
+ 'modelval.length'() {
502
+ this.put()
503
+ },
504
+ },
505
+ computed: {
506
+ getCondition() {
507
+ return {condition: `${this.$refs.paged.$refs.cri.condition}` + this.orgCondtionStr,
508
+ orderitem: this.orderitem?`${this.orderitem}`: " f_operate_date desc"}
509
+ },
510
+ getfield() {
511
+ return exportConfig.CancellationConfig
512
+ }
513
+ },
514
+ events: {
515
+ 'cancel' () {
516
+ this.addressId=null
517
+ this.useraddressShow = false
518
+ },
519
+ 'confirm' () {
520
+ this.addressId=null
521
+ this.useraddressShow = false
522
+ this.search()
523
+ },
524
+ }
525
+ }
526
+ </script>