mirror of
https://gitee.com/liuxioabin/fengketrade.git
synced 2026-04-17 21:03:17 +08:00
提现限制
This commit is contained in:
parent
9e98a4fafc
commit
18e52067ee
@ -233,6 +233,16 @@ class Withdraw
|
||||
if ($withdraw->status != 1) {
|
||||
throw new ShoproException('请勿重复操作');
|
||||
}
|
||||
|
||||
// 检查7天限制
|
||||
if (isset($this->config['days_7']) && $this->config['days_7'] == 1) {
|
||||
$daysDiff = (time() - $withdraw->createtime) / 86400; // 86400秒 = 1天
|
||||
if ($daysDiff < 7) {
|
||||
$remainingDays = ceil(7 - $daysDiff);
|
||||
throw new ShoproException('提现申请时间未超过7天,还需等待' . $remainingDays . '天才能放款');
|
||||
}
|
||||
}
|
||||
|
||||
if ($withdraw->withdraw_type !== 'bank') {
|
||||
$withDrawStatus = $this->handleTransfer($withdraw);
|
||||
} else {
|
||||
|
||||
@ -631,6 +631,21 @@
|
||||
<template #append>次</template>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="限制7天后才能提现打款">
|
||||
<div>
|
||||
<div class="sa-flex">
|
||||
<el-switch v-model="form.model.withdraw.days_7" class="sa-m-r-8"
|
||||
:active-value="1" :inactive-value="0"></el-switch>
|
||||
<div class="label-tip"
|
||||
:class="form.model.withdraw.days_7 == 1?'sa-color--primary':''">
|
||||
{{form.model.withdraw.days_7 == 1?'开启':'关闭'}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="tip">
|
||||
开启后,如果提现申请时间没有超过7天是不能放款的
|
||||
</div>
|
||||
</div>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</template>
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user