feat: update users controller
This commit is contained in:
parent
94b0345f2b
commit
e672daaede
|
|
@ -47,6 +47,7 @@ func NewUsersController(usersService service.UsersService) UsersController {
|
||||||
// @Description API for getting all Users
|
// @Description API for getting all Users
|
||||||
// @Tags Users
|
// @Tags Users
|
||||||
// @Security Bearer
|
// @Security Bearer
|
||||||
|
// @Param Authorization header string false "Insert your access token" default(Bearer <Add access token here>)
|
||||||
// @Param req query request.UsersQueryRequest false "query parameters"
|
// @Param req query request.UsersQueryRequest false "query parameters"
|
||||||
// @Param req query paginator.Pagination false "pagination parameters"
|
// @Param req query paginator.Pagination false "pagination parameters"
|
||||||
// @Success 200 {object} response.Response
|
// @Success 200 {object} response.Response
|
||||||
|
|
@ -95,6 +96,7 @@ func (_i *usersController) All(c *fiber.Ctx) error {
|
||||||
// @Description API for getting one Users
|
// @Description API for getting one Users
|
||||||
// @Tags Users
|
// @Tags Users
|
||||||
// @Security Bearer
|
// @Security Bearer
|
||||||
|
// @Param Authorization header string false "Insert your access token" default(Bearer <Add access token here>)
|
||||||
// @Param id path int true "Users ID"
|
// @Param id path int true "Users ID"
|
||||||
// @Success 200 {object} response.Response
|
// @Success 200 {object} response.Response
|
||||||
// @Failure 400 {object} response.BadRequestError
|
// @Failure 400 {object} response.BadRequestError
|
||||||
|
|
@ -210,6 +212,7 @@ func (_i *usersController) Save(c *fiber.Ctx) error {
|
||||||
// @Tags Users
|
// @Tags Users
|
||||||
// @Security Bearer
|
// @Security Bearer
|
||||||
// @Param X-Csrf-Token header string true "Insert the X-Csrf-Token"
|
// @Param X-Csrf-Token header string true "Insert the X-Csrf-Token"
|
||||||
|
// @Param Authorization header string false "Insert your access token" default(Bearer <Add access token here>)
|
||||||
// @Param id path int true "Users ID"
|
// @Param id path int true "Users ID"
|
||||||
// @Param payload body request.UsersUpdateRequest true "Required payload"
|
// @Param payload body request.UsersUpdateRequest true "Required payload"
|
||||||
// @Success 200 {object} response.Response
|
// @Success 200 {object} response.Response
|
||||||
|
|
|
||||||
|
|
@ -13674,6 +13674,13 @@ const docTemplate = `{
|
||||||
],
|
],
|
||||||
"summary": "Get all Users",
|
"summary": "Get all Users",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
|
{
|
||||||
|
"type": "string",
|
||||||
|
"default": "Bearer \u003cAdd access token here\u003e",
|
||||||
|
"description": "Insert your access token",
|
||||||
|
"name": "Authorization",
|
||||||
|
"in": "header"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"name": "degree",
|
"name": "degree",
|
||||||
|
|
@ -13884,6 +13891,13 @@ const docTemplate = `{
|
||||||
],
|
],
|
||||||
"summary": "Get one Users",
|
"summary": "Get one Users",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
|
{
|
||||||
|
"type": "string",
|
||||||
|
"default": "Bearer \u003cAdd access token here\u003e",
|
||||||
|
"description": "Insert your access token",
|
||||||
|
"name": "Authorization",
|
||||||
|
"in": "header"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"type": "integer",
|
"type": "integer",
|
||||||
"description": "Users ID",
|
"description": "Users ID",
|
||||||
|
|
@ -14567,6 +14581,13 @@ const docTemplate = `{
|
||||||
"in": "header",
|
"in": "header",
|
||||||
"required": true
|
"required": true
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"type": "string",
|
||||||
|
"default": "Bearer \u003cAdd access token here\u003e",
|
||||||
|
"description": "Insert your access token",
|
||||||
|
"name": "Authorization",
|
||||||
|
"in": "header"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"type": "integer",
|
"type": "integer",
|
||||||
"description": "Users ID",
|
"description": "Users ID",
|
||||||
|
|
|
||||||
|
|
@ -13663,6 +13663,13 @@
|
||||||
],
|
],
|
||||||
"summary": "Get all Users",
|
"summary": "Get all Users",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
|
{
|
||||||
|
"type": "string",
|
||||||
|
"default": "Bearer \u003cAdd access token here\u003e",
|
||||||
|
"description": "Insert your access token",
|
||||||
|
"name": "Authorization",
|
||||||
|
"in": "header"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"name": "degree",
|
"name": "degree",
|
||||||
|
|
@ -13873,6 +13880,13 @@
|
||||||
],
|
],
|
||||||
"summary": "Get one Users",
|
"summary": "Get one Users",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
|
{
|
||||||
|
"type": "string",
|
||||||
|
"default": "Bearer \u003cAdd access token here\u003e",
|
||||||
|
"description": "Insert your access token",
|
||||||
|
"name": "Authorization",
|
||||||
|
"in": "header"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"type": "integer",
|
"type": "integer",
|
||||||
"description": "Users ID",
|
"description": "Users ID",
|
||||||
|
|
@ -14556,6 +14570,13 @@
|
||||||
"in": "header",
|
"in": "header",
|
||||||
"required": true
|
"required": true
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"type": "string",
|
||||||
|
"default": "Bearer \u003cAdd access token here\u003e",
|
||||||
|
"description": "Insert your access token",
|
||||||
|
"name": "Authorization",
|
||||||
|
"in": "header"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"type": "integer",
|
"type": "integer",
|
||||||
"description": "Users ID",
|
"description": "Users ID",
|
||||||
|
|
|
||||||
|
|
@ -10067,6 +10067,11 @@ paths:
|
||||||
get:
|
get:
|
||||||
description: API for getting all Users
|
description: API for getting all Users
|
||||||
parameters:
|
parameters:
|
||||||
|
- default: Bearer <Add access token here>
|
||||||
|
description: Insert your access token
|
||||||
|
in: header
|
||||||
|
name: Authorization
|
||||||
|
type: string
|
||||||
- in: query
|
- in: query
|
||||||
name: degree
|
name: degree
|
||||||
type: string
|
type: string
|
||||||
|
|
@ -10237,6 +10242,11 @@ paths:
|
||||||
name: X-Csrf-Token
|
name: X-Csrf-Token
|
||||||
required: true
|
required: true
|
||||||
type: string
|
type: string
|
||||||
|
- default: Bearer <Add access token here>
|
||||||
|
description: Insert your access token
|
||||||
|
in: header
|
||||||
|
name: Authorization
|
||||||
|
type: string
|
||||||
- description: Users ID
|
- description: Users ID
|
||||||
in: path
|
in: path
|
||||||
name: id
|
name: id
|
||||||
|
|
@ -10274,6 +10284,11 @@ paths:
|
||||||
get:
|
get:
|
||||||
description: API for getting one Users
|
description: API for getting one Users
|
||||||
parameters:
|
parameters:
|
||||||
|
- default: Bearer <Add access token here>
|
||||||
|
description: Insert your access token
|
||||||
|
in: header
|
||||||
|
name: Authorization
|
||||||
|
type: string
|
||||||
- description: Users ID
|
- description: Users ID
|
||||||
in: path
|
in: path
|
||||||
name: id
|
name: id
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue