mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 10:00:01 -03:30
Merge pull request #4699 from mabashian/4549-not-found
Don't render the 404 not found page until the content's finished loading Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
This commit is contained in:
commit
5193209ca7
@ -149,15 +149,17 @@ class Job extends Component {
|
||||
<Route
|
||||
key="not-found"
|
||||
path="*"
|
||||
render={() => (
|
||||
<ContentError isNotFound>
|
||||
<Link
|
||||
to={`/jobs/${match.params.type}/${match.params.id}/details`}
|
||||
>
|
||||
{i18n._(`View Job Details`)}
|
||||
</Link>
|
||||
</ContentError>
|
||||
)}
|
||||
render={() =>
|
||||
!hasContentLoading && (
|
||||
<ContentError isNotFound>
|
||||
<Link
|
||||
to={`/jobs/${match.params.type}/${match.params.id}/details`}
|
||||
>
|
||||
{i18n._(`View Job Details`)}
|
||||
</Link>
|
||||
</ContentError>
|
||||
)
|
||||
}
|
||||
/>,
|
||||
]}
|
||||
</Switch>
|
||||
|
||||
@ -238,15 +238,17 @@ class Organization extends Component {
|
||||
<Route
|
||||
key="not-found"
|
||||
path="*"
|
||||
render={() => (
|
||||
<ContentError isNotFound>
|
||||
{match.params.id && (
|
||||
<Link to={`/organizations/${match.params.id}/details`}>
|
||||
{i18n._(`View Organization Details`)}
|
||||
</Link>
|
||||
)}
|
||||
</ContentError>
|
||||
)}
|
||||
render={() =>
|
||||
!hasContentLoading && (
|
||||
<ContentError isNotFound>
|
||||
{match.params.id && (
|
||||
<Link to={`/organizations/${match.params.id}/details`}>
|
||||
{i18n._(`View Organization Details`)}
|
||||
</Link>
|
||||
)}
|
||||
</ContentError>
|
||||
)
|
||||
}
|
||||
/>
|
||||
,
|
||||
</Switch>
|
||||
|
||||
@ -119,17 +119,19 @@ class Template extends Component {
|
||||
<Route
|
||||
key="not-found"
|
||||
path="*"
|
||||
render={() => (
|
||||
<ContentError isNotFound>
|
||||
{match.params.id && (
|
||||
<Link
|
||||
to={`/templates/${match.params.templateType}/${match.params.id}/details`}
|
||||
>
|
||||
{i18n._(`View Template Details`)}
|
||||
</Link>
|
||||
)}
|
||||
</ContentError>
|
||||
)}
|
||||
render={() =>
|
||||
!hasContentLoading && (
|
||||
<ContentError isNotFound>
|
||||
{match.params.id && (
|
||||
<Link
|
||||
to={`/templates/${match.params.templateType}/${match.params.id}/details`}
|
||||
>
|
||||
{i18n._(`View Template Details`)}
|
||||
</Link>
|
||||
)}
|
||||
</ContentError>
|
||||
)
|
||||
}
|
||||
/>,
|
||||
]}
|
||||
</Switch>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user