|
@@ -20,6 +20,7 @@ class Gift extends Api
|
|
$this->gifttypeModel = new \app\common\model\GiftType();
|
|
$this->gifttypeModel = new \app\common\model\GiftType();
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ //仅用来测试
|
|
public function test2(){
|
|
public function test2(){
|
|
$user_id = $this->auth->id;
|
|
$user_id = $this->auth->id;
|
|
$gift_id = input('gift_id');
|
|
$gift_id = input('gift_id');
|
|
@@ -35,6 +36,7 @@ class Gift extends Api
|
|
}
|
|
}
|
|
|
|
|
|
//gift_id必须是爆币礼物才可以
|
|
//gift_id必须是爆币礼物才可以
|
|
|
|
+ //仅用来测试
|
|
public function baobi($user_id,$gift_id,$pay_total){
|
|
public function baobi($user_id,$gift_id,$pay_total){
|
|
|
|
|
|
//奖项参数
|
|
//奖项参数
|
|
@@ -219,24 +221,6 @@ class Gift extends Api
|
|
$this->success("获取成功!", $list);
|
|
$this->success("获取成功!", $list);
|
|
}
|
|
}
|
|
|
|
|
|
- /**
|
|
|
|
- * 获取我的礼物墙
|
|
|
|
- */
|
|
|
|
- public function getMyGiftWall_typing() {
|
|
|
|
- $user_id = input("user_id", 0);
|
|
|
|
-
|
|
|
|
- $userid = $user_id ? $user_id : $this->auth->id;
|
|
|
|
-
|
|
|
|
- $list = Db::name('gift_user_typing')->alias('log')
|
|
|
|
- ->join('gift', 'gift.id = log.gift_id', 'LEFT')
|
|
|
|
- ->field('log.*,sum(number) as number,gift.name,gift.image,gift.special')
|
|
|
|
- ->where(['log.user_to_id' => $userid])
|
|
|
|
- ->group('log.gift_id')
|
|
|
|
- ->order('gift.price desc')
|
|
|
|
- ->select();
|
|
|
|
- $list = list_domain_image($list,['image','special']);
|
|
|
|
- $this->success("获取成功!", $list);
|
|
|
|
- }
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
* 获取我的收送礼明细
|
|
* 获取我的收送礼明细
|
|
@@ -266,9 +250,9 @@ class Gift extends Api
|
|
|
|
|
|
foreach($list as $key => $val){
|
|
foreach($list as $key => $val){
|
|
if($type == 1){
|
|
if($type == 1){
|
|
- $remark = '赠送'.$val['nickname'].','.$val['gift_name'].'*'.$val['number'].',价值'.$val['value'].'钻石';
|
|
|
|
|
|
+ $remark = '送给Ta '.$val['gift_name'].'*'.$val['number'];
|
|
}else{
|
|
}else{
|
|
- $remark = $val['nickname'].'赠送,'.$val['gift_name'].'*'.$val['number'].',价值'.$val['value'].'钻石';
|
|
|
|
|
|
+ $remark = '送给你 '.$val['gift_name'].'*'.$val['number'];
|
|
}
|
|
}
|
|
$rs[] = [
|
|
$rs[] = [
|
|
'id' => $val['id'],
|
|
'id' => $val['id'],
|
|
@@ -278,6 +262,7 @@ class Gift extends Api
|
|
'nickname' => $val['nickname'],
|
|
'nickname' => $val['nickname'],
|
|
'avatar' => $val['avatar'],
|
|
'avatar' => $val['avatar'],
|
|
'gender' => $val['gender'],
|
|
'gender' => $val['gender'],
|
|
|
|
+ 'user_id' => $type == 1 ? $val['user_to_id'] : $val['user_id'],
|
|
];
|
|
];
|
|
}
|
|
}
|
|
$this->success(1,$rs);
|
|
$this->success(1,$rs);
|