db

package
v0.0.0-...-635ad70 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect() (*gorm.DB, error)

Types

type Profile

type Profile struct {
	gorm.Model
	UserType string `json:"usertype" gorm:"size:30"`
	Username string `json:"username" gorm:"size:20"`
	Password string `json:"pxwd" gorm:"size:150"`
}

type Pupil

type Pupil struct {
	gorm.Model
	Profile Profile `json:"profile"`

	Firstname   string `json:"firstname" gorm:"size:20"`
	Lastname    string `json:"lastname" gorm:"size:20"`
	Phone       string `json:"phone" gorm:"size:20"`
	UserCode    string `json:"usercode" gorm:"size:20"`
	Deactivated bool   `json:"deactivated" gorm:"default:false"`
	// contains filtered or unexported fields
}

type Teacher

type Teacher struct {
	gorm.Model
	Profile Profile `json:"profile"`

	Firstname string `json:"firstname" gorm:"size:20"`
	Lastname  string `json:"lastname" gorm:"size:20"`
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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