[func] adm. data

main
yaemiku 2022-09-28 20:48:08 +02:00
parent 345c6fa750
commit 000bf734c6
Signed by: podlaskizbs
GPG Key ID: ADC039636B3E4AAB
5 changed files with 52 additions and 15 deletions

View File

@ -18,6 +18,7 @@ def load_config(request):
'uppernav': UpperButton.objects.all(), 'uppernav': UpperButton.objects.all(),
'gpw': GrandPrixW.load(), 'gpw': GrandPrixW.load(),
'posts': Post.objects.filter(published=True), 'posts': Post.objects.filter(published=True),
'daneadresowe': Data.load(),
'czlonkowie': Member.objects.all(), 'czlonkowie': Member.objects.all(),
'statut': Statute.objects.first(), 'statut': Statute.objects.first(),
'ogloszenia': Announcement.objects.all(), 'ogloszenia': Announcement.objects.all(),

View File

@ -2,7 +2,7 @@
<!----> <!---->
{% block title %}Zarząd | pdlzbs{% endblock %} {% block title %}Zarząd | pdlzbs{% endblock %}
<!----> <!---->
{% load static tailwind_tags %} {% block content %} {% load static tailwind_tags wysiwyg %} {% block content %}
<div <div
class="flex flex-col lg:flex-row flex-wrap items-center justify-around gap-6 bg-white shadow-md rounded-md p-4 mb-2" class="flex flex-col lg:flex-row flex-wrap items-center justify-around gap-6 bg-white shadow-md rounded-md p-4 mb-2"
> >
@ -56,20 +56,7 @@
</a> </a>
<h2 class="mt-6">Dane adresowe</h2> <h2 class="mt-6">Dane adresowe</h2>
<h3 <div class="">{% content daneadresowe %}</div>
class="flex flex-col items-center text-center text-xl font-medium px-4 py-3 bg-blue-50 border border-blue-100 rounded-md shadow-md mb-8"
>
<span>Adres Podlaskiego ZBS - <strong>15-057 Białystok</strong></span>
<span><strong>ul. B. Chrobrego 5B m.33</strong></span>
<span
>Konto: PKO SA O/B-tok
<strong
>43&nbsp;1240&nbsp;5211&nbsp;1111&nbsp;0000&nbsp;4919&nbsp;1721</strong
>
</span>
<span>NIP: <strong>542&nbsp;258&nbsp;14&nbsp;53</strong></span>
<span>REGON: <strong>050816091</strong></span>
</h3>
<h2>Członkowie</h2> <h2>Członkowie</h2>
{% if czlonkowie %} {% if czlonkowie %}

View File

@ -0,0 +1,25 @@
# Generated by Django 4.0.5 on 2022-09-28 18:31
from django.db import migrations, models
import tinymce.models
class Migration(migrations.Migration):
dependencies = [
('administration', '0010_alter_announcement_attachment_and_more'),
]
operations = [
migrations.CreateModel(
name='Data',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('content', tinymce.models.HTMLField(blank=True, default='', verbose_name='Dane zarządu')),
],
options={
'verbose_name': 'Dane zarządu',
'verbose_name_plural': 'Dane zarządu',
},
),
]

View File

@ -2,6 +2,7 @@ from django.db import models
from admin_ordering.models import OrderableModel from admin_ordering.models import OrderableModel
from filebrowser.fields import FileBrowseField from filebrowser.fields import FileBrowseField
from core.utils import SingletonModel from core.utils import SingletonModel
from tinymce.models import HTMLField
# Create your models here. # Create your models here.
@ -35,6 +36,17 @@ class Announcement(AttachmentModel):
verbose_name_plural = 'Ogłoszenia' verbose_name_plural = 'Ogłoszenia'
class Data(SingletonModel):
content = HTMLField('Dane zarządu', default='', blank=True)
def __str__(self):
return 'Dane zarządu'
class Meta:
verbose_name = 'Dane zarządu'
verbose_name_plural = 'Dane zarządu'
class Member(OrderableModel): class Member(OrderableModel):
name = models.CharField('Imię i nazwisko', max_length=512) name = models.CharField('Imię i nazwisko', max_length=512)
contact = models.CharField('Dane kontaktowe', max_length=512) contact = models.CharField('Dane kontaktowe', max_length=512)

View File

@ -1309,6 +1309,10 @@ select {
margin-bottom: auto; margin-bottom: auto;
} }
.mt-0 {
margin-top: 0px;
}
.block { .block {
display: block; display: block;
} }
@ -1618,6 +1622,10 @@ select {
line-height: 1.5; line-height: 1.5;
} }
.leading-3 {
line-height: .75rem;
}
.tracking-normal { .tracking-normal {
letter-spacing: 0em; letter-spacing: 0em;
} }
@ -1775,6 +1783,10 @@ h4 {
display: block; display: block;
} }
.prose-headings\:mt-0 :is(:where(h1, h2, h3, h4, th):not(:where([class~="not-prose"] *))) {
margin-top: 0px;
}
.prose-h2\:mb-2 :is(:where(h2):not(:where([class~="not-prose"] *))) { .prose-h2\:mb-2 :is(:where(h2):not(:where([class~="not-prose"] *))) {
margin-bottom: 0.5rem; margin-bottom: 0.5rem;
} }