"fix(niki):fixed some small bugs"

This commit is contained in:
AMiR 2024-05-20 21:07:44 +03:30 committed by Iman Mirazimi
parent ec08823901
commit 16b8093e8c
9 changed files with 9 additions and 33 deletions

View File

@ -25,3 +25,6 @@ run:
docker:
sudo docker compose up -d
swagger:
swag init

View File

@ -751,9 +751,6 @@ const docTemplate = `{
"adminkindboxreqparam.AssignSenderRequest": {
"type": "object",
"properties": {
"kind_box_req_id": {
"type": "integer"
},
"sender_agent_id": {
"type": "integer"
}
@ -770,9 +767,6 @@ const docTemplate = `{
"properties": {
"count_accepted": {
"type": "integer"
},
"id": {
"type": "integer"
}
}
},
@ -819,10 +813,6 @@ const docTemplate = `{
"description": {
"type": "string",
"example": "description"
},
"id": {
"type": "integer",
"example": 1
}
}
},

View File

@ -740,9 +740,6 @@
"adminkindboxreqparam.AssignSenderRequest": {
"type": "object",
"properties": {
"kind_box_req_id": {
"type": "integer"
},
"sender_agent_id": {
"type": "integer"
}
@ -759,9 +756,6 @@
"properties": {
"count_accepted": {
"type": "integer"
},
"id": {
"type": "integer"
}
}
},
@ -808,10 +802,6 @@
"description": {
"type": "string",
"example": "description"
},
"id": {
"type": "integer",
"example": 1
}
}
},

View File

@ -44,8 +44,6 @@ definitions:
type: object
adminkindboxreqparam.AssignSenderRequest:
properties:
kind_box_req_id:
type: integer
sender_agent_id:
type: integer
type: object
@ -57,8 +55,6 @@ definitions:
properties:
count_accepted:
type: integer
id:
type: integer
type: object
adminkindboxreqparam.KindBoxReqAcceptResponse:
properties:
@ -89,9 +85,6 @@ definitions:
description:
example: description
type: string
id:
example: 1
type: integer
type: object
adminkindboxreqparam.KindBoxReqRejectResponse:
properties:

View File

@ -7,7 +7,7 @@ import (
)
type KindBoxReqAcceptRequest struct {
ID uint `json:"id"`
ID uint `json:"-"`
CountAccepted uint `json:"count_accepted"`
}

View File

@ -1,7 +1,7 @@
package adminkindboxreqparam
type AssignSenderRequest struct {
KindBoxReqID uint `json:"kind_box_req_id"`
KindBoxReqID uint `json:"-"`
SenderAgentID uint `json:"sender_agent_id"`
}

View File

@ -1,7 +1,7 @@
package adminkindboxreqparam
type DeliverKindBoxReqRequest struct {
KindBoxReqID uint `json:"kind_box_req_id"`
KindBoxReqID uint `json:"-"`
}
type DeliverKindBoxReqResponse struct{}

View File

@ -7,7 +7,7 @@ import (
)
type KindBoxReqRejectRequest struct {
ID uint `json:"id" example:"1"`
ID uint `json:"-"`
Description string `json:"description" example:"description"`
}

View File

@ -5,7 +5,7 @@ CREATE TABLE `admins` (
`last_name` VARCHAR(191),
`password` VARCHAR(191) NOT NULL,
`phone_number` VARCHAR(191) NOT NULL UNIQUE,
`role` ENUM('super-admin','admin','agent') NOT NULL, -- default?
`role` ENUM('super-admin','admin','agent') NOT NULL DEFAULT 'admin',
`description` TEXT,
`email` VARCHAR(191) NOT NULL UNIQUE,
`gender` ENUM('male','female'),