Преглед изворни кода

feat: 项目下单位列表获取最大pageSize

lanjianrong пре 3 година
родитељ
комит
1f8380cd04
1 измењених фајлова са 8 додато и 5 уклоњено
  1. 8 5
      src/pages/Project/Management/components/TreeNodeSelect.tsx

+ 8 - 5
src/pages/Project/Management/components/TreeNodeSelect.tsx

@@ -5,12 +5,15 @@ import { queryAcountInstitutionList } from '@/services/api/institution'
 
 const TreeNodeSelect = ({ onChange, placeholder = '请选择', ...otherProps }) => {
   const [list, setList] = useState([])
-  const { run: tryAcountInstitutionList } = useRequest(() => queryAcountInstitutionList(), {
-    manual: true,
-    onSuccess: result => {
-      setList(result)
+  const { run: tryAcountInstitutionList } = useRequest(
+    () => queryAcountInstitutionList({ pageSize: 125000 }),
+    {
+      manual: true,
+      onSuccess: result => {
+        setList(result)
+      }
     }
-  })
+  )
 
   useEffect(() => {
     tryAcountInstitutionList()