apply-clients 3.0.10-21 → 3.0.10-210

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 (65) hide show
  1. package/.gradle/3.5/file-changes/last-build.bin +0 -0
  2. package/.gradle/3.5/taskHistory/taskHistory.lock +0 -0
  3. package/.gradle/5.2.1/executionHistory/executionHistory.bin +0 -0
  4. package/.gradle/5.2.1/executionHistory/executionHistory.lock +0 -0
  5. package/.gradle/5.2.1/fileChanges/last-build.bin +0 -0
  6. package/.gradle/5.2.1/fileHashes/fileHashes.bin +0 -0
  7. package/.gradle/5.2.1/fileHashes/fileHashes.lock +0 -0
  8. package/.gradle/5.2.1/gc.properties +0 -0
  9. package/.gradle/buildOutputCleanup/built.bin +0 -0
  10. package/.gradle/buildOutputCleanup/cache.properties +2 -0
  11. package/.gradle/buildOutputCleanup/cache.properties.lock +1 -0
  12. package/.gradle/vcs-1/gc.properties +0 -0
  13. package/doc//346/226/260/347/224/250/346/210/267/350/212/261/345/220/215/345/206/214/345/257/274/345/205/245/346/250/241/346/235/277.xls +0 -0
  14. package/gradle/wrapper/gradle-wrapper.jar +0 -0
  15. package/gradle/wrapper/gradle-wrapper.properties +5 -0
  16. package/gradlew +0 -0
  17. package/gradlew.bat +84 -0
  18. package/package.json +5 -4
  19. package/src/apply.js +187 -146
  20. package/src/components/Util.js +26 -22
  21. package/src/components/app_apply/ApplyDownList.vue +21 -8
  22. package/src/components/app_apply/ApplyToDoList.vue +83 -59
  23. package/src/components/app_apply/ApplyUserInfo.vue +3 -3
  24. package/src/components/app_apply/PlaceControler.vue +255 -255
  25. package/src/components/app_apply/ServiceControl.vue +1387 -1387
  26. package/src/components/app_apply/ServiceView.vue +583 -361
  27. package/src/components/image/doc.jpg +0 -0
  28. package/src/components/image/excel.jpg +0 -0
  29. package/src/components/image/pdf.jpg +0 -0
  30. package/src/components/product/BatchFunction/BatchPay.vue +663 -0
  31. package/src/components/product/Function/InstallFunction.vue +9 -9
  32. package/src/components/product/Function/InstallInfoSelect.vue +230 -38
  33. package/src/components/product/Function/Service/FunctionServiceControl.vue +3 -1
  34. package/src/components/product/Function/functions/InstallFee.vue +58 -35
  35. package/src/components/product/Function/functions/StopInstall.vue +13 -1
  36. package/src/components/product/HiddenDangersInProjects/AddHiddenDangers.vue +957 -0
  37. package/src/components/product/HiddenDangersInProjects/HiddenProjectList.vue +425 -0
  38. package/src/components/product/HiddenDangersInProjects/HiddenProjectSchedule.vue +146 -0
  39. package/src/components/product/Process/ExplorationSelect.vue +302 -71
  40. package/src/components/product/Process/ExplorationUser.vue +18 -3
  41. package/src/components/product/Process/Processes/CustomerRecordMessage.vue +736 -201
  42. package/src/components/product/Process/Processes/Service/ApplyChargeSearch.vue +75 -69
  43. package/src/components/product/Process/Processes/Service/ServiceControl.vue +3172 -3053
  44. package/src/components/product/ProjectManagement/AddProjectSchedule.vue +863 -0
  45. package/src/components/product/ProjectManagement/ProjectList.vue +420 -0
  46. package/src/components/product/ProjectManagement/ProjectSchedule.vue +146 -0
  47. package/src/components/product/ReportForm/PaymentRecord.vue +801 -0
  48. package/src/components/product/ReportForm/PaymentRecordAdd.vue +105 -0
  49. package/src/components/product/ReportForm/PaymentRecordBad.vue +1273 -0
  50. package/src/components/product/ReportForm/PaymentRecordDetailed.vue +472 -0
  51. package/src/components/product/ReportForm/PaymentRecordTooBad.vue +60 -0
  52. package/src/components/product/ReportForm/PaymentReport.vue +532 -0
  53. package/src/components/product/ReportForm/ProjectReport.vue +447 -0
  54. package/src/components/product/ReportForm/SettlementReport.vue +336 -0
  55. package/src/components/product/ReportForm/SummaryReport.vue +451 -0
  56. package/src/components/product/ReportForm/UserReport.vue +402 -0
  57. package/src/components/product/ServiceView.vue +17 -9
  58. package/src/components/product/Supervisory/Service/SupervisoryServiceControl.vue +36 -2
  59. package/src/components/product/Supervisory/SupervisoryControl.vue +30 -6
  60. package/src/components/product/Supervisory/SupervisoryList.vue +249 -34
  61. package/src/components/product/VueUtils/ApplyUpload.vue +310 -0
  62. package/src/components/product/VueUtils/rightview/InstallCardList2.vue +0 -1
  63. package/src/main.js +4 -0
  64. package/success.rar +0 -0
  65. package/doc//350/212/261/345/220/215/345/206/214/345/257/274/345/205/245/346/250/241/346/235/277.xlsx +0 -0
@@ -0,0 +1,801 @@
1
+ <template>
2
+ <div class="d1">
3
+ <div class="left col-sm-12">
4
+ <criteria-paged :model="model" v-ref:cp>
5
+ <criteria partial='criteria' @condition-changed='search' v-ref:cri
6
+ style="padding: 20px;background-color: #f6f6f6;">
7
+ <form novalidate class="" partial>
8
+ <div class="col-sm-12">
9
+ <div class="form-group col-sm-2" >
10
+ <div class="col-sm-12">
11
+ <v-select :width ="'100%'" style="width: 100%" :options="$parent.$parent.apply_org" placeholder='所属公司' condition="f_filiale = '{}'" @change="$parent.$parent.orgChange"
12
+ v-model="model.f_filiale" :value.sync="model.f_filiale" close-on-select>
13
+ </v-select>
14
+ </div>
15
+ </div>
16
+ <div class="form-group col-sm-2">
17
+ <div class="col-sm-12">
18
+ <v-select :width ="'100%'" style="width: 100%" :options="$parent.$parent.entry_name" placeholder='项目名称' condition="f_entry_name = '{}'"
19
+ v-model="model.f_entry_name" @change="$parent.$parent.entryChange" :value.sync="model.f_entry_name" close-on-select>
20
+ </v-select>
21
+ </div>
22
+ </div>
23
+ <div class="form-group col-sm-2">
24
+ <div class="col-sm-12">
25
+ <input type="text" class="form-control" v-model="model.f_operator"
26
+ condition="f_operator = '{}'" placeholder='请输入收费员'>
27
+ </div>
28
+ </div>
29
+ <div class="form-group col-sm-2">
30
+ <div class="col-sm-12">
31
+ <input type="text" class="form-control" v-model="model.f_payment_remarks"
32
+ condition="f_payment_remarks like '%{}%'" placeholder='请输入备注'>
33
+ </div>
34
+ </div>
35
+
36
+ <div class="form-group col-sm-2">
37
+ <div class="col-sm-12">
38
+ <datepicker placeholder="打款开始日期"
39
+ style="width: 223.73px"
40
+ v-model="model.f_payment_date_start"
41
+ :value.sync="model.f_payment_date_start"
42
+ :format="'yyyy-MM-dd 00:00:00'"
43
+ condition="f_payment_date >= '{}'"
44
+ ></datepicker>
45
+ </div>
46
+ </div>
47
+ <div class="form-group col-sm-2">
48
+ <div class="col-sm-12">
49
+ <datepicker placeholder="打款结束日期"
50
+ style="width: 223.73px"
51
+ v-model="model.f_payment_date_end"
52
+ :value.sync="model.f_payment_date_end"
53
+ :format="'yyyy-MM-dd 23:59:59'"
54
+ condition="f_payment_date <= '{}'"
55
+ ></datepicker>
56
+ </div>
57
+ </div>
58
+
59
+ </div>
60
+ <div class="col-sm-12">
61
+ <div class="form-group col-sm-2">
62
+ <div class="col-sm-4">
63
+ <button class="btn btn-primary btn-sm" type="button" @click="search(),$parent.$parent.close()">
64
+ <span class="glyphicon glyphicon-search"></span>查询
65
+ </button>
66
+ </div>
67
+ <div class="col-sm-4">
68
+ <button class="btn btn-primary btn-sm" type="button" @click="$parent.$parent.clear()">
69
+ <span class="glyphicon glyphicon-search"></span>清空
70
+ </button>
71
+ </div>
72
+ <div class="col-sm-4">
73
+ <button class="btn btn-primary btn-sm" type="button" @click="$parent.$parent.add()">
74
+ <span class="glyphicon glyphicon-search"></span>新增
75
+ </button>
76
+ <!-- <button class="button_clear button_spacing" @click="$parent.$parent.clear()">新增</button>-->
77
+ </div>
78
+
79
+ </div>
80
+ <div class="form-group col-sm-2">
81
+ <div class="col-sm-4">
82
+ <export-excel progress="apply_getExportProgress"
83
+ :data="{condition: condition,data: {fengongsi: this.$login.f.orgs, company: $parent.$parent.company_ok}}"
84
+ :field="$parent.$parent.getfield()"
85
+ sqlurl="rs/logic/apply_exportfile"
86
+ sql-name="reportFormPayment"
87
+ template-name='打款记录报表导出'
88
+ :choose-col="true">
89
+ </export-excel>
90
+ </div>
91
+ </div>
92
+ </div>
93
+ </form>
94
+ </criteria>
95
+ <data-grid :model="model" partial='list' v-ref:grid class="data-grid" is-fixed='false' style="overflow-x:auto">
96
+ <template partial='head'>
97
+ <tr class="title">
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
+ <th>
129
+ <nobr>作废</nobr>
130
+ </th>
131
+ <th>
132
+ <nobr>明细</nobr>
133
+ </th>
134
+ </tr>
135
+ </template>
136
+ <template partial='body'>
137
+ <tr>
138
+ <td style="text-align: center;">
139
+ <nobr>{{$index+1}}</nobr>
140
+ </td>
141
+ <td style="text-align: center;">
142
+ <nobr>{{row.f_filiale}}</nobr>
143
+ </td>
144
+ <td style="text-align: center;">
145
+ <nobr>{{row.f_entry_name}}</nobr>
146
+ </td>
147
+ <td style="text-align: center;">
148
+ <nobr>{{row.f_payment_number}}</nobr>
149
+ </td>
150
+ <td style="text-align: center;">
151
+ <nobr>{{row.f_payment_money}}</nobr>
152
+ </td>
153
+ <td style="text-align: center;">
154
+ <nobr>{{row.f_operator}}</nobr>
155
+ </td>
156
+ <td style="text-align: center;">
157
+ <nobr>{{row.f_payment_date}}</nobr>
158
+ </td>
159
+ <!-- <td style="text-align: center;">-->
160
+ <!-- <nobr>{{row.f_payment_remarks}}</nobr>-->
161
+ <!-- </td>-->
162
+ <td style="text-align: center;">
163
+ <nobr>{{row.f_payment_state}}</nobr>
164
+ </td>
165
+ <td @click="$parent.$parent.$parent.examine(row.f_payment_state,row.id)" style="text-align: center;color: #0b87e2">
166
+ <nobr>审核</nobr>
167
+ </td>
168
+ <td @click="$parent.$parent.$parent.cancel(row.id)" style="text-align: center;color: #0b87e2">
169
+ <nobr>作废</nobr>
170
+ </td>
171
+ <td @click="$parent.$parent.$parent.paymentDetailed(row.id)" style="text-align: center;color: #0b87e2">
172
+ <nobr>单价明细</nobr>
173
+ </td>
174
+ </tr>
175
+
176
+ </template>
177
+ </data-grid>
178
+ </criteria-paged>
179
+ <!--查看单价明细-->
180
+ <!-- <div class="col-sm-12 span recordTable" style="margin-top: -224px;height:auto;" v-if="recordSearch" >-->
181
+ <!-- <p class="text-center" style="padding: 8px;font-size: 20px">-->
182
+ <!-- &lt;!&ndash;单价明细&ndash;&gt;-->
183
+ <!-- <button type="button" class="close" @click="recordSearch=false" aria-hidden="true">&times;</button>-->
184
+ <!-- </p>-->
185
+ <!-- <partial-view v-ref:single-load>-->
186
+ <!-- <data-grid :model="detailedmodel" v-ref:batchgrid>-->
187
+ <!-- <template partial='head'>-->
188
+ <!-- <tr>-->
189
+ <!-- <th>序号</th>-->
190
+ <!-- <th>单价</th>-->
191
+ <!-- <th>户数</th>-->
192
+ <!-- <th>小计</th>-->
193
+ <!-- <th>备注</th>-->
194
+ <!-- </tr>-->
195
+ <!-- </template>-->
196
+ <!-- <template partial='body'>-->
197
+ <!-- <td style="text-align: center">{{$index+1}}</td>-->
198
+ <!-- <td style="text-align: center">{{row.f_install_price}}</td>-->
199
+ <!-- <td style="text-align: center">{{row.f_payment_number}}</td>-->
200
+ <!-- <td style="text-align: center">{{row.f_payment_subtotal}}</td>-->
201
+ <!-- <td style="text-align: center">{{row.f_payment_remarks}}</td>-->
202
+ <!-- </template>-->
203
+ <!-- </data-grid>-->
204
+ <!-- </partial-view>-->
205
+ <!-- </div>-->
206
+ </div>
207
+ <modal :show.sync="recordAdd" v-ref:modal backdrop="false">
208
+ <header slot="modal-header" class="modal-header">
209
+ <button type="button" class="close" @click="close"><span>&times;</span></button>
210
+ <h4 class="modal-title">新增记录</h4>
211
+ </header>
212
+ <article slot="modal-body" class="modal-body">
213
+ <div v-if="recordAdd">
214
+ <div class="from-group" :class="addItem.f_filiale ? '':'has-error'">
215
+ <label>公司名称</label>
216
+ <input-select v-model="addItem.f_filiale" :options='apply_org' :value.sync="addItem.f_filiale" :valueSingle="true"></input-select>
217
+ </div>
218
+ <div class="from-group" :class="addItem.f_entry_name ? '':'has-error'">
219
+ <label>项目名称</label>
220
+ <input-select v-model="addItem.f_entry_name" :options='project_name' :value.sync="addItem.f_entry_name" :valueSingle="true"></input-select>
221
+ </div>
222
+ <div class="from-group">
223
+ <payment-record-add :stairmodel.sync='stairmodel' :f_payment_money.sync="addItem.f_payment_money"></payment-record-add>
224
+ </div>
225
+ <!-- <div class="from-group">-->
226
+ <!-- <label>单价汇总</label>-->
227
+ <!-- <input type="text" class="form-control" v-model="addItem.f_price_summary" :value.sync="addItem.f_price_summary" readonly="readonly">-->
228
+ <!-- </div>-->
229
+ <div class="from-group" :class="addItem.f_payment_money ? '':'has-error'">
230
+ <label>打款金额</label>
231
+ <input type="number" class="form-control" v-model="addItem.f_payment_money" :value.sync="addItem.f_payment_money" readonly="readonly">
232
+ </div>
233
+ <div class="from-group" :class="addItem.f_payment_date ? '':'has-error'">
234
+ <label>打款日期</label>
235
+ <div>
236
+ <datepicker
237
+ style="width: 568px"
238
+ :value.sync="addItem.f_payment_date"
239
+ :format="'yyyy-MM-dd HH:mm:ss'"
240
+ v-model="addItem.f_payment_date"
241
+ :show-reset-button="reset">
242
+ </datepicker>
243
+ </div>
244
+ </div>
245
+ <!-- <div class="from-group">-->
246
+ <!-- <label>备注</label>-->
247
+ <!-- <input type="text" class="form-control" v-model="addItem.f_payment_remarks">-->
248
+ <!-- </div>-->
249
+
250
+ </div>
251
+ </article>
252
+ <footer slot="modal-footer" class="modal-footer">
253
+ <!-- <button type="button" class="btn btn-success" @click='paymentPrice'>添加单价明细</button>-->
254
+ <button type="button" class="btn btn-default" @click='close'>取消</button>
255
+ <button type="button" class="btn btn-success" @click='confirm'>确认</button>
256
+ </footer>
257
+ </modal>
258
+ <!-- 增加单价明细 -->
259
+ <modal :show.sync="paymentAdd" v-ref:modal backdrop="false">
260
+ <header slot="modal-header" class="modal-header">
261
+ <button type="button" class="close" @click="closePrice"><span>&times;</span></button>
262
+ <h4 class="modal-title">单价明细</h4>
263
+ </header>
264
+ <article slot="modal-body" class="modal-body">
265
+ <div v-if="paymentAdd">
266
+ <div class="from-group">
267
+ <label>单价汇总</label>
268
+ <input type="text" class="form-control" v-model="numberItem.f_price_summary" :value.sync="numberItem.f_price_summary" readonly="readonly">
269
+ </div>
270
+ <div class="from-group" :class="numberItem.f_install_price ? '':'has-error'">
271
+ <label>安装费单价</label>
272
+ <input type="number" class="form-control" v-model="numberItem.f_install_price" @change="priceChange">
273
+ </div>
274
+ <div class="from-group" :class="numberItem.f_payment_number ? '':'has-error'">
275
+ <label>户数</label>
276
+ <input type="number" class="form-control" v-model="numberItem.f_payment_number" @change="countChange">
277
+ </div>
278
+ </div>
279
+ </article>
280
+ <footer slot="modal-footer" class="modal-footer">
281
+ <button type="button" class="btn btn-default" @click='closePrice'>取消</button>
282
+ <button type="button" class="btn btn-success" @click='confirmPrice'>确认</button>
283
+ </footer>
284
+ </modal>
285
+ <!-- 查看单价明细 -->
286
+ <modal :show.sync="recordSearch" v-ref:modal backdrop="false" width="500px">
287
+ <header slot="modal-header" class="modal-header">
288
+ <button type="button" class="close" @click="closeSearch"><span>&times;</span></button>
289
+ <h4 class="modal-title">单价明细</h4>
290
+ </header>
291
+ <article slot="modal-body" class="modal-body">
292
+ <div v-if="recordSearch">
293
+ <!-- <payment-record-detailed :condition = 'condition' :f_payment_record_id = 'f_payment_record_id'></payment-record-detailed>-->
294
+ <payment-record-bad></payment-record-bad>
295
+ </div>
296
+ </article>
297
+ <footer slot="modal-footer" class="modal-footer">
298
+ <button type="button" class="btn btn-default" @click='closeSearch'>关闭</button>
299
+ <!-- <button type="button" class="btn btn-success" @click='confirm'>确认</button>-->
300
+ </footer>
301
+ </modal>
302
+ <!-- <div class="col-sm-12 span recordTable" style="overflow-y: scroll" :style="{width: (isdetail && !true) ? '50%' : 'auto'}" v-if="recordSearch" >-->
303
+ <!-- <p class="text-center" style="padding: 8px;font-size: 20px">单价明细-->
304
+ <!-- <button type="button" class="close" @click="recordSearch=false" aria-hidden="true">&times;</button>-->
305
+ <!-- </p>-->
306
+ <!-- <payment-record-detailed :condition = 'condition' :f_payment_record_id = 'f_payment_record_id'></payment-record-detailed>-->
307
+ <!-- </div>-->
308
+ </div>
309
+ </template>
310
+ <script>
311
+ import AppData from '../../../stores/AppData.js'
312
+ import PagedListLogic from '../../../stores/PagedListLogic'
313
+ import getNowDate from '../../getNowDate.js'
314
+ import {HttpResetClass} from 'vue-client'
315
+ import {isEmpty} from '../../Util'
316
+
317
+ export default {
318
+ title: '打款记录报表',
319
+ data() {
320
+ return {
321
+ applytype: this.$appdata.getParam('报建类型'),
322
+ applydepartment: this.$appdata.getParam('项目部'),
323
+ company: this.$login.f.orgs === '重庆盛焰集团' || this.$login.f.orgs === '湖南燎原燃气有限公司' ? " 1 = 1" : " f_filiale = '" + this.$login.f.orgs + "'",
324
+ company_ok: this.$login.f.orgs === '重庆盛焰集团' || this.$login.f.orgs === '湖南燎原燃气有限公司' ? "f_filiale = '1' or 1 = 1" : '1 = 1',
325
+ model: new PagedListLogic('rs/sql/reportFormPayment', 20, {
326
+ data: {
327
+ id: `${this.$login.f.name}`,
328
+ fengongsi: `${this.$login.f.orgs}`,
329
+ company: `${this.$login.f.orgs === '重庆盛焰集团' || this.$login.f.orgs === '湖南燎原燃气有限公司' ? "f_filiale = '1' or 1 = 1" : '1 = 1'}`
330
+ }
331
+ },{f_now_payment_sum:0}),
332
+ users:[],
333
+ defnames:[],
334
+ select: '',
335
+ sum: 0 , //累计总金额
336
+ entry_name: [], //项目名称
337
+ entry_num: [], //项目编号
338
+ apply_org: [],
339
+ recordAdd: false, //打款记录新增记录开关
340
+ recordSearch: false, //打款记录明细开关
341
+ mainPage: true,
342
+ addItem: {
343
+ f_payment_money: 0,
344
+ f_price_summary: ''
345
+ },
346
+ numberItem: {
347
+ f_install_price: 0,
348
+ f_payment_number: 0,
349
+ f_price_summary: ''
350
+ },
351
+ price_summary: '',
352
+ project_name: this.$appdata.getParam('项目名称'),
353
+ condition: '',
354
+ f_payment_record_id: '',
355
+ paymentAdd: false,
356
+ priceArray: [],
357
+ stairmodel: [{f_install_price: 0, f_payment_number: 0, f_payment_subtotal: 0, f_payment_remarks: ''}],
358
+ detailedmodel :{
359
+ rows: []
360
+ }
361
+
362
+ }
363
+ },
364
+ ready() {
365
+ this.getEntry()
366
+ this.getOrgName()
367
+ this.$refs.cp.$refs.cri.search()
368
+ },
369
+ methods: {
370
+ // 获取所有组织名称
371
+ async getOrgName() {
372
+ let http = new HttpResetClass()
373
+ let org = this.$login.f.orgs === '重庆盛焰集团' || this.$login.f.orgs === '湖南燎原燃气有限公司' ? " 1 = 1" : " name = '" + this.$login.f.orgs + "'"
374
+ let data = {
375
+ tablename: 't_organization',
376
+ condition: " name != '组织机构' and " + org
377
+
378
+ }
379
+ let res = await http.load('POST','rs/sql/applysingleTable',{data:data}, {
380
+ resolveMsg: null,
381
+ rejectMsg: '获取公司名称失败'
382
+ })
383
+ for (let i = 0; i < res.data.length; i++) {
384
+ // 所属公司
385
+ let data1 = []
386
+ let array1 = []
387
+ data1 = res.data.map(item => {
388
+ return item.name;
389
+ })
390
+ for (let q = 0; q < data1.length; q++) {
391
+ let arraydata = {
392
+ 'label': data1[q],
393
+ 'value': data1[q]
394
+ }
395
+ if (array1.length != 0) {
396
+ for (let w = 0; w < array1.length; w++) {
397
+ if (array1[w].label == data1[q]) {
398
+ break
399
+ }
400
+ while (w == array1.length - 1) {
401
+ array1.push(arraydata)
402
+ break
403
+ }
404
+ }
405
+ } else {
406
+ array1.push(arraydata)
407
+ }
408
+ }
409
+ this.apply_org = array1
410
+ }
411
+ },
412
+ generateUUID() {
413
+ var d = new Date().getTime()
414
+ var uuid = 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
415
+ var r = (d + Math.random() * 16) % 16 | 0
416
+ d = Math.floor(d / 16)
417
+ return (c === 'x' ? r : (r & 0x3 | 0x8)).toString(16)
418
+ })
419
+ return uuid
420
+ },
421
+ async getEntry(val) {
422
+ // 获取项目名称和项目编号
423
+ let http = new HttpResetClass()
424
+ let data = {
425
+ tablename: 't_payment_record',
426
+ condition: this.company
427
+ }
428
+ // 判断是不是总公司得账号
429
+ if (this.$login.f.orgs == '重庆盛焰集团' || this.$login.f.orgs == '湖南燎原燃气有限公司') {
430
+ data.condition = " f_filiale = '" + val + "'"
431
+ }
432
+ let res = await http.load('POST','rs/sql/applysingleTable',{data:data}, {
433
+ resolveMsg: null,
434
+ rejectMsg: '获取项目名称和项目编号失败'
435
+ })
436
+ for (let i = 0; i < res.data.length; i++) {
437
+ // 项目名称
438
+ let data = []
439
+ let array = []
440
+ data = res.data.map(item => {
441
+ return item.f_entry_name;
442
+ })
443
+ for (let q = 0; q < data.length; q++) {
444
+ let arraydata = {
445
+ 'label': data[q],
446
+ 'value': data[q]
447
+ }
448
+ if (array.length != 0) {
449
+ for (let w = 0; w < array.length; w++) {
450
+ if (array[w].label == data[q]) {
451
+ break
452
+ }
453
+ while (w == array.length - 1) {
454
+ array.push(arraydata)
455
+ break
456
+ }
457
+ }
458
+ } else {
459
+ array.push(arraydata)
460
+ }
461
+ }
462
+ this.entry_name = array
463
+
464
+ }
465
+ },
466
+ async getNum(val) {
467
+ // 获取项目名称和项目编号
468
+ let http = new HttpResetClass()
469
+ let data = {
470
+ tablename: 't_apply',
471
+ condition: this.$login.f.orgs === '重庆盛焰集团' || this.$login.f.orgs === '湖南燎原燃气有限公司' ? "f_entry_name = '" + val + "'" : "f_filiale = '" + this.$login.f.orgs + "'" + " and f_entry_name = '" + val + "'"
472
+ }
473
+ let res = await http.load('POST','rs/sql/applysingleTable',{data:data}, {
474
+ resolveMsg: null,
475
+ rejectMsg: '获取项目名称和项目编号失败'
476
+ })
477
+ for (let i = 0; i < res.data.length; i++) {
478
+ // 项目编号
479
+ let data1 = []
480
+ let array1 = []
481
+ data1 = res.data.map(item => {
482
+ return item.f_entry_num;
483
+ })
484
+ for (let q = 0; q < data1.length; q++) {
485
+ let arraydata = {
486
+ 'label': data1[q],
487
+ 'value': data1[q]
488
+ }
489
+ if (array1.length != 0) {
490
+ for (let w = 0; w < array1.length; w++) {
491
+ if (array1[w].label == data1[q]) {
492
+ break
493
+ }
494
+ while (w == array1.length - 1) {
495
+ array1.push(arraydata)
496
+ break
497
+ }
498
+ }
499
+ } else {
500
+ array1.push(arraydata)
501
+ }
502
+ }
503
+ this.entry_num = array1
504
+ }
505
+ },
506
+ entryChange(val) {
507
+ console.log("被选中的数据:" + val)
508
+ this.getNum(val)
509
+ },
510
+ orgChange(val) {
511
+ console.log("被选中的数据:" + val)
512
+ this.getEntry(val)
513
+ },
514
+ async moneyChange() {
515
+ // if (isEmpty(this.addItem.f_install_money)) {
516
+ // if (isEmpty(this.addItem.f_payment_count)) {
517
+ this.addItem.f_payment_money = this.addItem.f_install_money * this.addItem.f_payment_count
518
+ console.log("进入金额计算:" + this.addItem.f_payment_money)
519
+ // }
520
+ //
521
+ // }
522
+
523
+ },
524
+ async priceChange() {
525
+ console.log("改变单价---------")
526
+ // this.addItem.f_install_money = this.addItem.f_install_money + this.numberItem.f_install_price + '|'
527
+ // let str1 = this.addItem.f_install_money + this.numberItem.f_install_price + '|'
528
+ // this.$set('addItem.f_install_money', str1)
529
+ },
530
+ async countChange() {
531
+ console.log("改变户数---------")
532
+ // this.addItem.f_payment_count = this.addItem.f_payment_count + this.numberItem.f_payment_number + '|'
533
+ // let str2 = this.addItem.f_payment_count + this.numberItem.f_payment_number + '|'
534
+ // this.$set('addItem.f_payment_count', str2)
535
+ },
536
+ check(val) {
537
+ this.$dispatch('check', val)
538
+ },
539
+ close(apply) {
540
+ this.recordAdd = false
541
+ this.addItem = {
542
+ f_payment_money: 0
543
+ }
544
+ this.priceArray = []
545
+ this.$dispatch('close')
546
+ },
547
+ closeSearch() {
548
+ // this.mainPage = true
549
+ this.recordSearch = false
550
+ this.$dispatch('close')
551
+ },
552
+ async paymentDetailed(f_payment_record_id) {
553
+ console.log("进入paymentDetailed方法")
554
+ // this.mainPage = false
555
+ this.recordSearch = true
556
+ this.condition = this.model.condition
557
+ this.f_payment_record_id = f_payment_record_id
558
+ let http = new HttpResetClass()
559
+ let data = {
560
+ f_payment_record_id: f_payment_record_id
561
+ }
562
+ let res = await http.load('POST','rs/sql/reportFormPaymentDetailed',{data: data}, {
563
+ resolveMsg: null,
564
+ rejectMsg: '新增单价户数失败'
565
+ })
566
+ this.detailedmodel.rows = res.data
567
+ },
568
+ async confirm() {
569
+ if (isEmpty(this.addItem.f_filiale)) {
570
+ this.$showAlert('请选择公司名称!!!', 'warning', 3000)
571
+ return
572
+ }
573
+ if (isEmpty(this.addItem.f_entry_name)) {
574
+ this.$showAlert('请选择项目名称!!!', 'warning', 3000)
575
+ return
576
+ }
577
+ //先增加明细
578
+ if (this.stairmodel[0].f_install_price && this.stairmodel[0].f_payment_number) {
579
+
580
+ let http = new HttpResetClass()
581
+ let data = {
582
+ tablename: 't_price_count',
583
+ stairmodel: this.stairmodel
584
+ }
585
+ let res = await http.load('POST','rs/logic/addPrice',{data: data}, {
586
+ resolveMsg: null,
587
+ rejectMsg: '新增单价户数失败'
588
+ })
589
+ console.log("添加成功:" + JSON.stringify(res.data))
590
+ if (res.data.length > 0) {
591
+ console.log("修改成功")
592
+ this.priceArray = res.data
593
+ // this.$showMessage("添加成功!")
594
+ }
595
+
596
+ }
597
+ // 后增加记录
598
+
599
+ if (this.addItem.f_payment_money) {
600
+ // this.addItem.f_payment_date = new Date().Format("yyyy-MM-dd HH:mm:ss")
601
+ // this.addItem.f_operate_date = new Date().Format('yyyy-MM-dd HH:mm:ss')
602
+ this.addItem.f_operator = this.$login.f.name
603
+ this.addItem.f_payment_state = '审核中'
604
+
605
+ let http = new HttpResetClass()
606
+ let data = {
607
+ tablename: 't_payment_record',
608
+ parameters: this.addItem
609
+ }
610
+ let res = await http.load('POST','rs/logic/apply_save',{data: data}, {
611
+ resolveMsg: null,
612
+ rejectMsg: '新增打款记录失败'
613
+ })
614
+ console.log("添加成功:" + res.data.id)
615
+ if (res.data.id) {
616
+ let http1 = new HttpResetClass()
617
+ let data1 = {
618
+ f_payment_record_id: res.data.id,
619
+ priceArray: this.priceArray
620
+ }
621
+ console.log("更新的数据" + JSON.stringify(data1))
622
+ let res1 = await http1.load('POST','rs/logic/updatePrice',{data: data1}, {
623
+ resolveMsg: null,
624
+ rejectMsg: '更新打款记录id失败'
625
+ })
626
+ this.priceArray = []
627
+ this.close()
628
+ this.$refs.cp.$refs.cri.search()
629
+ this.$showMessage("添加成功!")
630
+ }
631
+
632
+ }
633
+
634
+ },
635
+ paymentPrice() {
636
+ this.numberItem.f_install_price = 0
637
+ this.numberItem.f_payment_number = 0
638
+ this.recordAdd = false
639
+ this.paymentAdd = true
640
+ },
641
+ closePrice() {
642
+ this.recordAdd = true
643
+ this.paymentAdd = false
644
+ },
645
+ examine(f_payment_state,id) {
646
+ if (this.$login.f.rolesnames.includes("打款审核")) {
647
+ if (f_payment_state != '审核中') {
648
+ this.$showMessage('该记录无需审核!')
649
+ } else {
650
+ this.$showMessage('是否已确认财务到账?', ['confirm', 'cancel']).then(async (res) => {
651
+ if (res === 'confirm') {
652
+ let http = new HttpResetClass()
653
+ let data = {
654
+ tablename: 't_payment_record',
655
+ parameters: {
656
+ id: id,
657
+ f_payment_state: '有效'
658
+ }
659
+ }
660
+
661
+ let result = await http.load('POST','rs/logic/apply_save',{data: data}, {
662
+ resolveMsg: null,
663
+ rejectMsg: '审核失败'
664
+ })
665
+ console.log("审核成功:" + result.data.id)
666
+ if (result.data.id) {
667
+ this.$refs.cp.$refs.cri.search()
668
+ this.$showMessage("审核成功!")
669
+ }
670
+ }
671
+ })
672
+ }
673
+
674
+ } else {
675
+ this.$showMessage("您没有此操作权限!")
676
+ }
677
+
678
+
679
+ },
680
+ cancel(id) {
681
+ if (this.$login.f.rolesnames.includes("打款作废")) {
682
+ this.$showMessage('是否将此条记录作废?', ['confirm', 'cancel']).then(async (res) => {
683
+ if (res === 'confirm') {
684
+ let http = new HttpResetClass()
685
+ let data = {
686
+ tablename: 't_payment_record',
687
+ parameters: {
688
+ id: id,
689
+ f_payment_state: '作废'
690
+ }
691
+ }
692
+
693
+ let result = await http.load('POST','rs/logic/apply_save',{data: data}, {
694
+ resolveMsg: null,
695
+ rejectMsg: '作废失败'
696
+ })
697
+ console.log("作废成功:" + result.data.id)
698
+ if (result.data.id) {
699
+ this.$refs.cp.$refs.cri.search()
700
+ this.$showMessage("作废成功!")
701
+ }
702
+ }
703
+ })
704
+
705
+ } else {
706
+ this.$showMessage("您没有此操作权限!")
707
+ }
708
+ },
709
+ async confirmPrice() {
710
+ if (isEmpty(this.numberItem.f_install_price)) {
711
+ this.$showAlert('请输入安装费单价!!!', 'warning', 3000)
712
+ return
713
+ }
714
+ if (isEmpty(this.numberItem.f_payment_number)) {
715
+ this.$showAlert('请输入户数!!!', 'warning', 3000)
716
+ return
717
+ }
718
+ if (this.numberItem.f_install_price && this.numberItem.f_payment_number) {
719
+
720
+ let http = new HttpResetClass()
721
+ let data = {
722
+ tablename: 't_price_count',
723
+ parameters: this.numberItem
724
+ }
725
+ let res = await http.load('POST','rs/logic/apply_save',{data: data}, {
726
+ resolveMsg: null,
727
+ rejectMsg: '新增单价户数失败'
728
+ })
729
+ console.log("添加成功:" + res.data.id)
730
+ if (res.data.id) {
731
+ this.price_summary = this.price_summary + this.numberItem.f_install_price + ' | ' + this.numberItem.f_payment_number + ' || '
732
+ this.numberItem = Object.assign({},this.numberItem,{f_price_summary:this.price_summary})
733
+ this.addItem = Object.assign({},this.addItem,{f_price_summary:this.price_summary})
734
+ this.addItem.f_payment_money = Number(this.addItem.f_payment_money) + Number(this.numberItem.f_install_price * this.numberItem.f_payment_number)
735
+ console.log("修改成功")
736
+ this.priceArray.push(res.data.id)
737
+ // this.closePrice()
738
+ this.$showMessage("添加成功!")
739
+ this.numberItem.f_install_price = 0
740
+ this.numberItem.f_payment_number = 0
741
+ }
742
+
743
+ }
744
+ },
745
+ compare(val) {
746
+ val === '完工'
747
+ console.log('完工', val)
748
+ return false
749
+ },
750
+ clear() {
751
+ Object.keys(this.$refs.cp.$refs.cri.model).forEach((key) => {
752
+ this.$refs.cp.$refs.cri.model[key] = []
753
+ })
754
+ },
755
+ add() {
756
+ this.recordAdd = true
757
+ this.stairmodel = [{f_install_price: 0, f_payment_number: 0, f_payment_subtotal: 0, f_payment_remarks: ''}]
758
+ },
759
+ getfield() {
760
+ let report = {
761
+ 'f_filiale': '所属公司',
762
+ 'f_entry_name': '项目名称',
763
+ 'f_install_money': '安装费单价',
764
+ 'f_payment_count': '户数',
765
+ 'f_payment_money': '金额',
766
+ 'f_operator': '收费员',
767
+ 'f_payment_date': '打款日期',
768
+ 'f_payment_remarks': '备注',
769
+ 'f_payment_state': '打款状态'
770
+ }
771
+ return report
772
+ },
773
+ getCondition() {
774
+ let data = {
775
+ condition: ` 1 = 1`,
776
+ data: {
777
+ fengongsi: `${this.$login.f.f_fengongsi}`
778
+ }
779
+ }
780
+ return data
781
+ }
782
+ },
783
+ computed: {
784
+ date() {
785
+ return getNowDate()
786
+ },
787
+ selected() {
788
+ return this.$refs.cp.$refs.grid.selected
789
+ },
790
+ applytype() {
791
+ return [{label: '全部', value: ''}, ...this.$appdata.getParam('报建类型')]
792
+ }
793
+ }
794
+ }
795
+ </script>
796
+ <style>
797
+ tr.title {
798
+ background-color: #6666ff;
799
+ }
800
+
801
+ </style>