Added main page. Added links page
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
from django.contrib import admin
|
||||
|
||||
# Register your models here.
|
||||
@@ -0,0 +1,6 @@
|
||||
from django.apps import AppConfig
|
||||
|
||||
|
||||
class MainConfig(AppConfig):
|
||||
default_auto_field = 'django.db.models.BigAutoField'
|
||||
name = 'main'
|
||||
@@ -0,0 +1,3 @@
|
||||
from django.db import models
|
||||
|
||||
# Create your models here.
|
||||
@@ -0,0 +1,33 @@
|
||||
aside.menu {
|
||||
border: 3px solid black;
|
||||
border-radius: 10px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 15px;
|
||||
margin: 25px;
|
||||
}
|
||||
|
||||
aside.menu ul {
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
aside.menu li {
|
||||
display: flex;
|
||||
margin: 10px;
|
||||
}
|
||||
|
||||
aside.menu a {
|
||||
border-radius: 10px;
|
||||
text-decoration: none;
|
||||
color: black;
|
||||
font-weight: bold;
|
||||
background: DeepSkyBlue;
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
aside.menu a:hover {
|
||||
background: DodgerBlue;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
{% extends 'main/pagetemplate.html' %}
|
||||
|
||||
{% block pagetitle %}
|
||||
Главная страница
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="mainpage">
|
||||
<h1>Главная страница</h1>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,30 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
{% load static %}
|
||||
|
||||
<html lang="ru">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>{% block pagetitle %}{% endblock %}</title>
|
||||
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.0-beta1/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-0evHe/X+R7YkIZDRvuzKMRqM+OrBnVFBL6DOitfPri4tjfHxaWutUpFmBp4vmVor" crossorigin="anonymous">
|
||||
<link rel="stylesheet" href="{% static 'main/css/main.css' %}">
|
||||
<link rel="stylesheet" href="{% static 'faerun_calendar/css/main.css' %}">
|
||||
|
||||
<link rel="icon" href="{% static 'iconsmall.png' %}">
|
||||
<link rel="apple-touch-icon" href="{% static 'iconbig.png' %}">
|
||||
</head>
|
||||
<body>
|
||||
<aside class="menu">
|
||||
<ul>
|
||||
<li><a href="/">Главная</a></li>
|
||||
<li><a href="/calendar">Календарь</a></li>
|
||||
<li><a href="/links">Полезные ссылки</a></li>
|
||||
<li><a href="/static/ookona.html">Оокона</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
|
||||
{% block content %}
|
||||
{% endblock %}
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,3 @@
|
||||
from django.test import TestCase
|
||||
|
||||
# Create your tests here.
|
||||
@@ -0,0 +1,8 @@
|
||||
from django.urls import path
|
||||
|
||||
from . import views
|
||||
|
||||
urlpatterns = [
|
||||
path('', views.index, name='index'),
|
||||
]
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
from django.shortcuts import render
|
||||
|
||||
|
||||
def index(request):
|
||||
return render(request, 'main/index.html')
|
||||
Reference in New Issue
Block a user