Added subscription changed trigger

Is very useful if some subscription data is updated by API and you want to trigger after that because segments (filters) have changed.
This commit is contained in:
Gernot Pansy 2019-10-10 12:35:57 +02:00
parent ed2655b78e
commit e2a69ef76d
8 changed files with 21 additions and 3 deletions

View file

@ -54,6 +54,7 @@ export default class CUD extends Component {
this.eventOptions = {
[Entity.SUBSCRIPTION]: [
{key: SubscriptionEvent.CREATED, label: eventLabels[Entity.SUBSCRIPTION][SubscriptionEvent.CREATED]},
{key: SubscriptionEvent.UPDATED, label: eventLabels[Entity.SUBSCRIPTION][SubscriptionEvent.UPDATED]},
{key: SubscriptionEvent.LATEST_OPEN, label: eventLabels[Entity.SUBSCRIPTION][SubscriptionEvent.LATEST_OPEN]},
{key: SubscriptionEvent.LATEST_CLICK, label: eventLabels[Entity.SUBSCRIPTION][SubscriptionEvent.LATEST_CLICK]}
],

View file

@ -15,6 +15,7 @@ export function getTriggerTypes(t) {
const eventLabels = {
[Entity.SUBSCRIPTION]: {
[SubscriptionEvent.CREATED]: t('created'),
[SubscriptionEvent.UPDATED]: t('updated'),
[SubscriptionEvent.LATEST_OPEN]: t('latestOpen'),
[SubscriptionEvent.LATEST_CLICK]: t('latestClick')
},