2021-03-25 17:32:36 +08:00
|
|
|
<?php
|
|
|
|
declare (strict_types=1);
|
|
|
|
|
|
|
|
namespace App\Model\Group;
|
|
|
|
|
|
|
|
use App\Model\BaseModel;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 聊天群组[成员]数据表模型
|
|
|
|
*
|
2021-04-20 16:30:57 +08:00
|
|
|
* @property integer $id 群成员ID
|
|
|
|
* @property integer $group_id 群组ID
|
|
|
|
* @property integer $user_id 用户ID
|
|
|
|
* @property integer $leader 成员属性[0:普通成员;1:管理员;2:群主;]
|
|
|
|
* @property integer $is_mute 是否禁言[0:否;1:是;]
|
|
|
|
* @property integer $is_quit 是否退群[0:否;1:是;]
|
|
|
|
* @property string $user_card 群名片
|
|
|
|
* @property string $created_at 入群时间
|
|
|
|
* @property string $deleted_at 退群时间
|
2021-03-25 17:32:36 +08:00
|
|
|
* @package App\Model\Group
|
|
|
|
*/
|
|
|
|
class GroupMember extends BaseModel
|
|
|
|
{
|
|
|
|
protected $table = 'group_member';
|
|
|
|
|
|
|
|
protected $fillable = [
|
|
|
|
'group_id',
|
|
|
|
'user_id',
|
|
|
|
'leader',
|
|
|
|
'is_mute',
|
|
|
|
'is_quit',
|
|
|
|
'user_card',
|
|
|
|
'created_at',
|
2022-01-16 14:22:53 +08:00
|
|
|
'updated_at',
|
2021-03-25 17:32:36 +08:00
|
|
|
'deleted_at',
|
|
|
|
];
|
|
|
|
|
|
|
|
protected $casts = [
|
2021-03-26 22:03:11 +08:00
|
|
|
'group_id' => 'integer',
|
|
|
|
'user_id' => 'integer',
|
|
|
|
'leader' => 'integer',
|
|
|
|
'is_mute' => 'integer',
|
|
|
|
'is_quit' => 'integer',
|
2021-03-25 17:32:36 +08:00
|
|
|
'created_at' => 'datetime',
|
2022-01-16 14:22:53 +08:00
|
|
|
'updated_at' => 'datetime',
|
2021-03-25 17:32:36 +08:00
|
|
|
'deleted_at' => 'datetime',
|
|
|
|
];
|
|
|
|
}
|