添加:提现设置添加审核时间设置,只能在指定时间内进行审核操作(已提交)

This commit is contained in:
wuhui_zzw 2023-12-05 09:48:15 +08:00
parent 85a46dfbcc
commit 299e22ebb8
3 changed files with 19 additions and 2 deletions

View File

@ -122,6 +122,21 @@ class DetailController extends BaseController
$this->withdrawModel->actual_amounts = bcsub(bcsub($this->withdrawModel->amounts, $this->withdrawModel->poundage, 2), $this->withdrawModel->servicetax, 2);
}
// 判断:当前时间是否可以进行审核
$incomeSet = \Setting::get('withdraw.income');
$withdraw_date_time_start = (int)$incomeSet['withdraw_date_time_start'];
$withdraw_date_time_end = (int)$incomeSet['withdraw_date_time_end'];
$startTime = strtotime(date("Y-m-d {$withdraw_date_time_start}:00:00"));
$startEnd = strtotime(date("Y-m-d {$withdraw_date_time_end}:00:00"));
$isAllowExamine = true;// 默认允许审核
if($withdraw_date_time_start > 0 && $withdraw_date_time_end > 0){
$isAllowExamine = ($startTime < time() && $startEnd > time());
}else if($withdraw_date_time_start > 0 && $withdraw_date_time_end == 0){
$isAllowExamine = $startTime < time();
}else if($withdraw_date_time_start == 0 && $withdraw_date_time_end > 0){
$isAllowExamine = $startEnd > time();
}
$result_data['is_allow_examine'] = $isAllowExamine;
return $result_data;
}

View File

@ -679,7 +679,7 @@
<div class="tab-pane active">
<div class="form-group">
<label class="col-xs-12 col-sm-3 col-md-2 control-label">提现时间</label>
<label class="col-xs-12 col-sm-3 col-md-2 control-label">提现审核时间</label>
<div class="col-sm-10 col-xs-12">
<div class="input-group" style="width: 40%!important;">
<input type="text" name="withdraw[income][withdraw_date_time_start]" class="form-control" value="{{ $set['withdraw_date_time_start'] ?? ''}}" placeholder="请输入可提现开始时间"/>
@ -687,7 +687,7 @@
<input type="text" name="withdraw[income][withdraw_date_time_end]" class="form-control" value="{{ $set['withdraw_date_time_end'] ?? ''}}" placeholder="请输入可提现结束时间"/>
<div class="input-group-addon"></div>
</div>
<span class='help-block'>当前可提现时间例如9至17则代表只能在9时0分0秒至17时0分0秒(下午5时0分0秒)进行提现申请。为空则默认为当天0时0分0秒至23时59分59秒可以提现</span>
<span class='help-block'>提现审核时间例如9至17则代表只能在9时0分0秒至17时0分0秒(下午5时0分0秒)进行提现审核。为空或者0则不限制时间</span>
</div>
</div>
</div>

View File

@ -225,6 +225,7 @@
<div style="height: 60px;"></div>
<div class="vue-page">
<el-button @click="goback">返回列表</el-button>
@if($is_allow_examine == 1)
<el-button type="primary" @click="examine('审核成功')" v-if="withdraw.status==0">提交审核</el-button>
<template v-if="withdraw.status==1">
<el-button v-if="withdraw.pay_way=='consol_withdraw_bank'" type="primary" @click="Repayment('pay_way')">汇聚代发薪-银行卡</el-button>
@ -257,6 +258,7 @@
<template v-else-if="withdraw.status==-1">
<el-button type="primary" @click="examine('重新审核成功')">重新审核</el-button>
</template>
@endif
</div>
<el-dialog title="详情" :visible.sync="dialogVisible" width="30%">