mirror of
https://github.com/scm-manager/scm-manager.git
synced 2026-07-06 10:27:25 +02:00
Fix repository create route from namespace overview page (#1602)
This commit is contained in:
2
gradle/changelog/repo_create_route.yaml
Normal file
2
gradle/changelog/repo_create_route.yaml
Normal file
@@ -0,0 +1,2 @@
|
||||
- type: fixed
|
||||
description: Fix repository creation route from repository namespace overview page ([#1602](https://github.com/scm-manager/scm-manager/pull/1602))
|
||||
@@ -32,6 +32,7 @@ type Props = {
|
||||
currentGroup: string;
|
||||
groups?: string[];
|
||||
link: string;
|
||||
createLink?: string;
|
||||
groupSelected: (namespace: string) => void;
|
||||
label?: string;
|
||||
testId?: string;
|
||||
@@ -47,6 +48,7 @@ const OverviewPageActions: FC<Props> = ({
|
||||
currentGroup,
|
||||
showCreateButton,
|
||||
link: inputLink,
|
||||
createLink,
|
||||
groupSelected,
|
||||
label,
|
||||
testId,
|
||||
@@ -72,7 +74,7 @@ const OverviewPageActions: FC<Props> = ({
|
||||
if (showCreateButton) {
|
||||
return (
|
||||
<div className={classNames("input-button", "control", "column")}>
|
||||
<Button label={label} link={`${link}create`} color="primary" />
|
||||
<Button label={label} link={createLink || `${link}create`} color="primary" />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -145,6 +145,7 @@ const Overview: FC = () => {
|
||||
groups={namespacesToRender}
|
||||
groupSelected={namespaceSelected}
|
||||
link={namespace ? `repos/${namespace}` : "repos"}
|
||||
createLink="/repos/create"
|
||||
label={t("overview.createButton")}
|
||||
testId="repository-overview"
|
||||
searchPlaceholder={t("overview.searchRepository")}
|
||||
|
||||
Reference in New Issue
Block a user