mirror of
https://gitee.com/baidu/amis.git
synced 2024-12-02 12:08:13 +08:00
fix: 修复 select tree 模式值格式不正确的问题 (#3458)
Co-authored-by: 2betop <2betop.cn@gmail.com>
This commit is contained in:
parent
b3cd56a93f
commit
5805e52da5
@ -128,7 +128,7 @@ export class BaseTransferRenderer<
|
||||
T extends OptionsControlProps = BaseTransferProps
|
||||
> extends React.Component<T> {
|
||||
@autobind
|
||||
handleChange(value: Array<Option>, optionModified?: boolean) {
|
||||
handleChange(value: Array<Option> | Option, optionModified?: boolean) {
|
||||
const {
|
||||
onChange,
|
||||
joinValues,
|
||||
@ -169,6 +169,11 @@ export class BaseTransferRenderer<
|
||||
if (joinValues) {
|
||||
newValue = newValue.join(delimiter || ',');
|
||||
}
|
||||
} else if (value) {
|
||||
newValue =
|
||||
joinValues || extractValue
|
||||
? value[(valueField as string) || 'value']
|
||||
: value;
|
||||
}
|
||||
|
||||
(newOptions.length > options.length || optionModified) &&
|
||||
|
Loading…
Reference in New Issue
Block a user