Add trigger
This commit is contained in:
parent
4743cc3ae5
commit
62eaa11ebb
|
@ -7,13 +7,16 @@ import {
|
||||||
AutomationEventType,
|
AutomationEventType,
|
||||||
} from "@budibase/types"
|
} from "@budibase/types"
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
|
||||||
export const definition: AutomationTriggerSchema = {
|
export const definition: AutomationTriggerSchema = {
|
||||||
type: AutomationStepType.TRIGGER,
|
type: AutomationStepType.TRIGGER,
|
||||||
|
name: "Row Action",
|
||||||
|
event: AutomationEventType.ROW_ACTION, // TODO
|
||||||
|
icon: "Workflow", // TODO
|
||||||
tagline:
|
tagline:
|
||||||
"Row action triggered in {{inputs.enriched.table.name}} by {{inputs.enriched.row._id}}",
|
"Row action triggered in {{inputs.enriched.table.name}} by {{inputs.enriched.row._id}}",
|
||||||
name: "Row Action",
|
description: "TODO description", // TODO
|
||||||
description: "TODO description",
|
|
||||||
icon: "Workflow",
|
|
||||||
stepId: AutomationTriggerStepId.ROW_ACTION,
|
stepId: AutomationTriggerStepId.ROW_ACTION,
|
||||||
inputs: {},
|
inputs: {},
|
||||||
schema: {
|
schema: {
|
||||||
|
@ -41,15 +44,14 @@ export const definition: AutomationTriggerSchema = {
|
||||||
table: {
|
table: {
|
||||||
type: AutomationIOType.OBJECT,
|
type: AutomationIOType.OBJECT,
|
||||||
customType: AutomationCustomIOType.TABLE,
|
customType: AutomationCustomIOType.TABLE,
|
||||||
title: "Table",
|
title: "The table linked to the row action",
|
||||||
},
|
},
|
||||||
row: {
|
row: {
|
||||||
type: AutomationIOType.OBJECT,
|
type: AutomationIOType.OBJECT,
|
||||||
customType: AutomationCustomIOType.ROW,
|
customType: AutomationCustomIOType.ROW,
|
||||||
description: "The new row that was created",
|
description: "The row linked to the row action",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
event: AutomationEventType.ROW_SAVE,
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -279,6 +279,7 @@ export enum AutomationEventType {
|
||||||
APP_TRIGGER = "app:trigger",
|
APP_TRIGGER = "app:trigger",
|
||||||
CRON_TRIGGER = "cron:trigger",
|
CRON_TRIGGER = "cron:trigger",
|
||||||
WEBHOOK_TRIGGER = "web:trigger",
|
WEBHOOK_TRIGGER = "web:trigger",
|
||||||
|
ROW_ACTION = "row:action",
|
||||||
}
|
}
|
||||||
|
|
||||||
export type UpdatedRowEventEmitter = {
|
export type UpdatedRowEventEmitter = {
|
||||||
|
|
Loading…
Reference in New Issue