apply-clients 7.1.36-yuchuan-12 → 7.1.36-yuchuan-13
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.
- package/android.html +28 -28
- package/build/dev-server.js +28 -10
- package/index.html +39 -39
- package/package.json +3 -4
- package/src/apply.js +162 -161
- package/src/applyAndroid.js +97 -97
- package/src/components/android/AppSign.vue +235 -235
- package/src/components/android/AppUpload.vue +275 -275
- package/src/components/android/Ignition/VentilationIgnition.vue +408 -408
- package/src/components/android/Ignition/VentilationIgnitionHandle.vue +462 -462
- package/src/components/android/Process/AppExplorationUser.vue +454 -454
- package/src/components/android/Process/AppServiceControl.vue +1437 -1437
- package/src/components/android/Process/Processes/AppInstallationDetails.vue +980 -980
- package/src/components/android/Sign/AppSignTask.vue +183 -183
- package/src/components/android/Supervisory/AppProcessSupervisory.vue +344 -344
- package/src/components/android/Task/GuanXianJianShe/AppExplorationGuanXian.vue +317 -317
- package/src/components/android/Task/ShiGongXinXi/AppShowBuildUser.vue +431 -431
- package/src/components/android/Task/yiban/AppShowDone.vue +442 -442
- package/src/components/android/Task/yiban/ShowDone.vue +95 -95
- package/src/components/android/Task/yiban/satisfactionShow.vue +166 -166
- package/src/components/android/newPackage/customerServiceManager.vue +218 -218
- package/src/components/android/newPackage/projectPrice.vue +218 -218
- package/src/components/product/ApplyCharge/ApplyChargeList.vue +1 -1
- package/src/components/product/ApplyGaiXianCharge/ApplyGaiXianViewList.vue +272 -272
- package/src/components/product/ApplyGuanXian/GuanXianCaiLiao.vue +236 -236
- package/src/components/product/ApplyGuanXian/GuanXianExplorationSelect.vue +324 -324
- package/src/components/product/ApplyGuanXian/GuanXianExplorationUser.vue +144 -144
- package/src/components/product/ApplyGuanXian/GuanXianSupervisoryhCart.vue +119 -119
- package/src/components/product/ApplyMap/AMapLocation.vue +870 -0
- package/src/components/product/ApplyMap/AmapUtil.js +37 -0
- package/src/components/product/ApplyMap/ApplyDragaboutList.vue +223 -223
- package/src/components/product/ApplyMap/ApplyInputSearch.vue +212 -212
- package/src/components/product/ApplyMap/ApplyMapCom.vue +82 -82
- package/src/components/product/ApplyMap/ApplyMapInputSearch.vue +335 -335
- package/src/components/product/ApplyMap/ApplyMapLocation.vue +862 -862
- package/src/components/product/ChongZheng/ApplyChongZhengList.vue +415 -415
- package/src/components/product/Function/InstallFunction.vue +133 -133
- package/src/components/product/Function/InstallInfoSelect.vue +371 -371
- package/src/components/product/Function/Service/FunctionServiceControl.vue +586 -586
- package/src/components/product/GongJianPush/ApplyPushDispose.vue +162 -72
- package/src/components/product/GongJianPush/ApplyPushList.vue +47 -52
- package/src/components/product/GongJianPush/ApplyPushManage.vue +4 -3
- package/src/components/product/Ignition/IgnitionListManage.vue +602 -602
- package/src/components/product/Ignition/IgnitionRecord.vue +380 -380
- package/src/components/product/InsuranceApply/InsuranceReport.vue +3 -4
- package/src/components/product/List/OldShowDevices.vue +271 -271
- package/src/components/product/List/ShowAllActivity.vue +540 -540
- package/src/components/product/List/ShowDevices.vue +279 -279
- package/src/components/product/Print/BuildOrder/buildOrderList.vue +446 -446
- package/src/components/product/Process/ExplorationSelect.vue +597 -597
- package/src/components/product/Process/ExplorationUser.vue +158 -158
- package/src/components/product/Process/New1ExplorationUser.vue +201 -201
- package/src/components/product/Process/NewExplorationSelect.vue +586 -586
- package/src/components/product/Process/NewExplorationUser.vue +219 -219
- package/src/components/product/Process/Processes/InstallationDetails.vue +1159 -1159
- package/src/components/product/Process/Processes/Print/printCharge.vue +250 -250
- package/src/components/product/Process/Processes/Print/printGaiXianCharge.vue +244 -244
- package/src/components/product/Process/Processes/chargeManagement.vue +704 -704
- package/src/components/product/Process/Processes/devicesManagement.vue +393 -393
- package/src/components/product/Process/Processes/newDevicesManagement.vue +413 -413
- package/src/components/product/Process/Processes/selectChaiChuUserinfo.vue +230 -230
- package/src/components/product/Process/Processes/selectOldUserinfo.vue +241 -241
- package/src/components/product/Process/Processes/selectUserinfo.vue +234 -234
- package/src/components/product/Process/Service/ServiceControl.vue +2205 -2205
- package/src/components/product/ServiceView.vue +644 -644
- package/src/components/product/Stop/StopApplyList.vue +224 -224
- package/src/components/product/Supervisory/NewSupervisoryhCart.vue +175 -175
- package/src/components/product/Supervisory/Service/SupervisoryServiceControl.vue +592 -592
- package/src/components/product/Supervisory/SupervisoryControl.vue +116 -116
- package/src/components/product/Supervisory/SupervisoryList.vue +557 -557
- package/src/components/product/Supervisory/SupervisoryhCart.vue +119 -119
- package/src/components/product/Supervisory/YiBanSupervisoryList.vue +539 -539
- package/src/components/product/VueUtils/ApplyUpload.vue +294 -285
- package/src/components/product/records/AdjustmentRecordList.vue +162 -162
- package/src/main.js +27 -27
- package/static/marker-default.png +0 -0
- package/static/myLocationIcon.png +0 -0
|
@@ -1,704 +1,704 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="col-sm-12" style="margin: 20px 0px;">
|
|
3
|
-
<data-grid :model="model" v-ref:grid class="list_area table_sy" style="padding: 0px">
|
|
4
|
-
<template partial='head'>
|
|
5
|
-
<tr>
|
|
6
|
-
<th class="textNoLineBreak">序号</th>
|
|
7
|
-
<th class="textNoLineBreak">收费金额</th>
|
|
8
|
-
<th class="textNoLineBreak">金额大写</th>
|
|
9
|
-
<th class="textNoLineBreak">付款方式</th>
|
|
10
|
-
<th class="textNoLineBreak">收费人员</th>
|
|
11
|
-
<th class="textNoLineBreak">收费日期</th>
|
|
12
|
-
<th class="textNoLineBreak">备注</th>
|
|
13
|
-
<th class="textNoLineBreak">缴费状态</th>
|
|
14
|
-
<th class="textNoLineBreak">作废人员</th>
|
|
15
|
-
<th class="textNoLineBreak">作废时间</th>
|
|
16
|
-
<th class="textNoLineBreak">作废原因</th>
|
|
17
|
-
<th class="textNoLineBreak">票据类型</th>
|
|
18
|
-
<th class="textNoLineBreak">票据状态</th>
|
|
19
|
-
<th class="textNoLineBreak">
|
|
20
|
-
<button
|
|
21
|
-
type="button"
|
|
22
|
-
class="btn btn-info head-but"
|
|
23
|
-
@click="$parent.$parent.showChargeModal()"
|
|
24
|
-
:disabled="$parent.$parent.mark === 1 || ($parent.$parent.selectdata.f_cumulative_payment_money >= $parent.$parent.selectdata.f_due_money || $parent.$parent.selectdata.f_surplus_money === 0)"
|
|
25
|
-
>新增收费</button>
|
|
26
|
-
</th>
|
|
27
|
-
</tr>
|
|
28
|
-
</template>
|
|
29
|
-
<template partial='body'>
|
|
30
|
-
<tr>
|
|
31
|
-
<td style="text-align: center;">
|
|
32
|
-
<nobr>{{$index+1}}</nobr>
|
|
33
|
-
</td>
|
|
34
|
-
<td style="text-align: center;">
|
|
35
|
-
<nobr>{{row.f_charge_money}}</nobr>
|
|
36
|
-
</td>
|
|
37
|
-
<td style="text-align: center;">
|
|
38
|
-
<nobr>{{row.f_amount_words}}</nobr>
|
|
39
|
-
</td>
|
|
40
|
-
<td style="text-align: center;">
|
|
41
|
-
<nobr>{{row.f_payment_method}}</nobr>
|
|
42
|
-
</td>
|
|
43
|
-
<td style="text-align: center;">
|
|
44
|
-
<nobr>{{row.f_charge_collectors}}</nobr>
|
|
45
|
-
</td>
|
|
46
|
-
<td style="text-align: center;">
|
|
47
|
-
<nobr>{{row.f_charge_date}}</nobr>
|
|
48
|
-
</td>
|
|
49
|
-
<td style="text-align: center;">
|
|
50
|
-
<nobr>{{row.f_charge_remarks}}</nobr>
|
|
51
|
-
</td>
|
|
52
|
-
<td style="text-align: center;">
|
|
53
|
-
<nobr>{{row.f_charge_status}}</nobr>
|
|
54
|
-
</td>
|
|
55
|
-
<td style="text-align: center;">
|
|
56
|
-
<nobr>{{row.f_void_staff}}</nobr>
|
|
57
|
-
</td>
|
|
58
|
-
<td style="text-align: center;">
|
|
59
|
-
<nobr>{{row.f_void_date}}</nobr>
|
|
60
|
-
</td>
|
|
61
|
-
<td style="text-align: center;">
|
|
62
|
-
<nobr>{{row.f_void_remarks}}</nobr>
|
|
63
|
-
</td>
|
|
64
|
-
<td style="text-align: center;">
|
|
65
|
-
<nobr>{{row.f_bill_style}}</nobr>
|
|
66
|
-
</td>
|
|
67
|
-
<td style="text-align: center;">
|
|
68
|
-
<nobr>{{row.f_bill_state}}</nobr>
|
|
69
|
-
</td>
|
|
70
|
-
<td style="text-align: center;">
|
|
71
|
-
<nobr v-if="row.f_charge_status !== '退款'">
|
|
72
|
-
<button
|
|
73
|
-
type="button"
|
|
74
|
-
name="button"
|
|
75
|
-
class="btn btn-link"
|
|
76
|
-
v-if = false
|
|
77
|
-
:disabled="$parent.$parent.mark === 1 || row.f_charge_status === '作废'"
|
|
78
|
-
@click="$parent.$parent.showInvalidModal(row)"
|
|
79
|
-
>作废</button>
|
|
80
|
-
|
|
81
|
-
<button
|
|
82
|
-
type="button" name="button" class="btn btn-link"
|
|
83
|
-
v-if="row.f_bill_state !== '开票成功' && row.f_charge_status !== '作废'"
|
|
84
|
-
@click="$parent.$parent.openBill(row)"
|
|
85
|
-
>开票</button>
|
|
86
|
-
|
|
87
|
-
<button
|
|
88
|
-
type="button" name="button" class="btn btn-link"
|
|
89
|
-
v-if = "row.f_bill_state === '开票成功'"
|
|
90
|
-
@click="$parent.$parent.showPrintModal(row)"
|
|
91
|
-
>查看发票</button>
|
|
92
|
-
</nobr>
|
|
93
|
-
</td>
|
|
94
|
-
</tr>
|
|
95
|
-
</template>
|
|
96
|
-
</data-grid>
|
|
97
|
-
|
|
98
|
-
<validator name="v">
|
|
99
|
-
<modal v-if="showCharge" :show.sync="showCharge" v-ref:modal :large="true" :backdrop="false" title="收费明细">
|
|
100
|
-
<header slot="modal-header" class="modal-header">
|
|
101
|
-
<button type="button" class="close" @click="closeModal"><span>×</span></button>
|
|
102
|
-
<h4 class="modal-title">收费明细</h4>
|
|
103
|
-
</header>
|
|
104
|
-
<article slot="modal-body" class="modal-body clearfix">
|
|
105
|
-
<div class="form-group col-sm-6" :class="[$v.f_charge_money.required ? 'has-error' : '']">
|
|
106
|
-
<label class="col-sm-4 control-label">收费金额:</label>
|
|
107
|
-
<div class="col-sm-8">
|
|
108
|
-
<input type="text"
|
|
109
|
-
class="form-control input_view"
|
|
110
|
-
style="width: 100%"
|
|
111
|
-
placeholder="0.00"
|
|
112
|
-
@keyup="handleInput"
|
|
113
|
-
@change="moneyChange"
|
|
114
|
-
v-validate:f_charge_money = "['required']"
|
|
115
|
-
v-model="charge.f_charge_money" />
|
|
116
|
-
</div>
|
|
117
|
-
</div>
|
|
118
|
-
<div class="form-group col-sm-6" :class="[$v.f_feecount.required ? 'has-error' : '']">
|
|
119
|
-
<label class="col-sm-4 control-label">缴费户数:</label>
|
|
120
|
-
<div class="col-sm-8">
|
|
121
|
-
<input type="text"
|
|
122
|
-
class="form-control input_view"
|
|
123
|
-
style="width: 100%"
|
|
124
|
-
v-validate:f_feecount = "['required']"
|
|
125
|
-
v-model="charge.f_feecount"
|
|
126
|
-
:value="selectdata.f_install_count"
|
|
127
|
-
/>
|
|
128
|
-
</div>
|
|
129
|
-
</div>
|
|
130
|
-
<div class="form-group col-sm-6">
|
|
131
|
-
<label class="col-sm-4 control-label">金额大写:</label>
|
|
132
|
-
<div class="col-sm-8">
|
|
133
|
-
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
134
|
-
:value="smalltoBIG(0)" v-model.sync="charge.f_amount_words"/>
|
|
135
|
-
</div>
|
|
136
|
-
</div>
|
|
137
|
-
<div class="form-group col-sm-6" :class="[$v.f_payment_method.required ? 'has-error' : '']">
|
|
138
|
-
<label class="col-sm-4 control-label">付款方式:</label>
|
|
139
|
-
<div class="col-sm-8">
|
|
140
|
-
<input type="text" v-show="false" v-model="charge.f_payment_method" v-validate:f_payment_method = "['required']" >
|
|
141
|
-
<input-select
|
|
142
|
-
placeholder='请选择' width="100%"
|
|
143
|
-
v-model="charge.f_payment_method"
|
|
144
|
-
:value.sync="charge.f_payment_method"
|
|
145
|
-
:options='paymentMethod'
|
|
146
|
-
class="select select_list"
|
|
147
|
-
:value-single="true"
|
|
148
|
-
close-on-select ></input-select>
|
|
149
|
-
</div>
|
|
150
|
-
</div>
|
|
151
|
-
<div class="form-group col-sm-6" :class="[$v.f_bill_style.required ? 'has-error' : '']">
|
|
152
|
-
<label class="col-sm-4 control-label">票据类型:</label>
|
|
153
|
-
<div class="col-sm-8">
|
|
154
|
-
<input type="text" v-show="false" v-model="charge.f_bill_style" :value.sync="selectdata.f_paper_type" v-validate:f_bill_style = "['required']" >
|
|
155
|
-
<input-select
|
|
156
|
-
placeholder='请选择' width="100%"
|
|
157
|
-
v-model="charge.f_bill_style"
|
|
158
|
-
:value.sync="selectdata.f_paper_type"
|
|
159
|
-
:options='billStyleList'
|
|
160
|
-
class="select select_list"
|
|
161
|
-
:value-single="true"
|
|
162
|
-
close-on-select ></input-select>
|
|
163
|
-
</div>
|
|
164
|
-
</div>
|
|
165
|
-
<div class="form-group col-sm-6">
|
|
166
|
-
<label class="col-sm-4 control-label">应交总金额:</label>
|
|
167
|
-
<div class="col-sm-8">
|
|
168
|
-
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
169
|
-
v-model="selectdata.f_due_money" />
|
|
170
|
-
</div>
|
|
171
|
-
</div>
|
|
172
|
-
<div class="form-group col-sm-6">
|
|
173
|
-
<label class="col-sm-4 control-label">未结总金额:</label>
|
|
174
|
-
<div class="col-sm-8">
|
|
175
|
-
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
176
|
-
v-model="selectdata.f_surplus_money" />
|
|
177
|
-
</div>
|
|
178
|
-
</div>
|
|
179
|
-
<div class="form-group col-sm-6">
|
|
180
|
-
<label class="col-sm-4 control-label">累计缴费总金额:</label>
|
|
181
|
-
<div class="col-sm-8">
|
|
182
|
-
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
183
|
-
v-model="selectdata.f_cumulative_payment_money" />
|
|
184
|
-
</div>
|
|
185
|
-
</div>
|
|
186
|
-
<div class="form-group col-sm-12">
|
|
187
|
-
<label class="col-sm-2 control-label">备注:</label>
|
|
188
|
-
<div class="col-sm-10">
|
|
189
|
-
<input type="text" class="form-control input_view" style="width: 100%"
|
|
190
|
-
v-model="charge.f_charge_remarks" />
|
|
191
|
-
</div>
|
|
192
|
-
</div>
|
|
193
|
-
<div class="form-group col-sm-6">
|
|
194
|
-
<label class="col-sm-4 control-label">购货单位识别号:</label>
|
|
195
|
-
<div class="col-sm-8">
|
|
196
|
-
<input type="text" class="form-control input_view" style="width: 100%"
|
|
197
|
-
v-model="charge.f_taxpayer_id" :value="selectdata.f_taxpayer_id" />
|
|
198
|
-
</div>
|
|
199
|
-
</div>
|
|
200
|
-
<div class="form-group col-sm-6" :class="[$v.f_paper_name.required ? 'has-error' : '']">
|
|
201
|
-
<label class="col-sm-4 control-label">购货单位名称:</label>
|
|
202
|
-
<div class="col-sm-8">
|
|
203
|
-
<input type="text" class="form-control input_view" style="width: 100%"
|
|
204
|
-
v-validate:f_paper_name = "['required']"
|
|
205
|
-
v-model="charge.f_paper_name" :value="selectdata.f_paper_name" />
|
|
206
|
-
</div>
|
|
207
|
-
</div>
|
|
208
|
-
<div class="form-group col-sm-6">
|
|
209
|
-
<label class="col-sm-4 control-label">购货单位银行账号:</label>
|
|
210
|
-
<div class="col-sm-8">
|
|
211
|
-
<input type="text" class="form-control input_view" style="width: 100%"
|
|
212
|
-
v-model="charge.f_paper_account" :value="selectdata.f_paper_account" />
|
|
213
|
-
</div>
|
|
214
|
-
</div>
|
|
215
|
-
<div class="form-group col-sm-6">
|
|
216
|
-
<label class="col-sm-4 control-label">购货单位地址电话:</label>
|
|
217
|
-
<div class="col-sm-8">
|
|
218
|
-
<input type="text" class="form-control input_view" style="width: 100%"
|
|
219
|
-
v-model="charge.f_address_phone" :value="selectdata.f_address_phone" />
|
|
220
|
-
</div>
|
|
221
|
-
</div>
|
|
222
|
-
<div class="form-group col-sm-12">
|
|
223
|
-
<label class="col-sm-2 control-label">发票备注:</label>
|
|
224
|
-
<div class="col-sm-10">
|
|
225
|
-
<input type="text" class="form-control input_view" style="width: 100%"
|
|
226
|
-
v-model="charge.f_bill_remarks" :value="selectdata.f_paper_remarks"/>
|
|
227
|
-
</div>
|
|
228
|
-
</div>
|
|
229
|
-
</article>
|
|
230
|
-
<footer slot="modal-footer" class="modal-footer">
|
|
231
|
-
<button type="button" class="btn btn-primary" :disabled='!$v.valid' @click="saveCharge()">新增收费</button>
|
|
232
|
-
</footer>
|
|
233
|
-
</modal>
|
|
234
|
-
</validator>
|
|
235
|
-
|
|
236
|
-
<modal v-if="showInvalid" :show.sync="showInvalid" v-ref:modal :backdrop="false" title="作废收费">
|
|
237
|
-
<header slot="modal-header" class="modal-header">
|
|
238
|
-
<button type="button" class="close" @click="closeModal"><span>×</span></button>
|
|
239
|
-
<h4 class="modal-title">作废收费</h4>
|
|
240
|
-
</header>
|
|
241
|
-
<article slot="modal-body" class="modal-body clearfix">
|
|
242
|
-
<div class="form-group col-sm-12" v-if="false">
|
|
243
|
-
<label class="col-sm-2 control-label">缴费地址:</label>
|
|
244
|
-
<div class="col-sm-10">
|
|
245
|
-
<input type="text"
|
|
246
|
-
class="form-control input_view"
|
|
247
|
-
style="width: 100%"
|
|
248
|
-
readonly
|
|
249
|
-
v-model="charge.f_useraddres" />
|
|
250
|
-
</div>
|
|
251
|
-
</div>
|
|
252
|
-
<div class="form-group col-sm-12">
|
|
253
|
-
<label class="col-sm-2 control-label">收费金额:</label>
|
|
254
|
-
<div class="col-sm-10">
|
|
255
|
-
<input type="text"
|
|
256
|
-
class="form-control input_view"
|
|
257
|
-
style="width: 100%"
|
|
258
|
-
readonly
|
|
259
|
-
v-model="charge.f_charge_money" />
|
|
260
|
-
</div>
|
|
261
|
-
</div>
|
|
262
|
-
<div class="form-group col-sm-12">
|
|
263
|
-
<label class="col-sm-2 control-label">付款方式:</label>
|
|
264
|
-
<div class="col-sm-10">
|
|
265
|
-
<input type="text"
|
|
266
|
-
class="form-control input_view"
|
|
267
|
-
style="width: 100%"
|
|
268
|
-
readonly
|
|
269
|
-
v-model="charge.f_payment_method" />
|
|
270
|
-
</div>
|
|
271
|
-
</div>
|
|
272
|
-
<div class="form-group col-sm-12">
|
|
273
|
-
<label class="col-sm-2 control-label">金额大写:</label>
|
|
274
|
-
<div class="col-sm-10">
|
|
275
|
-
<input type="text"
|
|
276
|
-
class="form-control input_view"
|
|
277
|
-
style="width: 100%"
|
|
278
|
-
readonly
|
|
279
|
-
v-model="charge.f_amount_words" />
|
|
280
|
-
</div>
|
|
281
|
-
</div>
|
|
282
|
-
<div class="form-group col-sm-12">
|
|
283
|
-
<label class="col-sm-2 control-label">收费人员:</label>
|
|
284
|
-
<div class="col-sm-10">
|
|
285
|
-
<input type="text"
|
|
286
|
-
class="form-control input_view"
|
|
287
|
-
style="width: 100%"
|
|
288
|
-
readonly
|
|
289
|
-
v-model="charge.f_charge_collectors" />
|
|
290
|
-
</div>
|
|
291
|
-
</div>
|
|
292
|
-
<div class="form-group col-sm-12" :class="charge.f_void_remarks ? '':'has-error'">
|
|
293
|
-
<label class="col-sm-2 control-label">作废原因:</label>
|
|
294
|
-
<div class="col-sm-10">
|
|
295
|
-
<input type="text"
|
|
296
|
-
class="form-control input_view"
|
|
297
|
-
style="width: 100%"
|
|
298
|
-
v-model="charge.f_void_remarks" />
|
|
299
|
-
</div>
|
|
300
|
-
</div>
|
|
301
|
-
</article>
|
|
302
|
-
<footer slot="modal-footer" class="modal-footer">
|
|
303
|
-
<button type="button" class="btn btn-primary" :disabled="!charge.f_void_remarks" @click="invalidApplyCharge()">确认作废</button>
|
|
304
|
-
</footer>
|
|
305
|
-
</modal>
|
|
306
|
-
|
|
307
|
-
<modal v-if="showPrint" :show.sync="showPrint" v-ref:modal :large="true" :backdrop="false">
|
|
308
|
-
<header slot="modal-header" class="modal-header">
|
|
309
|
-
<button type="button" class="close" @click="closeModal()"><span>×</span></button>
|
|
310
|
-
<h4 class="modal-title">票据信息</h4>
|
|
311
|
-
</header>
|
|
312
|
-
<article slot="modal-body" class="modal-body clearfix">
|
|
313
|
-
<iframe width="100%" height="500px" :src="charge.f_bill_link" v-if="charge.f_bill_link"></iframe>
|
|
314
|
-
</article>
|
|
315
|
-
<footer slot="modal-footer" class="modal-footer">
|
|
316
|
-
</footer>
|
|
317
|
-
</modal>
|
|
318
|
-
</div>
|
|
319
|
-
</template>
|
|
320
|
-
<script>
|
|
321
|
-
import {PagedList} from 'vue-client'
|
|
322
|
-
import {HttpResetClass} from 'vue-client'
|
|
323
|
-
import Vue from 'vue'
|
|
324
|
-
import {isEmpty} from '../../../Util'
|
|
325
|
-
|
|
326
|
-
export default {
|
|
327
|
-
title: '收费管理',
|
|
328
|
-
props: {
|
|
329
|
-
selectdata: {
|
|
330
|
-
type: Object
|
|
331
|
-
},
|
|
332
|
-
mark: {
|
|
333
|
-
type: Number,
|
|
334
|
-
default: 0
|
|
335
|
-
}
|
|
336
|
-
},
|
|
337
|
-
data () {
|
|
338
|
-
return {
|
|
339
|
-
showCharge: false, // 收费明细
|
|
340
|
-
showInvalid: false, // 作废
|
|
341
|
-
showPrint: false, // 打印
|
|
342
|
-
model: {
|
|
343
|
-
data: null
|
|
344
|
-
}, // 记录
|
|
345
|
-
charge: {
|
|
346
|
-
|
|
347
|
-
}
|
|
348
|
-
}
|
|
349
|
-
},
|
|
350
|
-
ready () {
|
|
351
|
-
this.search()
|
|
352
|
-
},
|
|
353
|
-
methods: {
|
|
354
|
-
|
|
355
|
-
async invalidApplyCharge() {
|
|
356
|
-
|
|
357
|
-
let http = new HttpResetClass()
|
|
358
|
-
let data = {
|
|
359
|
-
apply: this.selectdata,
|
|
360
|
-
user: this.$login.f,
|
|
361
|
-
charge: this.charge
|
|
362
|
-
}
|
|
363
|
-
let res = await http.load('POST', 'rs/logic/invalidApplyCharge', {data:data}, {
|
|
364
|
-
resolveMsg: null,
|
|
365
|
-
rejectMsg: '作废失败!!!'
|
|
366
|
-
})
|
|
367
|
-
this.selectdata = res.data
|
|
368
|
-
|
|
369
|
-
this.$dispatch('breakControl', this.selectdata)
|
|
370
|
-
},
|
|
371
|
-
// 打开作废收费
|
|
372
|
-
showInvalidModal(row) {
|
|
373
|
-
this.charge = row
|
|
374
|
-
this.showInvalid = true
|
|
375
|
-
},
|
|
376
|
-
// 查看发票
|
|
377
|
-
showPrintModal(row, type) {
|
|
378
|
-
this.charge = row
|
|
379
|
-
if (!this.charge.f_bill_link && this.charge.f_filepath){
|
|
380
|
-
let date = new Date(this.charge.f_charge_date)
|
|
381
|
-
let year = date.getFullYear()
|
|
382
|
-
let month = date.getMonth() + 1
|
|
383
|
-
let month2 = month <= 9 ? '0' + month : month
|
|
384
|
-
let day = date.getDate()
|
|
385
|
-
let day2 = day <= 9 ? '0' + day : day
|
|
386
|
-
let chargedate = year + '-' + month2 + '-' + day2
|
|
387
|
-
this.charge.f_bill_link = `http://193.168.1.6:8082/eticket/` + chargedate + '/' + this.charge.f_filepath + '.pdf'
|
|
388
|
-
}else if(!this.charge.f_bill_link){
|
|
389
|
-
this.charge.f_bill_link = this.charge.f_bill_url
|
|
390
|
-
}
|
|
391
|
-
this.showPrint = true
|
|
392
|
-
},
|
|
393
|
-
// 开票组织数据
|
|
394
|
-
async openBill (charge) {
|
|
395
|
-
this.charge = charge
|
|
396
|
-
let data = null
|
|
397
|
-
let res = null
|
|
398
|
-
|
|
399
|
-
let http = new HttpResetClass()
|
|
400
|
-
|
|
401
|
-
if (isEmpty(this.charge.f_bill_id)) {
|
|
402
|
-
try {
|
|
403
|
-
data = {
|
|
404
|
-
id: this.charge.id,
|
|
405
|
-
charge_type: '报装收费',
|
|
406
|
-
f_user_name: this.selectdata.f_user_name
|
|
407
|
-
}
|
|
408
|
-
if (this.selectdata.f_apply_type === '改线业务'){
|
|
409
|
-
data.charge_type = '整改收费'
|
|
410
|
-
}
|
|
411
|
-
res = await http.load('POST', 'rs/logic/bjEticketCharge', {data:data}, {
|
|
412
|
-
resolveMsg: null,
|
|
413
|
-
rejectMsg: '开票组织数据失败!!!'
|
|
414
|
-
}).then((res) => {
|
|
415
|
-
this.charge.f_bill_id = res.data
|
|
416
|
-
this.outBill()
|
|
417
|
-
})
|
|
418
|
-
}catch (e){
|
|
419
|
-
console.error("错误信息",e)
|
|
420
|
-
this.charge.f_bill_state = '开票失败'
|
|
421
|
-
|
|
422
|
-
data = {
|
|
423
|
-
f_bill_id: '',
|
|
424
|
-
id: this.charge.id,
|
|
425
|
-
apply: this.selectdata,
|
|
426
|
-
user: this.$login.f
|
|
427
|
-
}
|
|
428
|
-
res = await http.load('POST', 'rs/logic/updateChargeBill', {data: data}, {
|
|
429
|
-
resolveMsg: null,
|
|
430
|
-
rejectMsg: '收费信息更新失败!!!'
|
|
431
|
-
})
|
|
432
|
-
this.$showMessage(`开票信息组织失败!!`, ['confirm']).then(async (res) => {
|
|
433
|
-
if (res === 'confirm') {
|
|
434
|
-
this.$dispatch('loadPage')
|
|
435
|
-
}else {
|
|
436
|
-
this.$dispatch('loadPage')
|
|
437
|
-
}
|
|
438
|
-
})
|
|
439
|
-
}
|
|
440
|
-
}else {
|
|
441
|
-
await this.outBill()
|
|
442
|
-
}
|
|
443
|
-
},
|
|
444
|
-
//开票
|
|
445
|
-
async outBill () {
|
|
446
|
-
|
|
447
|
-
let data = null
|
|
448
|
-
let res = null
|
|
449
|
-
let http = new HttpResetClass()
|
|
450
|
-
if (this.charge.f_bill_style === '电子票') {
|
|
451
|
-
data = {
|
|
452
|
-
id: this.charge.f_bill_id,
|
|
453
|
-
f_sell_id: this.charge.id
|
|
454
|
-
}
|
|
455
|
-
try {
|
|
456
|
-
res = await http.load('POST', 'rs/logic/bjOpenEticket', {data: data}, {
|
|
457
|
-
resolveMsg: null,
|
|
458
|
-
rejectMsg: '开票失败!!!'
|
|
459
|
-
})
|
|
460
|
-
|
|
461
|
-
// res.data.f_bill_url = 'https://dlj.51fapiao.cn/dlj/v7/de4c9b985021111ef1c722c2914e34d9273291'
|
|
462
|
-
|
|
463
|
-
if (res.data.f_bill_state !== '开票成功') {
|
|
464
|
-
throw '开票失败!!!'
|
|
465
|
-
} else {
|
|
466
|
-
this.charge.f_bill_state = res.data.f_bill_state
|
|
467
|
-
this.charge.f_bill_url = res.data.f_bill_url
|
|
468
|
-
let date = new Date(this.charge.f_charge_date)
|
|
469
|
-
let year = date.getFullYear()
|
|
470
|
-
let month = date.getMonth() + 1
|
|
471
|
-
let month2 = month <= 9 ? '0' + month : month
|
|
472
|
-
let day = date.getDate()
|
|
473
|
-
let day2 = day <= 9 ? '0' + day : day
|
|
474
|
-
let chargedate = year + '-' + month2 + '-' + day2
|
|
475
|
-
this.charge.f_bill_link = `http://193.168.1.6:8082/eticket/` + chargedate + '/' + res.data.f_filepath + '.pdf'
|
|
476
|
-
this.showPrint = true
|
|
477
|
-
let pram = {
|
|
478
|
-
f_bill_link: this.charge.f_bill_link,
|
|
479
|
-
f_sell_id: this.charge.id,
|
|
480
|
-
apply: this.selectdata,
|
|
481
|
-
user: this.$login.f
|
|
482
|
-
}
|
|
483
|
-
await http.load('POST', 'rs/logic/updataChargeRecord', {data: pram}, {
|
|
484
|
-
resolveMsg: null,
|
|
485
|
-
rejectMsg: null
|
|
486
|
-
})
|
|
487
|
-
}
|
|
488
|
-
} catch (e) {
|
|
489
|
-
console.error(e)
|
|
490
|
-
this.charge.f_bill_state = '开票失败'
|
|
491
|
-
|
|
492
|
-
data = {
|
|
493
|
-
f_bill_id: this.charge.f_bill_id,
|
|
494
|
-
id: this.charge.id,
|
|
495
|
-
apply: this.selectdata,
|
|
496
|
-
user: this.$login.f
|
|
497
|
-
}
|
|
498
|
-
res = await http.load('POST', 'rs/logic/updateChargeBill', {data: data}, {
|
|
499
|
-
resolveMsg: null,
|
|
500
|
-
rejectMsg: '收费信息更新失败!!!'
|
|
501
|
-
})
|
|
502
|
-
this.$showMessage(`开票失败!!`, ['confirm']).then(async (res) => {
|
|
503
|
-
if (res === 'confirm') {
|
|
504
|
-
this.$dispatch('loadPage')
|
|
505
|
-
}else {
|
|
506
|
-
this.$dispatch('loadPage')
|
|
507
|
-
}
|
|
508
|
-
})
|
|
509
|
-
}
|
|
510
|
-
} else if (this.charge.f_bill_style === '专票') {
|
|
511
|
-
|
|
512
|
-
data = {
|
|
513
|
-
id: this.charge.f_bill_id
|
|
514
|
-
}
|
|
515
|
-
res = await http.load('POST', 'rs/sql/getEticketData', {data: data}, {
|
|
516
|
-
resolveMsg: null,
|
|
517
|
-
rejectMsg: '开票数据查询失败!!!'
|
|
518
|
-
})
|
|
519
|
-
let openBillData = JSON.parse(res.data[0].f_bill_data)
|
|
520
|
-
openBillData.kpzdbs = this.$login.f.taxnum
|
|
521
|
-
const nowDate = new Date()
|
|
522
|
-
let year = nowDate.getFullYear()
|
|
523
|
-
let mouth = nowDate.getMonth() + 1
|
|
524
|
-
let day = nowDate.getDate()
|
|
525
|
-
openBillData.f_operate_date = year + '-' + mouth + '-' + day
|
|
526
|
-
openBillData.f_operator = this.$login.f.name
|
|
527
|
-
openBillData.outlets = this.$login.f.
|
|
528
|
-
openBillData.hjse = ''
|
|
529
|
-
openBillData.jshh = ''
|
|
530
|
-
openBillData.tzdbh = ''
|
|
531
|
-
openBillData.yfpdm = ''
|
|
532
|
-
openBillData.yfphm = ''
|
|
533
|
-
console.log('返回开票信息。。 ', openBillData)
|
|
534
|
-
let billInfo = await this.$resetpost('http://127.0.0.1:8003/Goldtax', openBillData, {
|
|
535
|
-
resolveMsg: null,
|
|
536
|
-
rejectMsg: '专用发票开具失败!'
|
|
537
|
-
})
|
|
538
|
-
console.log('返回票据信息。。 ', JSON.parse(billInfo.data))//保存发票明细
|
|
539
|
-
if (!JSON.parse(billInfo.data).fphm) {
|
|
540
|
-
this.charge.f_bill_state = '开票失败'
|
|
541
|
-
data = {
|
|
542
|
-
f_bill_id: this.charge.f_bill_id,
|
|
543
|
-
id: this.charge.id,
|
|
544
|
-
apply: this.selectdata,
|
|
545
|
-
user: this.$login.f
|
|
546
|
-
}
|
|
547
|
-
res = await http.load('POST', 'rs/logic/updateChargeBill', {data: data}, {
|
|
548
|
-
resolveMsg: null,
|
|
549
|
-
rejectMsg: '收费信息更新失败!!!'
|
|
550
|
-
})
|
|
551
|
-
this.$showMessage(`开票失败!!`, ['confirm']).then(async (res) => {
|
|
552
|
-
if (res === 'confirm') {
|
|
553
|
-
this.$dispatch('loadPage')
|
|
554
|
-
}else {
|
|
555
|
-
this.$dispatch('loadPage')
|
|
556
|
-
}
|
|
557
|
-
})
|
|
558
|
-
} else {
|
|
559
|
-
data = {
|
|
560
|
-
id: this.charge.f_bill_id,
|
|
561
|
-
f_bill_number: JSON.parse(billInfo.data).fphm,
|
|
562
|
-
f_bill_code: JSON.parse(billInfo.data).fpdm,
|
|
563
|
-
f_filepath: JSON.parse(billInfo.data).dzpkex ? JSON.parse(billInfo.data).dzpkex : '',
|
|
564
|
-
charge_id: this.charge.id,
|
|
565
|
-
apply: this.selectdata,
|
|
566
|
-
user: this.$login.f
|
|
567
|
-
}
|
|
568
|
-
res = await http.load('POST', 'rs/logic/updateEticketBill', {data: data}, {
|
|
569
|
-
resolveMsg: null,
|
|
570
|
-
rejectMsg: '开票信息更新失败!!!'
|
|
571
|
-
})
|
|
572
|
-
|
|
573
|
-
this.charge.f_bill_state = '开票成功'
|
|
574
|
-
this.charge.f_bill_url = ''
|
|
575
|
-
this.charge.f_bill_link = ''
|
|
576
|
-
}
|
|
577
|
-
}
|
|
578
|
-
},
|
|
579
|
-
// 新增收费
|
|
580
|
-
async saveCharge() {
|
|
581
|
-
let http = new HttpResetClass()
|
|
582
|
-
let data = {
|
|
583
|
-
apply: this.selectdata,
|
|
584
|
-
user: this.$login.f,
|
|
585
|
-
charge: this.charge
|
|
586
|
-
}
|
|
587
|
-
|
|
588
|
-
let res = await http.load('POST', 'rs/logic/addApplyChargeRecord', {data:data}, {
|
|
589
|
-
resolveMsg: null,
|
|
590
|
-
rejectMsg: '缴费失败!!!'
|
|
591
|
-
}).then((res) => {
|
|
592
|
-
this.charge = res.data.charge
|
|
593
|
-
this.selectdata = res.data.apply
|
|
594
|
-
|
|
595
|
-
this.showCharge = false
|
|
596
|
-
try {
|
|
597
|
-
if (this.charge.id) {
|
|
598
|
-
this.openBill(this.charge)
|
|
599
|
-
}
|
|
600
|
-
} catch (e) {
|
|
601
|
-
this.$dispatch('breakControl', this.selectdata)
|
|
602
|
-
}
|
|
603
|
-
})
|
|
604
|
-
},
|
|
605
|
-
moneyChange () {
|
|
606
|
-
if (isEmpty(this.charge.f_charge_money) || Number(this.charge.f_charge_money) === 0) {
|
|
607
|
-
this.$showAlert('单笔收费不能为0元!!!', 'warning', 3000)
|
|
608
|
-
this.charge.f_charge_money = null
|
|
609
|
-
return
|
|
610
|
-
}
|
|
611
|
-
if (Number(this.charge.f_charge_money) > Number(this.selectdata.f_surplus_money)) {
|
|
612
|
-
this.$showAlert('单笔收费不能超过未交总金额!!!', 'warning', 3000)
|
|
613
|
-
this.charge.f_charge_money = null
|
|
614
|
-
return
|
|
615
|
-
}
|
|
616
|
-
},
|
|
617
|
-
// 金额转大写
|
|
618
|
-
handleInput(e) {
|
|
619
|
-
// 通过正则过滤小数点后两位
|
|
620
|
-
e.target.value = (e.target.value.match(/^\d*(\.?\d{0,2})/g)[0]) || null
|
|
621
|
-
this.charge.f_amount_words = this.smalltoBIG(e.target.value)
|
|
622
|
-
},
|
|
623
|
-
// 金额转大写
|
|
624
|
-
smalltoBIG(n) {
|
|
625
|
-
let fraction = ['角', '分'];
|
|
626
|
-
let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
|
|
627
|
-
let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
|
|
628
|
-
let head = n < 0 ? '欠' : '';
|
|
629
|
-
n = Math.abs(n);
|
|
630
|
-
|
|
631
|
-
let s = '';
|
|
632
|
-
|
|
633
|
-
for (var i = 0; i < fraction.length; i++) {
|
|
634
|
-
s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
|
|
635
|
-
}
|
|
636
|
-
s = s || '整';
|
|
637
|
-
n = Math.floor(n);
|
|
638
|
-
|
|
639
|
-
for (var i = 0; i < unit[0].length && n > 0; i++) {
|
|
640
|
-
let p = '';
|
|
641
|
-
for (var j = 0; j < unit[1].length && n > 0; j++) {
|
|
642
|
-
p = digit[n % 10] + unit[1][j] + p;
|
|
643
|
-
n = Math.floor(n / 10);
|
|
644
|
-
}
|
|
645
|
-
s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s;
|
|
646
|
-
}
|
|
647
|
-
return head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
|
|
648
|
-
},
|
|
649
|
-
async showChargeModal() {
|
|
650
|
-
this.showCharge = true
|
|
651
|
-
},
|
|
652
|
-
async search () {
|
|
653
|
-
let http = new HttpResetClass()
|
|
654
|
-
let data = {
|
|
655
|
-
f_process_id: this.selectdata.f_process_id
|
|
656
|
-
}
|
|
657
|
-
let res = await http.load('POST', 'rs/sql/getApplyChargeRecord', {data:data}, {
|
|
658
|
-
resolveMsg: null,
|
|
659
|
-
rejectMsg: '收费记录查询失败!!!'
|
|
660
|
-
})
|
|
661
|
-
this.model.data = res.data
|
|
662
|
-
},
|
|
663
|
-
// 关闭对话框
|
|
664
|
-
closeModal() {
|
|
665
|
-
this.showCharge = false
|
|
666
|
-
this.showInvalid = false
|
|
667
|
-
this.showPrint = false
|
|
668
|
-
this.charge = {}
|
|
669
|
-
this.search()
|
|
670
|
-
}
|
|
671
|
-
},
|
|
672
|
-
events: {
|
|
673
|
-
},
|
|
674
|
-
computed: {
|
|
675
|
-
billStyleList () {
|
|
676
|
-
return this.$appdata.getParam("打印格式")
|
|
677
|
-
},
|
|
678
|
-
paymentMethod() {
|
|
679
|
-
return this.$appdata.getParam("付款方式")
|
|
680
|
-
},
|
|
681
|
-
paymentTerm() {
|
|
682
|
-
return this.$appdata.getParam("收费项目")
|
|
683
|
-
}
|
|
684
|
-
},
|
|
685
|
-
watch: {
|
|
686
|
-
}
|
|
687
|
-
}
|
|
688
|
-
</script>
|
|
689
|
-
<style scoped>
|
|
690
|
-
.textNoLineBreak {
|
|
691
|
-
white-space: nowrap;
|
|
692
|
-
}
|
|
693
|
-
.head-but{
|
|
694
|
-
margin-left: 5px;
|
|
695
|
-
height: 34px;
|
|
696
|
-
/*background-color: #6aa6e2;*/
|
|
697
|
-
border-radius: 4px;
|
|
698
|
-
font-family: PingFang;
|
|
699
|
-
color: #ffffff;
|
|
700
|
-
}
|
|
701
|
-
.form-control{
|
|
702
|
-
padding: 8px 12px;
|
|
703
|
-
}
|
|
704
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="col-sm-12" style="margin: 20px 0px;">
|
|
3
|
+
<data-grid :model="model" v-ref:grid class="list_area table_sy" style="padding: 0px">
|
|
4
|
+
<template partial='head'>
|
|
5
|
+
<tr>
|
|
6
|
+
<th class="textNoLineBreak">序号</th>
|
|
7
|
+
<th class="textNoLineBreak">收费金额</th>
|
|
8
|
+
<th class="textNoLineBreak">金额大写</th>
|
|
9
|
+
<th class="textNoLineBreak">付款方式</th>
|
|
10
|
+
<th class="textNoLineBreak">收费人员</th>
|
|
11
|
+
<th class="textNoLineBreak">收费日期</th>
|
|
12
|
+
<th class="textNoLineBreak">备注</th>
|
|
13
|
+
<th class="textNoLineBreak">缴费状态</th>
|
|
14
|
+
<th class="textNoLineBreak">作废人员</th>
|
|
15
|
+
<th class="textNoLineBreak">作废时间</th>
|
|
16
|
+
<th class="textNoLineBreak">作废原因</th>
|
|
17
|
+
<th class="textNoLineBreak">票据类型</th>
|
|
18
|
+
<th class="textNoLineBreak">票据状态</th>
|
|
19
|
+
<th class="textNoLineBreak">
|
|
20
|
+
<button
|
|
21
|
+
type="button"
|
|
22
|
+
class="btn btn-info head-but"
|
|
23
|
+
@click="$parent.$parent.showChargeModal()"
|
|
24
|
+
:disabled="$parent.$parent.mark === 1 || ($parent.$parent.selectdata.f_cumulative_payment_money >= $parent.$parent.selectdata.f_due_money || $parent.$parent.selectdata.f_surplus_money === 0)"
|
|
25
|
+
>新增收费</button>
|
|
26
|
+
</th>
|
|
27
|
+
</tr>
|
|
28
|
+
</template>
|
|
29
|
+
<template partial='body'>
|
|
30
|
+
<tr>
|
|
31
|
+
<td style="text-align: center;">
|
|
32
|
+
<nobr>{{$index+1}}</nobr>
|
|
33
|
+
</td>
|
|
34
|
+
<td style="text-align: center;">
|
|
35
|
+
<nobr>{{row.f_charge_money}}</nobr>
|
|
36
|
+
</td>
|
|
37
|
+
<td style="text-align: center;">
|
|
38
|
+
<nobr>{{row.f_amount_words}}</nobr>
|
|
39
|
+
</td>
|
|
40
|
+
<td style="text-align: center;">
|
|
41
|
+
<nobr>{{row.f_payment_method}}</nobr>
|
|
42
|
+
</td>
|
|
43
|
+
<td style="text-align: center;">
|
|
44
|
+
<nobr>{{row.f_charge_collectors}}</nobr>
|
|
45
|
+
</td>
|
|
46
|
+
<td style="text-align: center;">
|
|
47
|
+
<nobr>{{row.f_charge_date}}</nobr>
|
|
48
|
+
</td>
|
|
49
|
+
<td style="text-align: center;">
|
|
50
|
+
<nobr>{{row.f_charge_remarks}}</nobr>
|
|
51
|
+
</td>
|
|
52
|
+
<td style="text-align: center;">
|
|
53
|
+
<nobr>{{row.f_charge_status}}</nobr>
|
|
54
|
+
</td>
|
|
55
|
+
<td style="text-align: center;">
|
|
56
|
+
<nobr>{{row.f_void_staff}}</nobr>
|
|
57
|
+
</td>
|
|
58
|
+
<td style="text-align: center;">
|
|
59
|
+
<nobr>{{row.f_void_date}}</nobr>
|
|
60
|
+
</td>
|
|
61
|
+
<td style="text-align: center;">
|
|
62
|
+
<nobr>{{row.f_void_remarks}}</nobr>
|
|
63
|
+
</td>
|
|
64
|
+
<td style="text-align: center;">
|
|
65
|
+
<nobr>{{row.f_bill_style}}</nobr>
|
|
66
|
+
</td>
|
|
67
|
+
<td style="text-align: center;">
|
|
68
|
+
<nobr>{{row.f_bill_state}}</nobr>
|
|
69
|
+
</td>
|
|
70
|
+
<td style="text-align: center;">
|
|
71
|
+
<nobr v-if="row.f_charge_status !== '退款'">
|
|
72
|
+
<button
|
|
73
|
+
type="button"
|
|
74
|
+
name="button"
|
|
75
|
+
class="btn btn-link"
|
|
76
|
+
v-if = false
|
|
77
|
+
:disabled="$parent.$parent.mark === 1 || row.f_charge_status === '作废'"
|
|
78
|
+
@click="$parent.$parent.showInvalidModal(row)"
|
|
79
|
+
>作废</button>
|
|
80
|
+
|
|
81
|
+
<button
|
|
82
|
+
type="button" name="button" class="btn btn-link"
|
|
83
|
+
v-if="row.f_bill_state !== '开票成功' && row.f_charge_status !== '作废'"
|
|
84
|
+
@click="$parent.$parent.openBill(row)"
|
|
85
|
+
>开票</button>
|
|
86
|
+
|
|
87
|
+
<button
|
|
88
|
+
type="button" name="button" class="btn btn-link"
|
|
89
|
+
v-if = "row.f_bill_state === '开票成功'"
|
|
90
|
+
@click="$parent.$parent.showPrintModal(row)"
|
|
91
|
+
>查看发票</button>
|
|
92
|
+
</nobr>
|
|
93
|
+
</td>
|
|
94
|
+
</tr>
|
|
95
|
+
</template>
|
|
96
|
+
</data-grid>
|
|
97
|
+
|
|
98
|
+
<validator name="v">
|
|
99
|
+
<modal v-if="showCharge" :show.sync="showCharge" v-ref:modal :large="true" :backdrop="false" title="收费明细">
|
|
100
|
+
<header slot="modal-header" class="modal-header">
|
|
101
|
+
<button type="button" class="close" @click="closeModal"><span>×</span></button>
|
|
102
|
+
<h4 class="modal-title">收费明细</h4>
|
|
103
|
+
</header>
|
|
104
|
+
<article slot="modal-body" class="modal-body clearfix">
|
|
105
|
+
<div class="form-group col-sm-6" :class="[$v.f_charge_money.required ? 'has-error' : '']">
|
|
106
|
+
<label class="col-sm-4 control-label">收费金额:</label>
|
|
107
|
+
<div class="col-sm-8">
|
|
108
|
+
<input type="text"
|
|
109
|
+
class="form-control input_view"
|
|
110
|
+
style="width: 100%"
|
|
111
|
+
placeholder="0.00"
|
|
112
|
+
@keyup="handleInput"
|
|
113
|
+
@change="moneyChange"
|
|
114
|
+
v-validate:f_charge_money = "['required']"
|
|
115
|
+
v-model="charge.f_charge_money" />
|
|
116
|
+
</div>
|
|
117
|
+
</div>
|
|
118
|
+
<div class="form-group col-sm-6" :class="[$v.f_feecount.required ? 'has-error' : '']">
|
|
119
|
+
<label class="col-sm-4 control-label">缴费户数:</label>
|
|
120
|
+
<div class="col-sm-8">
|
|
121
|
+
<input type="text"
|
|
122
|
+
class="form-control input_view"
|
|
123
|
+
style="width: 100%"
|
|
124
|
+
v-validate:f_feecount = "['required']"
|
|
125
|
+
v-model="charge.f_feecount"
|
|
126
|
+
:value="selectdata.f_install_count"
|
|
127
|
+
/>
|
|
128
|
+
</div>
|
|
129
|
+
</div>
|
|
130
|
+
<div class="form-group col-sm-6">
|
|
131
|
+
<label class="col-sm-4 control-label">金额大写:</label>
|
|
132
|
+
<div class="col-sm-8">
|
|
133
|
+
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
134
|
+
:value="smalltoBIG(0)" v-model.sync="charge.f_amount_words"/>
|
|
135
|
+
</div>
|
|
136
|
+
</div>
|
|
137
|
+
<div class="form-group col-sm-6" :class="[$v.f_payment_method.required ? 'has-error' : '']">
|
|
138
|
+
<label class="col-sm-4 control-label">付款方式:</label>
|
|
139
|
+
<div class="col-sm-8">
|
|
140
|
+
<input type="text" v-show="false" v-model="charge.f_payment_method" v-validate:f_payment_method = "['required']" >
|
|
141
|
+
<input-select
|
|
142
|
+
placeholder='请选择' width="100%"
|
|
143
|
+
v-model="charge.f_payment_method"
|
|
144
|
+
:value.sync="charge.f_payment_method"
|
|
145
|
+
:options='paymentMethod'
|
|
146
|
+
class="select select_list"
|
|
147
|
+
:value-single="true"
|
|
148
|
+
close-on-select ></input-select>
|
|
149
|
+
</div>
|
|
150
|
+
</div>
|
|
151
|
+
<div class="form-group col-sm-6" :class="[$v.f_bill_style.required ? 'has-error' : '']">
|
|
152
|
+
<label class="col-sm-4 control-label">票据类型:</label>
|
|
153
|
+
<div class="col-sm-8">
|
|
154
|
+
<input type="text" v-show="false" v-model="charge.f_bill_style" :value.sync="selectdata.f_paper_type" v-validate:f_bill_style = "['required']" >
|
|
155
|
+
<input-select
|
|
156
|
+
placeholder='请选择' width="100%"
|
|
157
|
+
v-model="charge.f_bill_style"
|
|
158
|
+
:value.sync="selectdata.f_paper_type"
|
|
159
|
+
:options='billStyleList'
|
|
160
|
+
class="select select_list"
|
|
161
|
+
:value-single="true"
|
|
162
|
+
close-on-select ></input-select>
|
|
163
|
+
</div>
|
|
164
|
+
</div>
|
|
165
|
+
<div class="form-group col-sm-6">
|
|
166
|
+
<label class="col-sm-4 control-label">应交总金额:</label>
|
|
167
|
+
<div class="col-sm-8">
|
|
168
|
+
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
169
|
+
v-model="selectdata.f_due_money" />
|
|
170
|
+
</div>
|
|
171
|
+
</div>
|
|
172
|
+
<div class="form-group col-sm-6">
|
|
173
|
+
<label class="col-sm-4 control-label">未结总金额:</label>
|
|
174
|
+
<div class="col-sm-8">
|
|
175
|
+
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
176
|
+
v-model="selectdata.f_surplus_money" />
|
|
177
|
+
</div>
|
|
178
|
+
</div>
|
|
179
|
+
<div class="form-group col-sm-6">
|
|
180
|
+
<label class="col-sm-4 control-label">累计缴费总金额:</label>
|
|
181
|
+
<div class="col-sm-8">
|
|
182
|
+
<input type="text" class="form-control input_view" style="width: 100%" readonly
|
|
183
|
+
v-model="selectdata.f_cumulative_payment_money" />
|
|
184
|
+
</div>
|
|
185
|
+
</div>
|
|
186
|
+
<div class="form-group col-sm-12">
|
|
187
|
+
<label class="col-sm-2 control-label">备注:</label>
|
|
188
|
+
<div class="col-sm-10">
|
|
189
|
+
<input type="text" class="form-control input_view" style="width: 100%"
|
|
190
|
+
v-model="charge.f_charge_remarks" />
|
|
191
|
+
</div>
|
|
192
|
+
</div>
|
|
193
|
+
<div class="form-group col-sm-6">
|
|
194
|
+
<label class="col-sm-4 control-label">购货单位识别号:</label>
|
|
195
|
+
<div class="col-sm-8">
|
|
196
|
+
<input type="text" class="form-control input_view" style="width: 100%"
|
|
197
|
+
v-model="charge.f_taxpayer_id" :value="selectdata.f_taxpayer_id" />
|
|
198
|
+
</div>
|
|
199
|
+
</div>
|
|
200
|
+
<div class="form-group col-sm-6" :class="[$v.f_paper_name.required ? 'has-error' : '']">
|
|
201
|
+
<label class="col-sm-4 control-label">购货单位名称:</label>
|
|
202
|
+
<div class="col-sm-8">
|
|
203
|
+
<input type="text" class="form-control input_view" style="width: 100%"
|
|
204
|
+
v-validate:f_paper_name = "['required']"
|
|
205
|
+
v-model="charge.f_paper_name" :value="selectdata.f_paper_name" />
|
|
206
|
+
</div>
|
|
207
|
+
</div>
|
|
208
|
+
<div class="form-group col-sm-6">
|
|
209
|
+
<label class="col-sm-4 control-label">购货单位银行账号:</label>
|
|
210
|
+
<div class="col-sm-8">
|
|
211
|
+
<input type="text" class="form-control input_view" style="width: 100%"
|
|
212
|
+
v-model="charge.f_paper_account" :value="selectdata.f_paper_account" />
|
|
213
|
+
</div>
|
|
214
|
+
</div>
|
|
215
|
+
<div class="form-group col-sm-6">
|
|
216
|
+
<label class="col-sm-4 control-label">购货单位地址电话:</label>
|
|
217
|
+
<div class="col-sm-8">
|
|
218
|
+
<input type="text" class="form-control input_view" style="width: 100%"
|
|
219
|
+
v-model="charge.f_address_phone" :value="selectdata.f_address_phone" />
|
|
220
|
+
</div>
|
|
221
|
+
</div>
|
|
222
|
+
<div class="form-group col-sm-12">
|
|
223
|
+
<label class="col-sm-2 control-label">发票备注:</label>
|
|
224
|
+
<div class="col-sm-10">
|
|
225
|
+
<input type="text" class="form-control input_view" style="width: 100%"
|
|
226
|
+
v-model="charge.f_bill_remarks" :value="selectdata.f_paper_remarks"/>
|
|
227
|
+
</div>
|
|
228
|
+
</div>
|
|
229
|
+
</article>
|
|
230
|
+
<footer slot="modal-footer" class="modal-footer">
|
|
231
|
+
<button type="button" class="btn btn-primary" :disabled='!$v.valid' @click="saveCharge()">新增收费</button>
|
|
232
|
+
</footer>
|
|
233
|
+
</modal>
|
|
234
|
+
</validator>
|
|
235
|
+
|
|
236
|
+
<modal v-if="showInvalid" :show.sync="showInvalid" v-ref:modal :backdrop="false" title="作废收费">
|
|
237
|
+
<header slot="modal-header" class="modal-header">
|
|
238
|
+
<button type="button" class="close" @click="closeModal"><span>×</span></button>
|
|
239
|
+
<h4 class="modal-title">作废收费</h4>
|
|
240
|
+
</header>
|
|
241
|
+
<article slot="modal-body" class="modal-body clearfix">
|
|
242
|
+
<div class="form-group col-sm-12" v-if="false">
|
|
243
|
+
<label class="col-sm-2 control-label">缴费地址:</label>
|
|
244
|
+
<div class="col-sm-10">
|
|
245
|
+
<input type="text"
|
|
246
|
+
class="form-control input_view"
|
|
247
|
+
style="width: 100%"
|
|
248
|
+
readonly
|
|
249
|
+
v-model="charge.f_useraddres" />
|
|
250
|
+
</div>
|
|
251
|
+
</div>
|
|
252
|
+
<div class="form-group col-sm-12">
|
|
253
|
+
<label class="col-sm-2 control-label">收费金额:</label>
|
|
254
|
+
<div class="col-sm-10">
|
|
255
|
+
<input type="text"
|
|
256
|
+
class="form-control input_view"
|
|
257
|
+
style="width: 100%"
|
|
258
|
+
readonly
|
|
259
|
+
v-model="charge.f_charge_money" />
|
|
260
|
+
</div>
|
|
261
|
+
</div>
|
|
262
|
+
<div class="form-group col-sm-12">
|
|
263
|
+
<label class="col-sm-2 control-label">付款方式:</label>
|
|
264
|
+
<div class="col-sm-10">
|
|
265
|
+
<input type="text"
|
|
266
|
+
class="form-control input_view"
|
|
267
|
+
style="width: 100%"
|
|
268
|
+
readonly
|
|
269
|
+
v-model="charge.f_payment_method" />
|
|
270
|
+
</div>
|
|
271
|
+
</div>
|
|
272
|
+
<div class="form-group col-sm-12">
|
|
273
|
+
<label class="col-sm-2 control-label">金额大写:</label>
|
|
274
|
+
<div class="col-sm-10">
|
|
275
|
+
<input type="text"
|
|
276
|
+
class="form-control input_view"
|
|
277
|
+
style="width: 100%"
|
|
278
|
+
readonly
|
|
279
|
+
v-model="charge.f_amount_words" />
|
|
280
|
+
</div>
|
|
281
|
+
</div>
|
|
282
|
+
<div class="form-group col-sm-12">
|
|
283
|
+
<label class="col-sm-2 control-label">收费人员:</label>
|
|
284
|
+
<div class="col-sm-10">
|
|
285
|
+
<input type="text"
|
|
286
|
+
class="form-control input_view"
|
|
287
|
+
style="width: 100%"
|
|
288
|
+
readonly
|
|
289
|
+
v-model="charge.f_charge_collectors" />
|
|
290
|
+
</div>
|
|
291
|
+
</div>
|
|
292
|
+
<div class="form-group col-sm-12" :class="charge.f_void_remarks ? '':'has-error'">
|
|
293
|
+
<label class="col-sm-2 control-label">作废原因:</label>
|
|
294
|
+
<div class="col-sm-10">
|
|
295
|
+
<input type="text"
|
|
296
|
+
class="form-control input_view"
|
|
297
|
+
style="width: 100%"
|
|
298
|
+
v-model="charge.f_void_remarks" />
|
|
299
|
+
</div>
|
|
300
|
+
</div>
|
|
301
|
+
</article>
|
|
302
|
+
<footer slot="modal-footer" class="modal-footer">
|
|
303
|
+
<button type="button" class="btn btn-primary" :disabled="!charge.f_void_remarks" @click="invalidApplyCharge()">确认作废</button>
|
|
304
|
+
</footer>
|
|
305
|
+
</modal>
|
|
306
|
+
|
|
307
|
+
<modal v-if="showPrint" :show.sync="showPrint" v-ref:modal :large="true" :backdrop="false">
|
|
308
|
+
<header slot="modal-header" class="modal-header">
|
|
309
|
+
<button type="button" class="close" @click="closeModal()"><span>×</span></button>
|
|
310
|
+
<h4 class="modal-title">票据信息</h4>
|
|
311
|
+
</header>
|
|
312
|
+
<article slot="modal-body" class="modal-body clearfix">
|
|
313
|
+
<iframe width="100%" height="500px" :src="charge.f_bill_link" v-if="charge.f_bill_link"></iframe>
|
|
314
|
+
</article>
|
|
315
|
+
<footer slot="modal-footer" class="modal-footer">
|
|
316
|
+
</footer>
|
|
317
|
+
</modal>
|
|
318
|
+
</div>
|
|
319
|
+
</template>
|
|
320
|
+
<script>
|
|
321
|
+
import {PagedList} from 'vue-client'
|
|
322
|
+
import {HttpResetClass} from 'vue-client'
|
|
323
|
+
import Vue from 'vue'
|
|
324
|
+
import {isEmpty} from '../../../Util'
|
|
325
|
+
|
|
326
|
+
export default {
|
|
327
|
+
title: '收费管理',
|
|
328
|
+
props: {
|
|
329
|
+
selectdata: {
|
|
330
|
+
type: Object
|
|
331
|
+
},
|
|
332
|
+
mark: {
|
|
333
|
+
type: Number,
|
|
334
|
+
default: 0
|
|
335
|
+
}
|
|
336
|
+
},
|
|
337
|
+
data () {
|
|
338
|
+
return {
|
|
339
|
+
showCharge: false, // 收费明细
|
|
340
|
+
showInvalid: false, // 作废
|
|
341
|
+
showPrint: false, // 打印
|
|
342
|
+
model: {
|
|
343
|
+
data: null
|
|
344
|
+
}, // 记录
|
|
345
|
+
charge: {
|
|
346
|
+
|
|
347
|
+
}
|
|
348
|
+
}
|
|
349
|
+
},
|
|
350
|
+
ready () {
|
|
351
|
+
this.search()
|
|
352
|
+
},
|
|
353
|
+
methods: {
|
|
354
|
+
|
|
355
|
+
async invalidApplyCharge() {
|
|
356
|
+
|
|
357
|
+
let http = new HttpResetClass()
|
|
358
|
+
let data = {
|
|
359
|
+
apply: this.selectdata,
|
|
360
|
+
user: this.$login.f,
|
|
361
|
+
charge: this.charge
|
|
362
|
+
}
|
|
363
|
+
let res = await http.load('POST', 'rs/logic/invalidApplyCharge', {data:data}, {
|
|
364
|
+
resolveMsg: null,
|
|
365
|
+
rejectMsg: '作废失败!!!'
|
|
366
|
+
})
|
|
367
|
+
this.selectdata = res.data
|
|
368
|
+
|
|
369
|
+
this.$dispatch('breakControl', this.selectdata)
|
|
370
|
+
},
|
|
371
|
+
// 打开作废收费
|
|
372
|
+
showInvalidModal(row) {
|
|
373
|
+
this.charge = row
|
|
374
|
+
this.showInvalid = true
|
|
375
|
+
},
|
|
376
|
+
// 查看发票
|
|
377
|
+
showPrintModal(row, type) {
|
|
378
|
+
this.charge = row
|
|
379
|
+
if (!this.charge.f_bill_link && this.charge.f_filepath){
|
|
380
|
+
let date = new Date(this.charge.f_charge_date)
|
|
381
|
+
let year = date.getFullYear()
|
|
382
|
+
let month = date.getMonth() + 1
|
|
383
|
+
let month2 = month <= 9 ? '0' + month : month
|
|
384
|
+
let day = date.getDate()
|
|
385
|
+
let day2 = day <= 9 ? '0' + day : day
|
|
386
|
+
let chargedate = year + '-' + month2 + '-' + day2
|
|
387
|
+
this.charge.f_bill_link = `http://193.168.1.6:8082/eticket/` + chargedate + '/' + this.charge.f_filepath + '.pdf'
|
|
388
|
+
}else if(!this.charge.f_bill_link){
|
|
389
|
+
this.charge.f_bill_link = this.charge.f_bill_url
|
|
390
|
+
}
|
|
391
|
+
this.showPrint = true
|
|
392
|
+
},
|
|
393
|
+
// 开票组织数据
|
|
394
|
+
async openBill (charge) {
|
|
395
|
+
this.charge = charge
|
|
396
|
+
let data = null
|
|
397
|
+
let res = null
|
|
398
|
+
|
|
399
|
+
let http = new HttpResetClass()
|
|
400
|
+
|
|
401
|
+
if (isEmpty(this.charge.f_bill_id)) {
|
|
402
|
+
try {
|
|
403
|
+
data = {
|
|
404
|
+
id: this.charge.id,
|
|
405
|
+
charge_type: '报装收费',
|
|
406
|
+
f_user_name: this.selectdata.f_user_name
|
|
407
|
+
}
|
|
408
|
+
if (this.selectdata.f_apply_type === '改线业务'){
|
|
409
|
+
data.charge_type = '整改收费'
|
|
410
|
+
}
|
|
411
|
+
res = await http.load('POST', 'rs/logic/bjEticketCharge', {data:data}, {
|
|
412
|
+
resolveMsg: null,
|
|
413
|
+
rejectMsg: '开票组织数据失败!!!'
|
|
414
|
+
}).then((res) => {
|
|
415
|
+
this.charge.f_bill_id = res.data
|
|
416
|
+
this.outBill()
|
|
417
|
+
})
|
|
418
|
+
}catch (e){
|
|
419
|
+
console.error("错误信息",e)
|
|
420
|
+
this.charge.f_bill_state = '开票失败'
|
|
421
|
+
|
|
422
|
+
data = {
|
|
423
|
+
f_bill_id: '',
|
|
424
|
+
id: this.charge.id,
|
|
425
|
+
apply: this.selectdata,
|
|
426
|
+
user: this.$login.f
|
|
427
|
+
}
|
|
428
|
+
res = await http.load('POST', 'rs/logic/updateChargeBill', {data: data}, {
|
|
429
|
+
resolveMsg: null,
|
|
430
|
+
rejectMsg: '收费信息更新失败!!!'
|
|
431
|
+
})
|
|
432
|
+
this.$showMessage(`开票信息组织失败!!`, ['confirm']).then(async (res) => {
|
|
433
|
+
if (res === 'confirm') {
|
|
434
|
+
this.$dispatch('loadPage')
|
|
435
|
+
}else {
|
|
436
|
+
this.$dispatch('loadPage')
|
|
437
|
+
}
|
|
438
|
+
})
|
|
439
|
+
}
|
|
440
|
+
}else {
|
|
441
|
+
await this.outBill()
|
|
442
|
+
}
|
|
443
|
+
},
|
|
444
|
+
//开票
|
|
445
|
+
async outBill () {
|
|
446
|
+
|
|
447
|
+
let data = null
|
|
448
|
+
let res = null
|
|
449
|
+
let http = new HttpResetClass()
|
|
450
|
+
if (this.charge.f_bill_style === '电子票') {
|
|
451
|
+
data = {
|
|
452
|
+
id: this.charge.f_bill_id,
|
|
453
|
+
f_sell_id: this.charge.id
|
|
454
|
+
}
|
|
455
|
+
try {
|
|
456
|
+
res = await http.load('POST', 'rs/logic/bjOpenEticket', {data: data}, {
|
|
457
|
+
resolveMsg: null,
|
|
458
|
+
rejectMsg: '开票失败!!!'
|
|
459
|
+
})
|
|
460
|
+
|
|
461
|
+
// res.data.f_bill_url = 'https://dlj.51fapiao.cn/dlj/v7/de4c9b985021111ef1c722c2914e34d9273291'
|
|
462
|
+
|
|
463
|
+
if (res.data.f_bill_state !== '开票成功') {
|
|
464
|
+
throw '开票失败!!!'
|
|
465
|
+
} else {
|
|
466
|
+
this.charge.f_bill_state = res.data.f_bill_state
|
|
467
|
+
this.charge.f_bill_url = res.data.f_bill_url
|
|
468
|
+
let date = new Date(this.charge.f_charge_date)
|
|
469
|
+
let year = date.getFullYear()
|
|
470
|
+
let month = date.getMonth() + 1
|
|
471
|
+
let month2 = month <= 9 ? '0' + month : month
|
|
472
|
+
let day = date.getDate()
|
|
473
|
+
let day2 = day <= 9 ? '0' + day : day
|
|
474
|
+
let chargedate = year + '-' + month2 + '-' + day2
|
|
475
|
+
this.charge.f_bill_link = `http://193.168.1.6:8082/eticket/` + chargedate + '/' + res.data.f_filepath + '.pdf'
|
|
476
|
+
this.showPrint = true
|
|
477
|
+
let pram = {
|
|
478
|
+
f_bill_link: this.charge.f_bill_link,
|
|
479
|
+
f_sell_id: this.charge.id,
|
|
480
|
+
apply: this.selectdata,
|
|
481
|
+
user: this.$login.f
|
|
482
|
+
}
|
|
483
|
+
await http.load('POST', 'rs/logic/updataChargeRecord', {data: pram}, {
|
|
484
|
+
resolveMsg: null,
|
|
485
|
+
rejectMsg: null
|
|
486
|
+
})
|
|
487
|
+
}
|
|
488
|
+
} catch (e) {
|
|
489
|
+
console.error(e)
|
|
490
|
+
this.charge.f_bill_state = '开票失败'
|
|
491
|
+
|
|
492
|
+
data = {
|
|
493
|
+
f_bill_id: this.charge.f_bill_id,
|
|
494
|
+
id: this.charge.id,
|
|
495
|
+
apply: this.selectdata,
|
|
496
|
+
user: this.$login.f
|
|
497
|
+
}
|
|
498
|
+
res = await http.load('POST', 'rs/logic/updateChargeBill', {data: data}, {
|
|
499
|
+
resolveMsg: null,
|
|
500
|
+
rejectMsg: '收费信息更新失败!!!'
|
|
501
|
+
})
|
|
502
|
+
this.$showMessage(`开票失败!!`, ['confirm']).then(async (res) => {
|
|
503
|
+
if (res === 'confirm') {
|
|
504
|
+
this.$dispatch('loadPage')
|
|
505
|
+
}else {
|
|
506
|
+
this.$dispatch('loadPage')
|
|
507
|
+
}
|
|
508
|
+
})
|
|
509
|
+
}
|
|
510
|
+
} else if (this.charge.f_bill_style === '专票') {
|
|
511
|
+
|
|
512
|
+
data = {
|
|
513
|
+
id: this.charge.f_bill_id
|
|
514
|
+
}
|
|
515
|
+
res = await http.load('POST', 'rs/sql/getEticketData', {data: data}, {
|
|
516
|
+
resolveMsg: null,
|
|
517
|
+
rejectMsg: '开票数据查询失败!!!'
|
|
518
|
+
})
|
|
519
|
+
let openBillData = JSON.parse(res.data[0].f_bill_data)
|
|
520
|
+
openBillData.kpzdbs = this.$login.f.taxnum
|
|
521
|
+
const nowDate = new Date()
|
|
522
|
+
let year = nowDate.getFullYear()
|
|
523
|
+
let mouth = nowDate.getMonth() + 1
|
|
524
|
+
let day = nowDate.getDate()
|
|
525
|
+
openBillData.f_operate_date = year + '-' + mouth + '-' + day
|
|
526
|
+
openBillData.f_operator = this.$login.f.name
|
|
527
|
+
openBillData.outlets = this.$login.f.f_department_name
|
|
528
|
+
openBillData.hjse = ''
|
|
529
|
+
openBillData.jshh = ''
|
|
530
|
+
openBillData.tzdbh = ''
|
|
531
|
+
openBillData.yfpdm = ''
|
|
532
|
+
openBillData.yfphm = ''
|
|
533
|
+
console.log('返回开票信息。。 ', openBillData)
|
|
534
|
+
let billInfo = await this.$resetpost('http://127.0.0.1:8003/Goldtax', openBillData, {
|
|
535
|
+
resolveMsg: null,
|
|
536
|
+
rejectMsg: '专用发票开具失败!'
|
|
537
|
+
})
|
|
538
|
+
console.log('返回票据信息。。 ', JSON.parse(billInfo.data))//保存发票明细
|
|
539
|
+
if (!JSON.parse(billInfo.data).fphm) {
|
|
540
|
+
this.charge.f_bill_state = '开票失败'
|
|
541
|
+
data = {
|
|
542
|
+
f_bill_id: this.charge.f_bill_id,
|
|
543
|
+
id: this.charge.id,
|
|
544
|
+
apply: this.selectdata,
|
|
545
|
+
user: this.$login.f
|
|
546
|
+
}
|
|
547
|
+
res = await http.load('POST', 'rs/logic/updateChargeBill', {data: data}, {
|
|
548
|
+
resolveMsg: null,
|
|
549
|
+
rejectMsg: '收费信息更新失败!!!'
|
|
550
|
+
})
|
|
551
|
+
this.$showMessage(`开票失败!!`, ['confirm']).then(async (res) => {
|
|
552
|
+
if (res === 'confirm') {
|
|
553
|
+
this.$dispatch('loadPage')
|
|
554
|
+
}else {
|
|
555
|
+
this.$dispatch('loadPage')
|
|
556
|
+
}
|
|
557
|
+
})
|
|
558
|
+
} else {
|
|
559
|
+
data = {
|
|
560
|
+
id: this.charge.f_bill_id,
|
|
561
|
+
f_bill_number: JSON.parse(billInfo.data).fphm,
|
|
562
|
+
f_bill_code: JSON.parse(billInfo.data).fpdm,
|
|
563
|
+
f_filepath: JSON.parse(billInfo.data).dzpkex ? JSON.parse(billInfo.data).dzpkex : '',
|
|
564
|
+
charge_id: this.charge.id,
|
|
565
|
+
apply: this.selectdata,
|
|
566
|
+
user: this.$login.f
|
|
567
|
+
}
|
|
568
|
+
res = await http.load('POST', 'rs/logic/updateEticketBill', {data: data}, {
|
|
569
|
+
resolveMsg: null,
|
|
570
|
+
rejectMsg: '开票信息更新失败!!!'
|
|
571
|
+
})
|
|
572
|
+
|
|
573
|
+
this.charge.f_bill_state = '开票成功'
|
|
574
|
+
this.charge.f_bill_url = ''
|
|
575
|
+
this.charge.f_bill_link = ''
|
|
576
|
+
}
|
|
577
|
+
}
|
|
578
|
+
},
|
|
579
|
+
// 新增收费
|
|
580
|
+
async saveCharge() {
|
|
581
|
+
let http = new HttpResetClass()
|
|
582
|
+
let data = {
|
|
583
|
+
apply: this.selectdata,
|
|
584
|
+
user: this.$login.f,
|
|
585
|
+
charge: this.charge
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
let res = await http.load('POST', 'rs/logic/addApplyChargeRecord', {data:data}, {
|
|
589
|
+
resolveMsg: null,
|
|
590
|
+
rejectMsg: '缴费失败!!!'
|
|
591
|
+
}).then((res) => {
|
|
592
|
+
this.charge = res.data.charge
|
|
593
|
+
this.selectdata = res.data.apply
|
|
594
|
+
|
|
595
|
+
this.showCharge = false
|
|
596
|
+
try {
|
|
597
|
+
if (this.charge.id) {
|
|
598
|
+
this.openBill(this.charge)
|
|
599
|
+
}
|
|
600
|
+
} catch (e) {
|
|
601
|
+
this.$dispatch('breakControl', this.selectdata)
|
|
602
|
+
}
|
|
603
|
+
})
|
|
604
|
+
},
|
|
605
|
+
moneyChange () {
|
|
606
|
+
if (isEmpty(this.charge.f_charge_money) || Number(this.charge.f_charge_money) === 0) {
|
|
607
|
+
this.$showAlert('单笔收费不能为0元!!!', 'warning', 3000)
|
|
608
|
+
this.charge.f_charge_money = null
|
|
609
|
+
return
|
|
610
|
+
}
|
|
611
|
+
if (Number(this.charge.f_charge_money) > Number(this.selectdata.f_surplus_money)) {
|
|
612
|
+
this.$showAlert('单笔收费不能超过未交总金额!!!', 'warning', 3000)
|
|
613
|
+
this.charge.f_charge_money = null
|
|
614
|
+
return
|
|
615
|
+
}
|
|
616
|
+
},
|
|
617
|
+
// 金额转大写
|
|
618
|
+
handleInput(e) {
|
|
619
|
+
// 通过正则过滤小数点后两位
|
|
620
|
+
e.target.value = (e.target.value.match(/^\d*(\.?\d{0,2})/g)[0]) || null
|
|
621
|
+
this.charge.f_amount_words = this.smalltoBIG(e.target.value)
|
|
622
|
+
},
|
|
623
|
+
// 金额转大写
|
|
624
|
+
smalltoBIG(n) {
|
|
625
|
+
let fraction = ['角', '分'];
|
|
626
|
+
let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
|
|
627
|
+
let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
|
|
628
|
+
let head = n < 0 ? '欠' : '';
|
|
629
|
+
n = Math.abs(n);
|
|
630
|
+
|
|
631
|
+
let s = '';
|
|
632
|
+
|
|
633
|
+
for (var i = 0; i < fraction.length; i++) {
|
|
634
|
+
s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
|
|
635
|
+
}
|
|
636
|
+
s = s || '整';
|
|
637
|
+
n = Math.floor(n);
|
|
638
|
+
|
|
639
|
+
for (var i = 0; i < unit[0].length && n > 0; i++) {
|
|
640
|
+
let p = '';
|
|
641
|
+
for (var j = 0; j < unit[1].length && n > 0; j++) {
|
|
642
|
+
p = digit[n % 10] + unit[1][j] + p;
|
|
643
|
+
n = Math.floor(n / 10);
|
|
644
|
+
}
|
|
645
|
+
s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s;
|
|
646
|
+
}
|
|
647
|
+
return head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
|
|
648
|
+
},
|
|
649
|
+
async showChargeModal() {
|
|
650
|
+
this.showCharge = true
|
|
651
|
+
},
|
|
652
|
+
async search () {
|
|
653
|
+
let http = new HttpResetClass()
|
|
654
|
+
let data = {
|
|
655
|
+
f_process_id: this.selectdata.f_process_id
|
|
656
|
+
}
|
|
657
|
+
let res = await http.load('POST', 'rs/sql/getApplyChargeRecord', {data:data}, {
|
|
658
|
+
resolveMsg: null,
|
|
659
|
+
rejectMsg: '收费记录查询失败!!!'
|
|
660
|
+
})
|
|
661
|
+
this.model.data = res.data
|
|
662
|
+
},
|
|
663
|
+
// 关闭对话框
|
|
664
|
+
closeModal() {
|
|
665
|
+
this.showCharge = false
|
|
666
|
+
this.showInvalid = false
|
|
667
|
+
this.showPrint = false
|
|
668
|
+
this.charge = {}
|
|
669
|
+
this.search()
|
|
670
|
+
}
|
|
671
|
+
},
|
|
672
|
+
events: {
|
|
673
|
+
},
|
|
674
|
+
computed: {
|
|
675
|
+
billStyleList () {
|
|
676
|
+
return this.$appdata.getParam("打印格式")
|
|
677
|
+
},
|
|
678
|
+
paymentMethod() {
|
|
679
|
+
return this.$appdata.getParam("付款方式")
|
|
680
|
+
},
|
|
681
|
+
paymentTerm() {
|
|
682
|
+
return this.$appdata.getParam("收费项目")
|
|
683
|
+
}
|
|
684
|
+
},
|
|
685
|
+
watch: {
|
|
686
|
+
}
|
|
687
|
+
}
|
|
688
|
+
</script>
|
|
689
|
+
<style scoped>
|
|
690
|
+
.textNoLineBreak {
|
|
691
|
+
white-space: nowrap;
|
|
692
|
+
}
|
|
693
|
+
.head-but{
|
|
694
|
+
margin-left: 5px;
|
|
695
|
+
height: 34px;
|
|
696
|
+
/*background-color: #6aa6e2;*/
|
|
697
|
+
border-radius: 4px;
|
|
698
|
+
font-family: PingFang;
|
|
699
|
+
color: #ffffff;
|
|
700
|
+
}
|
|
701
|
+
.form-control{
|
|
702
|
+
padding: 8px 12px;
|
|
703
|
+
}
|
|
704
|
+
</style>
|