[]]], tags: ['Platforms'], responses: [ new OA\Response( response: 200, description: '获取成功', content: new OA\JsonContent(properties: [ new OA\Property(property: 'code', type: 'integer', example: 0), new OA\Property(property: 'message', type: 'string', example: '获取成功'), new OA\Property(property: 'data', type: 'array', items: new OA\Items( properties: [ new OA\Property(property: 'id', type: 'integer', example: 1), new OA\Property(property: 'developer_id', type: 'integer', example: 1), new OA\Property(property: 'created_at', type: 'string', format: 'date-time'), new OA\Property(property: 'updated_at', type: 'string', format: 'date-time'), ], type: 'object' )), ]) ), new OA\Response(response: 401, description: '未认证', content: new OA\JsonContent(ref: '#/components/schemas/ErrorResponse')), ] )] #[RequestMapping(path: "", methods: "GET")] #[Middleware(AuthMiddleware::class)] #[Middleware(PermissionMiddleware::class)] public function index(): array { $platforms = Platform::query()->orderBy('id')->get(); return [ 'code' => 0, 'message' => '获取成功', 'data' => $platforms, ]; } }