|
@@ -1009,6 +1009,15 @@ class Party extends Api
|
|
|
|
|
|
$this->redis->hDel("livingUser", $this->auth->id);
|
|
|
|
|
|
+
|
|
|
+ $key = "party_seat_".$party_id;
|
|
|
+ $seats = $this->redis->hGetAll($key);
|
|
|
+ foreach($seats as $seat_num => $seatuserid){
|
|
|
+ if($seatuserid == $userId){
|
|
|
+ $this->redis->HDel($key, $seat_num);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
$partyInfo = $this->redis->get($this->roomTypeArr[$room_type].'_'.$party_id);
|
|
|
if ($partyInfo) {
|
|
@@ -1027,14 +1036,7 @@ class Party extends Api
|
|
|
];
|
|
|
$easemob->room_setRoomCustomAttributeForced($partyInfo['easemob_room_id'],$partyInfo['user_id'],$matedata);
|
|
|
|
|
|
-
|
|
|
- $key = "party_seat_".$party_id;
|
|
|
- $seats = $this->redis->hGetAll($key);
|
|
|
- foreach($seats as $seat_num => $seatuserid){
|
|
|
- if($seatuserid == $userId){
|
|
|
- $this->redis->HDel($key, $seat_num);
|
|
|
- }
|
|
|
- }
|
|
|
+
|
|
|
|
|
|
|
|
|
|
|
@@ -2442,6 +2444,16 @@ class Party extends Api
|
|
|
$this->error('麦上有人了');
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+ $key = "party_seat_".$party_id;
|
|
|
+ $seats = $this->redis->hGetAll($key);
|
|
|
+ foreach($seats as $seat_num => $seatuserid){
|
|
|
+ if($seatuserid == $userId){
|
|
|
+ $this->redis->HDel($key, $seat_num);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
$this->redis->hSet($key,$seat_num,$userId);
|
|
|
|
|
|
|