Commit 83e120f5 authored by zhangwenshuai's avatar zhangwenshuai

修改textSelect

parent 99f4f85f
......@@ -137,8 +137,12 @@ class TextSelect extends React.Component<Props, State> {
onChange = (obj) => {
const { onChange } = this.props;
if (typeof onChange === 'function') {
if (!obj || (!obj.label && !obj.value)) {
onChange(undefined);
} else {
onChange(obj);
}
}
};
onClear = () => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment