|
|
@ -72,6 +72,13 @@ class Withdraw extends WithdrawModel |
|
|
|
if (!$this->validation($dealer, $data)) { |
|
|
|
if (!$this->validation($dealer, $data)) { |
|
|
|
return false; |
|
|
|
return false; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
//手续费 |
|
|
|
|
|
|
|
if(empty($data['is_invoice'])){ |
|
|
|
|
|
|
|
$commission = \app\api\model\Setting::getFinanceCommission(); |
|
|
|
|
|
|
|
if (empty($commission)) { |
|
|
|
|
|
|
|
$data['commission_price'] = bcmath($data['money'], $commission / 100, 2); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
// 事务处理 |
|
|
|
// 事务处理 |
|
|
|
$this->transaction(function () use ($dealer, $data) { |
|
|
|
$this->transaction(function () use ($dealer, $data) { |
|
|
|
// 新增申请记录 |
|
|
|
// 新增申请记录 |
|
|
@ -143,6 +150,7 @@ class Withdraw extends WithdrawModel |
|
|
|
$this->error = '请上传发票信息'; |
|
|
|
$this->error = '请上传发票信息'; |
|
|
|
return false; |
|
|
|
return false; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
return true; |
|
|
|
return true; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|