Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HandleCampaignEvent ¶
HandleCampaignEvent handles campaign event fires. For each event:
- loads the event to fire
- loads the org asset for that event
- locks on the contact
- loads the contact for that event
- creates the trigger for that event
- runs the flow that is to be started through our engine
- saves the flow run and session resulting from our run
func StartCampaignCron ¶
StartCampaignCron starts our cron job of firing expired campaign events
Types ¶
type EventFire ¶
type EventFire struct { FireID int `db:"fire_id"` Scheduled time.Time `db:"scheduled"` Fired *time.Time `db:"fired"` ContactID models.ContactID `db:"contact_id"` ContactUUID flows.ContactUUID `db:"contact_uuid"` EventID int64 `db:"event_id"` EventUUID string `db:"event_uuid"` CampaignID int64 `db:"campaign_id"` CampaignUUID string `db:"campaign_uuid"` CampaignName string `db:"campaign_name"` OrgID models.OrgID `db:"org_id"` FlowUUID flows.FlowUUID `db:"flow_uuid"` }
EventFire represents a single campaign event fire for an event and contact
Click to show internal directories.
Click to hide internal directories.