feat: создать базовый шаблон и структуру для страницы каталога
All checks were successful
Build and Push Docker Image / build (push) Successful in 26s
All checks were successful
Build and Push Docker Image / build (push) Successful in 26s
- Создан шаблон `catalog/index.html` с поддержкой хлебных крошек и активного раздела - Добавлены модели `Category` и `Item` с настройкой админ-панели - Реализован обработчик URL для отображения категорий и страницы каталога - Добавлены стили `catalog.css` и `error.css` для новых элементов - Переведён проект в production режим (DEBUG=False)
This commit is contained in:
19
templates/catalog/index.html
Normal file
19
templates/catalog/index.html
Normal file
@@ -0,0 +1,19 @@
|
||||
{% extends "_layouts/base.html" %}
|
||||
{% load static %}
|
||||
|
||||
{% block title %}Каталог{% endblock %}
|
||||
|
||||
{% block add_css %}
|
||||
<link rel="stylesheet" href="{% static "css/catalog.css" %}">
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<!-- HEADER -->
|
||||
{% include "_fragments/header.html" with active="catalog" %}
|
||||
{% if selected_category.id == None %}
|
||||
{% include '_fragments/breadcrumbs.html' with url_1='/' text_1='Главная' url_2='/catalog/' text_2='Каталог' %}
|
||||
{% else %}
|
||||
{% include '_fragments/breadcrumbs.html' with url_1='/' text_1='Главная' url_2='/catalog/' text_2='Каталог' text_3=selected_category.name %}
|
||||
{% endif %}
|
||||
{% include "_fragments/footer.html" %}
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user