model

package
v0.0.0-...-a311f88 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GenericResponse

type GenericResponse struct {
	Status   int         `json:"status"`
	Success  bool        `json:"success"`
	Messages []string    `json:"messages"`
	Data     interface{} `json:"data"`
}

GenericResponse represent the generic response API

func NewGenericResponse

func NewGenericResponse(stsCd, isError int, messages []string, data interface{}) *GenericResponse

NewGenericResponse will create an object that represent the GenericResponse struct

type UserModel

type UserModel struct {
	ID        gocql.UUID `json:"id" cql:"_id"`
	Name      string     `json:"name" cql:"name"`
	Gender    string     `json:"gender" cql:"gender"`
	Age       int        `json:"age" cql:"age"`
	CreatedAt time.Time  `json:"-" cql:"created_at"`
	UpdatedAt time.Time  `json:"-" cql:"updated_at"`
}

UserModel represent the user model

Jump to

Keyboard shortcuts

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