diff --git a/archilance/urls.py b/archilance/urls.py index 9745da0..0184fec 100644 --- a/archilance/urls.py +++ b/archilance/urls.py @@ -9,12 +9,13 @@ from wagtail.wagtailcore import urls as wagtail_urls from common.views import CustomRegistrationView from wallets.views import TmpCheckOrderView, TmpPaymentAvisoView -from .views import HomeTemplateView, TestChatTemplateView, TestView +from .views import HomeTemplateView, TestChatTemplateView, TestView, test_404 from projects.views import CustomerRealtyTrashView, CustomerRealtyDeleteView, CustomerRealtyRestoreView, SortRealtyBy, \ RealtyUpdateView urlpatterns = [ url(r'^$', HomeTemplateView.as_view()), + # url(r'^404$', test_404), url('', include('social.apps.django_app.urls', namespace='social')), url(r'^chattest/$', TestChatTemplateView.as_view()), url(r'^work_sell/', include('work_sell.urls')), diff --git a/archilance/views.py b/archilance/views.py index d80b2c8..3d8e731 100644 --- a/archilance/views.py +++ b/archilance/views.py @@ -13,6 +13,10 @@ _.map = _.map_; _.filter = _.filter_ +def test_404(request): + return render(request, '404.html') + + class HomeTemplateView(BaseMixin, View): template_name = 'home.html' diff --git a/assets/img/404house.jpg b/assets/img/404house.jpg new file mode 100644 index 0000000..4eb9f61 Binary files /dev/null and b/assets/img/404house.jpg differ diff --git a/templates/404.html b/templates/404.html index dc9655b..3ebed79 100644 --- a/templates/404.html +++ b/templates/404.html @@ -1,14 +1,35 @@ -{% extends 'partials/base.html' %} - +{% extends 'partials/_base.html' %} +{% load static %} +{% load sass_tags %} +{% block personal_css %} + +{% endblock %} {% block content %} -
- {% include 'partials/header.html' %} -
-
-

404 ошибка сайта

-
-
-
+
+
+
+ 404 +
+
+

404

+

+ Страница не найдена +

+

+ Что-то пошло не по плану
и мы не смогли найти эту страницу. +

+

+ Но всегда можно вернуться
на главную страницу и начать все с начала ;-) +

+
+
+
{% endblock %} - +{% block footer %} + +{% endblock %} diff --git a/templates/partials/sass/404.sass b/templates/partials/sass/404.sass new file mode 100644 index 0000000..6ef0845 --- /dev/null +++ b/templates/partials/sass/404.sass @@ -0,0 +1,8 @@ +img._404 + padding: 10px + border: 1px solid darkgray + +h1._404 + font-size: 90px + font-weight: bold + color: #ff0029 \ No newline at end of file