Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
103 changes: 80 additions & 23 deletions src/components/file/editForm/File.edit.file.js
Original file line number Diff line number Diff line change
Expand Up @@ -157,29 +157,86 @@ export default [
placeholder: '(optional) Enter a directory for the files',
tooltip: 'This will place all the files uploaded in this field in the directory',
weight: 20,
conditional: {
json: {
'!==': [{
var: 'data.storage'
}, 'googledrive']
}
}
},
{
type: 'textfield',
input: true,
key: 'dir',
label: 'Folder ID',
placeholder: '(optional) Enter an ID of the folder for the files',
tooltip: 'This will place all the files uploaded in this field in the folder',
weight: 20,
conditional: {
json: {
'===': [{
var: 'data.storage'
}, 'googledrive']
}
}
logic: [
{
name: 'Change To File ID',
trigger: {
type: 'simple',
simple: {
show: true,
conjunction: 'all',
conditions: [
{
component: 'storage',
operator: 'isEqual',
value: 'googledrive',
},
],
},
},
actions: [
{
name: 'Change placeholder',
type: 'property',
property: {
label: 'Placeholder',
value: 'placeholder',
type: 'string',
},
text: '(optional) Enter an ID of the folder for the files',
},
{
name: 'Change label',
type: 'property',
property: {
label: 'Label',
value: 'label',
type: 'string',
},
text: 'Folder ID',
},
],
},
{
name: 'Change to Directory',
trigger: {
type: 'simple',
simple: {
show: true,
conjunction: 'all',
conditions: [
{
component: 'storage',
operator: 'isNotEqual',
value: 'googledrive',
},
],
},
},
actions: [
{
name: 'Change placeholder',
type: 'property',
property: {
label: 'Placeholder',
value: 'placeholder',
type: 'string',
},
text: '(optional) Enter a directory for the files',
},
{
name: 'Change label',
type: 'property',
property: {
label: 'Label',
value: 'label',
type: 'string',
},
text: 'Directory',
},
],
},
],
},
{
type: 'textfield',
Expand Down
Loading