This is an automated email from the ASF dual-hosted git repository. abeizn pushed a commit to branch release-v1.0 in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
commit af235a968840513a07b55653fb5c9f753e2cb0e0 Author: wouldd <[email protected]> AuthorDate: Wed Apr 10 09:01:44 2024 +0100 pr-type/bug-fix 7114 - wire up the page size event to alter page size (#7124) * 7114 - wire up the page size event to alter page size * rollback bad merge change --------- Co-authored-by: Daniel Would <[email protected]> --- config-ui/src/routes/connection/connection.tsx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/config-ui/src/routes/connection/connection.tsx b/config-ui/src/routes/connection/connection.tsx index 05dbc5bcc..957a793a7 100644 --- a/config-ui/src/routes/connection/connection.tsx +++ b/config-ui/src/routes/connection/connection.tsx @@ -53,7 +53,7 @@ export const Connection = () => { const [operating, setOperating] = useState(false); const [version, setVersion] = useState(1); const [page, setPage] = useState(1); - const [pageSize] = useState(10); + const [pageSize, setPageSize] = useState(10); const [scopeId, setScopeId] = useState<ID>(); const [scopeIds, setScopeIds] = useState<ID[]>([]); const [scopeConfigId, setScopeConfigId] = useState<ID>(); @@ -97,7 +97,7 @@ export const Connection = () => { const handleHideDialog = () => { setType(undefined); }; - + const handleShowDeleteDialog = () => { setType('deleteConnection'); }; @@ -332,6 +332,10 @@ export const Connection = () => { pageSize, total, onChange: setPage, + onShowSizeChange: (current,size)=> { + setPage(1); + setPageSize(size); + } }} rowSelection={{ selectedRowKeys: scopeIds,
