subscriber

package
v1.49.42 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2026 License: MIT Imports: 16 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Query

Query returns a datastore query for subscribers.

Types

type Subscriber

type Subscriber struct {
	mixin.Model[Subscriber]

	FirstName string `json:"firstName"`
	LastName  string `json:"lastName"`

	Email  string `json:"email"`
	FormId string `json:"formId"`
	UserId string `json:"userId,omitempty"`

	Unsubscribed    bool      `json:"unsubscribed"`
	UnsubscribeDate time.Time `json:"unsubscribeDate,omitempty"`

	Client client.Client `json:"client"`

	Tags []string `json:"tags" orm:"default:[]"`

	Metadata  Map    `json:"metadata" datastore:"-" orm:"default:{}"`
	Metadata_ string `json:"-" datastore:",noindex"`
}

func Fake

func Fake(db *datastore.Datastore, userId string) *Subscriber

func FromJSON

func FromJSON(db *datastore.Datastore, data []byte) *Subscriber

func New

func New(db *datastore.Datastore) *Subscriber

New creates a new Subscriber wired to the given datastore.

func (*Subscriber) BeforeCreate

func (s *Subscriber) BeforeCreate() error

Hooks

func (*Subscriber) BeforeUpdate

func (s *Subscriber) BeforeUpdate(previous *Subscriber) error

func (*Subscriber) Load

func (s *Subscriber) Load(ps []datastore.Property) (err error)

func (Subscriber) Md5

func (s Subscriber) Md5() string

func (Subscriber) MergeFields

func (s Subscriber) MergeFields() map[string]interface{}

func (Subscriber) Name

func (s Subscriber) Name() string

func (*Subscriber) Normalize

func (s *Subscriber) Normalize()

func (*Subscriber) Save

func (s *Subscriber) Save() (ps []datastore.Property, err error)

Jump to

Keyboard shortcuts

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