这是indexloc提供的服务,不要输入任何密码

subscriber

package
v0.0.0-...-26b047c Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

Service charge firestore operation

func New

func New() (*Service, error)

New return a firestore service struct

func (*Service) GetSubscribers

func (s *Service) GetSubscribers() ([]Subscriber, error)

GetSubscribers return firestore collection convert to Subscriber struct array

func (*Service) UpdateLastCreatedAt

func (s *Service) UpdateLastCreatedAt(ref *firestore.DocumentRef, createdAt time.Time) error

UpdateLastCreatedAt update subscriber laster createdAt

type Subscriber

type Subscriber struct {
	Ref           *firestore.DocumentRef
	Mail          string
	Keywords      []string
	LastCreatedAt time.Time
}

Subscriber firestore collection value object

Jump to

Keyboard shortcuts

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