resources

package
v0.0.0-...-0387e7d Latest Latest
Warning

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

Go to latest
Published: May 26, 2024 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SurveyStatePending          = SurveyState("pending")
	SurveyStateGatheringOptions = SurveyState("gathering_options")
	SurveyStateVoting           = SurveyState("voting")
	SurveyStateClosed           = SurveyState("closed")

	SurveyVisibilityPublic  = SurveyVisibility("public")
	SurveyVisibilityPrivate = SurveyVisibility("private")
	SurveyVisibilityLink    = SurveyVisibility("link")
)

Variables

This section is empty.

Functions

func ValidateDisplayName

func ValidateDisplayName(displayName string) error

func ValidatePassword

func ValidatePassword(password string) error

func ValidateUsername

func ValidateUsername(username string) error

Types

type Survey

type Survey struct {
	Id            int64            `json:"id"`
	Title         string           `json:"title"`
	UserId        int64            `json:"user_id"`
	State         SurveyState      `json:"state"`
	Visibility    SurveyVisibility `json:"visibility"`
	Description   string           `json:"description,omitempty"`
	ResponseCount int64            `json:"response_count"`
	CreatedAt     time.Time        `json:"created_at"`
	UpdatedAt     time.Time        `json:"updated_at"`
}

type SurveyOption

type SurveyOption struct {
	Id    int64  `json:"id"`
	Title string `json:"title"`
}

type SurveyState

type SurveyState string

type SurveyVisibility

type SurveyVisibility string

type User

type User struct {
	Id          int64  `json:"id"`
	Username    string `json:"username"`
	DisplayName string `json:"display_name,omitempty"`
}

Jump to

Keyboard shortcuts

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