Member.php 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  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/framework
  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. $query = $this->_query($this->table)->like('nickname,phone')->equal('vip_level');
  39. $query->dateBetween('create_at')->order('id desc')->page();
  40. }
  41. /**
  42. * 数据列表处理
  43. * @param array $data
  44. */
  45. protected function _page_filter(&$data = [])
  46. {
  47. foreach ($data as &$vo) {
  48. $vo['nickname'] = emoji_decode($vo['nickname']);
  49. }
  50. }
  51. }