manage-client 3.3.1 → 3.3.3

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 (34) hide show
  1. package/package.json +1 -1
  2. package/src/components/sale/businessquery/GroupChargeQuery.vue +1 -1
  3. package/src/filiale/gehua/GroupChargeQuery.vue +1 -1
  4. package/src/filiale/macheng/config/exportConfig.js +1 -1
  5. package/src/filiale/shanxian/CancellationQuery.vue +426 -0
  6. package/src/filiale/shanxian/ChangeUserQuery.vue +395 -0
  7. package/src/filiale/shanxian/DeviceQuery.vue +586 -0
  8. package/src/filiale/shanxian/DisableQuery.vue +528 -0
  9. package/src/filiale/shanxian/EnableQuery.vue +461 -0
  10. package/src/filiale/shanxian/FMYGasQuery.vue +731 -0
  11. package/src/filiale/shanxian/FmyGasDeviceQuery.vue +68 -33
  12. package/src/filiale/shanxian/InspectListUserNew.vue +18 -16
  13. package/src/filiale/shanxian/LostContactAnalysisList.vue +19 -18
  14. package/src/filiale/shanxian/MeterQuery.vue +968 -0
  15. package/src/filiale/shanxian/MonthGasQuery.vue +481 -0
  16. package/src/filiale/shanxian/NewQueryInstruct.vue +457 -0
  17. package/src/filiale/shanxian/ReverseQuery.vue +454 -0
  18. package/src/filiale/shanxian/TransferQuery.vue +469 -0
  19. package/src/filiale/shanxian/UserGasAll.vue +15 -14
  20. package/src/filiale/shanxian/UserLostContactAnalysis.vue +18 -17
  21. package/src/filiale/shanxian/UserQuery.vue +27 -26
  22. package/src/filiale/shanxian/config/exportConfig.js +100 -100
  23. package/src/filiale/shanxian/newwebmeter/TotalExceptionByMeter.vue +608 -0
  24. package/src/filiale/shanxian/sale.js +20 -0
  25. package/src/filiale/shanxian/webmeterManage.js +4 -0
  26. package/src/filiale/wenxi/GasStatistics.vue +6 -6
  27. package/src/filiale/wenxi/HandplanQuery.vue +10 -10
  28. package/src/filiale/wenxi/MeterQuery.vue +41 -68
  29. package/.gradle/4.4/fileChanges/last-build.bin +0 -0
  30. package/.gradle/6.1/executionHistory/executionHistory.bin +0 -0
  31. package/.gradle/6.1/executionHistory/executionHistory.lock +0 -0
  32. package/.gradle/6.1/fileChanges/last-build.bin +0 -0
  33. package/.gradle/6.1/fileHashes/fileHashes.bin +0 -0
  34. package/.gradle/6.1/fileHashes/fileHashes.lock +0 -0
@@ -0,0 +1,586 @@
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div class="basic-main" @keyup.enter="search">
4
+ <div class="flex">
5
+ <div style="flex:1;" class="flex" v-if="!show">
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 class="font_normal_body">{{$parent.$parent.usertitle}}编号</label>
12
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_userinfo_code"
13
+ condition="f_userinfo_code = '{}' " placeholder={{$parent.$parent.usertitle}}编号>
14
+ </div>
15
+ <div class="col-sm-2 form-group" >
16
+ <label class="font_normal_body">{{$parent.$parent.usertitle}}名称</label>
17
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
18
+ condition="f_user_name like '%{}%'" placeholder={{$parent.$parent.usertitle}}名称>
19
+ </div>
20
+ <div class="col-sm-2 form-group" >
21
+ <label class="font_normal_body">{{$parent.$parent.usertitle}}地址</label>
22
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_address"
23
+ condition="f_address like '%{}%'" placeholder={{$parent.$parent.usertitle}}地址>
24
+ </div>
25
+ <div class="col-sm-2 form-group">
26
+ <label class="font_normal_body" title="旧客户编号">档案编号</label>
27
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_olduserinfo_code"
28
+ condition="f_olduserinfo_code = '{}' " placeholder="档案编号">
29
+ </div>
30
+
31
+ <div class="span" style = "float:right;">
32
+ <button class="button_search button_spacing" @click="search()">查询</button>
33
+ <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
34
+ <!--<button class="btn btn-default" @click="$parent.$parent.stamp()">打印</button>-->
35
+
36
+ <export-excel :data="$parent.$parent.getCondition"
37
+ :field="$parent.$parent.getExportField"
38
+ :header="$parent.$parent.other"
39
+ v-if="$parent.$parent.authArr.includes('档案查询导出')"
40
+ sqlurl="rs/logic/exportfile" sql-name="deviceQuery" template-name='表具设备查询导出' :choose-col="true"></export-excel>
41
+ <print-data :sum-field="$parent.$parent.getExportField" :model="$parent.model" :field="$parent.$parent.getExportField"
42
+ :defaultfield="$parent.$parent.defaultfield"
43
+ titletable="表具设备查询"
44
+ :sumsmodel="$parent.$parent.sumsmodel"></print-data>
45
+ <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>
46
+ </div>
47
+ </div>
48
+ <div class="row" v-show="$parent.$parent.criteriaShow">
49
+
50
+ <div class="col-sm-2 form-group" >
51
+ <label class="font_normal_body">{{$parent.$parent.usertitle}}电话</label>
52
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_phone"
53
+ condition="f_user_phone like '%{}%'" placeholder={{$parent.$parent.usertitle}}电话>
54
+ </div>
55
+
56
+ <div class="col-sm-2 form-group" >
57
+ <label class="font_normal_body">用户状态</label>
58
+ <v-select :value.sync="model.f_user_state"
59
+ v-model="model.f_user_state"
60
+ :options='$parent.$parent.userstates' placeholder='请选择'
61
+ condition="f_user_state = '{}'"
62
+ close-on-select></v-select>
63
+ </div>
64
+ <div class="col-sm-2 form-group">
65
+ <label class="font_normal_body">{{$parent.$parent.usertitle}}类型</label>
66
+ <v-select :value.sync="model.f_user_type"
67
+ :options='$parent.$parent.usertypes' placeholder='请选择' v-model="model.f_user_type"
68
+ condition="f_user_type = '{}'"
69
+ close-on-select></v-select>
70
+ </div>
71
+ <div class="col-sm-2 form-group" >
72
+ <label class="font_normal_body">所属表&nbsp;&nbsp;&nbsp;</label>
73
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_meternumber"
74
+ condition="f_meternumber like '%{}%'" placeholder='所属表(表号)'>
75
+ </div>
76
+
77
+ <div class="col-sm-2 form-group" >
78
+ <label class="font_normal_body">设备类型</label>
79
+ <v-select :value.sync="model.f_devices_type"
80
+ v-model="model.f_devices_type"
81
+ :options='$parent.$parent.deviceTypes' placeholder='请选择'
82
+ condition="f_devices_type = '{}'"
83
+ close-on-select></v-select>
84
+ </div>
85
+ <div class="col-sm-2 form-group" >
86
+ <label class="font_normal_body">购买方式</label>
87
+ <v-select :value.sync="model.watchpurchase"
88
+ v-model="model.watchpurchase"
89
+ :options='$parent.$parent.watchpurchases' placeholder='请选择'
90
+ condition="watchpurchase = '{}'"
91
+ close-on-select></v-select>
92
+ </div>
93
+ <div class="col-sm-2 form-group" >
94
+ <label class="font_normal_body">管道类型</label>
95
+ <v-select :value.sync="model.f_pipe_type"
96
+ v-model="model.f_pipe_type"
97
+ :options='$parent.$parent.pipetype' placeholder='请选择'
98
+ condition="f_pipe_type = '{}'"
99
+ close-on-select></v-select>
100
+ </div>
101
+ <div class="col-sm-2 form-group">
102
+ <label class="font_normal_body">表&emsp;&emsp;号</label>
103
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_meter_number"
104
+ condition="f_meternumber = '{}'" placeholder='表号'>
105
+ </div>
106
+ <div class="col-sm-2 form-group">
107
+ <label class="font_normal_body">卡&emsp;&emsp;号</label>
108
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_card_id"
109
+ condition="f_card_id = '{}'" placeholder='卡号'>
110
+ </div>
111
+ <div class="col-sm-2 form-group" >
112
+ <label class="font_normal_body">设备编号</label>
113
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_devices_no"
114
+ condition="f_devices_no like '%{}%'" placeholder='设备编号'>
115
+ </div>
116
+ <div class="col-sm-2 form-group" >
117
+ <label class="font_normal_body">设备品牌</label>
118
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_brand"
119
+ condition="f_brand like '%{}%'" placeholder='设备品牌'>
120
+ </div>
121
+ <div class="col-sm-2 form-group" >
122
+ <label class="font_normal_body">设备型号</label>
123
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_devices_model"
124
+ condition="f_devices_model like '%{}%'" placeholder='设备型号'>
125
+ </div>
126
+ <div class="col-sm-2 form-group" >
127
+ <label class="font_normal_body">设备数量</label>
128
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_devices_num"
129
+ condition="f_devices_num = {}" placeholder='设备数量'>
130
+ </div>
131
+ <div class="col-sm-2 form-group" >
132
+ <label class="font_normal_body" title="安装日期大于">安装日期</label>
133
+ <datepicker placeholder="安装日期大于" style="width:60%"
134
+ v-model="model.f_input_start_date"
135
+ :value.sync="model.f_input_start_date"
136
+ :format="'yyyy-MM-dd'"
137
+ :show-reset-button="true"
138
+ condition="f_input_date >= '{} 00:00:00'">
139
+ </datepicker>
140
+ </div>
141
+ <div class="col-sm-2 form-group" >
142
+ <label class="font_normal_body" title="安装日期小于">安装日期</label>
143
+ <datepicker placeholder="安装日期小于" style="width:60%"
144
+ v-model="model.f_input_end_date"
145
+ :value.sync="model.f_input_end_date"
146
+ :format="'yyyy-MM-dd'"
147
+ :show-reset-button="true"
148
+ condition="f_input_date <= '{} 23:59:59'">
149
+ </datepicker>
150
+ </div>
151
+ <div class="col-sm-2 form-group" >
152
+ <label class="font_normal_body" >到期日期</label>
153
+ <datepicker placeholder="到期日期大于" style="width:60%"
154
+ v-model="model.f_expire_start_date"
155
+ :value.sync="model.f_expire_start_date"
156
+ :format="'yyyy-MM-dd'"
157
+ :show-reset-button="true"
158
+ condition="f_expire_date >= '{} 00:00:00'">
159
+ </datepicker>
160
+ </div>
161
+ <div class="col-sm-2 form-group" >
162
+ <label class="font_normal_body">到期日期</label>
163
+ <datepicker placeholder="到期日期小于" style="width:60%"
164
+ v-model="model.f_expire_end_date"
165
+ :value.sync="model.f_expire_end_date"
166
+ :format="'yyyy-MM-dd'"
167
+ :show-reset-button="true"
168
+ condition="f_expire_date <= '{} 23:59:59'">
169
+ </datepicker>
170
+ </div>
171
+ <div class="col-sm-2 form-group" >
172
+ <label class="font_normal_body" title="生产日期大于" >生产日期</label>
173
+ <datepicker placeholder="生产日期大于" style="width:60%"
174
+ v-model="model.f_make_start_date"
175
+ :value.sync="model.f_make_start_date"
176
+ :format="'yyyy-MM-dd'"
177
+ :show-reset-button="true"
178
+ condition="f_make_date >= '{} 00:00:00'">
179
+ </datepicker>
180
+ </div>
181
+ <div class="col-sm-2 form-group" >
182
+ <label class="font_normal_body" title="生产日期小于">生产日期</label>
183
+ <datepicker placeholder="生产日期小于" style="width:60%"
184
+ v-model="model.f_make_end_date"
185
+ :value.sync="model.f_make_end_date"
186
+ :format="'yyyy-MM-dd'"
187
+ :show-reset-button="true"
188
+ condition="f_make_date <= '{} 23:59:59'">
189
+ </datepicker>
190
+ </div>
191
+ <div class="col-sm-2 form-group" >
192
+ <label for="startDate" class="font_normal_body" title="操作开始日期">开始日期</label>
193
+ <datepicker id="startDate" placeholder="开始日期" style="width:60%"
194
+ v-model="model.startDate"
195
+ :value.sync="model.startDate"
196
+ :format="'yyyy-MM-dd'"
197
+ :show-reset-button="true"
198
+ condition="f_operate_date >= '{} 00:00:00'">
199
+ </datepicker>
200
+ </div>
201
+ <div class="col-sm-2 form-group" >
202
+ <label for="endDate" class="font_normal_body" title="操作结束日期">结束日期</label>
203
+ <datepicker id="endDate" placeholder="结束日期" style="width:60%"
204
+ v-model="model.endDate"
205
+ :value.sync="model.endDate"
206
+ :format="'yyyy-MM-dd'"
207
+ :show-reset-button="true"
208
+ condition="f_operate_date <= '{} 23:59:59'">
209
+ </datepicker>
210
+ </div>
211
+ <div class="col-sm-2 form-group" >
212
+ <label class="font_normal_body">使用年限</label>
213
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_service_life"
214
+ condition="f_service_life = '{}'" placeholder='使用年限'>
215
+ </div>
216
+ <div class="col-sm-2 form-group" >
217
+ <label class="font_normal_body">备注信息</label>
218
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_comments"
219
+ condition="f_comments like '%{}%'" placeholder='备注'>
220
+ </div>
221
+ <div class="col-sm-2 form-group">
222
+ <label class="font_normal_body" >抄表员&emsp;</label>
223
+ <v-select :value.sync="model.f_inputtor"
224
+ v-model="model.f_inputtor"
225
+ :options='$parent.$parent.inputtores' placeholder='请选择'
226
+ condition="f_inputtor = '{}'"
227
+ close-on-select :search="false">
228
+ </v-select>
229
+ </div>
230
+ <res-select-group :initres="$parent.$parent.initres" @re-res="$parent.$parent.getRes"></res-select-group>
231
+ </div>
232
+ </div>
233
+ </criteria>
234
+
235
+ <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid>
236
+ <template partial='head'>
237
+ <tr>
238
+ <th>
239
+ <!--<nobr>客户编号</nobr>-->
240
+ <data-order field="f_userinfo_code" :name=`${$parent.$parent.$parent.usertitle}编号` :order.sync="$parent.$parent.$parent.orderFields.f_userinfo_code"></data-order>
241
+ </th>
242
+ <th><nobr>{{$parent.$parent.$parent.usertitle}}名称</nobr></th>
243
+ <th><nobr>档案编号</nobr></th>
244
+ <th><nobr>{{$parent.$parent.$parent.usertitle}}电话</nobr></th>
245
+ <th>
246
+ <!--<nobr>客户地址</nobr>-->
247
+ <data-order field="f_address" :name.sync=`${$parent.$parent.$parent.usertitle}地址` :order.sync="$parent.$parent.$parent.orderFields.f_address"></data-order>
248
+ </th>
249
+ <th><nobr>客户状态</nobr></th>
250
+ <th><nobr>所属表具(表号)</nobr></th>
251
+ <th><nobr>购买方式</nobr></th>
252
+ <th><nobr>设备类型</nobr></th>
253
+ <th><nobr>设备编号</nobr></th>
254
+ <th><nobr>设备品牌</nobr></th>
255
+ <th><nobr>设备型号</nobr></th>
256
+ <th><nobr>设备数量</nobr></th>
257
+ <th><nobr>设备状态</nobr></th>
258
+ <th><nobr>管道类型</nobr></th>
259
+ <th>
260
+ <!--<nobr>生产日期</nobr>-->
261
+ <data-order field="f_make_date" name="生产日期" :order.sync="$parent.$parent.$parent.orderFields.f_make_date"></data-order>
262
+ </th>
263
+ <th><nobr>使用年限</nobr></th>
264
+ <th><nobr>安装人</nobr></th>
265
+ <th>
266
+ <!--<nobr>安装日期</nobr>-->
267
+ <data-order field="f_input_date" name="安装日期" :order.sync="$parent.$parent.$parent.orderFields.f_input_date"></data-order>
268
+ </th>
269
+ <th>
270
+ <!--<nobr>到期日期</nobr>-->
271
+ <data-order field="f_expire_date" name="到期日期" :order.sync="$parent.$parent.$parent.orderFields.f_expire_date"></data-order>
272
+ </th>
273
+ <th><nobr>操作人</nobr></th>
274
+ <th>
275
+ <!--<nobr>操作时间</nobr>-->
276
+ <data-order field="f_operate_date" name="操作时间" :order.sync="$parent.$parent.$parent.orderFields.f_operate_date"></data-order>
277
+ </th>
278
+ <th><nobr>备注</nobr></th>
279
+ </tr>
280
+ </template>
281
+ <template partial='body'>
282
+ <td style="text-align: center;"><nobr>
283
+ <span @click="$parent.$parent.$parent.showmsg(row)"><a>{{row.f_userinfo_code}}</a></span>
284
+ </nobr> </td>
285
+ <td style="text-align: center;"><nobr>{{row.f_user_name}}</nobr></td>
286
+ <td style="text-align: center;"><nobr>{{row.f_olduserinfo_code}}</nobr></td>
287
+ <td style="text-align: center;"><nobr>{{row.f_user_phone}}</nobr></td>
288
+ <td style="text-align: center;"><nobr>{{row.f_address}}</nobr></td>
289
+ <td style="text-align: center;"><nobr>{{row.f_user_state}}</nobr></td>
290
+ <td style="text-align: center;"><nobr>{{row.f_meternumber}}</nobr></td>
291
+ <td style="text-align: center;"><nobr>{{row.watchpurchase}}</nobr></td>
292
+ <td style="text-align: center;"><nobr>{{row.f_devices_type}}</nobr></td>
293
+ <td style="text-align: center;"><nobr>{{row.f_devices_no}}</nobr></td>
294
+ <td style="text-align: center;"><nobr>{{row.f_brand}}</nobr></td>
295
+ <td style="text-align: center;"><nobr>{{row.f_devices_model}}</nobr></td>
296
+ <td style="text-align: center;"><nobr>{{row.f_devices_num}}</nobr></td>
297
+ <td style="text-align: center;"><nobr>{{row.f_userinfodevices_state}}</nobr></td>
298
+ <td style="text-align: center;"><nobr>{{row.f_pipe_type}}</nobr></td>
299
+ <td style="text-align: center;"><nobr>{{row.f_make_date}}</nobr></td>
300
+ <td style="text-align: center;"><nobr>{{row.f_service_life}}</nobr></td>
301
+ <td style="text-align: center;"><nobr>{{row.f_input_person}}</nobr></td>
302
+ <td style="text-align: center;"><nobr>{{row.f_input_date}}</nobr></td>
303
+ <td style="text-align: center;"><nobr>{{row.f_expire_date}}</nobr></td>
304
+ <td style="text-align: center;"><nobr>{{row.f_operator}}</nobr></td>
305
+ <td style="text-align: center;"><nobr>{{row.f_operate_date}}</nobr></td>
306
+ <td style="text-align: center;"><nobr>{{row.f_comments}}</nobr></td>
307
+ </template>
308
+ <template partial='foot'>
309
+
310
+ </template>
311
+ </data-grid>
312
+ </criteria-paged>
313
+
314
+ <table class="table-hover">
315
+ <tr style="position: relative" class="table-bordered">
316
+ <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;color: #5CB95C;font-weight: bold">汇总信息</td>
317
+ <td style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">暂无合计字段</td>
318
+ </tr>
319
+ </table>
320
+
321
+ <modal :show.sync="printshow" v-ref:modal backdrop="false">
322
+ <header slot="modal-header" class="modal-header text-center">
323
+ <h4 class="modal-title">打印列选择</h4>
324
+ <input type="checkbox" class="" id="f_generations" v-model="all">
325
+ <label for="f_generations" class="font-size">全选</label>
326
+ </header>
327
+ <article slot="modal-body">
328
+ <div class="auto col-sm-11 col-md-offset-1" style="margin-top: 10px;">
329
+ <div class="col-sm-3" v-for="f in fields">
330
+ <input type="checkbox" class="" :id="'water-owe-details-'+$index" v-model="modelval" :value="$key">
331
+ <label :for="'water-owe-details-'+$index" class="font-size">{{f}}</label>
332
+ </div>
333
+ </div>
334
+ </article>
335
+ <footer slot="modal-footer" class="modal-footer">
336
+ <center>
337
+ <button v-show="printshow" type="button" class="btn btn-default" @click='close()'>取消</button>
338
+ <button v-show="printshow" type="button" class="btn btn-success" @click='print()'>打印</button>
339
+ <print-table :model='model' v-show="false" v-ref:print
340
+ :top='40' :left='60' :right='40' :bottom='60'
341
+ :thead="thead" :tfoot='tfoot' :attach="yangsen"
342
+ :fields="modelval" :printpage="true">
343
+ </print-table>
344
+ </center>
345
+ </footer>
346
+ </modal>
347
+ </div>
348
+ <div class="flex" v-if="show">
349
+ <user-info-detail-manage-new :f_userinfo_id="rowdata.f_userinfo_id" @cancel-main="cancel"></user-info-detail-manage-new>
350
+ </div>
351
+ </div></div></div>
352
+ </template>
353
+
354
+ <script>
355
+ import { PagedList } from 'vue-client'
356
+ import defaultPrint from './config/DefaultPrint'
357
+ import exportConfig from './config/exportConfig'
358
+
359
+ let readySomething = async function (self) {
360
+ self.defaultfield = [...self.defaultfield, ...self.config.defaultPrint]
361
+ self.$MagGetSaleParam.initinputtor();
362
+ self.getinputtores();
363
+ // self.$refs.paged.$refs.cri.model.startDate = self.$login.toStandardDateString()
364
+ // self.$refs.paged.$refs.cri.model.endDate = self.$login.toStandardDateString()
365
+ // await self.$refs.paged.$refs.cri.search()
366
+ }
367
+ export default {
368
+ title: '表具设备查询',
369
+ data() {
370
+ return {
371
+ other:[],
372
+ footer:[],
373
+ model: new PagedList('rs/sql/deviceQuery', 20, {orderitem: this.orderitem?'"' + this.orderitem + ' "':`'f_userinfo_code desc'`}),
374
+ criteriaShow: false,
375
+ orgCondtionStr: '',
376
+ modelval: [],
377
+ printshow: false,
378
+ all: false,
379
+ fields: {},
380
+ //排序
381
+ orderitem:'f_userinfo_code desc',
382
+ orderFields: {
383
+ f_userinfo_id: 'no'
384
+ },
385
+ thead: '',
386
+ tfoot: '',
387
+ defaultfield: [],
388
+ config: {
389
+ defaultPrint: ['f_userinfo_code', 'f_user_name', 'f_user_phone']
390
+ },
391
+ show:false,
392
+ usertitle: this.$appdata.getSingleValue('用户名称前缀') ? this.$appdata.getSingleValue('用户名称前缀') : '客户',
393
+ rowdata:{},
394
+ // 下拉框参数
395
+ inputtores:[],
396
+ usertypes:this.$appdata.getParam('用户类型') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('用户类型')] : [],
397
+ userstates:this.$appdata.getParam('用户状态') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('用户状态')] : [],
398
+ deviceTypes: this.$appdata.getParam('设备类型') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('设备类型')] : [],
399
+ // brand: this.$appdata.getParam('设备品牌') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('设备品牌')] : [],
400
+ watchpurchases: this.$appdata.getParam('购买方式') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('购买方式')] : [],
401
+ pipetype: this.$appdata.getParam('管道类型') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('管道类型')] : [],
402
+ initres: {
403
+ org:[this.$login.f.orgid],
404
+ dep:[],
405
+ user:[],
406
+ },
407
+ // 合计数据
408
+ sumsmodel: {}
409
+ }
410
+ },
411
+ ready(){
412
+ readySomething(this).then(() => {
413
+ this.$emit('ready')
414
+ }).catch((error) => {
415
+ this.$emit('error', error)
416
+ })
417
+ },
418
+ methods: {
419
+ async getinputtores () {
420
+ // 获取抄表员
421
+ let rs = []
422
+ if (this.$login.f.f_gasman.length > 0) {
423
+ for (let i = 0; i < this.$login.f.f_gasman.length; i++) {
424
+ let temp = {
425
+ label: this.$login.f.f_gasman[i].name,
426
+ value: this.$login.f.f_gasman[i].name
427
+ }
428
+ rs.push(temp)
429
+ }
430
+ }
431
+ this.inputtores = [{label: '全部', value: ''}, ...rs]
432
+ },
433
+ getotherfooter () {
434
+ // this.$refs.paged.$refs.cri.$refs.exports.otherData = [];
435
+ // this.$refs.paged.$refs.cri.$refs.exports.footerData = [];
436
+ this.other = [];
437
+ this.footer = [];
438
+ let exportdata = this.getCondition;
439
+ let otherInData = [];
440
+ otherInData.push(`导出时间: ${this.$login.toStandardTimeString()}`);
441
+ // let footerData = [], exportfield = this.getExportField;
442
+ // footerData.push("合计");
443
+ // let self = this;
444
+ // for (var field in self.sumsmodel) {
445
+ // footerData.push(`${exportfield[field]}合计:${self.sumsmodel[field]}`);
446
+ // }
447
+ // this.footer.push(footerData);
448
+ this.other.push(otherInData);
449
+ },
450
+ search(){
451
+ this.$refs.paged.$refs.cri.search()
452
+ },
453
+ cancel() {
454
+ this.show = false
455
+ },
456
+ showmsg(obj){
457
+ this.rowdata=obj
458
+ this.show=true
459
+ },
460
+ selfSearch (args) {
461
+ if (!this.orgCondtionStr) {
462
+ args.condition = `${args.condition}` + " and f_orgid = " + this.$login.f.orgid
463
+ } else {
464
+ args.condition = `${args.condition}` + this.orgCondtionStr
465
+ }
466
+
467
+ this.model.search(args.condition, args.model)
468
+ this.sumsmodel = this.$refs.paged.$refs.grid.model.sums
469
+ console.log('合计字段',this.sumsmodel)
470
+ },
471
+ clear(){
472
+ Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
473
+ this.$refs.paged.$refs.cri.model[key] = []
474
+ })
475
+ },
476
+ hidden(){
477
+ this.criteriaShow = !this.criteriaShow
478
+ },
479
+ getRes(obj) {
480
+ this.orgCondtionStr = obj
481
+ },
482
+ stamp () {
483
+ this.all = false
484
+ //默认选择要打印的列
485
+ this.modelval = defaultPrint.config
486
+ this.fields = this.getfield
487
+ console.log('所有打印字段',this.fields)
488
+ this.printshow = true
489
+ this.put()
490
+ },
491
+ put () {
492
+ // 对Modelval进行排序
493
+ this.sortModelval()
494
+ this.thead = `<tr><th colspan=${this.modelval.length}>设备查询统计报表</th></tr><tr>`
495
+ for (let key of this.modelval) {
496
+ this.thead += '<th>' + this.fields[key] + '</th>'
497
+ }
498
+ this.thead += '</tr>'
499
+ },
500
+ print () {
501
+ this.$refs.print.PrintAsFile()
502
+ this.printshow = false
503
+ },
504
+ close () {
505
+ this.printshow = false
506
+ this.all = false
507
+ },
508
+ // 对选择的列进行排序
509
+ sortModelval () {
510
+ let sortModel = []
511
+ Object.keys(this.fields).forEach((key) => {
512
+ if (this.modelval.includes(key)) {
513
+ sortModel.push(key)
514
+ }
515
+ })
516
+ this.modelval = sortModel
517
+ console.log('选择的打印的字段', this.modelval)
518
+ },
519
+ sort (field, rule) {
520
+ // 将所有排序方式设为不排序,实现相互排斥
521
+ for (let key in this.orderFields) {
522
+ if (key === field) {
523
+ this.orderFields[key] = rule
524
+ } else {
525
+ this.orderFields[key] = 'no'
526
+ }
527
+ }
528
+ // 如果新规则不排序,还原为默认排序
529
+ if (rule === 'no') {
530
+ this.model.paramSource.orderitem = `'${this.orderitem}'`
531
+ } else {
532
+ this.model.paramSource.orderitem = `'${field} ${rule}'`
533
+ }
534
+
535
+ this.search()
536
+ }
537
+ },
538
+ watch:{
539
+ 'all' (val) {
540
+ if (val) {
541
+ this.modelval = this.bodyData
542
+ } else {
543
+ this.modelval = defaultPrint.config
544
+ this.put()
545
+ }
546
+ },
547
+ sumsmodel:{
548
+ handler: function(val) {
549
+ this.getotherfooter();
550
+ },
551
+ deep: true
552
+ },
553
+ 'modelval.length' () {
554
+ this.put()
555
+ },
556
+ },
557
+ computed:{
558
+ authArr () {
559
+ return this.$login.r ? this.$login.r : []
560
+ },
561
+ getCondition(){
562
+ return {condition: `${this.$refs.paged.$refs.cri.condition}`+this.orgCondtionStr,orderitem:this.orderitem}
563
+ },
564
+ getfield(){
565
+ let data = {}
566
+ this.bodyData.forEach((value, index)=>{
567
+ data[this.bodyData[index]] = this.headData[index]
568
+ })
569
+ //合计字段打印
570
+ this.tfoot = `<tr><th colspan=${this.modelval.length}>全表汇总信息: `
571
+ if(this.sumsmodel){
572
+ Object.keys(this.sumsmodel).forEach((key) => {
573
+ this.tfoot += this.fields[key] + '合计: ' + `<font color="blue">${this.sumsmodel[key]} </font>`
574
+ })
575
+ }else{
576
+ this.tfoot += '暂无'
577
+ }
578
+ this.tfoot += '</th></tr>'
579
+ return data
580
+ },
581
+ getExportField() {
582
+ return exportConfig.deviceConfig
583
+ }
584
+ }
585
+ }
586
+ </script>