model

package
v0.0.0-...-444ad2e Latest Latest
Warning

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

Go to latest
Published: Aug 17, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type DomainCreator

type DomainCreator struct {
	Name     string   `json:"name"`
	Email    string   `json:"email"`
	Domain   string   `json:"domain"`
	Callback string   `json:"callback"`
	Tags     []string `json:"tags"`
}

type InputType

type InputType string
const (
	InputTypeOption       InputType = "OPTION"
	InputTypeText         InputType = "TEXT"
	InputTypeBoolean      InputType = "BOOLEAN"
	InputTypeSatisfaction InputType = "SATISFACTION"
)

func (InputType) IsValid

func (e InputType) IsValid() bool

func (InputType) MarshalGQL

func (e InputType) MarshalGQL(w io.Writer)

func (InputType) String

func (e InputType) String() string

func (*InputType) UnmarshalGQL

func (e *InputType) UnmarshalGQL(v interface{}) error

type LastSurveyState

type LastSurveyState struct {
	LastQuestion *ent.Question `json:"lastQuestion"`
	Percent      float64       `json:"percent"`
}

type LoginResponse

type LoginResponse struct {
	Token string `json:"token"`
}

type Pair

type Pair struct {
	Key   string `json:"key"`
	Value string `json:"value"`
}

type QuestionCreator

type QuestionCreator struct {
	Title       string    `json:"title"`
	Description string    `json:"description"`
	Kind        InputType `json:"kind"`
	Multiple    *bool     `json:"multiple"`
	Anonymous   *bool     `json:"anonymous"`
	Options     []*Pair   `json:"options"`
}

type SurveyAudenceKind

type SurveyAudenceKind string
const (
	SurveyAudenceKindPublic SurveyAudenceKind = "PUBLIC"
	SurveyAudenceKindDomain SurveyAudenceKind = "DOMAIN"
	SurveyAudenceKindClose  SurveyAudenceKind = "CLOSE"
)

func (SurveyAudenceKind) IsValid

func (e SurveyAudenceKind) IsValid() bool

func (SurveyAudenceKind) MarshalGQL

func (e SurveyAudenceKind) MarshalGQL(w io.Writer)

func (SurveyAudenceKind) String

func (e SurveyAudenceKind) String() string

func (*SurveyAudenceKind) UnmarshalGQL

func (e *SurveyAudenceKind) UnmarshalGQL(v interface{}) error

type SurveyDomain

type SurveyDomain struct {
	ByID         *uuid.UUID `json:"byID"`
	ByDomainName *string    `json:"byDomainName"`
}

type SurveyGenerator

type SurveyGenerator struct {
	Title       string             `json:"title"`
	Description string             `json:"description"`
	Tags        []string           `json:"tags"`
	Questions   []*QuestionCreator `json:"questions"`
	Target      *SurveyTargetUsers `json:"target"`
	Metadata    []*Pair            `json:"metadata"`
	Logic       *string            `json:"logic"`
	Due         *time.Time         `json:"due"`
}

type SurveyTargetUsers

type SurveyTargetUsers struct {
	TargetKind SurveyAudenceKind `json:"targetKind"`
	Whitelist  []uuid.UUID       `json:"whitelist"`
}

type SuveyGenerationResult

type SuveyGenerationResult struct {
	How     int           `json:"how"`
	Surveys []*ent.Survey `json:"surveys"`
}

Jump to

Keyboard shortcuts

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