Documentation
¶
Index ¶
- func DeleteContentByID(ctx echo.Context) error
- func DeleteProductByID(ctx echo.Context) error
- func GetContentByID(ctx echo.Context) error
- func GetContents(ctx echo.Context) error
- func GetProductByID(ctx echo.Context) error
- func GetProducts(ctx echo.Context) error
- func PostContent(ctx echo.Context) error
- func PostProduct(ctx echo.Context) error
- func PutContentByID(ctx echo.Context) error
- func PutProductByID(ctx echo.Context) error
- func SetIAPManager(nk *echokit.EchoKit, cnf helpers.Config)
- type AddContentPayload
- type AddProductPayload
- type DownloadLog
- type FilterContentPayload
- type LoginRequest
- type MessageResponse
- type MessageWithPayloadResponse
- type UpdateProductPayload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeleteContentByID ¶
DeleteContentByID to getting content
func DeleteProductByID ¶
DeleteProductByID to getting products
func GetProductByID ¶
GetProductByID to getting products
func PutProductByID ¶
PutProductByID to getting products
Types ¶
type AddContentPayload ¶
type AddContentPayload struct {
ContentName string `validate:"required" json:"content_name"`
ContentDesc string `validate:"required" json:"content_desc"`
ContentTags string `validate:"required" json:"content_tags"`
ContentImage string `validate:"required" json:"content_image"`
}
AddContentPayload add content payload
type AddProductPayload ¶
type AddProductPayload struct {
ProductID string `validate:"required" json:"product_id"`
ProductName string `validate:"required" json:"product_name"`
ProductDesc string `validate:"required" json:"product_desc"`
ProductImage string `validate:"required" json:"product_image"`
ProductPrice float64 `validate:"required" json:"product_price"`
}
AddProductPayload add product payload
type DownloadLog ¶
type DownloadLog struct {
RevNum string `validate:"required" json:"rev_num"`
LastDate string `validate:"required" json:"last_date"`
LastEdit string `validate:"required" json:"last_edit"`
LastTime string `validate:"required" json:"last_time"`
MacAddress string `validate:"required" json:"mac_address"`
}
DownloadLog to post metadata after download
type FilterContentPayload ¶
type FilterContentPayload struct {
Page int `validate:"required" json:"page" query:"page"`
RowPerPage int `validate:"required" json:"row_per_page" query:"row_per_page"`
Tag []string `validate:"required" json:"tag" query:"tag"`
}
FilterContentPayload to filter content list
type LoginRequest ¶
type LoginRequest struct {
Email string `validate:"required,email" json:"email"`
Password string `validate:"required" json:"password"`
MacAddress string `validate:"required" json:"mac_address"`
}
LoginRequest for login request
type MessageResponse ¶
MessageResponse for response message
type MessageWithPayloadResponse ¶
type MessageWithPayloadResponse struct {
Title string `json:"title"`
Message string `json:"message"`
Payload interface{} `json:"payload"`
}
MessageWithPayloadResponse for response message with payload
type UpdateProductPayload ¶
type UpdateProductPayload struct {
ProductName string `validate:"required" json:"product_name"`
ProductDesc string `validate:"required" json:"product_desc"`
ProductImage string `validate:"required" json:"product_image"`
ProductPrice float64 `validate:"required" json:"product_price"`
}
UpdateProductPayload add product payload
Click to show internal directories.
Click to hide internal directories.