storage

package
v0.0.0-...-7c42c27 Latest Latest
Warning

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

Go to latest
Published: Aug 3, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Registration

type Registration struct {
	ChannelId                     string
	Timezone                      *time.Location
	OwnerId                       string
	TalksToShowOnVoting           int
	ScheduleDow                   int8
	ScheduleTimeInMinutes         int16
	MinimalPeopleRequired         int
	FirstReminderHours            int8
	SecondReminderMinutes         int8
	AddRandomTalkOnSecondReminder bool
	FinalCallMinutes              int8
	ShowVoteResult                bool
	CreatedAt                     time.Time
	UpdatedAt                     time.Time
	Active                        bool
}

func LoadRegistrationFromMap

func LoadRegistrationFromMap(data map[string]interface{}) (*Registration, map[string]error)

func (*Registration) GetDialogElements

func (r *Registration) GetDialogElements() []model.DialogElement

type Storage

type Storage struct {
	// contains filtered or unexported fields
}

func DbConnect

func DbConnect(uri string) (*Storage, error)

func (*Storage) GetRegistration

func (s *Storage) GetRegistration(channelId string) *Registration

func (*Storage) IsRegistered

func (s *Storage) IsRegistered(channelId string) bool

func (*Storage) Migrate

func (s *Storage) Migrate() error

func (*Storage) SaveRegistration

func (s *Storage) SaveRegistration(r *Registration) error

Jump to

Keyboard shortcuts

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