64], ]; } /** * {@inheritdoc} */ public function attributeLabels() { return [ 'id' => 'ID', 'mall_id' => 'Mall ID', 'user_id' => 'User ID', 'invite_code' => 'Invite Code', 'num' => 'Num', 'created_at' => 'Created At', 'updated_at' => 'Updated At', ]; } /** * 关联用户表 */ public function getUser() { return $this->hasOne(User::class,['id'=>'user_id'])->select('nickname,avatar_url,mobile,username,id,created_at'); } }