diff --git a/app/controller/api/user/User.php b/app/controller/api/user/User.php index 3a0ede6..c997b53 100755 --- a/app/controller/api/user/User.php +++ b/app/controller/api/user/User.php @@ -63,12 +63,12 @@ class User extends BaseController $where = array(); $where[] = array('uid', '=', $uid); - $where[] = array('create_time', '>=', date('Y-m-d 00:00:00')); + $where[] = array('create_time', '>=', date('Y-m-d')." 00:00:00"); $where[] = array('type', 'in', [1, 2]); - $list = $recordRepository->selectWhere($where); + $logList = $recordRepository->selectWhere($where); $config = $assetsRepository->getConfig(); - if($list && count($list) >= 1){ + if($logList && count($logList) >= 1){ $assets = $assetsRepository->assets($uid); if($assets['diamond'] < $config['lotteryPayDiamond']){ return app('json')->fail('钻石不足'); @@ -86,7 +86,7 @@ class User extends BaseController } } - if($list && count($list) >= 1 && $current['type'] != 3){ + if($logList && count($logList) >= 1 && $current['type'] != 3){ $assetsRepository->lottery($uid, -$config['lotteryPayDiamond']); }