steps

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Feb 3, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ContextPropertyKey    = "property"
	ContextButtonValueKey = "button_value"
	ContextOptionValueKey = "selected_option"
	ContextStepKey        = "step"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Step

type Step interface {
	PostSlackAttachment(flowHandler string, i int) *model.SlackAttachment
	ResponseSlackAttachment(value interface{}) *model.SlackAttachment
	GetPropertyName() string
	ShouldSkip(value interface{}) int
	IsEmpty() bool
	GetFreetextFetcher() freetextfetcher.FreetextFetcher
}

func NewEmptyStep

func NewEmptyStep(title, message string) Step

func NewFreetextStep

func NewFreetextStep(
	title,
	message,
	propertyName,
	baseURL string,
	store freetextfetcher.FreetextStore,
	validate func(string) string,
	r *mux.Router,
	p poster.Poster,
) Step

func NewSimpleStep

func NewSimpleStep(
	title,
	message,
	propertyName,
	trueButtonMessage,
	falseButtonMessage,
	trueResponseMessage,
	falseResponseMessage string,
	trueSkip,
	falseSkip int,
) Step

Jump to

Keyboard shortcuts

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