Member.php 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | framework
  4. // +----------------------------------------------------------------------
  5. // | 版权所有 2014~2018 广州楚才信息科技有限公司 [ http://www.cuci.cc ]
  6. // +----------------------------------------------------------------------
  7. // | 官方网站: http://framework.thinkadmin.top
  8. // +----------------------------------------------------------------------
  9. // | 开源协议 ( https://mit-license.org )
  10. // +----------------------------------------------------------------------
  11. // | github开源项目:https://github.com/zoujingli/ThinkAdmin
  12. // +----------------------------------------------------------------------
  13. namespace app\store\controller;
  14. use library\Controller;
  15. /**
  16. * 商城会员管理
  17. * Class Member
  18. * @package app\store\controller
  19. */
  20. class Member extends Controller
  21. {
  22. /**
  23. * 绑定数据表
  24. * @var string
  25. */
  26. protected $table = 'StoreMember';
  27. /**
  28. * 显示会员列表
  29. * @throws \think\Exception
  30. * @throws \think\db\exception\DataNotFoundException
  31. * @throws \think\db\exception\ModelNotFoundException
  32. * @throws \think\exception\DbException
  33. * @throws \think\exception\PDOException
  34. */
  35. public function index()
  36. {
  37. $this->title = '商城会员管理';
  38. $this->_query($this->table)->like('nickname,phone')->equal('vip_level')->dateBetween('create_at')->order('id desc')->page();
  39. }
  40. /**
  41. * 数据列表处理
  42. * @param array $data
  43. */
  44. protected function _page_filter(&$data = [])
  45. {
  46. foreach ($data as &$vo) {
  47. $vo['nickname'] = emoji_decode($vo['nickname']);
  48. }
  49. }
  50. }