Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Public contract registry
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TO
Public contract registry
Commits
2e20b144
Commit
2e20b144
authored
1 week ago
by
Alexa Valentová
Browse files
Options
Downloads
Patches
Plain Diff
update 404 page
parent
c838bc46
Branches
test
Branches containing commit
No related tags found
1 merge request
!8
update 404 page
Pipeline
#21541
passed
1 week ago
Stage: build
Stage: test_deploy
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
contracts/templates/contracts/404.html
+4
-14
4 additions, 14 deletions
contracts/templates/contracts/404.html
contracts/views.py
+0
-7
0 additions, 7 deletions
contracts/views.py
with
4 additions
and
21 deletions
contracts/templates/contracts/404.html
+
4
−
14
View file @
2e20b144
...
@@ -2,24 +2,14 @@
...
@@ -2,24 +2,14 @@
{% block content %}
{% block content %}
<h1
class=
"font-alt text-6xl mb-6 md:mb-10"
>
<h1
class=
"font-alt text-6xl mb-6 md:mb-10"
>
Přesun do nového Registru
Smlouva nenalezena
</h1>
</h1>
<div
class=
"prose max-w-none"
>
<div
class=
"prose max-w-none"
>
<p>
<p>
{% if archive_page_exists %}
Tato smlouva bohužel zatím nebyla zadána do nedávno nasazené nové verze Registru
smluv.
<br>
<strong>
Je však stále dostupná v archivu na adrese:
<a
href=
"{{ archive_url }}"
>
{{ archive_url }}
</a>
.
</strong>
{% else %}
Tato smlouva byla možná v určitou dobu dostupná ve staré verzi Registru smluv,
Tato smlouva byla možná v určitou dobu dostupná ve staré verzi Registru smluv,
ale aktuálně není dostupná v ani jedné ze dvou verzí. Pokud víš jistě, že ji
ale aktuálně není nahraná nikde. Pokud víš jistě, že odkaz je správný,
dokážeš najít, archiv najdeš na
napiš
<a
href=
"https://zulip.pirati.cz/#narrow/stream/34-Technick.C3.BD-odbor/topic/Registr.20smluv"
>
sem
</a>
.
<a
href=
"https://smlouvy-archiv.pirati.cz"
>
smlouvy-archiv.pirati.cz
</a>
.
{% endif %}
</p>
</p>
<p>
<p>
Více informací o novém Registru se můžeš dozvědět
Více informací o novém Registru se můžeš dozvědět
...
...
This diff is collapsed.
Click to expand it.
contracts/views.py
+
0
−
7
View file @
2e20b144
...
@@ -546,11 +546,6 @@ def get_ares_info(request, ico: int):
...
@@ -546,11 +546,6 @@ def get_ares_info(request, ico: int):
def
handle_404
(
request
,
exception
):
def
handle_404
(
request
,
exception
):
path
=
os
.
path
.
normpath
(
request
.
get_full_path
())
path
=
os
.
path
.
normpath
(
request
.
get_full_path
())
archive_url
=
f
"
https://smlouvy-archiv.pirati.cz
{
path
}
"
archive_response
=
requests
.
get
(
archive_url
)
# Quick dirty check for whether the page found is an actual contract
was_found
=
archive_response
.
ok
and
"
Datum podpisu
"
in
str
(
archive_response
.
content
)
return
render
(
return
render
(
request
,
request
,
...
@@ -559,7 +554,5 @@ def handle_404(request, exception):
...
@@ -559,7 +554,5 @@ def handle_404(request, exception):
**
get_base_context
(
request
),
**
get_base_context
(
request
),
"
title
"
:
"
Stránka nenalezena
"
,
"
title
"
:
"
Stránka nenalezena
"
,
"
description
"
:
""
,
"
description
"
:
""
,
"
archive_page_exists
"
:
was_found
,
"
archive_url
"
:
archive_url
,
},
},
)
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment