diff --git a/app/backend/modules/withdraw/controllers/DetailController.php b/app/backend/modules/withdraw/controllers/DetailController.php index 185eafb5..16200355 100644 --- a/app/backend/modules/withdraw/controllers/DetailController.php +++ b/app/backend/modules/withdraw/controllers/DetailController.php @@ -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; } diff --git a/resources/views/finance/withdraw/withdraw-income.blade.php b/resources/views/finance/withdraw/withdraw-income.blade.php index 5914c3c2..b96bbaac 100644 --- a/resources/views/finance/withdraw/withdraw-income.blade.php +++ b/resources/views/finance/withdraw/withdraw-income.blade.php @@ -679,7 +679,7 @@