mirror of
https://github.com/crmeb/CRMEB.git
synced 2026-10-29 05:50:50 +00:00
增加提现手续费
This commit is contained in:
parent
831d4df3d8
commit
cdde070e08
@ -462,10 +462,13 @@ class UserExtractServices extends BaseServices
|
||||
if ($data['money'] <= 0) {
|
||||
throw new ApiException(400664);
|
||||
}
|
||||
$data['extract_fee'] = bcmul((string)$data['money'], bcdiv((string)sys_config('withdrawal_fee', '0'), '100', 2), 2);
|
||||
$data['extract_price'] = bcsub((string)$data['money'], $data['extract_fee'], 2);
|
||||
$insertData = [
|
||||
'uid' => $user['uid'],
|
||||
'extract_type' => $data['extract_type'],
|
||||
'extract_price' => $data['money'],
|
||||
'extract_price' => $data['extract_price'],
|
||||
'extract_fee' => $data['extract_fee'],
|
||||
'add_time' => time(),
|
||||
'balance' => $user['brokerage_price'],
|
||||
'status' => 0
|
||||
@ -482,12 +485,12 @@ class UserExtractServices extends BaseServices
|
||||
if ($data['extract_type'] == 'alipay') {
|
||||
$insertData['alipay_code'] = $data['alipay_code'];
|
||||
$insertData['qrcode_url'] = $data['qrcode_url'];
|
||||
$mark = '使用支付宝提现' . $insertData['extract_price'] . '元';
|
||||
$mark = '使用支付宝提现' . $insertData['extract_price'] . '元,手续费' . $insertData['extract_fee'] . '元';
|
||||
} else if ($data['extract_type'] == 'bank') {
|
||||
$mark = '使用银联卡' . $insertData['bank_code'] . '提现' . $insertData['extract_price'] . '元';
|
||||
$mark = '使用银联卡' . $insertData['bank_code'] . '提现' . $insertData['extract_price'] . '元,手续费' . $insertData['extract_fee'] . '元';
|
||||
} else if ($data['extract_type'] == 'weixin') {
|
||||
$insertData['qrcode_url'] = $data['qrcode_url'];
|
||||
$mark = '使用微信提现' . $insertData['extract_price'] . '元';
|
||||
$mark = '使用微信提现' . $insertData['extract_price'] . '元,手续费' . $insertData['extract_fee'] . '元';
|
||||
if (sys_config('brokerage_type', 0) && $openid) {
|
||||
if ($data['money'] < 1) {
|
||||
throw new ApiException(400665);
|
||||
|
||||
@ -89,11 +89,16 @@
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="提现金额" min-width="130">
|
||||
<el-table-column label="提现金额" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<div>{{ scope.row.extract_price }}</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="提现手续费" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<div>{{ scope.row.extract_fee }}</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="提现方式" min-width="130">
|
||||
<template slot-scope="scope">
|
||||
<div class="type" v-if="scope.row.extract_type === 'bank'">
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user