validators

package
v0.0.0-...-e75809f Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2020 License: GPL-3.0 Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsAllQuestionPresent

func IsAllQuestionPresent(db *gorm.DB) validator.Func

IsAllQuestionPresent validates the "Data" value of FeedbackResponseSerializer

func IsValidQuestionResponse

func IsValidQuestionResponse(
	v *validator.Validate,
	topStruct reflect.Value,
	currentStruct reflect.Value,
	field reflect.Value,
	fieldType reflect.Type,
	fieldKind reflect.Kind,
	param string,
) bool

IsValidQuestionResponse validates the "Response" value of QuestionResponseSerializer

func IsValidSubmittedAt

func IsValidSubmittedAt(
	v *validator.Validate,
	topStruct reflect.Value,
	currentStruct reflect.Value,
	field reflect.Value,
	fieldType reflect.Type,
	fieldKind reflect.Kind,
	param string,
) bool

IsValidSubmittedAt validates the "SubmittedAt" value of FeedbackResponseSerializer

Types

type FeedbackValidators

type FeedbackValidators struct {
	DB *gorm.DB
}

FeedbackValidators is used for registering validators for the feedback app

func (FeedbackValidators) Register

func (feedbackValidator FeedbackValidators) Register()

Register registers all the validators for the feedback serializers

Jump to

Keyboard shortcuts

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