mysql

package
v0.0.0-...-36af1b1 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DB *gorm.DB

Functions

func CreateUsers

func CreateUsers(users []*User) error

func Init

func Init()

Types

type User

type User struct {
	gorm.Model
	Username string `json:"username"`
	Password string `json:"password"`
	Email    string `json:"email"`
}

func CheckUser

func CheckUser(username, password string) ([]*User, error)

func FindUserByNameOrEmail

func FindUserByNameOrEmail(username, email string) ([]*User, error)

func (*User) TableName

func (u *User) TableName() string

Jump to

Keyboard shortcuts

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