manage-client 3.2.80 → 3.2.81

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.
@@ -0,0 +1,324 @@
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div class="basic-main" @keyup.enter="search">
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 form-group">
10
+ <label class="font_normal_body">客户编号</label>
11
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_userinfo_code"
12
+ condition="u.f_userinfo_code = '{}' " placeholder="客户编号">
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="u.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
+ placeholder="地址" condition="f_address like '%{}%'">
23
+ </div>
24
+ <div class="col-sm-2 form-group">
25
+ <label class="font_normal_body">用户电话</label>
26
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_phone"
27
+ placeholder="地址" condition="f_user_phone='{}'">
28
+ </div>
29
+ <div class="col-sm-2 form-group">
30
+ <label class="font_normal_body">抄表状态</label>
31
+ <v-select :value.sync="model.f_meter_state" v-model="model.f_meter_state"
32
+ :options='$parent.$parent.meterstate' placeholder='请选择'
33
+ condition="f_meter_state = '{}'"
34
+ close-on-select>
35
+ </v-select>
36
+ </div>
37
+ <div class="row" v-show="$parent.$parent.criteriaShow">
38
+ <div class="col-sm-2 form-group">
39
+ <label for="startDate" class="font_normal_body">开始日期</label>
40
+ <datepicker id="startDate" placeholder="开始日期" style="width:60%"
41
+ v-model="model.startDate"
42
+ :value.sync="model.startDate"
43
+ format="yyyy-MM-dd HH:mm:ss"
44
+ :show-reset-button="true">
45
+ </datepicker>
46
+ </div>
47
+ <div class="col-sm-2 form-group">
48
+ <label for="endDate" class="font_normal_body">结束日期</label>
49
+ <datepicker id="endDate" placeholder="结束日期" style="width:60%"
50
+ v-model="model.endDate"
51
+ :value.sync="model.endDate"
52
+ format="yyyy-MM-dd HH:mm:ss"
53
+ :show-reset-button="true">
54
+ </datepicker>
55
+ </div>
56
+ <res-select-group :initres="$parent.$parent.initres" @re-res="$parent.$parent.getRes" :show-component="['company','department','operator']" v-ref:sel></res-select-group>
57
+ </div>
58
+ <div class="span" style="float:right;">
59
+ <button class="button_search button_spacing" @click="search()">查询</button>
60
+ <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
61
+ <div style="float: right" class="button_spacing" :class="{'button_shrink_top':$parent.$parent.criteriaShow,
62
+ 'button_shrink_bottom':!$parent.$parent.criteriaShow}" @click="$parent.$parent.hidden()"></div>
63
+
64
+ <!--<export-excel :data="$parent.$parent.getCondition"-->
65
+ <!--:field="$parent.$parent.getfield"-->
66
+ <!--:footer="$parent.$parent.footer"-->
67
+ <!--:header="$parent.$parent.other"-->
68
+ <!--sqlurl="rs/logic/exportfile"-->
69
+ <!--sql-name="OpertoerCollection"-->
70
+ <!--template-name='未抄表用户报表导出'-->
71
+ <!--:choose-col="true"></export-excel>-->
72
+ <!--<print-data :model="$parent.model"-->
73
+ <!--:field="$parent.$parent.getfield"-->
74
+ <!--titletable="未抄表用户报表导出"></print-data>-->
75
+ </div>
76
+ </div>
77
+ </div>
78
+ </criteria>
79
+
80
+ <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid>
81
+ <template partial='head'>
82
+ <tr>
83
+ <th>
84
+ <nobr>用户编号</nobr>
85
+ </th>
86
+ <th>
87
+ <nobr>用户名称</nobr>
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
+ <nobr>联系方式</nobr>
103
+ </th>
104
+ <th>
105
+ <nobr>用户类型</nobr>
106
+ </th>
107
+ <th>
108
+ <nobr>表号</nobr>
109
+ </th>
110
+ <th>
111
+ <nobr>累计气量</nobr>
112
+ </th>
113
+ <th>
114
+ <nobr>剩余金额</nobr>
115
+ </th>
116
+ <th>
117
+ <nobr>抄表状态</nobr>
118
+ </th>
119
+ <th>
120
+ <nobr>抄表时间</nobr>
121
+ </th>
122
+ <th>
123
+ <nobr>建档时间</nobr>
124
+ </th>
125
+ <th>
126
+ <nobr>所属机构</nobr>
127
+ </th>
128
+ </tr>
129
+ </template>
130
+ <template partial='body'>
131
+ <td style="text-align: center;">{{row.f_userinfo_code}}</td>
132
+ <td style="text-align: center;">{{row.f_user_name}}</td>
133
+ <td style="text-align: center;">{{row.f_olduserinfo_code}}</td>
134
+ <td style="text-align: center;">{{row.f_street}}</td>
135
+ <td style="text-align: center;">{{row.f_residential_area}}</td>
136
+ <td style="text-align: center;">{{row.f_address}}</td>
137
+ <td style="text-align: center;">{{row.f_user_phone}}</td>
138
+ <td style="text-align: center;">{{row.f_user_type}}</td>
139
+ <td style="text-align: center;">{{row.f_meternumber}}</td>
140
+ <td style="text-align: center;">{{row.f_total_gas}}</td>
141
+ <td style="text-align: center;">{{row.f_balance_amount}}</td>
142
+ <td style="text-align: center;">{{row.f_meter_state}}</td>
143
+ <td style="text-align: center;">{{row.f_hand_date}}</td>
144
+ <td style="text-align: center;">{{row.f_createfile_date}}</td>
145
+ <td style="text-align: center;">{{row.f_orgname}}</td>
146
+ </template>
147
+ </data-grid>
148
+ </criteria-paged>
149
+ </div>
150
+ </div>
151
+ </div>
152
+
153
+ </template>
154
+ <script>
155
+ /**
156
+ *档案查询列表以及添加操作组件
157
+ */
158
+ import {PagedList} from 'vue-client'
159
+ import defaultPrint from '../config/DefaultPrint'
160
+ import exportConfig from '../config/exportConfig'
161
+
162
+ let readySomething = async function (self) {
163
+ self.$refs.paged.$refs.cri.model.startDate = self.$login.toStandardDateString() + ' 00:00:00'
164
+ self.$refs.paged.$refs.cri.model.endDate = self.$login.toStandardDateString() + ' 23:59:59'
165
+
166
+ await self.$MagLoadParams.loadParam()
167
+
168
+ }
169
+
170
+
171
+ export default {
172
+ title: '未抄表用户报表',
173
+ data() {
174
+ return {
175
+ rows: null,
176
+ other: [],
177
+ footer: [],
178
+ criteriaShow: false,
179
+ model: new PagedList('rs/sql/UnhandBusiness', 50,
180
+ {startDate: 'this.model.startDate', endDate: 'this.model.endDate'}),
181
+ orgCondtionStr: '',
182
+ getfield: '',
183
+ show:false,
184
+ rowdata:{},
185
+ initres: {
186
+ org:[this.$login.f.orgid],
187
+ dep:[],
188
+ user:[],
189
+ },
190
+ defaultfield: []
191
+ }
192
+ },
193
+ ready() {
194
+ readySomething(this).then(() => {
195
+ this.$emit('ready')
196
+ }).catch((error) => {
197
+ this.$emit('error', error)
198
+ })
199
+ },
200
+ methods: {
201
+ getotherfooter() {
202
+ this.other = [];
203
+ this.footer = [];
204
+ let otherInData = [];
205
+ otherInData.push(`导出时间: ${this.$login.toStandardTimeString()}`);
206
+ let footerData = [], exportfield = this.getfield;
207
+ this.footer.push(footerData);
208
+ this.other.push(otherInData);
209
+ },
210
+ search(){
211
+ this.$refs.paged.$refs.cri.search()
212
+ },
213
+ selfSearch(args) {
214
+ args.condition = `${args.condition}` + this.orgCondtionStr
215
+ this.model.search(args.condition, args.model)
216
+ },
217
+ show() {
218
+ this.criteriaShow = true
219
+ },
220
+ cancel() {
221
+ this.show = false
222
+ },
223
+ showmsg(obj){
224
+ this.rowdata=obj
225
+ this.show=true
226
+ },
227
+ dealmsg(val) {
228
+ console.log('---------------dealmsg')
229
+ val.model = this.model.model
230
+ this.$dispatch('deal-msg', val)
231
+ },
232
+ hidden() {
233
+ this.criteriaShow = !this.criteriaShow
234
+ },
235
+ clear() {
236
+ //清空部门和人员
237
+ this.$refs.paged.$refs.cri.$refs.sel.$children[1].selectres = []
238
+ //部门和人员变为全选
239
+ this.$refs.paged.$refs.cri.$refs.sel.$children[1].$children[0].isSelectAll = false
240
+ this.$refs.paged.$refs.cri.$refs.sel.$children[2].$children[0].isSelectAll = false
241
+ Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
242
+ this.$refs.paged.$refs.cri.model[key] = []
243
+ })
244
+ },
245
+ getRes(obj) {
246
+ this.orgCondtionStr = obj
247
+ },
248
+ stamp() {
249
+ this.all = false
250
+ //默认选择要打印的列
251
+ this.modelval = defaultPrint.config
252
+ this.fields = this.getfield
253
+ console.log('所有打印字段', this.fields)
254
+ this.printshow = true
255
+ this.put()
256
+ },
257
+ put() {
258
+ // 对Modelval进行排序
259
+ this.sortModelval()
260
+ this.thead = `<tr><th colspan=${this.modelval.length}>未抄表用户报表</th></tr><tr>`
261
+ for (let key of this.modelval) {
262
+ this.thead += '<th>' + this.fields[key] + '</th>'
263
+ }
264
+ this.thead += '</tr>'
265
+ },
266
+ print() {
267
+ this.$refs.print.PrintAsFile()
268
+ this.printshow = false
269
+ },
270
+ close() {
271
+ this.printshow = false
272
+ this.all = false
273
+ },
274
+ // 对选择的列进行排序
275
+ sortModelval() {
276
+ let sortModel = []
277
+ Object.keys(this.fields).forEach((key) => {
278
+ if (this.modelval.includes(key)) {
279
+ sortModel.push(key)
280
+ }
281
+ })
282
+ this.modelval = sortModel
283
+ console.log('选择的打印的字段', this.modelval)
284
+ }
285
+ },
286
+ watch: {
287
+ 'all'(val) {
288
+ if (val) {
289
+ this.modelval = this.bodyData
290
+ } else {
291
+ this.modelval = defaultPrint.config
292
+ this.put()
293
+ }
294
+ },
295
+ 'modelval.length'() {
296
+ this.put()
297
+ },
298
+ },
299
+ computed: {
300
+ getCondition() {
301
+ let result = {
302
+ condition: this.$refs.paged.$refs.cri.condition + this.orgCondtionStr,
303
+ startDate: this.$refs.paged.$refs.cri.model.startDate,
304
+ endDate: this.$refs.paged.$refs.cri.model.endDate
305
+ }
306
+ return result
307
+ },
308
+ meterstate() {
309
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('抄表状态')]
310
+ },
311
+ getfield() {
312
+ return exportConfig.ProceedsOperConfig
313
+ }
314
+ }
315
+ }
316
+ </script>
317
+ <style media="screen">
318
+ .divtext {
319
+ min-width: 50px;
320
+ max-width: 200px;
321
+ border: 1px solid green;
322
+ display: inline-block;
323
+ }
324
+ </style>