models

package
v0.0.0-...-d777a83 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DB *gorm.DB

DB ...

Functions

func Database

func Database(dbConfig *config.DBConfig) error

Database ...

Types

type CustomeModel

type CustomeModel struct {
	ID        uint   `gorm:"primarykey"`
	CreatedAt uint64 `json:"created_at"`
	UpdatedAt uint64 `json:"update_at"`
	DeletedAt uint64 `json:"deleted_at"`
	IsDelete  bool   `json:"is_delete"`
}

CustomeModel a basic GoLang struct which includes the following fields: ID, CreatedAt, UpdatedAt, DeletedAt It may be embedded into your model or you may build your own model without it

type User struct {
  CustomeModel
}

Jump to

Keyboard shortcuts

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