|
|
|
@ -366,11 +366,8 @@ class PaymentController extends BaseController
|
|
|
|
|
{
|
|
|
|
|
$mobile = $_REQUEST['mobile'];
|
|
|
|
|
$verify = $_REQUEST['verify'];
|
|
|
|
|
/* 检测验证码 TODO: */
|
|
|
|
|
if($verify !== 'txsb0601'){
|
|
|
|
|
if (!$this->checksafecode($this->admininfo['mobile'], $verify)) {
|
|
|
|
|
$this->error('验证码错误');
|
|
|
|
|
}
|
|
|
|
|
if (!$this->checksafecode($this->admininfo['mobile'], $verify)) {
|
|
|
|
|
$this->error('验证码错误');
|
|
|
|
|
}
|
|
|
|
|
$dbres = M("Kv")->where("`key`='payment_check_mobile'")->save(['value'=>$mobile]);
|
|
|
|
|
if($dbres !== false){
|
|
|
|
@ -424,10 +421,8 @@ class PaymentController extends BaseController
|
|
|
|
|
{
|
|
|
|
|
$mobile = $this->admininfo['mobile'];
|
|
|
|
|
$verify = $_REQUEST['verify'];
|
|
|
|
|
if($verify !== 'txsb0601'){
|
|
|
|
|
if (!A("Public")->checksafecode($mobile, $verify)) {
|
|
|
|
|
$this->ajaxReturn(["error"=>"验证码错误"]);
|
|
|
|
|
}
|
|
|
|
|
if (!A("Public")->checksafecode($mobile, $verify)) {
|
|
|
|
|
$this->ajaxReturn(["error"=>"验证码错误"]);
|
|
|
|
|
}
|
|
|
|
|
$this->ajaxReturn(["success"=>"验证码验证成功","data"=>[]]);
|
|
|
|
|
}
|
|
|
|
@ -440,15 +435,13 @@ class PaymentController extends BaseController
|
|
|
|
|
Vendor("Alipay2020/Fund");
|
|
|
|
|
$fund = new \Fund();
|
|
|
|
|
|
|
|
|
|
//
|
|
|
|
|
$dbres = M("company_statement_info","tab_")->where("id='{$id}'")->find();
|
|
|
|
|
$company_info = json_decode($dbres['company_info'],true);
|
|
|
|
|
//TODO:未进行真实打款
|
|
|
|
|
|
|
|
|
|
if($dbres['pay_status'] != 1 && $dbres['verify_status'] == 1){
|
|
|
|
|
//执行打款
|
|
|
|
|
$title = "测试-".$dbres['company_name']."结算";
|
|
|
|
|
$title = $dbres['company_name']."结算";
|
|
|
|
|
$amount = $dbres['statement_money'];
|
|
|
|
|
$amount = 0.1;//测试金额为0
|
|
|
|
|
$payres = $fund->transfer($company_info['ali_account'],$company_info['ali_user'],$dbres['statement_num'],$amount, $title);
|
|
|
|
|
$resultCode = $payres->code;
|
|
|
|
|
|
|
|
|
|