domain

package
v0.0.0-...-2de19fb Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dialog

type Dialog struct {
	ID   int
	User string // username
	Meta DialogMeta
}

Dialog holds dialog reference in different messagers

type DialogMeta

type DialogMeta struct {
	Teams    string
	Telegram string // for example
	Slack    string // for example
}

DialogMeta stores serialize dialog reference for messagers

type Message

type Message struct {
	ID           int
	Text         string
	Attachment   string
	System       string
	Direction    string
	Proactive    bool
	PayloadType  string
	PayloadValue string
}

Message is used for messagers

type Project

type Project struct {
	ID      int
	User    string
	Title   string
	DueDate time.Time
}

Project holds project data

type User

type User struct {
	ID           int  // id is passed to domain model for simplicity
	Service      bool // if user is a service
	Username     string
	DisplayName  string // human readable name
	Password     string
	PasswordHash string
	Email        string   // TODO: add ent validation
	Meta         UserMeta // stores messagers ids
}

User holds user data

type UserMessagerData

type UserMessagerData struct {
	ID       *string
	Username *string
}

UserMessagerData stores users data for a specific messager

type UserMeta

type UserMeta struct {
	Teams    UserMessagerData
	Telegram UserMessagerData
	Slack    UserMessagerData
}

UserMeta stores users data for messagers

Jump to

Keyboard shortcuts

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