cp 等级升级 装扮挂件和特效修改
This commit is contained in:
@@ -248,20 +248,23 @@ class UserCp extends Model
|
|||||||
|
|
||||||
//添加一个记录
|
//添加一个记录
|
||||||
$pendant = db::name('vs_decorate_price')->where('id',$level['pendant_id'])->field('did,day')->find();
|
$pendant = db::name('vs_decorate_price')->where('id',$level['pendant_id'])->field('did,day')->find();
|
||||||
$pendant_title = '装扮-'.$pendant['day'].'天-'.db::name('vs_decorate')->where('did',$pendant['did'])->value('title');
|
if($pendant){
|
||||||
$datas = [
|
$pendant_title = '装扮-'.$pendant['day'].'天-'.db::name('vs_decorate')->where('did',$pendant['did'])->value('title');
|
||||||
'room_id' => $room_id,
|
$datas = [
|
||||||
'from_user_id' => $from_user_id,
|
'room_id' => $room_id,
|
||||||
'to_user_id' => $to_user_id,
|
'from_user_id' => $from_user_id,
|
||||||
'gift_id' => 0,
|
'to_user_id' => $to_user_id,
|
||||||
'num' => 0,
|
'gift_id' => 0,
|
||||||
'cp_zone_id' => $cp_zone_id,
|
'num' => 0,
|
||||||
'exp' => 0,
|
'cp_zone_id' => $cp_zone_id,
|
||||||
'exp_total' => 0,
|
'exp' => 0,
|
||||||
'remark' => '我们等级达到了'.$level['level'].'级,获得奖励'.$pendant_title,
|
'exp_total' => 0,
|
||||||
'createtime' => time(),
|
'remark' => '我们等级达到了'.$level['level'].'级,获得奖励'.$pendant_title,
|
||||||
];
|
'createtime' => time(),
|
||||||
Db::name('user_cp_gift_log')->insert($datas);
|
];
|
||||||
|
Db::name('user_cp_gift_log')->insert($datas);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
$data['exp'] = $yuan_exp + $exp;
|
$data['exp'] = $yuan_exp + $exp;
|
||||||
Db::name('user_cp_zone')->where(['id' => $cp_zone_id])->update($data);
|
Db::name('user_cp_zone')->where(['id' => $cp_zone_id])->update($data);
|
||||||
|
|||||||
Reference in New Issue
Block a user