mirror of
https://gitlab.com/bramw/baserow.git
synced 2025-05-20 15:39:35 +00:00
Create a "Create/Update row" local baserow service, part 2
This commit is contained in:
parent
b916443203
commit
724803f440
56 changed files with 2511 additions and 209 deletions
web-frontend/modules/builder/components/workflowAction
|
@ -0,0 +1,48 @@
|
|||
<template>
|
||||
<UpsertRowWorkflowActionForm
|
||||
:workflow-action="workflowAction"
|
||||
:default-values="defaultValues.service"
|
||||
:application="builder"
|
||||
@values-changed="mutateService($event)"
|
||||
>
|
||||
</UpsertRowWorkflowActionForm>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import UpsertRowWorkflowActionForm from '@baserow/modules/integrations/localBaserow/components/services/LocalBaserowUpsertRowServiceForm'
|
||||
import form from '@baserow/modules/core/mixins/form'
|
||||
import _ from 'lodash'
|
||||
import { DATA_PROVIDERS_ALLOWED_ELEMENTS } from '@baserow/modules/builder/enums'
|
||||
|
||||
export default {
|
||||
name: 'CreateRowWorkflowAction',
|
||||
components: { UpsertRowWorkflowActionForm },
|
||||
mixins: [form],
|
||||
provide() {
|
||||
return { dataProvidersAllowed: DATA_PROVIDERS_ALLOWED_ELEMENTS }
|
||||
},
|
||||
inject: ['builder'],
|
||||
props: {
|
||||
workflowAction: {
|
||||
type: Object,
|
||||
required: false,
|
||||
default: null,
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
allowedValues: ['service'],
|
||||
values: {
|
||||
service: {},
|
||||
},
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
mutateService(newValues) {
|
||||
if (!_.isMatch(this.workflowAction.service, newValues)) {
|
||||
this.values.service = { ...this.workflowAction.service, ...newValues }
|
||||
}
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue