dto

package
v0.0.0-...-0eaed87 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Filter

type Filter struct {
	Limit  int      `json:"limit"`
	Page   int      `json:"page"`
	Query  *string  `json:"q"`
	Sort   string   `json:"sort"`
	Status int      `json:"status"`
	Order  []string `json:"order"`
}

Filter ...

type Pagination

type Pagination struct {
	Limit     int   `json:"limit"`
	Page      int   `json:"page"`
	TotalPage uint  `json:"total_page"`
	TotalRows int64 `json:"total_rows"`
}

Pagination ...

type User

type User struct {
	ID        uint       `json:"id"`
	Name      string     `json:"name"`
	CreatedAt *time.Time `json:"created_at"`
	UpdatedAt *time.Time `json:"updated_at"`
}

type UserRequest

type UserRequest struct {
	Name string `json:"name" form:"name" validate:"required,min=2,max=150"`
}

UserRequest ...

type UserResponse

type UserResponse struct {
	ID        string      `json:"id"`
	Name      string      `json:"name"`
	CreatedAt interface{} `json:"created_at"`
	UpdatedAt interface{} `json:"updated_at"`
}

UserResponse ...

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL