Ver código fonte

修复 BuildSelect 项目控件

魏熙美 5 anos atrás
pai
commit
202adbb359
1 arquivos alterados com 2 adições e 2 exclusões
  1. 2
    2
      src/components/SelectButton/BuildSelect.jsx

+ 2
- 2
src/components/SelectButton/BuildSelect.jsx Ver arquivo

@@ -47,11 +47,11 @@ const BuildingSelect = (props) => {
47 47
     setValue(e)
48 48
     props.onChange(e)
49 49
   }
50
-
50
+  // '' === value ? undefined : value
51 51
   return (
52 52
       <Select
53 53
       showSearch
54
-      value={'' === value ? undefined : value}
54
+      value={props.value}
55 55
       style={{ width: '180px' }} 
56 56
       placeholder="请选择项目" 
57 57
       onChange={handleChange}