telephone-clients 4.0.0-1-60 → 4.0.0-1-62
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/CHANGELOG.md +37 -37
- package/README.md +38 -38
- package/package.json +1 -1
- package/release.bat +5 -5
- package/src/components/android/PhoneWriteCard.vue +476 -476
- package/src/components/sendsingle/CardChangeFill.vue +338 -338
- package/src/components/sendsingle/PosMakeGas.vue +342 -342
- package/src/components/sendsingle/onlineBuyGas.vue +632 -632
- package/src/filiale/jiaocheng/android/onlineBuyGas.vue +637 -637
- package/src/filiale/meihekou/android/onlineBuyGas.vue +727 -727
- package/src/filiale/rongcheng/onlineBuyGas.vue +798 -798
- package/src/filiale/yuncheng/pc/TelLossList.vue +285 -285
- package/src/filiale/zhoukou/android/onlineBuyGas.vue +804 -804
|
@@ -1,338 +1,338 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="flex-row">
|
|
3
|
-
<div class="panel auto repair-info-content">
|
|
4
|
-
<form novalidate class="form-horizontal">
|
|
5
|
-
<div class="row app-row">
|
|
6
|
-
<div class="col-xs-4">
|
|
7
|
-
<img src="../../assets/换表.png" style="width: 20px;margin-bottom: 5px" alt="">
|
|
8
|
-
<label class="font text-left">应补气量</label>
|
|
9
|
-
</div>
|
|
10
|
-
<div class="col-xs-8">
|
|
11
|
-
<input type="text" class ="input_search input_ys" placeholder="请输入转移气量..." readonly v-model="model.f_fill_gas">
|
|
12
|
-
</div>
|
|
13
|
-
</div>
|
|
14
|
-
<div class="row app-row">
|
|
15
|
-
<div class="col-xs-4">
|
|
16
|
-
<img src="../../assets/换表.png" style="width: 20px;margin-bottom: 5px" alt="">
|
|
17
|
-
<label class="font text-left">应补金额</label>
|
|
18
|
-
</div>
|
|
19
|
-
<div class="col-xs-8">
|
|
20
|
-
<input type="text" class ="input_search input_ys" placeholder="请输入转移气量..." readonly v-model="model.f_fill_money">
|
|
21
|
-
</div>
|
|
22
|
-
</div>
|
|
23
|
-
<div class="row app-row" style="">
|
|
24
|
-
<div class="col-xs-4">
|
|
25
|
-
<label class="font text-left"> 备注 </label>
|
|
26
|
-
</div>
|
|
27
|
-
<div class="col-xs-8">
|
|
28
|
-
<input class="search_input input-font" style="width:60%" v-model="model.f_comments">
|
|
29
|
-
</div>
|
|
30
|
-
</div>
|
|
31
|
-
</form>
|
|
32
|
-
|
|
33
|
-
<div class="row text-center" style="margin-top: 25px;">
|
|
34
|
-
<button type="button" class="btn btn-lg btn-font btn-color" style="width: 28%;" @click="confirm()">确认</button>
|
|
35
|
-
</div>
|
|
36
|
-
</div>
|
|
37
|
-
</div>
|
|
38
|
-
</template>
|
|
39
|
-
<script>
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
*卡表补气组件
|
|
43
|
-
*/
|
|
44
|
-
import Vue from 'vue'
|
|
45
|
-
import { HttpResetClass } from 'vue-client'
|
|
46
|
-
|
|
47
|
-
export default {
|
|
48
|
-
title: '换表补气',
|
|
49
|
-
data() {
|
|
50
|
-
return {
|
|
51
|
-
model: {
|
|
52
|
-
//真实补气量
|
|
53
|
-
f_fill_gas:0,
|
|
54
|
-
f_fill_money:0,
|
|
55
|
-
f_stairprice_id: '',
|
|
56
|
-
f_payment: '现金缴费',
|
|
57
|
-
f_pregas: 0,
|
|
58
|
-
f_preamount: 0,
|
|
59
|
-
f_totalcost: 0, // 收款
|
|
60
|
-
f_balance: 0,
|
|
61
|
-
f_curbalance: 0,
|
|
62
|
-
f_collection: 0,
|
|
63
|
-
chargeprice: [],
|
|
64
|
-
f_print: '普通收据',
|
|
65
|
-
f_meter_type: '',
|
|
66
|
-
f_voucher_number: '',
|
|
67
|
-
payments: [{"f_payment":"现金缴费", "f_money":0}],
|
|
68
|
-
|
|
69
|
-
},
|
|
70
|
-
cardallot: null,
|
|
71
|
-
calculatedetail: '',
|
|
72
|
-
blodid: '',
|
|
73
|
-
billData: {
|
|
74
|
-
url: 'rs/report/card_gas_bill',
|
|
75
|
-
bill: ''
|
|
76
|
-
},
|
|
77
|
-
print: false,
|
|
78
|
-
|
|
79
|
-
// 是否有限购
|
|
80
|
-
hasLimit: false,
|
|
81
|
-
//补气提示开关
|
|
82
|
-
remanentfalg:false,
|
|
83
|
-
//补气提示
|
|
84
|
-
remanentstr:'',
|
|
85
|
-
// 启用发票管理需要对票号进行验证
|
|
86
|
-
hasValidateBill: false,
|
|
87
|
-
validateOk: false,
|
|
88
|
-
|
|
89
|
-
maxgas: 99999999,
|
|
90
|
-
|
|
91
|
-
clickConfirm: false,
|
|
92
|
-
|
|
93
|
-
mulPrint: false, // 控制打印格式是否可以多选
|
|
94
|
-
openFee: 0, // 是否有开卡费
|
|
95
|
-
paymentModel: [], // 多笔付款方式
|
|
96
|
-
paytype: this.$appdata.getParam('付款方式') ? this.$appdata.getParam('付款方式') : [],
|
|
97
|
-
printstyle: this.$appdata.getParam('打印格式') ? this.$appdata.getParam('打印格式') : [],
|
|
98
|
-
|
|
99
|
-
// 付款码弹框显示
|
|
100
|
-
paymentCodeShow: false,
|
|
101
|
-
// 付款码值
|
|
102
|
-
paymentCode: null,
|
|
103
|
-
// 付款码流程控制
|
|
104
|
-
paycoderesolve: null,
|
|
105
|
-
// 定时器
|
|
106
|
-
timer: null,
|
|
107
|
-
// 收费成功id
|
|
108
|
-
sellinggasId: null,
|
|
109
|
-
// xml解析对象
|
|
110
|
-
// xotree: new XML.ObjTree()
|
|
111
|
-
}
|
|
112
|
-
},
|
|
113
|
-
|
|
114
|
-
props: ['row'],
|
|
115
|
-
ready() {
|
|
116
|
-
// this.$showMessage('正在维护中...')
|
|
117
|
-
//tag
|
|
118
|
-
//tag)
|
|
119
|
-
|
|
120
|
-
if(this.row.f_remanent_gas == 0) {
|
|
121
|
-
//tag
|
|
122
|
-
let remanent_gas = parseFloat(this.row.f_remanent_money) / parseFloat(this.row.f_remanent_price)
|
|
123
|
-
|
|
124
|
-
this.model.f_fill_gas = remanent_gas.toFixed(2)
|
|
125
|
-
this.model.f_fill_money = this.row.f_remanent_gas
|
|
126
|
-
}
|
|
127
|
-
if(this.row.f_remanent_money == 0) {
|
|
128
|
-
//tag
|
|
129
|
-
let remanent_money = parseFloat(this.row.f_remanent_gas) * parseFloat(this.row.f_remanent_price)
|
|
130
|
-
this.model.f_fill_money = remanent_money.toFixed(2)
|
|
131
|
-
this.model.f_fill_gas = this.row.f_remanent_gas
|
|
132
|
-
}
|
|
133
|
-
if (this.row.f_remanent_type == 1) {
|
|
134
|
-
//tag
|
|
135
|
-
// 换新表
|
|
136
|
-
this.model.writeCard_gas = this.model.f_total_gas = (this.row.f_total_gas - 0) + (this.model.f_fill_money - 0)
|
|
137
|
-
this.model.writeCard_fee = this.model.f_total_fee = (this.row.f_total_fee - 0) + (this.model.f_fill_gas - 0)
|
|
138
|
-
} else {
|
|
139
|
-
//tag
|
|
140
|
-
// 清零换表
|
|
141
|
-
this.model.f_total_gas = (this.row.f_total_gas - 0)
|
|
142
|
-
this.model.f_total_fee = (this.row.f_total_fee - 0)
|
|
143
|
-
this.model.writeCard_fee = (this.model.f_fill_money- 0)
|
|
144
|
-
this.model.writeCard_gas = (this.model.f_fill_gas - 0)
|
|
145
|
-
}
|
|
146
|
-
this.model.f_remanent_gas = this.row.f_remanent_gas
|
|
147
|
-
this.model.f_remanent_price = this.row.f_remanent_price
|
|
148
|
-
this.model.f_remanent_money = this.row.f_remanent_money
|
|
149
|
-
this.model.f_remanent_type = this.row.f_remanent_type
|
|
150
|
-
this.model.f_user_name = this.row.f_user_name
|
|
151
|
-
this.model.f_user_type = this.row.f_user_type
|
|
152
|
-
this.model.f_gasproperties = this.row.f_gasproperties
|
|
153
|
-
this.model.f_address = this.row.f_address
|
|
154
|
-
this.model.f_meter_brand = this.row.f_meter_brand
|
|
155
|
-
this.model.f_meter_type = this.row.f_meter_type
|
|
156
|
-
this.model.f_collection_type = this.row.f_collection_type
|
|
157
|
-
this.model.f_price_id = this.row.f_price_id
|
|
158
|
-
this.model.f_user_id = this.row.f_user_id
|
|
159
|
-
this.model.f_userfiles_id = this.row.f_userfiles_id
|
|
160
|
-
this.model.f_userinfo_id = this.row.f_userinfo_id
|
|
161
|
-
this.model.userinfo_version = this.row.userinfo_version
|
|
162
|
-
this.model.version = this.row.version
|
|
163
|
-
this.model.f_operator= Vue.user.name
|
|
164
|
-
this.model.f_operatorid= Vue.user.id
|
|
165
|
-
this.model.f_orgid = Vue.user.orgid
|
|
166
|
-
this.model.f_orgname = Vue.user.orgs
|
|
167
|
-
this.model.f_depid = Vue.user.depids
|
|
168
|
-
this.model.f_depname = Vue.user.deps
|
|
169
|
-
// this.model.f_total_gas = this.row.f_total_gas
|
|
170
|
-
// this.model.f_total_fee = this.row.f_total_fee
|
|
171
|
-
//补气信息
|
|
172
|
-
this.model.f_balance = this.row.f_balance
|
|
173
|
-
//tag)
|
|
174
|
-
// 获取卡号
|
|
175
|
-
this.getcardid()
|
|
176
|
-
},
|
|
177
|
-
watch: {},
|
|
178
|
-
methods: {
|
|
179
|
-
confirm() {
|
|
180
|
-
if (this.model.cardNumber) {
|
|
181
|
-
// 用于获取卡号
|
|
182
|
-
this.$showMessage(`对客户${this.row.f_user_name}进行补气购气操作。请确保你已经插入了${this.row.f_meter_brand}的卡?`, ['confirm', 'cancel']).then(async (res) => {
|
|
183
|
-
if (res === 'confirm') {
|
|
184
|
-
// 1.判断是否是新卡 2.补气存库 3.写卡
|
|
185
|
-
await this.isnewcard()
|
|
186
|
-
|
|
187
|
-
}
|
|
188
|
-
})
|
|
189
|
-
}else {
|
|
190
|
-
this.$showMessage('获取卡号失败!')
|
|
191
|
-
}
|
|
192
|
-
},
|
|
193
|
-
getcardid () {
|
|
194
|
-
this.$resetpost(`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/logic/getCardNumber`, {data: {id: this.row.brand_id}}, {
|
|
195
|
-
resolveMsg: '获取卡号成功!!',
|
|
196
|
-
rejectMsg: '获取卡号出错!!!'
|
|
197
|
-
}).then((row) => {
|
|
198
|
-
//tag)
|
|
199
|
-
let cardId = row.data.cardNumber + ''
|
|
200
|
-
this.model.cardNumber = cardId.substring(0, cardId.length - 8) + this.row.f_userinfo_code
|
|
201
|
-
//tag)
|
|
202
|
-
//tag)
|
|
203
|
-
}).catch((e) => {
|
|
204
|
-
//tag)
|
|
205
|
-
})
|
|
206
|
-
},
|
|
207
|
-
async isnewcard() {
|
|
208
|
-
//tag
|
|
209
|
-
let fengongsi = this.$appdata.getSingleValue('分公司')
|
|
210
|
-
if (!fengongsi) {
|
|
211
|
-
this.$showMessage('分公司获取失败!')
|
|
212
|
-
return
|
|
213
|
-
}
|
|
214
|
-
let posinfo = HostApp.read(fengongsi)
|
|
215
|
-
// let posinfo = HostApp.read("XianYang")
|
|
216
|
-
//tag)
|
|
217
|
-
if (posinfo.code == 200) {
|
|
218
|
-
if (posinfo.msg.Gas>0 || posinfo.msg.Money > 0 ) {
|
|
219
|
-
this.$showMessage('卡上有余额是否继续写卡!', ['confirm', 'cancel']).then( async (res) => {
|
|
220
|
-
if (res === 'confirm') {
|
|
221
|
-
//tag
|
|
222
|
-
await this.compensategas()
|
|
223
|
-
}
|
|
224
|
-
})
|
|
225
|
-
}else {
|
|
226
|
-
// 存库
|
|
227
|
-
await this.compensategas()
|
|
228
|
-
}
|
|
229
|
-
}else {
|
|
230
|
-
this.$showMessage(posinfo.msg)
|
|
231
|
-
}
|
|
232
|
-
},
|
|
233
|
-
async compensategas() {
|
|
234
|
-
//tag)
|
|
235
|
-
await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/logic/sendCardRemanentGas`, {data: this.model}, {}).then( async (row) => {
|
|
236
|
-
//tag)
|
|
237
|
-
this.$showMessage('补气成功!!!')
|
|
238
|
-
// 写卡
|
|
239
|
-
await this.writcard()
|
|
240
|
-
}).catch((e) => {
|
|
241
|
-
//tag)
|
|
242
|
-
})
|
|
243
|
-
},
|
|
244
|
-
async writcard() {
|
|
245
|
-
//tag
|
|
246
|
-
let params = {
|
|
247
|
-
AREA:'XianYang', // 分公司
|
|
248
|
-
ulen: 0, // 判断版本
|
|
249
|
-
factory: this.row.f_alias,
|
|
250
|
-
kmm: '0', // 2019-12-22 查旭说的。给一个0 卡密码,写卡后返回新密码, 不论补卡还是先开户都没有密码
|
|
251
|
-
kzt: '0', // 卡状态,0开户卡,1用户卡(0新开户,1补卡)
|
|
252
|
-
kh: this.model.cardNumber, // 卡号
|
|
253
|
-
yhh: this.row.f_meterid ? this.row.f_meterid : 0, // 用户号,档案中自己输
|
|
254
|
-
ql: this.model.writeCard_gas, // 预购气量
|
|
255
|
-
csql: '0', // 上次购气量,新开户为0
|
|
256
|
-
ccsql: '0', // 上上次购气量,新开户为0
|
|
257
|
-
cs: '1', // 求购气次数,先开户为1
|
|
258
|
-
ljgql: this.model.f_total_gas, // 当前累计购气量
|
|
259
|
-
bkcs: '0', // 新开户卡,为0
|
|
260
|
-
ljyql: '0', // 累积用气量,有些表要累加原来用气量,新开户卡,为0
|
|
261
|
-
bjql: this.row.f_police_gas, // 报警气量,t_gasbrand表中
|
|
262
|
-
czsx: this.row.f_topup_ceil, // 充值上线,t_gasbrand表中
|
|
263
|
-
tzed: this.row.f_overdr_lines, // 透支额度,t_gasbrand表中
|
|
264
|
-
cssqrq: '0', // 上次售气日期,格式为YYYYMMDD
|
|
265
|
-
meterid: this.row.f_meternumber, // 表号
|
|
266
|
-
money: this.model.writeCard_fee, // 购气金额
|
|
267
|
-
dqdm: this.row.f_area_code, // 精益工业地区代码
|
|
268
|
-
klx: this.row.f_coding
|
|
269
|
-
}
|
|
270
|
-
// 获取写卡参数
|
|
271
|
-
let data = {
|
|
272
|
-
f_card_id: this.model.cardNumber + '',
|
|
273
|
-
f_alias: this.row.alias,
|
|
274
|
-
f_user_id: this.row.f_user_id,
|
|
275
|
-
f_userfiles_id: this.row.f_userfiles_id
|
|
276
|
-
}
|
|
277
|
-
//tag)
|
|
278
|
-
let http = new HttpResetClass()
|
|
279
|
-
let cardParams = await http.load('POST',`${this.$androidUtil.getProxyUrl()}/af-
|
|
280
|
-
//tag)
|
|
281
|
-
// 拼接参数
|
|
282
|
-
params = await Object.assign({}, await this.writeCardParams(cardParams), params)
|
|
283
|
-
//tag)
|
|
284
|
-
let writres = await HostApp.issue(JSON.stringify(params))
|
|
285
|
-
//tag)
|
|
286
|
-
if(writres.code =='200') {
|
|
287
|
-
this.$showMessage('写卡成功!!!')
|
|
288
|
-
// this.$dispatch('confirm')
|
|
289
|
-
this.$back()
|
|
290
|
-
}else {
|
|
291
|
-
this.$showMessage('写卡失败!!!')
|
|
292
|
-
}
|
|
293
|
-
},
|
|
294
|
-
clean() {
|
|
295
|
-
//tag
|
|
296
|
-
this.$dispatch('refresh', this.row)
|
|
297
|
-
}
|
|
298
|
-
},
|
|
299
|
-
computed: {
|
|
300
|
-
|
|
301
|
-
}
|
|
302
|
-
}
|
|
303
|
-
</script>
|
|
304
|
-
|
|
305
|
-
<style scoped>
|
|
306
|
-
.app-row {
|
|
307
|
-
background-color: white;
|
|
308
|
-
padding: 10px 10px 0 10px;
|
|
309
|
-
border-bottom: 1px solid rgba(235, 235, 235, 0.7);
|
|
310
|
-
}
|
|
311
|
-
.font{
|
|
312
|
-
font: 15px PingFang-SC-Medium;
|
|
313
|
-
color: #666666;
|
|
314
|
-
}
|
|
315
|
-
.search_input {
|
|
316
|
-
border: 0;
|
|
317
|
-
outline: none;
|
|
318
|
-
}
|
|
319
|
-
.input-font{
|
|
320
|
-
font: 15px PingFang-SC-Medium;
|
|
321
|
-
color: #333333;
|
|
322
|
-
}
|
|
323
|
-
.btn-color{
|
|
324
|
-
background-color: #FFFFFF;
|
|
325
|
-
border-radius: 10px ;
|
|
326
|
-
border: 1px solid #499EDF;
|
|
327
|
-
}
|
|
328
|
-
.btn-font{
|
|
329
|
-
font:600 16px PingFang-SC-Bold;
|
|
330
|
-
color: #499EDF;
|
|
331
|
-
}
|
|
332
|
-
.input_ys {
|
|
333
|
-
/*border: 1px solid #93B2D3 !important;*/
|
|
334
|
-
border: none !important;
|
|
335
|
-
width: 220px;
|
|
336
|
-
height: 35px;
|
|
337
|
-
}
|
|
338
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="flex-row">
|
|
3
|
+
<div class="panel auto repair-info-content">
|
|
4
|
+
<form novalidate class="form-horizontal">
|
|
5
|
+
<div class="row app-row">
|
|
6
|
+
<div class="col-xs-4">
|
|
7
|
+
<img src="../../assets/换表.png" style="width: 20px;margin-bottom: 5px" alt="">
|
|
8
|
+
<label class="font text-left">应补气量</label>
|
|
9
|
+
</div>
|
|
10
|
+
<div class="col-xs-8">
|
|
11
|
+
<input type="text" class ="input_search input_ys" placeholder="请输入转移气量..." readonly v-model="model.f_fill_gas">
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
14
|
+
<div class="row app-row">
|
|
15
|
+
<div class="col-xs-4">
|
|
16
|
+
<img src="../../assets/换表.png" style="width: 20px;margin-bottom: 5px" alt="">
|
|
17
|
+
<label class="font text-left">应补金额</label>
|
|
18
|
+
</div>
|
|
19
|
+
<div class="col-xs-8">
|
|
20
|
+
<input type="text" class ="input_search input_ys" placeholder="请输入转移气量..." readonly v-model="model.f_fill_money">
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
<div class="row app-row" style="">
|
|
24
|
+
<div class="col-xs-4">
|
|
25
|
+
<label class="font text-left"> 备注 </label>
|
|
26
|
+
</div>
|
|
27
|
+
<div class="col-xs-8">
|
|
28
|
+
<input class="search_input input-font" style="width:60%" v-model="model.f_comments">
|
|
29
|
+
</div>
|
|
30
|
+
</div>
|
|
31
|
+
</form>
|
|
32
|
+
|
|
33
|
+
<div class="row text-center" style="margin-top: 25px;">
|
|
34
|
+
<button type="button" class="btn btn-lg btn-font btn-color" style="width: 28%;" @click="confirm()">确认</button>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
38
|
+
</template>
|
|
39
|
+
<script>
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
*卡表补气组件
|
|
43
|
+
*/
|
|
44
|
+
import Vue from 'vue'
|
|
45
|
+
import { HttpResetClass } from 'vue-client'
|
|
46
|
+
|
|
47
|
+
export default {
|
|
48
|
+
title: '换表补气',
|
|
49
|
+
data() {
|
|
50
|
+
return {
|
|
51
|
+
model: {
|
|
52
|
+
//真实补气量
|
|
53
|
+
f_fill_gas:0,
|
|
54
|
+
f_fill_money:0,
|
|
55
|
+
f_stairprice_id: '',
|
|
56
|
+
f_payment: '现金缴费',
|
|
57
|
+
f_pregas: 0,
|
|
58
|
+
f_preamount: 0,
|
|
59
|
+
f_totalcost: 0, // 收款
|
|
60
|
+
f_balance: 0,
|
|
61
|
+
f_curbalance: 0,
|
|
62
|
+
f_collection: 0,
|
|
63
|
+
chargeprice: [],
|
|
64
|
+
f_print: '普通收据',
|
|
65
|
+
f_meter_type: '',
|
|
66
|
+
f_voucher_number: '',
|
|
67
|
+
payments: [{"f_payment":"现金缴费", "f_money":0}],
|
|
68
|
+
|
|
69
|
+
},
|
|
70
|
+
cardallot: null,
|
|
71
|
+
calculatedetail: '',
|
|
72
|
+
blodid: '',
|
|
73
|
+
billData: {
|
|
74
|
+
url: 'rs/report/card_gas_bill',
|
|
75
|
+
bill: ''
|
|
76
|
+
},
|
|
77
|
+
print: false,
|
|
78
|
+
|
|
79
|
+
// 是否有限购
|
|
80
|
+
hasLimit: false,
|
|
81
|
+
//补气提示开关
|
|
82
|
+
remanentfalg:false,
|
|
83
|
+
//补气提示
|
|
84
|
+
remanentstr:'',
|
|
85
|
+
// 启用发票管理需要对票号进行验证
|
|
86
|
+
hasValidateBill: false,
|
|
87
|
+
validateOk: false,
|
|
88
|
+
|
|
89
|
+
maxgas: 99999999,
|
|
90
|
+
|
|
91
|
+
clickConfirm: false,
|
|
92
|
+
|
|
93
|
+
mulPrint: false, // 控制打印格式是否可以多选
|
|
94
|
+
openFee: 0, // 是否有开卡费
|
|
95
|
+
paymentModel: [], // 多笔付款方式
|
|
96
|
+
paytype: this.$appdata.getParam('付款方式') ? this.$appdata.getParam('付款方式') : [],
|
|
97
|
+
printstyle: this.$appdata.getParam('打印格式') ? this.$appdata.getParam('打印格式') : [],
|
|
98
|
+
|
|
99
|
+
// 付款码弹框显示
|
|
100
|
+
paymentCodeShow: false,
|
|
101
|
+
// 付款码值
|
|
102
|
+
paymentCode: null,
|
|
103
|
+
// 付款码流程控制
|
|
104
|
+
paycoderesolve: null,
|
|
105
|
+
// 定时器
|
|
106
|
+
timer: null,
|
|
107
|
+
// 收费成功id
|
|
108
|
+
sellinggasId: null,
|
|
109
|
+
// xml解析对象
|
|
110
|
+
// xotree: new XML.ObjTree()
|
|
111
|
+
}
|
|
112
|
+
},
|
|
113
|
+
|
|
114
|
+
props: ['row'],
|
|
115
|
+
ready() {
|
|
116
|
+
// this.$showMessage('正在维护中...')
|
|
117
|
+
//tag
|
|
118
|
+
//tag)
|
|
119
|
+
|
|
120
|
+
if(this.row.f_remanent_gas == 0) {
|
|
121
|
+
//tag
|
|
122
|
+
let remanent_gas = parseFloat(this.row.f_remanent_money) / parseFloat(this.row.f_remanent_price)
|
|
123
|
+
|
|
124
|
+
this.model.f_fill_gas = remanent_gas.toFixed(2)
|
|
125
|
+
this.model.f_fill_money = this.row.f_remanent_gas
|
|
126
|
+
}
|
|
127
|
+
if(this.row.f_remanent_money == 0) {
|
|
128
|
+
//tag
|
|
129
|
+
let remanent_money = parseFloat(this.row.f_remanent_gas) * parseFloat(this.row.f_remanent_price)
|
|
130
|
+
this.model.f_fill_money = remanent_money.toFixed(2)
|
|
131
|
+
this.model.f_fill_gas = this.row.f_remanent_gas
|
|
132
|
+
}
|
|
133
|
+
if (this.row.f_remanent_type == 1) {
|
|
134
|
+
//tag
|
|
135
|
+
// 换新表
|
|
136
|
+
this.model.writeCard_gas = this.model.f_total_gas = (this.row.f_total_gas - 0) + (this.model.f_fill_money - 0)
|
|
137
|
+
this.model.writeCard_fee = this.model.f_total_fee = (this.row.f_total_fee - 0) + (this.model.f_fill_gas - 0)
|
|
138
|
+
} else {
|
|
139
|
+
//tag
|
|
140
|
+
// 清零换表
|
|
141
|
+
this.model.f_total_gas = (this.row.f_total_gas - 0)
|
|
142
|
+
this.model.f_total_fee = (this.row.f_total_fee - 0)
|
|
143
|
+
this.model.writeCard_fee = (this.model.f_fill_money- 0)
|
|
144
|
+
this.model.writeCard_gas = (this.model.f_fill_gas - 0)
|
|
145
|
+
}
|
|
146
|
+
this.model.f_remanent_gas = this.row.f_remanent_gas
|
|
147
|
+
this.model.f_remanent_price = this.row.f_remanent_price
|
|
148
|
+
this.model.f_remanent_money = this.row.f_remanent_money
|
|
149
|
+
this.model.f_remanent_type = this.row.f_remanent_type
|
|
150
|
+
this.model.f_user_name = this.row.f_user_name
|
|
151
|
+
this.model.f_user_type = this.row.f_user_type
|
|
152
|
+
this.model.f_gasproperties = this.row.f_gasproperties
|
|
153
|
+
this.model.f_address = this.row.f_address
|
|
154
|
+
this.model.f_meter_brand = this.row.f_meter_brand
|
|
155
|
+
this.model.f_meter_type = this.row.f_meter_type
|
|
156
|
+
this.model.f_collection_type = this.row.f_collection_type
|
|
157
|
+
this.model.f_price_id = this.row.f_price_id
|
|
158
|
+
this.model.f_user_id = this.row.f_user_id
|
|
159
|
+
this.model.f_userfiles_id = this.row.f_userfiles_id
|
|
160
|
+
this.model.f_userinfo_id = this.row.f_userinfo_id
|
|
161
|
+
this.model.userinfo_version = this.row.userinfo_version
|
|
162
|
+
this.model.version = this.row.version
|
|
163
|
+
this.model.f_operator= Vue.user.name
|
|
164
|
+
this.model.f_operatorid= Vue.user.id
|
|
165
|
+
this.model.f_orgid = Vue.user.orgid
|
|
166
|
+
this.model.f_orgname = Vue.user.orgs
|
|
167
|
+
this.model.f_depid = Vue.user.depids
|
|
168
|
+
this.model.f_depname = Vue.user.deps
|
|
169
|
+
// this.model.f_total_gas = this.row.f_total_gas
|
|
170
|
+
// this.model.f_total_fee = this.row.f_total_fee
|
|
171
|
+
//补气信息
|
|
172
|
+
this.model.f_balance = this.row.f_balance
|
|
173
|
+
//tag)
|
|
174
|
+
// 获取卡号
|
|
175
|
+
this.getcardid()
|
|
176
|
+
},
|
|
177
|
+
watch: {},
|
|
178
|
+
methods: {
|
|
179
|
+
confirm() {
|
|
180
|
+
if (this.model.cardNumber) {
|
|
181
|
+
// 用于获取卡号
|
|
182
|
+
this.$showMessage(`对客户${this.row.f_user_name}进行补气购气操作。请确保你已经插入了${this.row.f_meter_brand}的卡?`, ['confirm', 'cancel']).then(async (res) => {
|
|
183
|
+
if (res === 'confirm') {
|
|
184
|
+
// 1.判断是否是新卡 2.补气存库 3.写卡
|
|
185
|
+
await this.isnewcard()
|
|
186
|
+
|
|
187
|
+
}
|
|
188
|
+
})
|
|
189
|
+
}else {
|
|
190
|
+
this.$showMessage('获取卡号失败!')
|
|
191
|
+
}
|
|
192
|
+
},
|
|
193
|
+
getcardid () {
|
|
194
|
+
this.$resetpost(`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/logic/getCardNumber`, {data: {id: this.row.brand_id}}, {
|
|
195
|
+
resolveMsg: '获取卡号成功!!',
|
|
196
|
+
rejectMsg: '获取卡号出错!!!'
|
|
197
|
+
}).then((row) => {
|
|
198
|
+
//tag)
|
|
199
|
+
let cardId = row.data.cardNumber + ''
|
|
200
|
+
this.model.cardNumber = cardId.substring(0, cardId.length - 8) + this.row.f_userinfo_code
|
|
201
|
+
//tag)
|
|
202
|
+
//tag)
|
|
203
|
+
}).catch((e) => {
|
|
204
|
+
//tag)
|
|
205
|
+
})
|
|
206
|
+
},
|
|
207
|
+
async isnewcard() {
|
|
208
|
+
//tag
|
|
209
|
+
let fengongsi = this.$appdata.getSingleValue('分公司')
|
|
210
|
+
if (!fengongsi) {
|
|
211
|
+
this.$showMessage('分公司获取失败!')
|
|
212
|
+
return
|
|
213
|
+
}
|
|
214
|
+
let posinfo = HostApp.read(fengongsi)
|
|
215
|
+
// let posinfo = HostApp.read("XianYang")
|
|
216
|
+
//tag)
|
|
217
|
+
if (posinfo.code == 200) {
|
|
218
|
+
if (posinfo.msg.Gas>0 || posinfo.msg.Money > 0 ) {
|
|
219
|
+
this.$showMessage('卡上有余额是否继续写卡!', ['confirm', 'cancel']).then( async (res) => {
|
|
220
|
+
if (res === 'confirm') {
|
|
221
|
+
//tag
|
|
222
|
+
await this.compensategas()
|
|
223
|
+
}
|
|
224
|
+
})
|
|
225
|
+
}else {
|
|
226
|
+
// 存库
|
|
227
|
+
await this.compensategas()
|
|
228
|
+
}
|
|
229
|
+
}else {
|
|
230
|
+
this.$showMessage(posinfo.msg)
|
|
231
|
+
}
|
|
232
|
+
},
|
|
233
|
+
async compensategas() {
|
|
234
|
+
//tag)
|
|
235
|
+
await this.$resetpost(`${this.$androidUtil.getProxyUrl()}/af-telephone/rs/logic/sendCardRemanentGas`, {data: this.model}, {}).then( async (row) => {
|
|
236
|
+
//tag)
|
|
237
|
+
this.$showMessage('补气成功!!!')
|
|
238
|
+
// 写卡
|
|
239
|
+
await this.writcard()
|
|
240
|
+
}).catch((e) => {
|
|
241
|
+
//tag)
|
|
242
|
+
})
|
|
243
|
+
},
|
|
244
|
+
async writcard() {
|
|
245
|
+
//tag
|
|
246
|
+
let params = {
|
|
247
|
+
AREA:'XianYang', // 分公司
|
|
248
|
+
ulen: 0, // 判断版本
|
|
249
|
+
factory: this.row.f_alias,
|
|
250
|
+
kmm: '0', // 2019-12-22 查旭说的。给一个0 卡密码,写卡后返回新密码, 不论补卡还是先开户都没有密码
|
|
251
|
+
kzt: '0', // 卡状态,0开户卡,1用户卡(0新开户,1补卡)
|
|
252
|
+
kh: this.model.cardNumber, // 卡号
|
|
253
|
+
yhh: this.row.f_meterid ? this.row.f_meterid : 0, // 用户号,档案中自己输
|
|
254
|
+
ql: this.model.writeCard_gas, // 预购气量
|
|
255
|
+
csql: '0', // 上次购气量,新开户为0
|
|
256
|
+
ccsql: '0', // 上上次购气量,新开户为0
|
|
257
|
+
cs: '1', // 求购气次数,先开户为1
|
|
258
|
+
ljgql: this.model.f_total_gas, // 当前累计购气量
|
|
259
|
+
bkcs: '0', // 新开户卡,为0
|
|
260
|
+
ljyql: '0', // 累积用气量,有些表要累加原来用气量,新开户卡,为0
|
|
261
|
+
bjql: this.row.f_police_gas, // 报警气量,t_gasbrand表中
|
|
262
|
+
czsx: this.row.f_topup_ceil, // 充值上线,t_gasbrand表中
|
|
263
|
+
tzed: this.row.f_overdr_lines, // 透支额度,t_gasbrand表中
|
|
264
|
+
cssqrq: '0', // 上次售气日期,格式为YYYYMMDD
|
|
265
|
+
meterid: this.row.f_meternumber, // 表号
|
|
266
|
+
money: this.model.writeCard_fee, // 购气金额
|
|
267
|
+
dqdm: this.row.f_area_code, // 精益工业地区代码
|
|
268
|
+
klx: this.row.f_coding
|
|
269
|
+
}
|
|
270
|
+
// 获取写卡参数
|
|
271
|
+
let data = {
|
|
272
|
+
f_card_id: this.model.cardNumber + '',
|
|
273
|
+
f_alias: this.row.alias,
|
|
274
|
+
f_user_id: this.row.f_user_id,
|
|
275
|
+
f_userfiles_id: this.row.f_userfiles_id
|
|
276
|
+
}
|
|
277
|
+
//tag)
|
|
278
|
+
let http = new HttpResetClass()
|
|
279
|
+
let cardParams = await http.load('POST',`${this.$androidUtil.getProxyUrl()}/api/af-revenue/logic/stairCard`, {data: data}, {resolveMsg: null, rejectMsg: '获取写卡参数失败'})
|
|
280
|
+
//tag)
|
|
281
|
+
// 拼接参数
|
|
282
|
+
params = await Object.assign({}, await this.writeCardParams(cardParams), params)
|
|
283
|
+
//tag)
|
|
284
|
+
let writres = await HostApp.issue(JSON.stringify(params))
|
|
285
|
+
//tag)
|
|
286
|
+
if(writres.code =='200') {
|
|
287
|
+
this.$showMessage('写卡成功!!!')
|
|
288
|
+
// this.$dispatch('confirm')
|
|
289
|
+
this.$back()
|
|
290
|
+
}else {
|
|
291
|
+
this.$showMessage('写卡失败!!!')
|
|
292
|
+
}
|
|
293
|
+
},
|
|
294
|
+
clean() {
|
|
295
|
+
//tag
|
|
296
|
+
this.$dispatch('refresh', this.row)
|
|
297
|
+
}
|
|
298
|
+
},
|
|
299
|
+
computed: {
|
|
300
|
+
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
</script>
|
|
304
|
+
|
|
305
|
+
<style scoped>
|
|
306
|
+
.app-row {
|
|
307
|
+
background-color: white;
|
|
308
|
+
padding: 10px 10px 0 10px;
|
|
309
|
+
border-bottom: 1px solid rgba(235, 235, 235, 0.7);
|
|
310
|
+
}
|
|
311
|
+
.font{
|
|
312
|
+
font: 15px PingFang-SC-Medium;
|
|
313
|
+
color: #666666;
|
|
314
|
+
}
|
|
315
|
+
.search_input {
|
|
316
|
+
border: 0;
|
|
317
|
+
outline: none;
|
|
318
|
+
}
|
|
319
|
+
.input-font{
|
|
320
|
+
font: 15px PingFang-SC-Medium;
|
|
321
|
+
color: #333333;
|
|
322
|
+
}
|
|
323
|
+
.btn-color{
|
|
324
|
+
background-color: #FFFFFF;
|
|
325
|
+
border-radius: 10px ;
|
|
326
|
+
border: 1px solid #499EDF;
|
|
327
|
+
}
|
|
328
|
+
.btn-font{
|
|
329
|
+
font:600 16px PingFang-SC-Bold;
|
|
330
|
+
color: #499EDF;
|
|
331
|
+
}
|
|
332
|
+
.input_ys {
|
|
333
|
+
/*border: 1px solid #93B2D3 !important;*/
|
|
334
|
+
border: none !important;
|
|
335
|
+
width: 220px;
|
|
336
|
+
height: 35px;
|
|
337
|
+
}
|
|
338
|
+
</style>
|