models

package
v0.0.0-...-d35218b Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidateStudents

func ValidateStudents(student *Student) error

Types

type Student

type Student struct {
	gorm.Model
	Name     string `json:"name" validate:"nonzero"`
	Document string `json:"document" validate:"len=11,regexp=^[0-9]*$"`
	Age      int    `json:"age" validate:"nonzero"`
}

Jump to

Keyboard shortcuts

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