fix: view form type field linkages
This commit is contained in:
parent
e56d9b8573
commit
2e4bf25923
@ -60,11 +60,11 @@ export default {
|
|||||||
"target": "targetField",
|
"target": "targetField",
|
||||||
"condition": "{{ $self.value === 'association' }}"
|
"condition": "{{ $self.value === 'association' }}"
|
||||||
},
|
},
|
||||||
{
|
// {
|
||||||
"type": "value:visible",
|
// "type": "value:visible",
|
||||||
"target": "type",
|
// "target": "type",
|
||||||
"condition": "{{ $self.value === 'collection' }}"
|
// "condition": "{{ $self.value === 'collection' }}"
|
||||||
},
|
// },
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -40,20 +40,9 @@ export function getViewTypeLinkages() {
|
|||||||
"condition": `{{ $self.value === '${key}' }}`,
|
"condition": `{{ $self.value === '${key}' }}`,
|
||||||
});
|
});
|
||||||
if (linkages.type) {
|
if (linkages.type) {
|
||||||
xlinkages = xlinkages.concat(linkages.type.map(linkage => {
|
xlinkages.push(...linkages.type);
|
||||||
if (properties[linkage.target]) {
|
|
||||||
linkage.condition = `{{ $self.value === '${key}' }}`;
|
|
||||||
linkage.target = `x-${key}-props.${linkage.target}`;
|
|
||||||
}
|
|
||||||
return linkage;
|
|
||||||
}));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// xlinkages.push({
|
|
||||||
// type: "value:visible",
|
|
||||||
// target: 'collection',
|
|
||||||
// condition: `{{ $self.value !== 'wysiwyg' }}`,
|
|
||||||
// });
|
|
||||||
return xlinkages;
|
return xlinkages;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -260,5 +260,22 @@ export const wysiwyg = {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
linkages: {
|
linkages: {
|
||||||
|
type: [
|
||||||
|
{
|
||||||
|
type: "value:visible",
|
||||||
|
target: 'collection',
|
||||||
|
condition: `{{ $self.value && $self.value !== 'wysiwyg' }}`,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: "value:visible",
|
||||||
|
target: 'dataSourceType',
|
||||||
|
condition: `{{ $self.value && $self.value !== 'wysiwyg' }}`,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: "value:visible",
|
||||||
|
target: 'targetField',
|
||||||
|
condition: `{{ $self.value && $self.value !== 'wysiwyg' }}`,
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user