From e9d5cde4287af6b41b5d086a7a3cb250777892b2 Mon Sep 17 00:00:00 2001 From: dengbw Date: Wed, 8 Jun 2022 17:10:52 +0800 Subject: [PATCH] channel_608 --- admin/controllers/app/licheb/Channel.php | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/admin/controllers/app/licheb/Channel.php b/admin/controllers/app/licheb/Channel.php index ae95bed0..fb4c9dd4 100644 --- a/admin/controllers/app/licheb/Channel.php +++ b/admin/controllers/app/licheb/Channel.php @@ -26,9 +26,9 @@ class Channel extends HD_Controller { $params = $this->input->get(); $params['page'] = $params['page'] ? intval($params['page']) : 1; - $params['size'] = $params['size'] ? intval($params['size']) : 20; + $params['size'] = $params['size'] ? intval($params['size']) : 50; $lists = []; - $where = ['group_id' => 4, 'status' => 1]; + $where = ['group_id' => 4, 'status' => 1, 'biz_id<>' => 0]; if ($params['uname']) { $where['uname like "%' . $params['uname'] . '%"'] = null; } @@ -45,12 +45,16 @@ class Channel extends HD_Controller ->join('lc_biz', 'lc_biz.id = lc_app_licheb_channel_biz.biz_id', 'left') ->where(['lc_app_licheb_channel_biz.uid' => $value['id'], 'lc_biz.status' => 1]) ->count_all_results('lc_app_licheb_channel_biz'); - $setValue['id'] = $value['id']; - $setValue['uname'] = $value['uname']; - $setValue['mobile'] = $value['mobile']; - $setValue['bizs'] = $bizs; - $setValue['c_time'] = date('Y-m-d H:i:s', $value['c_time']); - $lists[] = $setValue; + if ($bizs > 0) { + $setValue['id'] = $value['id']; + $setValue['uname'] = $value['uname']; + $setValue['mobile'] = $value['mobile']; + $setValue['bizs'] = $bizs; + $setValue['c_time'] = date('Y-m-d H:i:s', $value['c_time']); + $lists[] = $setValue; + } else { + $count--; + } } } $this->data['lists'] = $lists;