diff --git a/app/agent/controller/Account.php b/app/agent/controller/Account.php index ca98568..7c9600d 100644 --- a/app/agent/controller/Account.php +++ b/app/agent/controller/Account.php @@ -57,6 +57,27 @@ class Account extends Controller if (!empty($get_data['keyWord'])){ $where['Account'] = ['like','%'.$get_data['keyWord'].'%']; } + //根据账号过期时间 + if ($get_data['ExpirdDay'] > -100) + { + + if (mb_strlen($where_str)>0){ + $where_str .= ' AND '; + } + if ($get_data['ExpirdDay'] == 0) + { + $where_str .= ' EndTime-4) { + $where_str .= ' TO_DAYS(EndTime) - (TO_DAYS(now()))>='.$get_data['ExpirdDay'].' AND EndTime < now() '; + } elseif ($get_data['ExpirdDay']==-4) { + $where_str .= 'TO_DAYS(EndTime) - (TO_DAYS(now()))<='.$get_data['ExpirdDay'].' '; + } elseif ($get_data['ExpirdDay'] > 0){ + $where_str .= ' TO_DAYS(EndTime) - (TO_DAYS(now()))<='.$get_data['ExpirdDay'].' AND EndTime>now() '; + // $where2 .= ' AND EndTime