From 5957ffddcf0c7f3de3a14173446a64fe8fe70072 Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Mon, 22 Jun 2020 15:45:33 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=B1=87=E6=80=BB=E5=8D=95=E4=BB=A3?= =?UTF-8?q?=E7=A0=81=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controller/WithdrawController.class.php | 32 +++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/Application/Home/Controller/WithdrawController.class.php b/Application/Home/Controller/WithdrawController.class.php index 4a5472841..8c946ecf0 100644 --- a/Application/Home/Controller/WithdrawController.class.php +++ b/Application/Home/Controller/WithdrawController.class.php @@ -24,6 +24,15 @@ class WithdrawController extends BaseController $row=10; if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;} + + $id = get_pid(); + $safePwd = M('promote','tab_')->where(['id'=>$id])->field('second_pwd')->find(); + if(empty($safePwd['second_pwd'])) { + $this->display('Public/setSafePwd'); + exit; + } + + $map = []; $map["promote.id"] = get_pid(); @@ -90,7 +99,12 @@ class WithdrawController extends BaseController public function doPayment() { - + $id = get_pid(); + $safePwd = M('promote','tab_')->where(['id'=>$id])->field('second_pwd')->find(); + if(empty($safePwd['second_pwd'])) { + $this->display('Public/setSafePwd'); + exit; + } $id = $_REQUEST['id']; $remark = $_REQUEST['remark']; @@ -106,7 +120,7 @@ class WithdrawController extends BaseController //执行打款 $title = "测试-".$dbres['company_name']."结算"; $amount = $dbres['statement_money']; -// $amount = 0.1;//测试金额为0 + $amount = 0.1;//测试金额为0 $payres = $fund->transfer($company_info['ali_account'],$company_info['ali_user'],$dbres['statement_num'],$amount, $title); $resultCode = $payres->code; @@ -167,6 +181,13 @@ class WithdrawController extends BaseController public function withdrawDetail() { + $id = get_pid(); + $safePwd = M('promote','tab_')->where(['id'=>$id])->field('second_pwd')->find(); + if(empty($safePwd['second_pwd'])) { + $this->display('Public/setSafePwd'); + exit; + } + $id = $_REQUEST["id"]; $dbres = M("company_statement_info","tab_") @@ -222,6 +243,13 @@ class WithdrawController extends BaseController public function withdrawOrderDetail($p=0) { + $id = get_pid(); + $safePwd = M('promote','tab_')->where(['id'=>$id])->field('second_pwd')->find(); + if(empty($safePwd['second_pwd'])) { + $this->display('Public/setSafePwd'); + exit; + } + $page = intval($p); $page = $page ? $page : 1; //默认显示第一页数据 $row=10; From f321c6259de7602446c64b8ab0ca3659dbc6de31 Mon Sep 17 00:00:00 2001 From: chenzhi Date: Mon, 22 Jun 2020 15:47:19 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=B0=B8=E6=98=9F=E5=90=88=E5=B9=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Home/Controller/WithdrawController.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Application/Home/Controller/WithdrawController.class.php b/Application/Home/Controller/WithdrawController.class.php index 8c946ecf0..0558c03c7 100644 --- a/Application/Home/Controller/WithdrawController.class.php +++ b/Application/Home/Controller/WithdrawController.class.php @@ -115,11 +115,12 @@ class WithdrawController extends BaseController $dbres = M("company_statement_info","tab_")->where("id='{$id}'")->find(); // $this->ajaxReturn(["msg"=>"打款成功","data"=>$dbres,"status"=>1]);die(); $company_info = json_decode($dbres['company_info'],true); - //TODO:未进行真实打款 + if($dbres['pay_status'] != 1 && $dbres['verify_status'] == 1){ //执行打款 $title = "测试-".$dbres['company_name']."结算"; $amount = $dbres['statement_money']; + //TODO:线上要关闭这个 $amount = 0.1;//测试金额为0 $payres = $fund->transfer($company_info['ali_account'],$company_info['ali_user'],$dbres['statement_num'],$amount, $title); $resultCode = $payres->code;