UserRecharge.php 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | CRMEB [ CRMEB赋能开发者,助力企业发展 ]
  4. // +----------------------------------------------------------------------
  5. // | Copyright (c) 2016~2020 https://www.crmeb.com All rights reserved.
  6. // +----------------------------------------------------------------------
  7. // | Licensed CRMEB并不是自由软件,未经许可不能去掉CRMEB相关版权
  8. // +----------------------------------------------------------------------
  9. // | Author: CRMEB Team <admin@crmeb.com>
  10. // +----------------------------------------------------------------------
  11. namespace app\admin\model\user;
  12. use traits\ModelTrait;
  13. use basic\ModelBasic;
  14. /**
  15. * 用户充值记录
  16. * Class UserRecharge
  17. * @package app\admin\model\user
  18. */
  19. class UserRecharge extends ModelBasic
  20. {
  21. use ModelTrait;
  22. public static function systemPage($where){
  23. $model = new self;
  24. $model = $model->alias('A');
  25. if($where['order_id'] != '') {
  26. $model = $model->where('A.order_id|B.nickname|A.id','like',"%$where[order_id]%");
  27. }
  28. $model = $model->where('A.paid',1);
  29. $model = $model->field('A.*,B.nickname');
  30. $model = $model->join('__USER__ B','A.uid = B.uid','RIGHT');
  31. $model = $model->order('A.id desc');
  32. return self::page($model,$where);
  33. }
  34. }