model

package
v0.14.1 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2023 License: MIT Imports: 3 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DSN

type DSN struct {
	Driver   string `json:"driver"`
	Username string `json:"username"`
	Password string `json:"password"`
	Hostname string `json:"hostname"`
	Port     int    `json:"port"`
	Name     string `json:"name"`
}

DSN struct

func (*DSN) ConvertToJSON

func (d *DSN) ConvertToJSON() (string, error)

ConvertToJSON convert object to json

func (*DSN) LoadFromJSON

func (d *DSN) LoadFromJSON(data []byte) error

LoadFromJSON update object from json

func (*DSN) ToString

func (d *DSN) ToString() string

ToString gets the dsn string

type Role

type Role struct {
	ID        int       `json:"id"`
	Name      string    `json:"name"`
	Value     string    `json:"value"`
	StartAt   time.Time `json:"startAt"`
	EndAt     time.Time `json:"endAt"`
	CreatedAt time.Time `json:"createdAt"`
	UpdatedAt time.Time `json:"updatedAt"`
}

Role struct

func (*Role) ConvertToJSON

func (o *Role) ConvertToJSON() (string, error)

ConvertToJSON convert object to json

func (*Role) LoadFromJSON

func (o *Role) LoadFromJSON(data []byte) error

LoadFromJSON update object from json

type RoleRequest

type RoleRequest struct {
	ID        int               `json:"id"`
	Name      string            `json:"name"`
	Value     map[string]string `json:"value"`
	StartAt   time.Time         `json:"startAt"`
	EndAt     time.Time         `json:"endAt"`
	CreatedAt time.Time         `json:"createdAt"`
	UpdatedAt time.Time         `json:"updatedAt"`
}

RoleRequest struct

func (*RoleRequest) ConvertToJSON

func (o *RoleRequest) ConvertToJSON() (string, error)

ConvertToJSON convert object to json

func (*RoleRequest) LoadFromJSON

func (o *RoleRequest) LoadFromJSON(data []byte) error

LoadFromJSON update object from json

type Roles

type Roles struct {
	Roles []Role `json:"roles"`
}

Roles struct

func (*Roles) ConvertToJSON

func (o *Roles) ConvertToJSON() (string, error)

ConvertToJSON convert object to json

func (*Roles) LoadFromJSON

func (o *Roles) LoadFromJSON(data []byte) error

LoadFromJSON update object from json

Jump to

Keyboard shortcuts

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