sale-client 3.6.21 → 3.6.23

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 (88) hide show
  1. package/build/dev-server.js +1 -1
  2. package/package.json +2 -2
  3. package/src/components/FilesManage/FileUserFiles.vue +1014 -1014
  4. package/src/components/FilesManage/FileUserMerge.vue +203 -203
  5. package/src/components/FilesManage/UserPaperInfoTest.vue +58 -51
  6. package/src/components/FilesManageNew/FileUserFiles.vue +756 -756
  7. package/src/components/FilesManageNew/FileUserMerge.vue +202 -202
  8. package/src/components/charge/business/CardMeterCenter.vue +944 -944
  9. package/src/components/charge/business/IOTMeterCenter.vue +793 -793
  10. package/src/components/charge/business/OtherChargeNew.vue +550 -550
  11. package/src/components/charge/business/machine/MachineMeterCenter.vue +676 -676
  12. package/src/components/charge/gasloss/gasLossOperate.vue +383 -383
  13. package/src/components/newBill/CardMeterCenter.vue +902 -902
  14. package/src/components/newBill/IOTMeterCenter.vue +797 -797
  15. package/src/components/revenue/Common/EticketModal.vue +95 -90
  16. package/src/components/revenue/comprehen/Maintenance/T+MoneyDocking/moneyDocking.vue +202 -202
  17. package/src/components/revenue/comprehen/SpecialUser/BasicLiving/BasicLivingList.vue +280 -280
  18. package/src/filiale/alashan/business/CardMeterCenter.vue +897 -897
  19. package/src/filiale/ancheng/FilesManage/FileUserFiles.vue +1010 -1010
  20. package/src/filiale/ancheng/FilesManageNew/FileUserFiles.vue +763 -763
  21. package/src/filiale/chengtou/components/FilesManage/FileUserFiles.vue +1019 -1019
  22. package/src/filiale/chengtou/components/OtherChargeNew.vue +549 -549
  23. package/src/filiale/dongguan/components/FilesManage/FileUserFiles.vue +1037 -1037
  24. package/src/filiale/gaomi/components/FilesManage/FileUserFiles.vue +934 -934
  25. package/src/filiale/gehua/CardMeterCenter.vue +898 -898
  26. package/src/filiale/gehua/FileManageNew/FileUserFiles.vue +769 -769
  27. package/src/filiale/gehua/FileUserFiles.vue +1007 -1007
  28. package/src/filiale/gehua/IOTMeterCenter.vue +791 -791
  29. package/src/filiale/gehua/MachineMeterCenter.vue +685 -685
  30. package/src/filiale/gehua/OtherChargeNew.vue +558 -558
  31. package/src/filiale/guangxi/CardMeterCenter.vue +891 -891
  32. package/src/filiale/guangxi/IOTMeterCenter.vue +774 -774
  33. package/src/filiale/guangxi/MachineMeterCenter.vue +622 -622
  34. package/src/filiale/haile/MachineMeterCenter.vue +762 -762
  35. package/src/filiale/huayin/CardMeterCenter.vue +903 -903
  36. package/src/filiale/huayin/FileUserFiles.vue +1007 -1007
  37. package/src/filiale/huayin/IOTMeterCenter.vue +796 -796
  38. package/src/filiale/huayin/MachineMeterCenter.vue +680 -680
  39. package/src/filiale/jingwei/CardMeterCenter.vue +870 -870
  40. package/src/filiale/jingwei/FileUserFiles.vue +905 -905
  41. package/src/filiale/jingwei/ShowCardSellGas.vue +903 -903
  42. package/src/filiale/kelai/CardMeterCenter.vue +934 -934
  43. package/src/filiale/kelai/FileUserFiles.vue +762 -762
  44. package/src/filiale/kelai/IOTMeterCenter.vue +833 -833
  45. package/src/filiale/kelai/MachineMeterCenter.vue +705 -705
  46. package/src/filiale/konggang/FileUserFiles.vue +990 -990
  47. package/src/filiale/liaoyuan/FileUserFiles.vue +844 -844
  48. package/src/filiale/macheng/CardMeterCenter.vue +939 -939
  49. package/src/filiale/macheng/FileUserFiles.vue +930 -930
  50. package/src/filiale/meihekou/FileUserFiles.vue +995 -995
  51. package/src/filiale/ningjin/FileUserFiles.vue +1020 -1020
  52. package/src/filiale/qianneng/OtherChargeNew.vue +544 -544
  53. package/src/filiale/qianneng/eticket/EticketModal.vue +96 -91
  54. package/src/filiale/qianneng/eticket/EticketPrint.vue +377 -376
  55. package/src/filiale/qianneng/eticket/EticketRecordList.vue +309 -289
  56. package/src/filiale/qianneng/machine/MachineMeterCenter.vue +676 -676
  57. package/src/filiale/rizhao/FileUserFiles.vue +984 -984
  58. package/src/filiale/rizhao/IOTMeterCenter.vue +795 -795
  59. package/src/filiale/rongcheng/FileUserFiles.vue +881 -881
  60. package/src/filiale/rongcheng/FilesManageNew/FileUserFiles.vue +732 -732
  61. package/src/filiale/rongcheng/FilesManageNew/FileUserMerge.vue +202 -202
  62. package/src/filiale/shanggao/FileUserFiles.vue +995 -995
  63. package/src/filiale/shangluo/CardMeterCenter.vue +892 -892
  64. package/src/filiale/shangluo/IOTMeterCenter.vue +797 -797
  65. package/src/filiale/shangluo/MachineMeterCenter.vue +734 -734
  66. package/src/filiale/shanxian/OtherChargeNew.vue +561 -561
  67. package/src/filiale/shanxian/components/FilesManage/FileUserFiles.vue +1004 -1004
  68. package/src/filiale/shanxian/components/FilesManageNew/FileUserFiles.vue +756 -756
  69. package/src/filiale/shanxian/components/revenue/CardMeterCenter.vue +944 -944
  70. package/src/filiale/shaoguan/FilesManage/FileUserFiles.vue +881 -881
  71. package/src/filiale/shaoguan/FilesManageNew/FileUserFiles.vue +734 -734
  72. package/src/filiale/shexian/FilesManage/FileUserFiles.vue +991 -991
  73. package/src/filiale/tongchuan/BasicLivingList.vue +253 -253
  74. package/src/filiale/tongchuan/CardMeterCenter.vue +923 -923
  75. package/src/filiale/tongchuan/FileUserFiles.vue +1206 -1206
  76. package/src/filiale/tongchuan/bill/EticketModal.vue +90 -90
  77. package/src/filiale/tongchuan/filemanagenew/FileUserFiles.vue +842 -842
  78. package/src/filiale/wenxi/CardMeterCenter.vue +942 -942
  79. package/src/filiale/wenxi/FileUserFiles.vue +1032 -1032
  80. package/src/filiale/wenxi/IOTMeterCenter.vue +774 -774
  81. package/src/filiale/wuan/FileUserFiles.vue +1006 -1006
  82. package/src/filiale/wuhai/CardMeterCenter.vue +945 -945
  83. package/src/filiale/wuhai/IOTMeterCenter.vue +757 -757
  84. package/src/filiale/yuansheng/CardMeterCenter.vue +950 -950
  85. package/src/filiale/yuansheng/IOTMeterCenter.vue +788 -788
  86. package/src/filiale/zhongsheng/FilesManage/FileUserFiles.vue +1038 -1038
  87. package/src/filiale/zhongyi/FileUserFiles.vue +1020 -1020
  88. package/src/main.js +27 -27
@@ -1,842 +1,842 @@
1
- <template>
2
- <div id="file-user-files" class="binary">
3
- <div :class="{'basic-main': !createFile,'binary-left': createFile}" >
4
- <div class="flex" style="flex: 1;">
5
- <div style="flex: 1.2">
6
- <criteria-paged :model="model" v-ref:paged @sort="sort">
7
- <criteria @condition-changed="$parent.selfSearch" partial='criteria' v-ref:criteria>
8
- <div class="form-horizontal select-overspread container-fluid auto" novalidate partial>
9
- <div class="row">
10
- <res-select-group :initres="$parent.$parent.initres"
11
- :show-component="['company','department','operator']"
12
- @re-res="$parent.$parent.getRes"
13
- v-ref:sel></res-select-group>
14
- <div
15
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
16
- class="form-group button-range">
17
- <!--<button class="button_search button_spacing" style="width: 90px" @click="$parent.$parent.showFileInfo()">查看批量状态-->
18
- <!--</button>-->
19
- <button @click="search(), $parent.$parent.clean()" class="button_search button_spacing"
20
- style="float: right">查询
21
- </button>
22
- <button @click="$parent.$parent.clear()" class="button_clear button_spacing"
23
- style="float: right">清空
24
- </button>
25
- <button @click="$parent.$parent.createnewfile()" class="button_search button_spacing"
26
- style="float: right">单户建档
27
- </button>
28
- <button class="button_search button_spacing" style="width: 90px" @click="$parent.$parent.createInfoForFile()">批量建档
29
- </button>
30
- <button @click="$parent.$parent.importFile" class="button_export button_spacing"
31
- style="float: right" v-if="false">导入
32
- </button>
33
- <!-- <button class="button_search" style="width: 90px" @click=" $parent.$parent.selectaddress()">选择地址</button>-->
34
- <button @click="$parent.$parent.bulkOperations('批量销户', 'batch-cancellation')"
35
- class="button_delete button_spacing"
36
- style="float: right"
37
- v-if="$parent.$parent.rows && $parent.$parent.rows.length === 1 && $parent.$parent.rows[0].f_user_state !== '正常'">
38
- 销户
39
- </button>
40
- <button @click="$parent.$parent.bulkOperations('批量启用', 'batch-enable')"
41
- class="button_search button_spacing"
42
- style="float: right"
43
- v-if="$parent.$parent.rows && $parent.$parent.rows.length === 1 && $parent.$parent.rows[0].f_user_state === '销户'">
44
- 启用
45
- </button>
46
- <div
47
- :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
48
- @click="$parent.$parent.hidden()"
49
- class="button_spacing"
50
- style="float: right"></div>
51
- </div>
52
- </div>
53
- <div class="row" v-if="$parent.$parent.criteriaShow">
54
- <div
55
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
56
- class="form-group"
57
- v-if="$parent.$parent.clientWidth>1600">
58
- <label class="font_normal_body">客户编号</label>
59
- <input class="input_search" condition="f_userinfo_code like '%{}%'"
60
- placeholder='客户编号'
61
- style="width:60%" type="text" v-model="model.f_userinfo_code">
62
- </div>
63
- <div
64
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
65
- class="form-group" v-if="!$parent.$parent.createFile">
66
- <label class="font_normal_body">客户名称</label>
67
- <input class="input_search" condition="f_user_name = '{}'"
68
- placeholder='客户姓名'
69
- style="width:60%" type="text" v-model="model.f_user_name">
70
- </div>
71
- <div
72
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
73
- class="form-group">
74
- <label class="font_normal_body">用气性质</label>
75
- <v-select :options='$parent.$parent.gasproperties' :value.sync="model.f_gasproperties"
76
- close-on-select condition="f_gasproperties='{}'"
77
- placeholder='用气性质' v-model="model.f_gasproperties"></v-select>
78
- </div>
79
- <div
80
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
81
- class="form-group">
82
- <label class="font_normal_body">客户电话</label>
83
- <input class="input_search" condition="f_user_phone = '{}'" placeholder='客户电话' style="width:60%"
84
- type="text"
85
- v-model="model.f_user_phone">
86
- </div>
87
- <div
88
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
89
- class="form-group">
90
- <label class="font_normal_body">客户地址</label>
91
- <input class="input_search" condition="f_address like '%{}%'" placeholder='客户地址' style="width:60%"
92
- type="text" v-model="model.f_address">
93
- </div>
94
- <div
95
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
96
- class="form-group">
97
- <label class="font_normal_body">客户状态</label>
98
- <v-select :options='$parent.$parent.userstates' :value.sync="model.f_user_state"
99
- close-on-select condition="f_user_state='{}'"
100
- :value-single="true"
101
- placeholder='客户状态' v-model="model.f_user_state"></v-select>
102
- </div>
103
- <div
104
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
105
- class="form-group">
106
- <label class="font_normal_body">调&ensp;压&ensp;箱</label>
107
- <v-select :options='$parent.$parent.adjustables' :search='true'
108
- :value.sync="model.f_adjustable_id"
109
- close-on-select
110
- condition="f_adjustable_id = '{}'" placeholder='调压箱'
111
- v-model='model.f_adjustable_id'></v-select>
112
- </div>
113
- <div
114
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
115
- class="form-group">
116
- <label class="font_normal_body">建档时间</label>
117
- <datepicker placeholder="开始日期" v-model="model.startDate" :value.sync="model.startDate" style="width:60%"
118
- :format="'yyyy-MM-dd'" condition="f_createfile_date >= '{}'">
119
- </datepicker>
120
- </div>
121
- <div
122
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
123
- class="form-group">
124
- <label class="font_normal_body">&emsp;&ensp;至&ensp;&emsp;</label>
125
- <datepicker placeholder="结束日期" v-model="model.endDate" :value.sync="model.endDate" style="width:60%"
126
- :format="'yyyy-MM-dd'" condition="f_createfile_date <= '{}'">
127
- </datepicker>
128
- </div>
129
- <div
130
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
131
- class="form-group">
132
- <label class="font_normal_body">打印时间</label>
133
- <datepicker placeholder="开始日期" v-model="model.startPrintDate" :value.sync="model.startPrintDate" style="width:60%"
134
- :format="'yyyy-MM-dd'" condition="f_printdate >= '{}'">
135
- </datepicker>
136
- </div>
137
- <div
138
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
139
- class="form-group">
140
- <label class="font_normal_body">打印时间</label>
141
- <datepicker placeholder="结束日期" v-model="model.endPrintDate" :value.sync="model.endPrintDate" style="width:60%"
142
- :format="'yyyy-MM-dd'" condition="f_printdate <= '{}'">
143
- </datepicker>
144
- </div>
145
- <div
146
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
147
- class="form-group">
148
- <label class="font_normal_body">工业备注</label>
149
- <v-select :options='$parent.$parent.industrycomments' :value.sync="model.f_industry_comments"
150
- close-on-select condition="f_industry_comments='{}'"
151
- placeholder='气表类型' v-model="model.f_industry_comments"></v-select>
152
- </div>
153
- <div
154
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
155
- class="form-group">
156
- <label class="font_normal_body">小&emsp;&emsp;区</label>
157
- <input class="input_search" condition="f_residential_area like '%{}%'" placeholder='小区' style="width:60%"
158
- type="text" v-model="model.f_residential_area">
159
- </div>
160
- <div
161
- :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
162
- class="form-group">
163
- <label class="font_normal_body">选择区域</label>
164
- <v-select
165
- v-model="model.f_pcd"
166
- placeholder='选择区域'
167
- :value.sync="model.f_pcd"
168
- :options='$parent.$parent.pcdslist'
169
- condition="f_pcd_id = '{}'"
170
- style="width: 60%"
171
- close-on-select >
172
- </v-select>
173
- </div>
174
- <!--<div-->
175
- <!--:class="{'col-sm-3':$parent.$parent.clientWidth>1600||!$parent.$parent.createFile,'col-sm-4':$parent.$parent.clientWidth<1600&&$parent.$parent.createFile}"-->
176
- <!--class="form-group">-->
177
- <!--<label class="font_normal_body">天然气使用证</label>-->
178
- <!--<v-select :options='$parent.$parent.usegas' :value.sync="model.f_send_usegas_card"-->
179
- <!--close-on-select condition="f_send_usegas_card='{}'"-->
180
- <!--placeholder='天然气使用证' v-model="model.f_send_usegas_card"></v-select>-->
181
- <!--</div>-->
182
- </div>
183
- </div>
184
- </criteria>
185
- <data-grid :model="model" class="list_area table_sy" v-ref:grid partial='list'>
186
- <template partial='head'>
187
- <tr>
188
- <th>
189
- <nobr>序号</nobr>
190
- </th>
191
- <th>
192
- <nobr>客户编号</nobr>
193
- </th>
194
- <th>
195
- <nobr>客户名称</nobr>
196
- </th>
197
- <th>
198
- <nobr>客户电话</nobr>
199
- </th>
200
- <th v-if="!$parent.$parent.$parent.isOper">
201
- <nobr>地址信息</nobr>
202
- </th>
203
- <th>
204
- <nobr>状态</nobr>
205
- </th>
206
- <th>
207
- <nobr>建档时间</nobr>
208
- </th>
209
- <th>
210
- <nobr>打印时间</nobr>
211
- </th>
212
- <th>
213
- <nobr>打印状态</nobr>
214
- </th>
215
- <th>
216
- <nobr>操作</nobr>
217
- </th>
218
- </tr>
219
- </template>
220
- <template partial='body'>
221
- <td style="text-align: center;">{{$index + 1}}</td>
222
- <td style="text-align: center;">{{row.f_userinfo_code}}</td>
223
- <td style="text-align: center;">{{row.f_user_name}}</td>
224
- <td style="text-align: center;">{{row.f_user_phone}}</td>
225
- <td style="text-align: center;" v-if="!$parent.$parent.$parent.isOper">{{row.f_address_detail ? row.f_address + row.f_address_detail :
226
- row.f_address}}
227
- </td>
228
- <td style="text-align: center;">{{row.f_user_state}}</td>
229
- <td style="text-align: center;">{{row.f_createfile_date}}</td>
230
- <td style="text-align: center;">{{row.f_printdate}}</td>
231
- <td style="text-align: center;">
232
- <div>{{row.print_stats}}</div>
233
- </td>
234
- <td style="text-align: center;">
235
- <button type="button" name="button" class="button_search-2 button_spacing width-60"
236
- v-if="row.f_user_state === '正常' || row.f_user_state==='预备'"
237
- @click.stop="$parent.$parent.$parent.modifyUser(row)">修正
238
- </button>
239
- </td>
240
- </template>
241
- </data-grid>
242
- </criteria-paged>
243
- </div>
244
- <div v-if="batcan || batenable">
245
- <batch-cancellation v-if="batcan" :useraccount="model.rows" @clean="batchClean"
246
- @success="batchSuccess"></batch-cancellation>
247
- <batch-enable v-if="batenable" :useraccount="model.rows" @clean="batchClean"
248
- @success="batchSuccess"></batch-enable>
249
- </div>
250
- </div>
251
- </div>
252
- <div class="binary-right" :style="{width:'70%'}" v-if="createFile">
253
- <div class="auto" style="height: 100%; margin-top: 1%" >
254
- <file-user-general-info-new :f_filialeid="f_filialeid" :row="row" :areainfo="areainfo"
255
- :haslimit="config.hasLimit" @success="renew" @clean="clean"
256
- :isedit="isedit" :configs="configs"
257
- @build-success="buildFileSuccess" v-ref:info></file-user-general-info-new>
258
- </div>
259
- </div>
260
-
261
- <modal :show.sync="show" width="500px" title="文件导入" v-ref:modal large backdrop="false">
262
- <article slot="modal-body" class="modal-body">
263
- <file-upload class="my-file-uploader " name="UploadFile" class="btn btn-success" style="border-radius: 2px;"
264
- action="rs/file/uploadFile" tagname="导入档案" v-ref:file :headers="headers"></file-upload>
265
- </article>
266
- <footer slot="modal-footer" class="modal-footer">
267
- </footer>
268
- </modal>
269
- <modal :show.sync="batchMeterShow" width="500px" title="文件导入" v-ref:modal large backdrop="false">
270
- <article slot="modal-body" class="modal-body">
271
- <file-upload class="my-file-uploader" name="useraddressUploadFile" action="rs/file/uploadFile" tagname="确定" multiple v-ref:file></file-upload>
272
- </article>
273
- <footer slot="modal-footer" class="modal-footer">
274
- </footer>
275
- </modal>
276
- <user-flow-sheet :show="printflag" :bill-config='configs' :bill-data='billData' :data='newdata' v-on:toggle="close" @printok="printok" v-ref:printbill></user-flow-sheet>
277
- <modal :show.sync="progressShow" v-ref:modal width="50%" style="width:auto;" backdrop="false" >
278
- <header slot="modal-header" class="modal-header">
279
- 批量建档
280
- </header>
281
- <article slot="modal-body" class="modal-body">
282
- <div class="progress" style="margin: 20px" >
283
- <div class="progress-bar progress-bar-success progress-bar-striped active" :style="{width: percent+'%'}">
284
- {{percent}}%
285
- </div>
286
- </div>
287
- <div style="width:100%;display: flex">
288
- <p style="text-align: center;width: 100%;" v-show="!downbutton">文件正在导入..</p>
289
- <p style="text-align: center;width: 100%;" v-show="downbutton">导入成功:{{inputsuccessmage}}</p>
290
- </div>
291
- </article>
292
- <footer slot="modal-footer" class="modal-footer">
293
- <button type="button" class="btn btn-default" @click='closeRequeset'>关闭</button>
294
- </footer>
295
- </modal>
296
-
297
- </div>
298
- </template>
299
-
300
- <script>
301
- import {PagedList, HttpResetClass} from 'vue-client'
302
- import Vue from 'vue'
303
- import co from 'co'
304
- import axios from 'axios'
305
-
306
- let loadParamGem = async function (self) {
307
- await self.$getConfig(self, 'UserFiles')
308
- self.headers.username = Vue.$login.f.name
309
- self.headers.username = Vue.$login.guid()
310
- await self.$LoadParams.loadParam(self.f_filialeid)
311
-
312
- let req = await self.$resetpost('rs/sql/address_singleTableOrderBy?pageNo=1&pageSize=9999999', {
313
- data: {
314
- items: '*',
315
- tablename: 't_pcd',
316
- orderitem: 'id',
317
- condition: `1=1 and f_filialeid = '${self.$login.f.orgid}'`
318
- }
319
- }, {resolveMsg: null, rejectMsg: '获取地址失败!'})
320
- let redata = []
321
- req.data.forEach((row, n) => {
322
- redata[n] = {
323
- label: row.f_pcd,
324
- value: row.id,
325
- data: row,
326
- id: row.id
327
- }
328
- })
329
- self.pcdslist = redata
330
- // await self.$LoadParams.loadMeterBook(self.f_filialeid)
331
- await self.search()
332
- self.initAdjustables()
333
- }
334
-
335
- let addressInfoGen = async function (self, areainfo) {
336
- areainfo.isEdit = false
337
- if (areainfo.file_num > 0 && !areainfo.f_userinfo_id) {
338
- // 完善
339
- // 将表档案信息带入,完善客户信息
340
- let getMetersInfo = await self.$resetpost('rs/logic/sale_getMeterByAddress', {
341
- data: {
342
- f_useraddress_id: areainfo.id
343
- }
344
- }, {resolveMsg: null, rejectMsg: '获取表信息出错'})
345
- areainfo.meter = getMetersInfo.data[0]
346
- }
347
- if (areainfo.file_num > 0 && areainfo.f_userinfo_id) {
348
- // 添加 将客户信息带入
349
- let getUserinfo = await self.$resetpost('rs/sql/saleSingleTable', {
350
- data: {
351
- tablename: 't_userinfo',
352
- condition: `f_userinfo_id = '${areainfo.f_userinfo_id}'`
353
- }
354
- }, {resolveMsg: null, rejectMsg: '获取档案出错'})
355
-
356
- areainfo.user = getUserinfo.data[0]
357
- }
358
- self.bulidFiles(areainfo)
359
- }
360
-
361
- export default {
362
- 'title': '预备户管理',
363
- data () {
364
- return {
365
- config: {
366
- createType: ['address', 'area'], // 建档方式: address-地址建档 area-小区建档
367
- hasLimit: true
368
- },
369
- model: new PagedList('rs/sql/filemanage_getUserfies', 30, {orderitem: '"f_userinfo_id DESC"'}),
370
- row: null, // 选择一条客户信息,对其进行修改
371
- areainfo: null, // 小区批量建档使用的数据
372
- rows: [], // 客户档案选择一条时,将只显示一条信息,rows用来存放整页的数据
373
- headers: {'username': this.$login.f.name, 'blodid': this.$login.guid()},
374
- contract: [{label: '全部', value: ' is null or f_contract_id is not null'}, {
375
- label: '有',
376
- value: ' is not null'
377
- },
378
- {label: '无', value: ' is null'}],
379
- industrycomments: this.$appdata.getParam('工业备注') ? [{
380
- label: '全部',
381
- value: ''
382
- }, ...this.$appdata.getParam('工业备注')] : [],
383
- orderDefault: 'f_createfile_date desc',
384
- orderFields: {
385
- f_userinfo_id: 'no'
386
- },
387
-
388
- createFile: false,
389
-
390
- initres: {
391
- org: [this.$login.f.orgid],
392
- dep: [],
393
- user: []
394
- },
395
- curorgid: [this.$login.f.orgid],
396
- f_filialeid: this.$login.f.orgid,
397
-
398
- // 销户启用
399
- batcan: false,
400
- batenable: false,
401
- version: '',
402
-
403
- pcdslist: [],
404
- inputtores: this.$appdata.getParam('抄表员'),
405
- adjustables: [],
406
-
407
- // 导入组件
408
- show: false,
409
-
410
- // 点击建档或修正时控制列表展示, 防止拥挤
411
- isOper: false,
412
-
413
- criteriaShow: false,
414
-
415
- gasproperties: this.$appdata.getParam('用气性质') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('用气性质')] : [],
416
- f_user_state: '预备',
417
- showselectaddress: false,
418
- isedit: false,
419
- clientWidth: document.body.clientWidth,
420
- batchMeterShow: false,
421
- billData: {
422
- url: 'rs/report/userignition',
423
- bill: ''
424
- },
425
- configs: {
426
- hasPrint: false, // 默认打票
427
- hasBillManage: false // 默认不启用发票管理
428
- },
429
- printflag: false,
430
- orgCondtionStr: '',
431
- newdata: {},
432
- downbutton:false,
433
- percent:0,
434
- timer:'',
435
- uuida:'',
436
- progressShow:false,
437
- inputsuccessmage:''
438
- }
439
- },
440
- ready () {
441
- this.$refs.paged.$refs.criteria.model.f_user_state = this.f_user_state
442
- loadParamGem(this)
443
- },
444
- compiled () {
445
- window.onresize = () => {
446
- return (() => {
447
- this.clientWidth = document.body.clientWidth
448
- })()
449
- }
450
- },
451
- methods: {
452
- progressclose(){
453
- if(this.timer != null){
454
- clearInterval(this.timer);
455
- }
456
- this.progressShow = false;
457
- this.percent=0;
458
- },
459
- closeRequeset(){
460
- this.$showMessage("确定关闭吗,当前正常导入,关闭后将无法获取导入进度!",['confirm','cancel']).then(res=>{
461
- if(res === 'confirm'){
462
- if(this.timer != null){
463
- clearInterval(this.timer);
464
- }
465
- this.progressclose();
466
- this.percent=0;
467
- this.uuida='';
468
- this.downbutton=false;
469
- }
470
- })
471
- },
472
- async getRequestReturn(){
473
- let timer = null;
474
- let self = this;
475
- let param = {
476
- uuid:this.uuida
477
- };
478
- this.timer = setInterval(function(){
479
- self.$resetpost('/rs/logic/getBatchOperaPro',{data:param},{resolveMsg: null, rejectMsg: null}, 0).then((res)=>{
480
- if(res.data && res.data.speed ){
481
- if(res.data.speed==100 || res.data.speed>100 ){
482
- clearInterval(self.timer);
483
- self.percent = 99;
484
- setTimeout(function(){
485
- self.percent = 100
486
- self.inputsuccessmage = `本次上传共上传${res.data.totalsum}条数据, 成功${res.data.successsum}条,失败${res.data.errorsum}条,具体失败数据请在稽查查询错误查询中查看!!`
487
- self.downbutton = true;
488
- },100);
489
- }else{
490
- self.percent = res.data.speed
491
- }
492
- }
493
- });
494
- },2000);
495
- },
496
- getuuid(){
497
- let uuidA = '';
498
- var s = [];
499
- var hexDigits = '0123456789abcdef';
500
- for (var i = 0; i < 36; i++) {
501
- s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);
502
- }
503
- s[14] = '4';
504
- s[19] = hexDigits.substr((s[19] & 0x3) | 0x8, 1);
505
- s[8] = s[13] = s[18] = s[23] = '-';
506
- uuidA = s.join('');
507
- this.uuida = uuidA;
508
- },
509
- getRes (obj) {
510
- this.orgCondtionStr = obj
511
- if(this.$refs.paged.$refs.criteria.$refs.sel.depresid.length>0){
512
- this.f_filialeid=this.$refs.paged.$refs.criteria.$refs.sel.depresid[0]
513
- if (this.$refs.paged.$refs.criteria.$refs.sel.userresid.length==0){
514
- this.createFile = false
515
- this.orgs=null
516
- }
517
- }else{
518
- this.f_filialeid=this.$login.f.orgid
519
- }
520
- },
521
- close () {
522
- this.printflag = false
523
- this.clean()
524
- },
525
- async downFiles (index, row) {
526
- let param = {
527
- f_userinfo_id: row.f_userinfo_id,
528
- version: row.version,
529
- f_print_lc: '是',
530
- f_printdate: this.$login.toStandardTimeString()
531
- }
532
- await await this.$resetpost('rs/logic/updateprint', {param}, {resolveMsg: null, rejectMsg: ''})
533
- console.log('xxxxxxxxxxxxxxxxxxxxx')
534
- // 下载不同文件
535
- if (index == 0) {
536
- let url = 'rs/report/userinstall'
537
- this.billData.url = url
538
- } else {
539
- let url = 'rs/report/userignition'
540
- this.billData.url = url
541
- }
542
- this.newdata = row
543
- this.printflag = true
544
- },
545
- showFileInfo () {
546
-
547
- },
548
- closemodal () {
549
- this.batchMeterShow = false
550
- },
551
- createInfoForFile () {
552
- this.batchMeterShow = true
553
- },
554
- hidden () {
555
- this.criteriaShow = !this.criteriaShow
556
- },
557
- search () {
558
- this.$refs.paged.$refs.criteria.model.f_user_state = this.f_user_state
559
- // this.$refs.paged.$refs.criteria.search()
560
- },
561
- modifyUser (row) {
562
- this.isOper = true
563
- this.createFile = true
564
- this.isedit = true
565
- this.row = row
566
- this.areainfo = null
567
- this.row.version = row.version
568
- console.log('row.version====>', this.row.version)
569
- },
570
- clean () {
571
- this.createFile = false
572
- this.row = null
573
- this.isOper = false
574
- this.areainfo = null
575
- // this.$refs.paged.$refs.grid.select(null)
576
- this.$refs.paged.$refs.grid.model.rows = this.rows
577
- this.search()
578
- },
579
- createnewfile () {
580
- this.isOper = true
581
- this.createFile = true
582
- this.isedit = false
583
- this.row = null
584
- this.areainfo = null
585
- this.$refs.info.clearinfo()
586
- },
587
- renew () {
588
- this.row = null
589
- this.areainfo = null
590
- this.isOper = false
591
- this.$refs.info.clearinfo()
592
- this.clearCondition()
593
- this.search()
594
- // 建档或修正档案成功刷新地址列表
595
- this.$refs.addressfiles.$refs.paged.$refs.cri.search()
596
- },
597
- clearCondition () {
598
- Object.keys(this.$refs.paged.$refs.criteria.model).forEach((key) => {
599
- this.$refs.paged.$refs.criteria.model[key] = ''
600
- })
601
- },
602
-
603
- bulkOperations (name, type) {
604
- if (name === '批量销户') {
605
- this.batcan = true
606
- this.batenable = false
607
- this.newArea = false
608
- } else if (name === '批量启用') {
609
- this.batenable = true
610
- this.batcan = false
611
- this.newArea = false
612
- }
613
- },
614
- batchSuccess () {
615
- this.clearCondition()
616
- this.batchClean()
617
- },
618
- batchClean () {
619
- this.batcan = false
620
- this.batenable = false
621
- this.newArea = false
622
- this.search()
623
- },
624
- buildFile (row) {
625
- // console.log('我是建档。。。', row)
626
- this.row = row
627
- },
628
- // 小区批量建档
629
- bulidFiles (row) {
630
- this.row = null
631
- this.areainfo = row
632
- // 将列表的数据清空
633
- this.$refs.paged.$refs.grid.model.rows = []
634
- },
635
- // 小区批量建档成功
636
- buildFileSuccess (data) {
637
- // console.log('建档案成功', data)
638
- this.model.rows.unshift(data)
639
- },
640
- selfSearch (args) {
641
- console.log('开始查询档案', this.f_filialeid)
642
- if (!this.f_filialeid) {
643
- this.f_filialeid = this.$login.f.orgid
644
- }
645
- if (!this.orgCondtionStr) {
646
- args.condition = `${args.condition}` + ' and f_orgid = ' + this.$login.f.orgid
647
- } else {
648
- args.condition = `${args.condition}` + this.orgCondtionStr
649
- }
650
- this.criteriaShow = false
651
- this.$refs.paged.$refs.grid.$el.scrollTop = 0
652
- this.model.search(args.condition, args.model)
653
- this.clean()
654
- },
655
- printok () {
656
- console.log('======================')
657
- // this.$dispatch('success')
658
- },
659
- sort (field, rule) {
660
- // 将所有排序方式设为不排序,实现相互排斥
661
- for (let key in this.orderFields) {
662
- if (key === field) {
663
- this.orderFields[key] = rule
664
- } else {
665
- this.orderFields[key] = 'no'
666
- }
667
- }
668
- // 如果新规则不排序,还原为默认排序
669
- if (rule === 'no') {
670
- this.model.paramSource.orderitem = `'${this.orderDefault}'`
671
- } else {
672
- this.model.paramSource.orderitem = `'${field} ${rule}'`
673
- }
674
-
675
- this.search()
676
- },
677
-
678
- getLocation (row) {
679
- // 可能会存在添加,完善,建档
680
- console.log('进入', row)
681
-
682
- addressInfoGen(this, row)
683
- },
684
- areaFiles (row) {
685
- row.isEdit = true
686
- row.f_residential_area_id = row.id
687
- // row.id = null
688
- delete row.id
689
- this.bulidFiles(row)
690
- },
691
-
692
- initAdjustables () {
693
- console.log('初始化调压箱', this.$GetSaleParam)
694
- let arr = []
695
- let filter = this.$login.f.orgid
696
- this.$GetSaleParam.getAdjustable(filter).forEach((item) => {
697
- let temp = {}
698
- temp.label = `[${item.value.f_adjustable_id}]-${item.label}`
699
- temp.value = `${item.value.id}`
700
- arr.push(temp)
701
- })
702
- this.adjustables = [{label: '全部', value: ''}, ...arr]
703
- },
704
- importFile () {
705
- this.show = true
706
- },
707
- clear () {
708
- Object.keys(this.$refs.paged.$refs.criteria.model).forEach((key) => {
709
- this.$refs.paged.$refs.criteria.model[key] = []
710
- })
711
- this.$refs.paged.$refs.criteria.model.f_user_state = this.f_user_state
712
- },
713
- getorg (val) {
714
- this.f_filialeid = val[0]
715
- }
716
- },
717
- computed: {
718
- userstates () {
719
- return [{label: '预备', value: '预备'}]
720
- },
721
- usegas () {
722
- return [{label: '全部', value: ''}, {label: '是', value: '是'}, {label: '否', value: '否'}]
723
- },
724
- areas () {
725
- let rs = []
726
- for (let i = 0; i < this.$login.f.f_allArea.length; i++) {
727
- let temp = {
728
- label: this.$login.f.f_allArea[i].label,
729
- value: this.$login.f.f_allArea[i].label
730
- }
731
- rs.push(temp)
732
- }
733
- return [{label: '全部', value: ''}, ...rs]
734
- },
735
- firestates () {
736
- return [
737
- {label: '全部', value: ''},
738
- {label: '点火', value: '1'},
739
- {label: '未点火', value: '0'}
740
- ]
741
- },
742
- jurisdiction () {
743
- return this.$login.r
744
- }
745
- },
746
- watch: {
747
- // 每次查询将查询到的数据存储起来,供选择操作后的替换
748
- 'model.state' (val) {
749
- if (val === '正确') {
750
- this.rows = this.model.rows
751
- }
752
- },
753
- 'f_filialeid' (val) {
754
- loadParamGem(this)
755
- }
756
- },
757
- events: {
758
- FileUpload: function (file, res) {
759
- let data = {
760
- tablename: 't_userinfo',
761
- filepath: res.path
762
- }
763
- this.$resetpost('rs/logic/import', data, {resolveMsg: null, rejectMsg: '上传失败'}).then((res) => {
764
- console.log('dddddddd', this)
765
- this.close()
766
- this.$showAlert(`一共上传${res.data.total}条数据, 成功${res.data.successnum}条`, 'success', 2000)
767
- this.search()
768
- })
769
- },
770
- 'onFileUpload': function (file, res) {
771
- if (this.batchmoneyShow) {
772
- let param = {
773
- filepath: res.f_downloadpath,
774
- f_operator: this.$login.f.name,
775
- f_operatorid: this.$login.f.id,
776
- f_orgid: this.$login.f.orgid,
777
- f_orgname: this.$login.f.orgs,
778
- f_depid: this.$login.f.depids,
779
- f_depname: this.$login.f.deps
780
- }
781
- let http = new HttpResetClass()
782
- http.load('POST', 'rs/logic/SumSettleFileImport', {data: param}, {
783
- resolveMsg: null,
784
- rejectMsg: '上传失败'
785
- })
786
- }
787
-
788
- if (this.batchMeterShow) {
789
- // this.iswork = true
790
- this.getuuid();
791
- if(this.uuida == '') return;
792
- // 当前上传的是批量导入的档案
793
- let param = {
794
- filepath: res.f_downloadpath,
795
- f_operator: this.$login.f.name,
796
- f_operatorid: this.$login.f.id,
797
- f_orgid: this.$login.f.orgid,
798
- f_orgname: this.$login.f.orgs,
799
- f_depid: this.$login.f.depids,
800
- f_depname: this.$login.f.deps,
801
- uuid: this.uuida
802
- }
803
- let self = this
804
- try {
805
- self.progressShow = true;
806
- axios.post('rs/logic/newPrepareSettleFileImport',
807
- {data: param}, {timeout: 1000}).then((res) => {
808
- })
809
- self.percent=0;
810
- self.getRequestReturn();
811
- } catch (error) {
812
- if (error.response) {
813
- if (error.response.status == 500) {
814
- this.$showAlert('服务繁忙,请重试!!!', 'danger', 3000)
815
- } else if (error.response.status == 404) {
816
- this.$showAlert('服务运行中,请耐心等待后进行重试!!', 'danger', 3000)
817
- } else {
818
- this.$showAlert(error.response.data, 'danger', 2000)
819
- }
820
- } else if (error.request) {
821
- this.$showAlert(error.request, 'danger', 2000)
822
- } else {
823
- this.$showAlert(error.message, 'danger', 2000)
824
- }
825
- this.iswork = false
826
- }
827
- this.$refs.file.$el.querySelector('input').value = ''
828
- this.batchMeterShow = false
829
- this.search()
830
- }
831
- },
832
- 'confirmaddress' (res) {
833
- console.log('选定地址', res)
834
- }
835
- }
836
- }
837
- </script>
838
- <style>
839
- .nav-tabss ul > li > a {
840
- padding: 5px 10px;
841
- }
842
- </style>
1
+ <template>
2
+ <div id="file-user-files" class="binary">
3
+ <div :class="{'basic-main': !createFile,'binary-left': createFile}" >
4
+ <div class="flex" style="flex: 1;">
5
+ <div style="flex: 1.2">
6
+ <criteria-paged :model="model" v-ref:paged @sort="sort">
7
+ <criteria @condition-changed="$parent.selfSearch" partial='criteria' v-ref:criteria>
8
+ <div class="form-horizontal select-overspread container-fluid auto" novalidate partial>
9
+ <div class="row">
10
+ <res-select-group :initres="$parent.$parent.initres"
11
+ :show-component="['company','department','operator']"
12
+ @re-res="$parent.$parent.getRes"
13
+ v-ref:sel></res-select-group>
14
+ <div
15
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
16
+ class="form-group button-range">
17
+ <!--<button class="button_search button_spacing" style="width: 90px" @click="$parent.$parent.showFileInfo()">查看批量状态-->
18
+ <!--</button>-->
19
+ <button @click="search(), $parent.$parent.clean()" class="button_search button_spacing"
20
+ style="float: right">查询
21
+ </button>
22
+ <button @click="$parent.$parent.clear()" class="button_clear button_spacing"
23
+ style="float: right">清空
24
+ </button>
25
+ <button @click="$parent.$parent.createnewfile()" class="button_search button_spacing"
26
+ style="float: right">单户建档
27
+ </button>
28
+ <button class="button_search button_spacing" style="width: 90px" @click="$parent.$parent.createInfoForFile()">批量建档
29
+ </button>
30
+ <button @click="$parent.$parent.importFile" class="button_export button_spacing"
31
+ style="float: right" v-if="false">导入
32
+ </button>
33
+ <!-- <button class="button_search" style="width: 90px" @click=" $parent.$parent.selectaddress()">选择地址</button>-->
34
+ <button @click="$parent.$parent.bulkOperations('批量销户', 'batch-cancellation')"
35
+ class="button_delete button_spacing"
36
+ style="float: right"
37
+ v-if="$parent.$parent.rows && $parent.$parent.rows.length === 1 && $parent.$parent.rows[0].f_user_state !== '正常'">
38
+ 销户
39
+ </button>
40
+ <button @click="$parent.$parent.bulkOperations('批量启用', 'batch-enable')"
41
+ class="button_search button_spacing"
42
+ style="float: right"
43
+ v-if="$parent.$parent.rows && $parent.$parent.rows.length === 1 && $parent.$parent.rows[0].f_user_state === '销户'">
44
+ 启用
45
+ </button>
46
+ <div
47
+ :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
48
+ @click="$parent.$parent.hidden()"
49
+ class="button_spacing"
50
+ style="float: right"></div>
51
+ </div>
52
+ </div>
53
+ <div class="row" v-if="$parent.$parent.criteriaShow">
54
+ <div
55
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
56
+ class="form-group"
57
+ v-if="$parent.$parent.clientWidth>1600">
58
+ <label class="font_normal_body">客户编号</label>
59
+ <input class="input_search" condition="f_userinfo_code like '%{}%'"
60
+ placeholder='客户编号'
61
+ style="width:60%" type="text" v-model="model.f_userinfo_code">
62
+ </div>
63
+ <div
64
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
65
+ class="form-group" v-if="!$parent.$parent.createFile">
66
+ <label class="font_normal_body">客户名称</label>
67
+ <input class="input_search" condition="f_user_name like '%{}%'"
68
+ placeholder='客户姓名'
69
+ style="width:60%" type="text" v-model="model.f_user_name">
70
+ </div>
71
+ <div
72
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
73
+ class="form-group">
74
+ <label class="font_normal_body">用气性质</label>
75
+ <v-select :options='$parent.$parent.gasproperties' :value.sync="model.f_gasproperties"
76
+ close-on-select condition="f_gasproperties='{}'"
77
+ placeholder='用气性质' v-model="model.f_gasproperties"></v-select>
78
+ </div>
79
+ <div
80
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
81
+ class="form-group">
82
+ <label class="font_normal_body">客户电话</label>
83
+ <input class="input_search" condition="f_user_phone = '{}'" placeholder='客户电话' style="width:60%"
84
+ type="text"
85
+ v-model="model.f_user_phone">
86
+ </div>
87
+ <div
88
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
89
+ class="form-group">
90
+ <label class="font_normal_body">客户地址</label>
91
+ <input class="input_search" condition="f_address like '%{}%'" placeholder='客户地址' style="width:60%"
92
+ type="text" v-model="model.f_address">
93
+ </div>
94
+ <div
95
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
96
+ class="form-group">
97
+ <label class="font_normal_body">客户状态</label>
98
+ <v-select :options='$parent.$parent.userstates' :value.sync="model.f_user_state"
99
+ close-on-select condition="f_user_state='{}'"
100
+ :value-single="true"
101
+ placeholder='客户状态' v-model="model.f_user_state"></v-select>
102
+ </div>
103
+ <div
104
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
105
+ class="form-group">
106
+ <label class="font_normal_body">调&ensp;压&ensp;箱</label>
107
+ <v-select :options='$parent.$parent.adjustables' :search='true'
108
+ :value.sync="model.f_adjustable_id"
109
+ close-on-select
110
+ condition="f_adjustable_id = '{}'" placeholder='调压箱'
111
+ v-model='model.f_adjustable_id'></v-select>
112
+ </div>
113
+ <div
114
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
115
+ class="form-group">
116
+ <label class="font_normal_body">建档时间</label>
117
+ <datepicker placeholder="开始日期" v-model="model.startDate" :value.sync="model.startDate" style="width:60%"
118
+ :format="'yyyy-MM-dd'" condition="f_createfile_date >= '{}'">
119
+ </datepicker>
120
+ </div>
121
+ <div
122
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
123
+ class="form-group">
124
+ <label class="font_normal_body">&emsp;&ensp;至&ensp;&emsp;</label>
125
+ <datepicker placeholder="结束日期" v-model="model.endDate" :value.sync="model.endDate" style="width:60%"
126
+ :format="'yyyy-MM-dd'" condition="f_createfile_date <= '{}'">
127
+ </datepicker>
128
+ </div>
129
+ <div
130
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
131
+ class="form-group">
132
+ <label class="font_normal_body">打印时间</label>
133
+ <datepicker placeholder="开始日期" v-model="model.startPrintDate" :value.sync="model.startPrintDate" style="width:60%"
134
+ :format="'yyyy-MM-dd'" condition="f_printdate >= '{}'">
135
+ </datepicker>
136
+ </div>
137
+ <div
138
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
139
+ class="form-group">
140
+ <label class="font_normal_body">打印时间</label>
141
+ <datepicker placeholder="结束日期" v-model="model.endPrintDate" :value.sync="model.endPrintDate" style="width:60%"
142
+ :format="'yyyy-MM-dd'" condition="f_printdate <= '{}'">
143
+ </datepicker>
144
+ </div>
145
+ <div
146
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
147
+ class="form-group">
148
+ <label class="font_normal_body">工业备注</label>
149
+ <v-select :options='$parent.$parent.industrycomments' :value.sync="model.f_industry_comments"
150
+ close-on-select condition="f_industry_comments='{}'"
151
+ placeholder='气表类型' v-model="model.f_industry_comments"></v-select>
152
+ </div>
153
+ <div
154
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
155
+ class="form-group">
156
+ <label class="font_normal_body">小&emsp;&emsp;区</label>
157
+ <input class="input_search" condition="f_residential_area like '%{}%'" placeholder='小区' style="width:60%"
158
+ type="text" v-model="model.f_residential_area">
159
+ </div>
160
+ <div
161
+ :class="{'col-sm-2':!$parent.$parent.createFile,'col-sm-4':$parent.$parent.createFile}"
162
+ class="form-group">
163
+ <label class="font_normal_body">选择区域</label>
164
+ <v-select
165
+ v-model="model.f_pcd"
166
+ placeholder='选择区域'
167
+ :value.sync="model.f_pcd"
168
+ :options='$parent.$parent.pcdslist'
169
+ condition="f_pcd_id = '{}'"
170
+ style="width: 60%"
171
+ close-on-select >
172
+ </v-select>
173
+ </div>
174
+ <!--<div-->
175
+ <!--:class="{'col-sm-3':$parent.$parent.clientWidth>1600||!$parent.$parent.createFile,'col-sm-4':$parent.$parent.clientWidth<1600&&$parent.$parent.createFile}"-->
176
+ <!--class="form-group">-->
177
+ <!--<label class="font_normal_body">天然气使用证</label>-->
178
+ <!--<v-select :options='$parent.$parent.usegas' :value.sync="model.f_send_usegas_card"-->
179
+ <!--close-on-select condition="f_send_usegas_card='{}'"-->
180
+ <!--placeholder='天然气使用证' v-model="model.f_send_usegas_card"></v-select>-->
181
+ <!--</div>-->
182
+ </div>
183
+ </div>
184
+ </criteria>
185
+ <data-grid :model="model" class="list_area table_sy" v-ref:grid partial='list'>
186
+ <template partial='head'>
187
+ <tr>
188
+ <th>
189
+ <nobr>序号</nobr>
190
+ </th>
191
+ <th>
192
+ <nobr>客户编号</nobr>
193
+ </th>
194
+ <th>
195
+ <nobr>客户名称</nobr>
196
+ </th>
197
+ <th>
198
+ <nobr>客户电话</nobr>
199
+ </th>
200
+ <th v-if="!$parent.$parent.$parent.isOper">
201
+ <nobr>地址信息</nobr>
202
+ </th>
203
+ <th>
204
+ <nobr>状态</nobr>
205
+ </th>
206
+ <th>
207
+ <nobr>建档时间</nobr>
208
+ </th>
209
+ <th>
210
+ <nobr>打印时间</nobr>
211
+ </th>
212
+ <th>
213
+ <nobr>打印状态</nobr>
214
+ </th>
215
+ <th>
216
+ <nobr>操作</nobr>
217
+ </th>
218
+ </tr>
219
+ </template>
220
+ <template partial='body'>
221
+ <td style="text-align: center;">{{$index + 1}}</td>
222
+ <td style="text-align: center;">{{row.f_userinfo_code}}</td>
223
+ <td style="text-align: center;">{{row.f_user_name}}</td>
224
+ <td style="text-align: center;">{{row.f_user_phone}}</td>
225
+ <td style="text-align: center;" v-if="!$parent.$parent.$parent.isOper">{{row.f_address_detail ? row.f_address + row.f_address_detail :
226
+ row.f_address}}
227
+ </td>
228
+ <td style="text-align: center;">{{row.f_user_state}}</td>
229
+ <td style="text-align: center;">{{row.f_createfile_date}}</td>
230
+ <td style="text-align: center;">{{row.f_printdate}}</td>
231
+ <td style="text-align: center;">
232
+ <div>{{row.print_stats}}</div>
233
+ </td>
234
+ <td style="text-align: center;">
235
+ <button type="button" name="button" class="button_search-2 button_spacing width-60"
236
+ v-if="row.f_user_state === '正常' || row.f_user_state==='预备'"
237
+ @click.stop="$parent.$parent.$parent.modifyUser(row)">修正
238
+ </button>
239
+ </td>
240
+ </template>
241
+ </data-grid>
242
+ </criteria-paged>
243
+ </div>
244
+ <div v-if="batcan || batenable">
245
+ <batch-cancellation v-if="batcan" :useraccount="model.rows" @clean="batchClean"
246
+ @success="batchSuccess"></batch-cancellation>
247
+ <batch-enable v-if="batenable" :useraccount="model.rows" @clean="batchClean"
248
+ @success="batchSuccess"></batch-enable>
249
+ </div>
250
+ </div>
251
+ </div>
252
+ <div class="binary-right" :style="{width:'70%'}" v-if="createFile">
253
+ <div class="auto" style="height: 100%; margin-top: 1%" >
254
+ <file-user-general-info-new :f_filialeid="f_filialeid" :row="row" :areainfo="areainfo"
255
+ :haslimit="config.hasLimit" @success="renew" @clean="clean"
256
+ :isedit="isedit" :configs="configs"
257
+ @build-success="buildFileSuccess" v-ref:info></file-user-general-info-new>
258
+ </div>
259
+ </div>
260
+
261
+ <modal :show.sync="show" width="500px" title="文件导入" v-ref:modal large backdrop="false">
262
+ <article slot="modal-body" class="modal-body">
263
+ <file-upload class="my-file-uploader " name="UploadFile" class="btn btn-success" style="border-radius: 2px;"
264
+ action="rs/file/uploadFile" tagname="导入档案" v-ref:file :headers="headers"></file-upload>
265
+ </article>
266
+ <footer slot="modal-footer" class="modal-footer">
267
+ </footer>
268
+ </modal>
269
+ <modal :show.sync="batchMeterShow" width="500px" title="文件导入" v-ref:modal large backdrop="false">
270
+ <article slot="modal-body" class="modal-body">
271
+ <file-upload class="my-file-uploader" name="useraddressUploadFile" action="rs/file/uploadFile" tagname="确定" multiple v-ref:file></file-upload>
272
+ </article>
273
+ <footer slot="modal-footer" class="modal-footer">
274
+ </footer>
275
+ </modal>
276
+ <user-flow-sheet :show="printflag" :bill-config='configs' :bill-data='billData' :data='newdata' v-on:toggle="close" @printok="printok" v-ref:printbill></user-flow-sheet>
277
+ <modal :show.sync="progressShow" v-ref:modal width="50%" style="width:auto;" backdrop="false" >
278
+ <header slot="modal-header" class="modal-header">
279
+ 批量建档
280
+ </header>
281
+ <article slot="modal-body" class="modal-body">
282
+ <div class="progress" style="margin: 20px" >
283
+ <div class="progress-bar progress-bar-success progress-bar-striped active" :style="{width: percent+'%'}">
284
+ {{percent}}%
285
+ </div>
286
+ </div>
287
+ <div style="width:100%;display: flex">
288
+ <p style="text-align: center;width: 100%;" v-show="!downbutton">文件正在导入..</p>
289
+ <p style="text-align: center;width: 100%;" v-show="downbutton">导入成功:{{inputsuccessmage}}</p>
290
+ </div>
291
+ </article>
292
+ <footer slot="modal-footer" class="modal-footer">
293
+ <button type="button" class="btn btn-default" @click='closeRequeset'>关闭</button>
294
+ </footer>
295
+ </modal>
296
+
297
+ </div>
298
+ </template>
299
+
300
+ <script>
301
+ import {PagedList, HttpResetClass} from 'vue-client'
302
+ import Vue from 'vue'
303
+ import co from 'co'
304
+ import axios from 'axios'
305
+
306
+ let loadParamGem = async function (self) {
307
+ await self.$getConfig(self, 'UserFiles')
308
+ self.headers.username = Vue.$login.f.name
309
+ self.headers.username = Vue.$login.guid()
310
+ await self.$LoadParams.loadParam(self.f_filialeid)
311
+
312
+ let req = await self.$resetpost('rs/sql/address_singleTableOrderBy?pageNo=1&pageSize=9999999', {
313
+ data: {
314
+ items: '*',
315
+ tablename: 't_pcd',
316
+ orderitem: 'id',
317
+ condition: `1=1 and f_filialeid = '${self.$login.f.orgid}'`
318
+ }
319
+ }, {resolveMsg: null, rejectMsg: '获取地址失败!'})
320
+ let redata = []
321
+ req.data.forEach((row, n) => {
322
+ redata[n] = {
323
+ label: row.f_pcd,
324
+ value: row.id,
325
+ data: row,
326
+ id: row.id
327
+ }
328
+ })
329
+ self.pcdslist = redata
330
+ // await self.$LoadParams.loadMeterBook(self.f_filialeid)
331
+ await self.search()
332
+ self.initAdjustables()
333
+ }
334
+
335
+ let addressInfoGen = async function (self, areainfo) {
336
+ areainfo.isEdit = false
337
+ if (areainfo.file_num > 0 && !areainfo.f_userinfo_id) {
338
+ // 完善
339
+ // 将表档案信息带入,完善客户信息
340
+ let getMetersInfo = await self.$resetpost('rs/logic/sale_getMeterByAddress', {
341
+ data: {
342
+ f_useraddress_id: areainfo.id
343
+ }
344
+ }, {resolveMsg: null, rejectMsg: '获取表信息出错'})
345
+ areainfo.meter = getMetersInfo.data[0]
346
+ }
347
+ if (areainfo.file_num > 0 && areainfo.f_userinfo_id) {
348
+ // 添加 将客户信息带入
349
+ let getUserinfo = await self.$resetpost('rs/sql/saleSingleTable', {
350
+ data: {
351
+ tablename: 't_userinfo',
352
+ condition: `f_userinfo_id = '${areainfo.f_userinfo_id}'`
353
+ }
354
+ }, {resolveMsg: null, rejectMsg: '获取档案出错'})
355
+
356
+ areainfo.user = getUserinfo.data[0]
357
+ }
358
+ self.bulidFiles(areainfo)
359
+ }
360
+
361
+ export default {
362
+ 'title': '预备户管理',
363
+ data () {
364
+ return {
365
+ config: {
366
+ createType: ['address', 'area'], // 建档方式: address-地址建档 area-小区建档
367
+ hasLimit: true
368
+ },
369
+ model: new PagedList('rs/sql/filemanage_getUserfies', 30, {orderitem: '"f_userinfo_id DESC"'}),
370
+ row: null, // 选择一条客户信息,对其进行修改
371
+ areainfo: null, // 小区批量建档使用的数据
372
+ rows: [], // 客户档案选择一条时,将只显示一条信息,rows用来存放整页的数据
373
+ headers: {'username': this.$login.f.name, 'blodid': this.$login.guid()},
374
+ contract: [{label: '全部', value: ' is null or f_contract_id is not null'}, {
375
+ label: '有',
376
+ value: ' is not null'
377
+ },
378
+ {label: '无', value: ' is null'}],
379
+ industrycomments: this.$appdata.getParam('工业备注') ? [{
380
+ label: '全部',
381
+ value: ''
382
+ }, ...this.$appdata.getParam('工业备注')] : [],
383
+ orderDefault: 'f_createfile_date desc',
384
+ orderFields: {
385
+ f_userinfo_id: 'no'
386
+ },
387
+
388
+ createFile: false,
389
+
390
+ initres: {
391
+ org: [this.$login.f.orgid],
392
+ dep: [],
393
+ user: []
394
+ },
395
+ curorgid: [this.$login.f.orgid],
396
+ f_filialeid: this.$login.f.orgid,
397
+
398
+ // 销户启用
399
+ batcan: false,
400
+ batenable: false,
401
+ version: '',
402
+
403
+ pcdslist: [],
404
+ inputtores: this.$appdata.getParam('抄表员'),
405
+ adjustables: [],
406
+
407
+ // 导入组件
408
+ show: false,
409
+
410
+ // 点击建档或修正时控制列表展示, 防止拥挤
411
+ isOper: false,
412
+
413
+ criteriaShow: false,
414
+
415
+ gasproperties: this.$appdata.getParam('用气性质') ? [{label: '全部', value: ''}, ...this.$appdata.getParam('用气性质')] : [],
416
+ f_user_state: '预备',
417
+ showselectaddress: false,
418
+ isedit: false,
419
+ clientWidth: document.body.clientWidth,
420
+ batchMeterShow: false,
421
+ billData: {
422
+ url: 'rs/report/userignition',
423
+ bill: ''
424
+ },
425
+ configs: {
426
+ hasPrint: false, // 默认打票
427
+ hasBillManage: false // 默认不启用发票管理
428
+ },
429
+ printflag: false,
430
+ orgCondtionStr: '',
431
+ newdata: {},
432
+ downbutton:false,
433
+ percent:0,
434
+ timer:'',
435
+ uuida:'',
436
+ progressShow:false,
437
+ inputsuccessmage:''
438
+ }
439
+ },
440
+ ready () {
441
+ this.$refs.paged.$refs.criteria.model.f_user_state = this.f_user_state
442
+ loadParamGem(this)
443
+ },
444
+ compiled () {
445
+ window.onresize = () => {
446
+ return (() => {
447
+ this.clientWidth = document.body.clientWidth
448
+ })()
449
+ }
450
+ },
451
+ methods: {
452
+ progressclose(){
453
+ if(this.timer != null){
454
+ clearInterval(this.timer);
455
+ }
456
+ this.progressShow = false;
457
+ this.percent=0;
458
+ },
459
+ closeRequeset(){
460
+ this.$showMessage("确定关闭吗,当前正常导入,关闭后将无法获取导入进度!",['confirm','cancel']).then(res=>{
461
+ if(res === 'confirm'){
462
+ if(this.timer != null){
463
+ clearInterval(this.timer);
464
+ }
465
+ this.progressclose();
466
+ this.percent=0;
467
+ this.uuida='';
468
+ this.downbutton=false;
469
+ }
470
+ })
471
+ },
472
+ async getRequestReturn(){
473
+ let timer = null;
474
+ let self = this;
475
+ let param = {
476
+ uuid:this.uuida
477
+ };
478
+ this.timer = setInterval(function(){
479
+ self.$resetpost('/rs/logic/getBatchOperaPro',{data:param},{resolveMsg: null, rejectMsg: null}, 0).then((res)=>{
480
+ if(res.data && res.data.speed ){
481
+ if(res.data.speed==100 || res.data.speed>100 ){
482
+ clearInterval(self.timer);
483
+ self.percent = 99;
484
+ setTimeout(function(){
485
+ self.percent = 100
486
+ self.inputsuccessmage = `本次上传共上传${res.data.totalsum}条数据, 成功${res.data.successsum}条,失败${res.data.errorsum}条,具体失败数据请在稽查查询错误查询中查看!!`
487
+ self.downbutton = true;
488
+ },100);
489
+ }else{
490
+ self.percent = res.data.speed
491
+ }
492
+ }
493
+ });
494
+ },2000);
495
+ },
496
+ getuuid(){
497
+ let uuidA = '';
498
+ var s = [];
499
+ var hexDigits = '0123456789abcdef';
500
+ for (var i = 0; i < 36; i++) {
501
+ s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);
502
+ }
503
+ s[14] = '4';
504
+ s[19] = hexDigits.substr((s[19] & 0x3) | 0x8, 1);
505
+ s[8] = s[13] = s[18] = s[23] = '-';
506
+ uuidA = s.join('');
507
+ this.uuida = uuidA;
508
+ },
509
+ getRes (obj) {
510
+ this.orgCondtionStr = obj
511
+ if(this.$refs.paged.$refs.criteria.$refs.sel.depresid.length>0){
512
+ this.f_filialeid=this.$refs.paged.$refs.criteria.$refs.sel.depresid[0]
513
+ if (this.$refs.paged.$refs.criteria.$refs.sel.userresid.length==0){
514
+ this.createFile = false
515
+ this.orgs=null
516
+ }
517
+ }else{
518
+ this.f_filialeid=this.$login.f.orgid
519
+ }
520
+ },
521
+ close () {
522
+ this.printflag = false
523
+ this.clean()
524
+ },
525
+ async downFiles (index, row) {
526
+ let param = {
527
+ f_userinfo_id: row.f_userinfo_id,
528
+ version: row.version,
529
+ f_print_lc: '是',
530
+ f_printdate: this.$login.toStandardTimeString()
531
+ }
532
+ await await this.$resetpost('rs/logic/updateprint', {param}, {resolveMsg: null, rejectMsg: ''})
533
+ console.log('xxxxxxxxxxxxxxxxxxxxx')
534
+ // 下载不同文件
535
+ if (index == 0) {
536
+ let url = 'rs/report/userinstall'
537
+ this.billData.url = url
538
+ } else {
539
+ let url = 'rs/report/userignition'
540
+ this.billData.url = url
541
+ }
542
+ this.newdata = row
543
+ this.printflag = true
544
+ },
545
+ showFileInfo () {
546
+
547
+ },
548
+ closemodal () {
549
+ this.batchMeterShow = false
550
+ },
551
+ createInfoForFile () {
552
+ this.batchMeterShow = true
553
+ },
554
+ hidden () {
555
+ this.criteriaShow = !this.criteriaShow
556
+ },
557
+ search () {
558
+ this.$refs.paged.$refs.criteria.model.f_user_state = this.f_user_state
559
+ // this.$refs.paged.$refs.criteria.search()
560
+ },
561
+ modifyUser (row) {
562
+ this.isOper = true
563
+ this.createFile = true
564
+ this.isedit = true
565
+ this.row = row
566
+ this.areainfo = null
567
+ this.row.version = row.version
568
+ console.log('row.version====>', this.row.version)
569
+ },
570
+ clean () {
571
+ this.createFile = false
572
+ this.row = null
573
+ this.isOper = false
574
+ this.areainfo = null
575
+ // this.$refs.paged.$refs.grid.select(null)
576
+ this.$refs.paged.$refs.grid.model.rows = this.rows
577
+ this.search()
578
+ },
579
+ createnewfile () {
580
+ this.isOper = true
581
+ this.createFile = true
582
+ this.isedit = false
583
+ this.row = null
584
+ this.areainfo = null
585
+ this.$refs.info.clearinfo()
586
+ },
587
+ renew () {
588
+ this.row = null
589
+ this.areainfo = null
590
+ this.isOper = false
591
+ this.$refs.info.clearinfo()
592
+ this.clearCondition()
593
+ this.search()
594
+ // 建档或修正档案成功刷新地址列表
595
+ this.$refs.addressfiles.$refs.paged.$refs.cri.search()
596
+ },
597
+ clearCondition () {
598
+ Object.keys(this.$refs.paged.$refs.criteria.model).forEach((key) => {
599
+ this.$refs.paged.$refs.criteria.model[key] = ''
600
+ })
601
+ },
602
+
603
+ bulkOperations (name, type) {
604
+ if (name === '批量销户') {
605
+ this.batcan = true
606
+ this.batenable = false
607
+ this.newArea = false
608
+ } else if (name === '批量启用') {
609
+ this.batenable = true
610
+ this.batcan = false
611
+ this.newArea = false
612
+ }
613
+ },
614
+ batchSuccess () {
615
+ this.clearCondition()
616
+ this.batchClean()
617
+ },
618
+ batchClean () {
619
+ this.batcan = false
620
+ this.batenable = false
621
+ this.newArea = false
622
+ this.search()
623
+ },
624
+ buildFile (row) {
625
+ // console.log('我是建档。。。', row)
626
+ this.row = row
627
+ },
628
+ // 小区批量建档
629
+ bulidFiles (row) {
630
+ this.row = null
631
+ this.areainfo = row
632
+ // 将列表的数据清空
633
+ this.$refs.paged.$refs.grid.model.rows = []
634
+ },
635
+ // 小区批量建档成功
636
+ buildFileSuccess (data) {
637
+ // console.log('建档案成功', data)
638
+ this.model.rows.unshift(data)
639
+ },
640
+ selfSearch (args) {
641
+ console.log('开始查询档案', this.f_filialeid)
642
+ if (!this.f_filialeid) {
643
+ this.f_filialeid = this.$login.f.orgid
644
+ }
645
+ if (!this.orgCondtionStr) {
646
+ args.condition = `${args.condition}` + ' and f_orgid = ' + this.$login.f.orgid
647
+ } else {
648
+ args.condition = `${args.condition}` + this.orgCondtionStr
649
+ }
650
+ this.criteriaShow = false
651
+ this.$refs.paged.$refs.grid.$el.scrollTop = 0
652
+ this.model.search(args.condition, args.model)
653
+ this.clean()
654
+ },
655
+ printok () {
656
+ console.log('======================')
657
+ // this.$dispatch('success')
658
+ },
659
+ sort (field, rule) {
660
+ // 将所有排序方式设为不排序,实现相互排斥
661
+ for (let key in this.orderFields) {
662
+ if (key === field) {
663
+ this.orderFields[key] = rule
664
+ } else {
665
+ this.orderFields[key] = 'no'
666
+ }
667
+ }
668
+ // 如果新规则不排序,还原为默认排序
669
+ if (rule === 'no') {
670
+ this.model.paramSource.orderitem = `'${this.orderDefault}'`
671
+ } else {
672
+ this.model.paramSource.orderitem = `'${field} ${rule}'`
673
+ }
674
+
675
+ this.search()
676
+ },
677
+
678
+ getLocation (row) {
679
+ // 可能会存在添加,完善,建档
680
+ console.log('进入', row)
681
+
682
+ addressInfoGen(this, row)
683
+ },
684
+ areaFiles (row) {
685
+ row.isEdit = true
686
+ row.f_residential_area_id = row.id
687
+ // row.id = null
688
+ delete row.id
689
+ this.bulidFiles(row)
690
+ },
691
+
692
+ initAdjustables () {
693
+ console.log('初始化调压箱', this.$GetSaleParam)
694
+ let arr = []
695
+ let filter = this.$login.f.orgid
696
+ this.$GetSaleParam.getAdjustable(filter).forEach((item) => {
697
+ let temp = {}
698
+ temp.label = `[${item.value.f_adjustable_id}]-${item.label}`
699
+ temp.value = `${item.value.id}`
700
+ arr.push(temp)
701
+ })
702
+ this.adjustables = [{label: '全部', value: ''}, ...arr]
703
+ },
704
+ importFile () {
705
+ this.show = true
706
+ },
707
+ clear () {
708
+ Object.keys(this.$refs.paged.$refs.criteria.model).forEach((key) => {
709
+ this.$refs.paged.$refs.criteria.model[key] = []
710
+ })
711
+ this.$refs.paged.$refs.criteria.model.f_user_state = this.f_user_state
712
+ },
713
+ getorg (val) {
714
+ this.f_filialeid = val[0]
715
+ }
716
+ },
717
+ computed: {
718
+ userstates () {
719
+ return [{label: '预备', value: '预备'}]
720
+ },
721
+ usegas () {
722
+ return [{label: '全部', value: ''}, {label: '是', value: '是'}, {label: '否', value: '否'}]
723
+ },
724
+ areas () {
725
+ let rs = []
726
+ for (let i = 0; i < this.$login.f.f_allArea.length; i++) {
727
+ let temp = {
728
+ label: this.$login.f.f_allArea[i].label,
729
+ value: this.$login.f.f_allArea[i].label
730
+ }
731
+ rs.push(temp)
732
+ }
733
+ return [{label: '全部', value: ''}, ...rs]
734
+ },
735
+ firestates () {
736
+ return [
737
+ {label: '全部', value: ''},
738
+ {label: '点火', value: '1'},
739
+ {label: '未点火', value: '0'}
740
+ ]
741
+ },
742
+ jurisdiction () {
743
+ return this.$login.r
744
+ }
745
+ },
746
+ watch: {
747
+ // 每次查询将查询到的数据存储起来,供选择操作后的替换
748
+ 'model.state' (val) {
749
+ if (val === '正确') {
750
+ this.rows = this.model.rows
751
+ }
752
+ },
753
+ 'f_filialeid' (val) {
754
+ loadParamGem(this)
755
+ }
756
+ },
757
+ events: {
758
+ FileUpload: function (file, res) {
759
+ let data = {
760
+ tablename: 't_userinfo',
761
+ filepath: res.path
762
+ }
763
+ this.$resetpost('rs/logic/import', data, {resolveMsg: null, rejectMsg: '上传失败'}).then((res) => {
764
+ console.log('dddddddd', this)
765
+ this.close()
766
+ this.$showAlert(`一共上传${res.data.total}条数据, 成功${res.data.successnum}条`, 'success', 2000)
767
+ this.search()
768
+ })
769
+ },
770
+ 'onFileUpload': function (file, res) {
771
+ if (this.batchmoneyShow) {
772
+ let param = {
773
+ filepath: res.f_downloadpath,
774
+ f_operator: this.$login.f.name,
775
+ f_operatorid: this.$login.f.id,
776
+ f_orgid: this.$login.f.orgid,
777
+ f_orgname: this.$login.f.orgs,
778
+ f_depid: this.$login.f.depids,
779
+ f_depname: this.$login.f.deps
780
+ }
781
+ let http = new HttpResetClass()
782
+ http.load('POST', 'rs/logic/SumSettleFileImport', {data: param}, {
783
+ resolveMsg: null,
784
+ rejectMsg: '上传失败'
785
+ })
786
+ }
787
+
788
+ if (this.batchMeterShow) {
789
+ // this.iswork = true
790
+ this.getuuid();
791
+ if(this.uuida == '') return;
792
+ // 当前上传的是批量导入的档案
793
+ let param = {
794
+ filepath: res.f_downloadpath,
795
+ f_operator: this.$login.f.name,
796
+ f_operatorid: this.$login.f.id,
797
+ f_orgid: this.$login.f.orgid,
798
+ f_orgname: this.$login.f.orgs,
799
+ f_depid: this.$login.f.depids,
800
+ f_depname: this.$login.f.deps,
801
+ uuid: this.uuida
802
+ }
803
+ let self = this
804
+ try {
805
+ self.progressShow = true;
806
+ axios.post('rs/logic/newPrepareSettleFileImport',
807
+ {data: param}, {timeout: 1000}).then((res) => {
808
+ })
809
+ self.percent=0;
810
+ self.getRequestReturn();
811
+ } catch (error) {
812
+ if (error.response) {
813
+ if (error.response.status == 500) {
814
+ this.$showAlert('服务繁忙,请重试!!!', 'danger', 3000)
815
+ } else if (error.response.status == 404) {
816
+ this.$showAlert('服务运行中,请耐心等待后进行重试!!', 'danger', 3000)
817
+ } else {
818
+ this.$showAlert(error.response.data, 'danger', 2000)
819
+ }
820
+ } else if (error.request) {
821
+ this.$showAlert(error.request, 'danger', 2000)
822
+ } else {
823
+ this.$showAlert(error.message, 'danger', 2000)
824
+ }
825
+ this.iswork = false
826
+ }
827
+ this.$refs.file.$el.querySelector('input').value = ''
828
+ this.batchMeterShow = false
829
+ this.search()
830
+ }
831
+ },
832
+ 'confirmaddress' (res) {
833
+ console.log('选定地址', res)
834
+ }
835
+ }
836
+ }
837
+ </script>
838
+ <style>
839
+ .nav-tabss ul > li > a {
840
+ padding: 5px 10px;
841
+ }
842
+ </style>