生成下游个人结算单bug修改

master
zhengyongxing 5 years ago
parent 3b47c94b1e
commit 938a82e993

@ -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);

Loading…
Cancel
Save