阶段更新

This commit is contained in:
2023-01-12 14:47:38 +08:00
parent 088dd64b2f
commit 5b8901281c
626 changed files with 39326 additions and 12 deletions

View File

@@ -0,0 +1,26 @@
<?php
namespace Modules\User\Http\Resources;
use Illuminate\Http\Resources\Json\JsonResource;
class UserInfoBaseResource extends JsonResource
{
public function toArray($request): array
{
return [
'user_id' => $this->id,
'username' => $this->username,
'nickname' => $this->info->nickname ?? '',
'avatar' => $this->info->avatar ?? '',
// 'sign' => $this->getSignData(),
'identity' => new UserIdentityBaseResource($this->identities->first()),
'status' => $this->getStateData(),
'canPick' => $this->canPick(),
'nowStatus' => $this->getNowStatus(),
'tag' => $this->tag
];
}
}