mirror of
https://github.com/harness/drone.git
synced 2025-05-21 19:39:59 +08:00
fix: [code-625]: fix url params on repo listing page
This commit is contained in:
parent
f8092fe117
commit
17f96a5c3a
@ -59,7 +59,9 @@ export default function RepositoriesListing() {
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setSearchTerm(undefined)
|
setSearchTerm(undefined)
|
||||||
updateQueryParams({ page: page.toString() })
|
if (page > 1) {
|
||||||
|
updateQueryParams({ page: page.toString() })
|
||||||
|
}
|
||||||
}, [space, setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
}, [space, setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
||||||
|
|
||||||
const columns: Column<TypesRepository>[] = useMemo(
|
const columns: Column<TypesRepository>[] = useMemo(
|
||||||
|
@ -44,7 +44,9 @@ export function RepositoryBranchesContent({ repoMetadata }: Pick<GitInfoProps, '
|
|||||||
})
|
})
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
updateQueryParams({ page: page.toString() })
|
if (page > 1) {
|
||||||
|
updateQueryParams({ page: page.toString() })
|
||||||
|
}
|
||||||
}, [setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
}, [setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
||||||
|
|
||||||
useShowRequestError(error)
|
useShowRequestError(error)
|
||||||
|
@ -55,7 +55,9 @@ export function RepositoryTagsContent({ repoMetadata }: Pick<GitInfoProps, 'repo
|
|||||||
})
|
})
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
updateQueryParams({ page: page.toString() })
|
if (page > 1) {
|
||||||
|
updateQueryParams({ page: page.toString() })
|
||||||
|
}
|
||||||
}, [setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
}, [setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
||||||
|
|
||||||
useShowRequestError(error)
|
useShowRequestError(error)
|
||||||
|
@ -69,7 +69,9 @@ export default function Webhooks() {
|
|||||||
lazy: !repoMetadata
|
lazy: !repoMetadata
|
||||||
})
|
})
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
updateQueryParams({ page: page.toString() })
|
if (page > 1) {
|
||||||
|
updateQueryParams({ page: page.toString() })
|
||||||
|
}
|
||||||
}, [setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
}, [setPage]) // eslint-disable-line react-hooks/exhaustive-deps
|
||||||
|
|
||||||
const columns: Column<OpenapiWebhookType>[] = useMemo(
|
const columns: Column<OpenapiWebhookType>[] = useMemo(
|
||||||
|
Loading…
Reference in New Issue
Block a user