Merge branch 'contextual-workflows' of github.com:Budibase/budibase into contextual-workflows

This commit is contained in:
Andrew Kingston 2020-09-18 20:31:39 +01:00
commit d90b48351b
2 changed files with 7 additions and 1 deletions

View File

@ -82,7 +82,7 @@ export const getBackendUiStore = () => {
state.models = state.models.filter( state.models = state.models.filter(
existing => existing._id !== model._id existing => existing._id !== model._id
) )
state.selectedModel = state.models[0] || {} state.selectedModel = {}
return state return state
}) })
}, },

View File

@ -28,6 +28,11 @@ module.exports.definition = {
}, },
outputs: { outputs: {
properties: { properties: {
record: {
type: "object",
customType: "record",
description: "The new record",
},
response: { response: {
type: "object", type: "object",
description: "The response from the table", description: "The response from the table",
@ -69,6 +74,7 @@ module.exports.run = async function({ inputs, instanceId }) {
try { try {
await recordController.save(ctx) await recordController.save(ctx)
return { return {
record: inputs.record,
response: ctx.body, response: ctx.body,
id: ctx.body._id, id: ctx.body._id,
revision: ctx.body._rev, revision: ctx.body._rev,