models

package
v0.0.0-...-8446c33 Latest Latest
Warning

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

Go to latest
Published: Sep 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 Base

type Base struct {
	CreatedTime time.Time `json:"created_time"`
	CreatedBy   string    `json:"created_by"`
	UpdatedTime time.Time `json:"updated_time,omitempty"`
	UpdatedBy   string    `json:"updated_by,omitempty"`
	DeletedTime time.Time `json:"deleted_time,omitempty"`
	DeletedBy   string    `json:"deleted_by,omitempty"`
}

Base ...

type Categories

type Categories struct {
	Base
	ID          string `json:"id"`
	Name        string `json:"name"`
	Description string `json:"desc"`
}

Categories ...

type Customers

type Customers struct {
	Base
	ID      string `json:"id"`
	Name    string `json:"name"`
	Address string `json:"address"`
	Email   string `json:"email"`
	Phone   string `json:"phone"`
}

Customers ...

type DetailTransactions

type DetailTransactions struct {
	Base
	ID        string `json:"id"`
	ProductID string `json:"productId"`
	Price     int    `json:"price"`
}

DetailTransactions ...

type Products

type Products struct {
	Base
	ID         string `json:"id"`
	Name       string `json:"name"`
	CategoryID string `json:"category_id"`
	Price      int    `json:"price"`
	Stock      int    `json:"stock"`
}

Products ...

type Roles

type Roles struct {
	Base
	ID   string `json:"id"`
	Name string `json:"name"`
}

Roles ...

type Token

type Token struct {
	//UserID uint
	ID       string
	Username string
	RoleID   string
	//Email  string
	*jwt.StandardClaims
}

Token ...

type Transactions

type Transactions struct {
	Base
	ID                 string               `json:"id"`
	CustomerID         string               `json:"customerID"`
	CashierID          string               `json:"cashierID"`
	DetailTransactions []DetailTransactions `json:"detailTransaction"`
	TotalPrice         int                  `json:"totalPrice"`
}

Transactions ...

type User

type User struct {
	Base
	ID       string `json:"id"`
	Username string `json:"username"`
	Password string `json:"password"`
	RoleID   string `json:"roleId"`
}

User models

Jump to

Keyboard shortcuts

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