Skip to content

Commit

Permalink
Prod build
Browse files Browse the repository at this point in the history
  • Loading branch information
ok200paul committed Aug 20, 2024
1 parent e8a6041 commit 854c867
Show file tree
Hide file tree
Showing 50 changed files with 1,230 additions and 2,137 deletions.
42 changes: 35 additions & 7 deletions app/Http/Controllers/Api/V1/ApiMyTeamController.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,13 @@
use App\Models\Team;
use Illuminate\Http\JsonResponse;
use Illuminate\Support\Facades\Auth;
use Knuckles\Scribe\Attributes\Authenticated;
use Knuckles\Scribe\Attributes\Endpoint;
use Knuckles\Scribe\Attributes\Group;
use Knuckles\Scribe\Attributes\QueryParam;
use Knuckles\Scribe\Attributes\Response;

#[Group('/my-team', 'Retrieve your team details.')]
class ApiMyTeamController extends Controller
{
use HandlesAPIRequests;
Expand All @@ -34,6 +40,31 @@ class ApiMyTeamController extends Controller
*
* @throws DisallowedApiFieldException
*/
#[Endpoint(
title : 'GET /',
description : 'Retrieve your team. Automatically filtered to your current team.',
authenticated: true
)]
#[Authenticated]
#[QueryParam(
name : 'cached',
type : 'bool',
description: 'Request the response to be cached. Default: `true`.',
required : false,
example : true
)]
#[QueryParam(
name : 'fields',
type : 'string',
description: 'Comma-separated list of database fields to return within the object.',
required : false,
example : 'id,created_at'
)]
#[Response(
content : '{"meta": {"responseCode": 200, "limit": 50, "offset": 0, "message": "", "cached": false, "availableRelations": []}, "data": {"current_page": 1, "data": {"id": 1, "name": "Team A", "created_at": "2024-08-16T06:54:28.000000Z", "updated_at": "2024-08-16T06:54:28.000000Z", "deleted_at": null}], "first_page_url": "https:\/\/vine.test\/api\/v1\/my-teams?page=1", "from": 1, "last_page": 1, "last_page_url": "https:\/\/vine.test\/api\/v1\/my-teams?page=1", "links": [{"url": null, "label": "« Previous", "active": false}, {"url": "https:\/\/vine.test\/api\/v1\/my-teams?page=1", "label": "1", "active": true}, {"url": null, "label": "Next »", "active": false}], "next_page_url": null, "path": "https:\/\/vine.test\/api\/v1\/my-teams", "per_page": 50, "prev_page_url": null, "to": 2, "total": 2}}',
status : 200,
description: ''
)]
public function index(): JsonResponse
{
$this->query = Team::with($this->associatedData);
Expand All @@ -45,7 +76,7 @@ public function index(): JsonResponse

/**
* POST /
*
* @hideFromAPIDocumentation
* @return JsonResponse
*/
public function store(): JsonResponse
Expand All @@ -58,9 +89,8 @@ public function store(): JsonResponse

/**
* GET / {id}
*
* @hideFromAPIDocumentation
* @param string $id
*
* @return JsonResponse
*/
public function show(string $id)
Expand All @@ -73,9 +103,8 @@ public function show(string $id)

/**
* PUT / {id}
*
* @hideFromAPIDocumentation
* @param string $id
*
* @return JsonResponse
*/
public function update(string $id)
Expand All @@ -88,9 +117,8 @@ public function update(string $id)

/**
* DELETE / {id}
*
* @hideFromAPIDocumentation
* @param string $id
*
* @return JsonResponse
*/
public function destroy(string $id)
Expand Down
1 change: 1 addition & 0 deletions public/build/assets/APIAccessToken-DKItmpSR.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion public/build/assets/APIAccessToken-eOpyExcQ.js

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion public/build/assets/AdminHome-C5ORN28T.js

This file was deleted.

Loading

0 comments on commit 854c867

Please sign in to comment.