seeds

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SeedAdminsTx

func SeedAdminsTx(tx *sqlx.Tx, schoolIds []SchooldId)

func SeedAlternativeTx

func SeedAlternativeTx(tx *sqlx.Tx)

func SeedQuestionsTx

func SeedQuestionsTx(tx *sqlx.Tx)

func SeedSchools

func SeedSchools()

Types

type Admin

type Admin struct {
	Username    string `db:"username"`
	Password    string `db:"password"`
	Email       string `db:"email"`
	PhoneNumber string `db:"phone_number"`
	SchoolId    string `db:"school_id"`
}

type Alternative

type Alternative struct {
	Alternative string `db:"alternative"`
	Description string `db:"description"`
}

type Question

type Question struct {
	Code        string `db:"code"`
	Question    string `db:"question"`
	Category    string `db:"category"`
	Description string `db:"description"`
	Number      int    `db:"number"`
}

type School

type School struct {
	Name string `db:"name"`
}

type SchooldId

type SchooldId struct {
	Id string `db:"id"`
}

func SeedStudentsTx

func SeedStudentsTx(tx *sqlx.Tx) []SchooldId

type Student

type Student struct {
	Username    string `db:"username"`
	Password    string `db:"password"`
	Fullname    string `db:"fullname"`
	Nisn        string `db:"nisn"`
	Email       string `db:"email"`
	PhoneNumber string `db:"phone_number"`
	SchoolId    string `db:"school_id"`
}

Jump to

Keyboard shortcuts

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