models

package
v0.0.0-...-de354b7 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DB *gorm.DB

Functions

func Setup

func Setup()

Setup initializes the database instance

Types

type Cluster

type Cluster struct {
	Name    string         `json:"name" gorm:"unique"`
	Desc    string         `json:"desc"`
	Context datatypes.JSON `json:"context"`
	State   bool           `json:"state"`
}

type ClusterModel

type ClusterModel struct {
	Model
	Cluster
}

type Model

type Model struct {
	ID        uint           `json:"id" gorm:"primarykey"`
	CreatedAt time.Time      `json:"createdAt"`
	UpdatedAt time.Time      `json:"updatedAt"`
	DeletedAt gorm.DeletedAt `json:"deleteAt" gorm:"index"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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