|
@@ -128,6 +128,13 @@ class Gift extends Api
|
|
|
$user_id = $this->auth->id;
|
|
|
$type = input('type',1);
|
|
|
|
|
|
+ //普通礼物 还是幸运礼物
|
|
|
+ $where_baobi = [];
|
|
|
+ $is_baobi = input('is_baobi','all');
|
|
|
+ if($is_baobi == 0){
|
|
|
+ $where_baobi['gup.is_baobi'] = 0;
|
|
|
+ }
|
|
|
+
|
|
|
$where = [];
|
|
|
if($type == 1){
|
|
|
$where['user_id'] = $user_id;//我送出
|
|
@@ -139,7 +146,7 @@ class Gift extends Api
|
|
|
|
|
|
$list = Db::name('gift_user_party')->alias('gup')
|
|
|
->join('user',$joinstr,'LEFT')->field('gup.*,user.nickname,user.avatar,user.gender')
|
|
|
- ->where($where)->order('id desc')->autopage()->select();
|
|
|
+ ->where($where)->where($where_baobi)->order('id desc')->autopage()->select();
|
|
|
$list = list_domain_image($list,['gift_gif_image','avatar']);
|
|
|
|
|
|
$rs = [];
|