party_id > 0) { $giftNotice = config("site.giftNotice"); $bigGiftNotice = config("site.bigGiftNotice"); $partyInfo = $giftUserParty->party; $money = $giftUserParty->value; $type = 0; if ($money >= $bigGiftNotice) { $type = 72; }elseif ($money >= $giftNotice){ $type = 71; } $type > 0 and QueueApi::sendGroupMessage($type, $giftUserParty->user->nickname, $giftUserParty->toUser->nickname, $partyInfo, $giftUserParty); } }); } */ public function user() { return $this->belongsTo('app\common\model\User', 'user_id', 'id', [], 'LEFT')->setEagerlyType(0); } public function toUser() { return $this->belongsTo('app\common\model\User', 'user_to_id', 'id', [], 'LEFT')->setEagerlyType(0); } public function party() { return $this->belongsTo('app\common\model\Party', 'party_id', 'id', [], 'LEFT')->setEagerlyType(0); } }