From 938a82e993c4b8a6f2d16f420840386a9b48e4c2 Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Fri, 14 Feb 2020 17:16:06 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=9F=E6=88=90=E4=B8=8B=E6=B8=B8=E4=B8=AA?= =?UTF-8?q?=E4=BA=BA=E7=BB=93=E7=AE=97=E5=8D=95bug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StatementMangementController.class.php | 64 ++++++++++--------- 1 file changed, 34 insertions(+), 30 deletions(-) diff --git a/Application/Admin/Controller/StatementMangementController.class.php b/Application/Admin/Controller/StatementMangementController.class.php index c1040fa63..82a405986 100644 --- a/Application/Admin/Controller/StatementMangementController.class.php +++ b/Application/Admin/Controller/StatementMangementController.class.php @@ -599,38 +599,42 @@ class StatementMangementController extends ThinkController ->select(); // dump($data);die(); -// $statement = M('statement','tab_') -// ->field('ext_field') -// ->where(['ext_field'=>['like','%,%']]) -// ->select(); -// -// $withdrawData = []; -// -// foreach($statement as $key => $value) { -// -// $handleData = explode(',',$value['ext_field']); -// -// foreach ($handleData as $hk => $hv) { -// array_push($withdrawData,$hv); -// } -// -// } -// -// foreach ($data as $key => $value) { -// $data[$key]['settlement_begin_time'] = date("Y-m-d H:i:s", $data[$key]['settlement_begin_time']); -// $data[$key]['settlement_end_time'] = date("Y-m-d H:i:s", $data[$key]['settlement_end_time']); -// -// if (in_array($value['widthdraw_number'],$withdrawData)) { -// unset($data[$key]); -// } -// -// } -// -// foreach ($data as $key => $value) { + $statement = M('statement','tab_') + ->field('ext_field') + ->where(['ext_field'=>['like','%,%']]) + ->select(); + + $withdrawData = []; + + foreach($statement as $key => $value) { + + $handleData = explode(',',$value['ext_field']); + + foreach ($handleData as $hk => $hv) { + array_push($withdrawData,$hv); + } + + } + + $thisWithdraw = explode(',',$_REQUEST['withdraw']); + + foreach ($data as $key => $value) { // $data[$key]['settlement_begin_time'] = date("Y-m-d H:i:s", $data[$key]['settlement_begin_time']); // $data[$key]['settlement_end_time'] = date("Y-m-d H:i:s", $data[$key]['settlement_end_time']); -// -// } + +// var_dump($value['widthdraw_number'].$_REQUEST['withdraw']);die(); + + if (in_array($value['widthdraw_number'],$withdrawData)&&!in_array($value['widthdraw_number'],$thisWithdraw)) { + unset($data[$key]); + } + + } + + foreach ($data as $key => $value) { + $data[$key]['settlement_begin_time'] = date("Y-m-d H:i:s", $data[$key]['settlement_begin_time']); + $data[$key]['settlement_end_time'] = date("Y-m-d H:i:s", $data[$key]['settlement_end_time']); + + } $this->assign('withdraw_data',$data);