fix(plugin-workflow): fix select value (#600)

This commit is contained in:
Junyi 2022-07-07 11:20:50 +08:00 committed by GitHub
parent f951ba1745
commit 39a3146f14
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 5 deletions

View File

@ -49,8 +49,8 @@ export default {
<CollectionFieldSelect <CollectionFieldSelect
collection={config.collection} collection={config.collection}
value={value} value={value}
onChange={(value) => { onChange={(path) => {
onChange({ type, options: { ...options, path: value?.join('.') } }); onChange({ type, options: { ...options, path } });
}} }}
/> />
); );

View File

@ -54,8 +54,8 @@ export default {
<CollectionFieldSelect <CollectionFieldSelect
collection={config.collection} collection={config.collection}
value={value} value={value}
onChange={(value) => { onChange={(path) => {
onChange({ type, options: { ...options, path: value?.join('.') } }); onChange({ type, options: { ...options, path } });
}} }}
/> />
); );

View File

@ -138,7 +138,7 @@ export default {
collection={workflow.config.collection} collection={workflow.config.collection}
value={value} value={value}
onChange={(value) => { onChange={(value) => {
onChange({ type, options: { ...options, path: `data.${value.join('.')}` } }); onChange({ type, options: { ...options, path: `data.${value}` } });
}} }}
/> />
); );