Compare commits
296 commits
pojmenovan
...
master
Author | SHA1 | Date | |
---|---|---|---|
ef9d51d922 | |||
ca5e6728dd | |||
7563dd728c | |||
174087edc7 | |||
4906f82365 | |||
41032be9eb | |||
422caadb9e | |||
aa997bfcd8 | |||
1a2bef328b | |||
a84df1909b | |||
0724030bef | |||
833893f233 | |||
a7746cddda | |||
0d67b5ff83 | |||
071c66ee10 | |||
1bee36d9b6 | |||
aa364b3f49 | |||
9a11491dcc | |||
a97071cd03 | |||
9c4c60765e | |||
d67d2f372b | |||
65ec9bfaed | |||
7038de2e25 | |||
c43575d8d2 | |||
8d6b352545 | |||
51eeffd0c5 | |||
42d57e7b42 | |||
edde41e1ab | |||
6ea212cdf8 | |||
|
497bb054ee | ||
e9451ed62e | |||
|
e87b84b028 | ||
ddd12b684d | |||
eb2b861d48 | |||
9020f5551d | |||
ca462289a9 | |||
80b20f5290 | |||
dbe8c39b37 | |||
0aee5b9bdb | |||
aee7637fcf | |||
5bf8df0218 | |||
5853b243dd | |||
|
5f87045b31 | ||
|
36b261580c | ||
|
3920ac72aa | ||
dc91ef571f | |||
f0fbd8021f | |||
3d035b994a | |||
db3dd39696 | |||
e0e1dfda41 | |||
|
44766efe2a | ||
d129f8a764 | |||
5b330567f8 | |||
e6a21a5f1b | |||
042246e948 | |||
e224ee66a7 | |||
5ccb94d155 | |||
fa00652a69 | |||
036c68bc2a | |||
fcc2c7c374 | |||
1b755ad1f7 | |||
ad5a242f8d | |||
6186914a7c | |||
7a781e463f | |||
2dbbb588d0 | |||
eada7920f0 | |||
6a7e4b1a39 | |||
5883a5cd28 | |||
7e8092c30c | |||
f01a808ac2 | |||
c8dd54e8ba | |||
|
f2825a97cf | ||
0f6f6a85b6 | |||
502588fd3a | |||
b4b6c7c0ce | |||
0e83f96318 | |||
e660a96df2 | |||
854c902322 | |||
024f8e0a80 | |||
bf726df117 | |||
227d438ebd | |||
71948383d2 | |||
6df9665af3 | |||
c1938c8ff7 | |||
4536c56a83 | |||
8156f7828e | |||
f5c2e22121 | |||
62a42675f8 | |||
a372aa1bc2 | |||
d0cb46b658 | |||
ac6c41cc88 | |||
1c146ac5c3 | |||
527a7b3ea6 | |||
e4a72940e8 | |||
7b3708d7ab | |||
c0825691a6 | |||
b606f03191 | |||
|
461cfa4253 | ||
|
a2517abade | ||
|
51618e0d89 | ||
|
9b14e4a333 | ||
|
8283b530e9 | ||
|
e10747aa9f | ||
|
8ae19988b1 | ||
|
2659d72d2e | ||
007332804e | |||
7f21d10c26 | |||
dc0ff80632 | |||
07d1505e2a | |||
9ca5967261 | |||
eb6eb2d6fb | |||
28fef9a393 | |||
f8b1f0978c | |||
5f931c49a5 | |||
|
5c7710ed3a | ||
6cdc37e80b | |||
8fd582d194 | |||
27a16719be | |||
87a76b17ef | |||
|
ad9a496cee | ||
|
26d37d96f7 | ||
|
062f70e947 | ||
5db14ea242 | |||
|
92c05342fb | ||
b8f377b15d | |||
a6085a64f4 | |||
c71195fba1 | |||
9ee82f72a7 | |||
ce83247fe0 | |||
46a8f136fa | |||
e0dc75763c | |||
788e8d22a2 | |||
11eb3c3665 | |||
446515a52e | |||
|
c7fe1cb386 | ||
|
07e9c8b7e4 | ||
|
10a824719b | ||
|
d288fefecc | ||
|
130907174d | ||
|
33381b4307 | ||
c7910ed72a | |||
35fa97d828 | |||
35131c96ec | |||
acdadc06ab | |||
2ae906495d | |||
|
49e93025c0 | ||
|
d1172b9d38 | ||
|
792a8fa4dc | ||
622b632773 | |||
91b6220f24 | |||
bb0cf871ec | |||
3db6231a77 | |||
d5d55d76a9 | |||
0423bce762 | |||
f9a28689b0 | |||
7108702e36 | |||
e443ecf33d | |||
8d846647f6 | |||
8ff66cb631 | |||
227b83b701 | |||
192f5d2ee7 | |||
77d158a3a7 | |||
05e6e5fb59 | |||
fbd5087c02 | |||
8dca676edc | |||
ffcc2e04a3 | |||
b491dcff7e | |||
592ae29d35 | |||
133c487637 | |||
9f421e9d77 | |||
e87bbe6048 | |||
6ec2a10bf5 | |||
c45bf88d40 | |||
733484b503 | |||
e250f1d5dc | |||
d8d37adc1f | |||
1b01fe54d2 | |||
b41b912aa4 | |||
348096024e | |||
d952ab13a5 | |||
bf748b55ee | |||
6a781323e0 | |||
0b0a939de5 | |||
c34716e134 | |||
85c3969c50 | |||
18364eb531 | |||
95ab0ee1dc | |||
731c795ee6 | |||
31b7cbb8d7 | |||
ba2ea74a04 | |||
a6eebb2d59 | |||
be8c9810e4 | |||
47894ce335 | |||
5f7ec853fa | |||
0cab9a8286 | |||
9920465f99 | |||
99a1fd9a9f | |||
431978e626 | |||
69635b4234 | |||
f0b642ca44 | |||
8dc3a2ba98 | |||
8fef21900c | |||
1d36cd0761 | |||
e21a93f9e7 | |||
ead2a4ede3 | |||
5f9bda9afe | |||
0817012130 | |||
7a6a7cb0f5 | |||
75344c2c3a | |||
350623c6ac | |||
2bb732959a | |||
d55199d6ae | |||
05a710185c | |||
4a3681b1a6 | |||
ccf3ec07f7 | |||
b44bdadb0a | |||
a6220e8d50 | |||
27beb34153 | |||
62a65af40e | |||
036af434c6 | |||
d1db1b952f | |||
ddda7052ae | |||
0fa2fb8e2b | |||
b094347b7c | |||
3188e024da | |||
69019baf4e | |||
ec474530e4 | |||
f564d4e145 | |||
49aea5b8b4 | |||
|
ca8e8506b3 | ||
|
2444e5f985 | ||
476f8263d4 | |||
1ce9cb445f | |||
6225630f9f | |||
0bebee5329 | |||
|
3c3b9f755a | ||
40ca76d414 | |||
cf3c9f6f80 | |||
fad2c6940d | |||
491f91cf47 | |||
|
2304a8282c | ||
|
8a5659420d | ||
|
d895cd0636 | ||
c0958d79db | |||
737c296da9 | |||
|
067cd07352 | ||
|
f75408e936 | ||
|
c917655a22 | ||
|
c78b932587 | ||
|
e431e23ad4 | ||
|
8dbb92d3a4 | ||
af9f244207 | |||
20691f483a | |||
4d13b0eb25 | |||
6cc1b1fbe7 | |||
72f11a25ce | |||
3f1a570878 | |||
53caf7f73a | |||
ed703b10a1 | |||
b8b0c5440f | |||
48123a8ce2 | |||
5eb936d891 | |||
df5ae2c12a | |||
bd1d04802b | |||
8cd3250bb0 | |||
cc09980632 | |||
3363fbdc7c | |||
3f8756148d | |||
7b1e3ab58b | |||
ee7771bdb3 | |||
10c252cd16 | |||
a4a4af5f93 | |||
5048439aee | |||
14e8520b20 | |||
31ee8937f8 | |||
d469019c44 | |||
a1fa654bec | |||
81004d7cdc | |||
da705927c2 | |||
ce54684680 | |||
837986bad8 | |||
d7195a42f1 | |||
264f4d7646 | |||
5bf2df563b | |||
6d270b7af5 | |||
d41eb64ab5 | |||
805ed9204c | |||
3d2f0f08c3 | |||
9cca7beba5 | |||
c5b81871d2 | |||
52dc337a20 | |||
eec9abb9c1 | |||
c731af9ccd | |||
f5e8f5bb77 | |||
72c20d2b94 | |||
b2911d5e9f |
12
.gitignore
vendored
|
@ -31,9 +31,15 @@ TODO
|
||||||
# reversion kvůli historii objektů v reversion
|
# reversion kvůli historii objektů v reversion
|
||||||
**/reversion
|
**/reversion
|
||||||
|
|
||||||
# pro lidi, co programují v nástrojích od JetBrains
|
|
||||||
.idea
|
|
||||||
|
|
||||||
# dokumentace
|
# dokumentace
|
||||||
docs/_build
|
docs/_build
|
||||||
docs/modules
|
docs/modules
|
||||||
|
|
||||||
|
# logy týracího skriptu (./checklinks.sh)
|
||||||
|
/wget.log.*
|
||||||
|
|
||||||
|
# pro lidi, co programují v nástrojích od JetBrains
|
||||||
|
.idea
|
||||||
|
|
||||||
|
# Mac users
|
||||||
|
.DS_Store
|
||||||
|
|
|
@ -1,16 +0,0 @@
|
||||||
git hooks
|
|
||||||
=========
|
|
||||||
|
|
||||||
Kontrola stylu pythoních zdrojáků pomocí flake8. Kontrolujeme jen změny,
|
|
||||||
abychom nenutili lidi dělat nesouvisející úpravy, které by rozbíjely historii
|
|
||||||
(git blame).
|
|
||||||
|
|
||||||
pre-commit
|
|
||||||
----------
|
|
||||||
* kontrola změn před commitnutím
|
|
||||||
* instalace: lokálně zkopírovat do .git/hooks (musí být spustitelný)
|
|
||||||
|
|
||||||
update
|
|
||||||
------
|
|
||||||
* kontrola změn přicházejících s pushem
|
|
||||||
* instalace: na atreyi zkopírovat do /akce/MaM/MaMweb/mamweb.git/hooks
|
|
|
@ -1,30 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
#
|
|
||||||
# Git hook script to verify what is about to be committed.
|
|
||||||
# Checks that the changes don't introduce new flake8 errors.
|
|
||||||
|
|
||||||
TMPDIFF=`tempfile`
|
|
||||||
FLAKE8="`git rev-parse --show-toplevel`/bin/flake8"
|
|
||||||
|
|
||||||
status=0
|
|
||||||
|
|
||||||
# select only changed python files which are not migrations
|
|
||||||
changed=`git diff --cached --name-only | grep 'py$' | grep -v 'migrations/[0-9]'`
|
|
||||||
if [ -z $changed ] ; then
|
|
||||||
# Nothing to check. Note the exit is necessary -- we would not pass any
|
|
||||||
# paths to git diff below and it would output the diff unfiltered.
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
git diff --unified=1 --cached HEAD -- $changed > $TMPDIFF
|
|
||||||
|
|
||||||
# only do the check when there are some changes to be commited
|
|
||||||
# otherwise flake8 would hang waiting for input
|
|
||||||
if [ -s $TMPDIFF ] ; then
|
|
||||||
cat $TMPDIFF | $FLAKE8 --diff
|
|
||||||
status=$?
|
|
||||||
fi
|
|
||||||
|
|
||||||
rm -f $TMPDIFF
|
|
||||||
|
|
||||||
exit $status
|
|
|
@ -1,61 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
# git update hook to check that pushed changes don't introduce new flake8
|
|
||||||
# errors
|
|
||||||
|
|
||||||
# --- Command line
|
|
||||||
refname="$1"
|
|
||||||
oldrev="$2"
|
|
||||||
newrev="$3"
|
|
||||||
|
|
||||||
# --- Safety check
|
|
||||||
if [ -z "$GIT_DIR" ]; then
|
|
||||||
echo "Don't run this script from the command line." >&2
|
|
||||||
echo " (if you want, you could supply GIT_DIR then run" >&2
|
|
||||||
echo " $0 <ref> <oldrev> <newrev>)" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -z "$refname" -o -z "$oldrev" -o -z "$newrev" ]; then
|
|
||||||
echo "usage: $0 <ref> <oldrev> <newrev>" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
TMPDIR=`mktemp -d`
|
|
||||||
TMPDIFF=`tempfile`
|
|
||||||
|
|
||||||
[ $refname != "refs/heads/master" -a $refname != "refs/heads/stable" ] && exit 0
|
|
||||||
|
|
||||||
# select only changed python files which are not migrations
|
|
||||||
changed=`git diff --name-only $oldrev $newrev | grep 'py$' | grep -v 'migrations/[0-9]'`
|
|
||||||
if [ -z $changed ] ; then
|
|
||||||
# Nothing to check. Note the exit is necessary -- we would not pass any
|
|
||||||
# paths to git diff below and it would output the diff unfiltered.
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
git diff --unified=1 $oldrev $newrev -- $changed >${TMPDIFF}
|
|
||||||
|
|
||||||
# there is no working tree in bare git repository, so we recreate it for flake8
|
|
||||||
git archive $newrev | tar -x -C ${TMPDIR}
|
|
||||||
|
|
||||||
cd ${TMPDIR}
|
|
||||||
# report only errors on lines in diff
|
|
||||||
# (if threre was flake8 installed on atrey, we could just call flake8)
|
|
||||||
/akce/MaM/WWW/mamweb-test/bin/flake8 --diff <${TMPDIFF}
|
|
||||||
status=$?
|
|
||||||
if [ $status != 0 ] ; then
|
|
||||||
echo
|
|
||||||
echo -n "Změny, které se snažíte pushnout, obsahují kód v pythonu "
|
|
||||||
echo -n "nevyhovující flake8 (viz výše). Opravte je a zkuste to znovu. "
|
|
||||||
echo -n "Nezapomeňte, že můžete editovat historii (git commit --amend, "
|
|
||||||
echo -n "git rebase -i). Pokud byste chybu příště raději odhalili už při "
|
|
||||||
echo "commitu, zkopírujte si pre-commit hook z _git_hooks do .git/hooks."
|
|
||||||
echo
|
|
||||||
fi
|
|
||||||
|
|
||||||
rm -rf ${TMPDIR}
|
|
||||||
rm -f ${TMPDIFF}
|
|
||||||
|
|
||||||
exit $status
|
|
|
@ -1,6 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící k pojmenování a jiným nastavením djangovské aplikace.
|
|
||||||
"""
|
|
||||||
from django.apps import AppConfig
|
from django.apps import AppConfig
|
||||||
|
|
||||||
class AesopConfig(AppConfig):
|
class AesopConfig(AppConfig):
|
||||||
|
|
|
@ -1,10 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící jako „router“, tj. zde se definují url adresy a na co ukazují:
|
|
||||||
|
|
||||||
- ``aesop-export/mam-rocnik-<int:prvni_rok>.csv`` (seminar_export_rocnik) :class:`~aesop.views.ExportRocnikView`
|
|
||||||
- ``aesop-export/mam-sous-<str:datum_zacatku>.csv`` (seminar_export_sous) :class:`~aesop.views.ExportSousView`
|
|
||||||
- ``aesop-export/index.csv`` (seminar_export_index) :class:`~aesop.views.ExportIndexView`
|
|
||||||
"""
|
|
||||||
from django.urls import path
|
from django.urls import path
|
||||||
from aesop import views
|
from aesop import views
|
||||||
|
|
||||||
|
@ -12,16 +5,16 @@ urlpatterns = [
|
||||||
path(
|
path(
|
||||||
'aesop-export/mam-rocnik-<int:prvni_rok>.csv',
|
'aesop-export/mam-rocnik-<int:prvni_rok>.csv',
|
||||||
views.ExportRocnikView.as_view(),
|
views.ExportRocnikView.as_view(),
|
||||||
name='seminar_export_rocnik'
|
name='aesop_export_rocnik'
|
||||||
),
|
),
|
||||||
path(
|
path(
|
||||||
'aesop-export/mam-sous-<str:datum_zacatku>.csv',
|
'aesop-export/mam-sous-<str:datum_zacatku>.csv',
|
||||||
views.ExportSousView.as_view(),
|
views.ExportSousView.as_view(),
|
||||||
name='seminar_export_sous'
|
name='aesop_export_sous'
|
||||||
),
|
),
|
||||||
path(
|
path(
|
||||||
'aesop-export/index.csv',
|
'aesop-export/index.csv',
|
||||||
views.ExportIndexView.as_view(),
|
views.ExportIndexView.as_view(),
|
||||||
name='seminar_export_index'
|
name='aesop_export_index'
|
||||||
),
|
),
|
||||||
]
|
]
|
||||||
|
|
|
@ -1,8 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící k deklaraci jednotlivých „views“ (nejčastěji funkce beroucí request
|
|
||||||
a vracející :func:`django.shortcuts.render` respektive nějakou response, nebo
|
|
||||||
třídy většinou rozšiřující nějakou třídu z :mod:`django.views.generic`)
|
|
||||||
"""
|
|
||||||
import django
|
import django
|
||||||
from django.shortcuts import get_object_or_404
|
from django.shortcuts import get_object_or_404
|
||||||
from django.http import HttpResponse
|
from django.http import HttpResponse
|
||||||
|
@ -11,18 +6,19 @@ from django.views import generic
|
||||||
from django.utils.encoding import force_str
|
from django.utils.encoding import force_str
|
||||||
|
|
||||||
from .utils import default_ovvpfile
|
from .utils import default_ovvpfile
|
||||||
from seminar.models import Rocnik, Soustredeni
|
from soustredeni.models import Soustredeni
|
||||||
|
from tvorba.models import Rocnik
|
||||||
from vysledkovky import utils
|
from vysledkovky import utils
|
||||||
from seminar.utils import aktivniResitele
|
from tvorba.utils import aktivniResitele
|
||||||
|
|
||||||
class ExportIndexView(generic.View):
|
class ExportIndexView(generic.View):
|
||||||
def get(self, request):
|
def get(self, request):
|
||||||
ls = []
|
ls = []
|
||||||
for r in Rocnik.objects.filter(exportovat = True):
|
for r in Rocnik.objects.filter(exportovat = True):
|
||||||
url = reverse('seminar_export_rocnik', kwargs={'prvni_rok': r.prvni_rok})
|
url = reverse('aesop_export_rocnik', kwargs={'prvni_rok': r.prvni_rok})
|
||||||
ls.append(url.split('/')[-1])
|
ls.append(url.split('/')[-1])
|
||||||
for s in Soustredeni.objects.filter(exportovat = True):
|
for s in Soustredeni.objects.filter(exportovat = True):
|
||||||
url = reverse('seminar_export_sous', kwargs={'datum_zacatku': s.datum_zacatku.isoformat()})
|
url = reverse('aesop_export_sous', kwargs={'datum_zacatku': s.datum_zacatku.isoformat()})
|
||||||
ls.append(url.split('/')[-1])
|
ls.append(url.split('/')[-1])
|
||||||
|
|
||||||
return HttpResponse('\n'.join(ls) + '\n', content_type='text/plain; charset=utf-8')
|
return HttpResponse('\n'.join(ls) + '\n', content_type='text/plain; charset=utf-8')
|
||||||
|
|
|
@ -1,6 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící k pojmenování a jiným nastavením djangovské aplikace.
|
|
||||||
"""
|
|
||||||
from django.apps import AppConfig
|
from django.apps import AppConfig
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
from django.test import TestCase, tag
|
from django.test import TestCase, tag
|
||||||
from django.urls import reverse
|
from django.urls import reverse
|
||||||
import seminar.models as m
|
from personalni.models import Skola
|
||||||
import seminar.views as v
|
from personalni.utils import sync_skoly
|
||||||
from seminar.utils import sync_skoly
|
|
||||||
|
|
||||||
@tag('stejny-model-na-produkci')
|
@tag('stejny-model-na-produkci')
|
||||||
class OrgSkolyAutocompleteTestCase(TestCase):
|
class OrgSkolyAutocompleteTestCase(TestCase):
|
||||||
|
@ -49,7 +48,7 @@ class OrgSkolyAutocompleteTestCase(TestCase):
|
||||||
"""Testuje, že pro každého orga je jeho škola ve výsledném QuerySetu"""
|
"""Testuje, že pro každého orga je jeho škola ve výsledném QuerySetu"""
|
||||||
for pfx, id in self.spravna_data:
|
for pfx, id in self.spravna_data:
|
||||||
with self.subTest(prefix=pfx, spravne_id=id):
|
with self.subTest(prefix=pfx, spravne_id=id):
|
||||||
spravna_skola = m.Skola.objects.get(id=id)
|
spravna_skola = Skola.objects.get(id=id)
|
||||||
# Zeptáme se view, co si myslí
|
# Zeptáme se view, co si myslí
|
||||||
resp = self.client.get(reverse('autocomplete_skola')+'?q='+pfx).json()
|
resp = self.client.get(reverse('autocomplete_skola')+'?q='+pfx).json()
|
||||||
ids = [int(x['id']) for x in resp['results']]
|
ids = [int(x['id']) for x in resp['results']]
|
||||||
|
|
16
api/urls.py
|
@ -1,18 +1,6 @@
|
||||||
"""
|
|
||||||
Soubor sloužící jako „router“, tj. zde se definují url adresy a na co ukazují:
|
|
||||||
|
|
||||||
- ``api/expor/skoly/`` (export_skoly) :func:`~api.views.exports.exportSkolView`
|
|
||||||
- ``api/autocomplete/skola/`` (autocomplete_skola) :class:`~api.views.autocomplete.SkolaAutocomplete`
|
|
||||||
- ``api/autocomplete/resitel/`` (autocomplete_resitel) :class:`~api.views.autocomplete.ResitelAutocomplete`
|
|
||||||
- ``api/autocomplete/problem/odevzdatelny`` (autocomplete_problem_odevzdatelny) :class:`~api.views.autocomplete.OdevzdatelnyProblemAutocomplete`
|
|
||||||
|
|
||||||
Na autocomplete v3 čeká:
|
|
||||||
|
|
||||||
- ``autocomplete/organizatori/`` (seminar_autocomplete_organizator) :class:`~api.views.autocomplete.OrganizatorAutocomplete`
|
|
||||||
"""
|
|
||||||
from django.urls import path
|
from django.urls import path
|
||||||
from . import views
|
from . import views
|
||||||
from seminar.utils import org_required
|
from personalni.utils import org_required
|
||||||
|
|
||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
# Export škol
|
# Export škol
|
||||||
|
@ -29,5 +17,5 @@ urlpatterns = [
|
||||||
# Ceka na autocomplete v3
|
# Ceka na autocomplete v3
|
||||||
# path('autocomplete/organizatori/',
|
# path('autocomplete/organizatori/',
|
||||||
# org_member_required(views.OrganizatorAutocomplete.as_view()),
|
# org_member_required(views.OrganizatorAutocomplete.as_view()),
|
||||||
# name='seminar_autocomplete_organizator')
|
# name='autocomplete_organizator')
|
||||||
]
|
]
|
||||||
|
|
|
@ -1,7 +1,2 @@
|
||||||
"""
|
|
||||||
Soubory sloužící k deklaraci jednotlivých „views“ (nejčastěji funkce beroucí request
|
|
||||||
a vracející :func:`django.shortcuts.render` respektive nějakou response, nebo
|
|
||||||
třídy většinou rozšiřující nějakou třídu z :mod:`django.views.generic`)
|
|
||||||
"""
|
|
||||||
from .autocomplete import *
|
from .autocomplete import *
|
||||||
from .exports import *
|
from .exports import *
|
||||||
|
|
|
@ -5,7 +5,9 @@ from dal import autocomplete
|
||||||
from django.shortcuts import get_object_or_404
|
from django.shortcuts import get_object_or_404
|
||||||
from django.db.models import Q
|
from django.db.models import Q
|
||||||
|
|
||||||
import seminar.models as m
|
from personalni.models import Skola, Resitel
|
||||||
|
from tvorba.models import Problem
|
||||||
|
from various.models import Nastaveni
|
||||||
from .helpers import LoginRequiredAjaxMixin
|
from .helpers import LoginRequiredAjaxMixin
|
||||||
|
|
||||||
# TODO filosofie - zkratky, jak v databázi, tak ve vyhledávání (SPŠE, GASOŠ, Kpt., soukr)
|
# TODO filosofie - zkratky, jak v databázi, tak ve vyhledávání (SPŠE, GASOŠ, Kpt., soukr)
|
||||||
|
@ -13,7 +15,7 @@ class SkolaAutocomplete(autocomplete.Select2QuerySetView):
|
||||||
""" View k :mod:`dal.autocomplete` pro vyhledávání škol hlavně při registraci. """
|
""" View k :mod:`dal.autocomplete` pro vyhledávání škol hlavně při registraci. """
|
||||||
def get_queryset(self):
|
def get_queryset(self):
|
||||||
# Don't forget to filter out results depending on the visitor !
|
# Don't forget to filter out results depending on the visitor !
|
||||||
qs = m.Skola.objects.all()
|
qs = Skola.objects.all()
|
||||||
if self.q:
|
if self.q:
|
||||||
words = self.q.split(' ') #TODO re split podle bileho znaku
|
words = self.q.split(' ') #TODO re split podle bileho znaku
|
||||||
partq = Q()
|
partq = Q()
|
||||||
|
@ -31,7 +33,7 @@ class SkolaAutocomplete(autocomplete.Select2QuerySetView):
|
||||||
class ResitelAutocomplete(LoginRequiredAjaxMixin,autocomplete.Select2QuerySetView):
|
class ResitelAutocomplete(LoginRequiredAjaxMixin,autocomplete.Select2QuerySetView):
|
||||||
""" View k :mod:`dal.autocomplete` pro vyhledávání řešitelů především v odevzdávátku. """
|
""" View k :mod:`dal.autocomplete` pro vyhledávání řešitelů především v odevzdávátku. """
|
||||||
def get_queryset(self):
|
def get_queryset(self):
|
||||||
qs = m.Resitel.objects.all()
|
qs = Resitel.objects.all()
|
||||||
if self.q:
|
if self.q:
|
||||||
parts = self.q.split()
|
parts = self.q.split()
|
||||||
query = Q()
|
query = Q()
|
||||||
|
@ -51,8 +53,8 @@ class PublicResitelAutocomplete(LoginRequiredAjaxMixin, autocomplete.Select2Quer
|
||||||
především v odevzdávátku.
|
především v odevzdávátku.
|
||||||
"""
|
"""
|
||||||
def get_queryset(self):
|
def get_queryset(self):
|
||||||
letos = m.Nastaveni.get_solo().aktualni_rocnik
|
letos = Nastaveni.get_solo().aktualni_rocnik
|
||||||
qs = m.Resitel.objects.filter(
|
qs = Resitel.objects.filter(
|
||||||
rok_maturity__gte=letos.druhy_rok()
|
rok_maturity__gte=letos.druhy_rok()
|
||||||
).filter(
|
).filter(
|
||||||
prezdivka_resitele__isnull=False
|
prezdivka_resitele__isnull=False
|
||||||
|
@ -70,7 +72,7 @@ class PublicResitelAutocomplete(LoginRequiredAjaxMixin, autocomplete.Select2Quer
|
||||||
class OdevzdatelnyProblemAutocomplete(autocomplete.Select2QuerySetView):
|
class OdevzdatelnyProblemAutocomplete(autocomplete.Select2QuerySetView):
|
||||||
""" View k :mod:`dal.autocomplete` pro vyhledávání problémů především v odevzdávátku. """
|
""" View k :mod:`dal.autocomplete` pro vyhledávání problémů především v odevzdávátku. """
|
||||||
def get_queryset(self):
|
def get_queryset(self):
|
||||||
qs = m.Problem.objects.filter(stav=m.Problem.STAV_ZADANY)
|
qs = Problem.objects.filter(stav=Problem.STAV_ZADANY)
|
||||||
if self.q:
|
if self.q:
|
||||||
qs = qs.filter(
|
qs = qs.filter(
|
||||||
Q(nazev__icontains=self.q))
|
Q(nazev__icontains=self.q))
|
||||||
|
@ -87,12 +89,12 @@ class ProblemAutocomplete(autocomplete.Select2QuerySetView):
|
||||||
""" View k :mod:`dal.autocomplete` pro vyhledávání problémů především v odevzdávátku. """
|
""" View k :mod:`dal.autocomplete` pro vyhledávání problémů především v odevzdávátku. """
|
||||||
def get_queryset(self):
|
def get_queryset(self):
|
||||||
# FIXME i starší úlohy
|
# FIXME i starší úlohy
|
||||||
nastaveni = get_object_or_404(m.Nastaveni)
|
nastaveni = get_object_or_404(Nastaveni)
|
||||||
rocnik = nastaveni.aktualni_rocnik
|
rocnik = nastaveni.aktualni_rocnik
|
||||||
temaQ = Q(Tema___rocnik = rocnik)
|
temaQ = Q(Tema___rocnik = rocnik)
|
||||||
ulohaQ = Q(Uloha___cislo_zadani__rocnik=rocnik)
|
ulohaQ = Q(Uloha___cislo_zadani__rocnik=rocnik)
|
||||||
clanekQ = Q(Clanek___cislo__rocnik=rocnik)
|
clanekQ = Q(Clanek___cislo__rocnik=rocnik)
|
||||||
qs = m.Problem.objects.filter(temaQ | ulohaQ | clanekQ).order_by("-stav", "nazev")
|
qs = Problem.objects.filter(temaQ | ulohaQ | clanekQ).order_by("-stav", "nazev")
|
||||||
if self.q:
|
if self.q:
|
||||||
qs = qs.filter(
|
qs = qs.filter(
|
||||||
Q(nazev__icontains=self.q))
|
Q(nazev__icontains=self.q))
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import seminar.models as m
|
import personalni.models as m
|
||||||
from django.core import serializers as ser
|
from django.core import serializers as ser
|
||||||
from django.http import HttpResponse
|
from django.http import HttpResponse
|
||||||
def exportSkolView(request):
|
def exportSkolView(request):
|
||||||
|
|
645
data/groups.json
Normal file
|
@ -0,0 +1,645 @@
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"fields": {
|
||||||
|
"name": "org",
|
||||||
|
"permissions": [
|
||||||
|
[
|
||||||
|
"org",
|
||||||
|
"auth",
|
||||||
|
"user"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_flatpage",
|
||||||
|
"flatpages",
|
||||||
|
"flatpage"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_flatpage",
|
||||||
|
"flatpages",
|
||||||
|
"flatpage"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_flatpage",
|
||||||
|
"flatpages",
|
||||||
|
"flatpage"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_flatpage",
|
||||||
|
"flatpages",
|
||||||
|
"flatpage"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_galerie",
|
||||||
|
"galerie",
|
||||||
|
"galerie"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_galerie",
|
||||||
|
"galerie",
|
||||||
|
"galerie"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_galerie",
|
||||||
|
"galerie",
|
||||||
|
"galerie"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_galerie",
|
||||||
|
"galerie",
|
||||||
|
"galerie"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_obrazek",
|
||||||
|
"galerie",
|
||||||
|
"obrazek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_obrazek",
|
||||||
|
"galerie",
|
||||||
|
"obrazek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_obrazek",
|
||||||
|
"galerie",
|
||||||
|
"obrazek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_obrazek",
|
||||||
|
"galerie",
|
||||||
|
"obrazek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_fotkaheader",
|
||||||
|
"header_fotky",
|
||||||
|
"fotkaheader"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_fotkaheader",
|
||||||
|
"header_fotky",
|
||||||
|
"fotkaheader"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_fotkaheader",
|
||||||
|
"header_fotky",
|
||||||
|
"fotkaheader"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_fotkaurlvazba",
|
||||||
|
"header_fotky",
|
||||||
|
"fotkaurlvazba"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_fotkaurlvazba",
|
||||||
|
"header_fotky",
|
||||||
|
"fotkaurlvazba"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_fotkaurlvazba",
|
||||||
|
"header_fotky",
|
||||||
|
"fotkaurlvazba"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_komentar",
|
||||||
|
"korektury",
|
||||||
|
"komentar"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_komentar",
|
||||||
|
"korektury",
|
||||||
|
"komentar"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_komentar",
|
||||||
|
"korektury",
|
||||||
|
"komentar"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_komentar",
|
||||||
|
"korektury",
|
||||||
|
"komentar"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_korekturovanepdf",
|
||||||
|
"korektury",
|
||||||
|
"korekturovanepdf"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_korekturovanepdf",
|
||||||
|
"korektury",
|
||||||
|
"korekturovanepdf"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_korekturovanepdf",
|
||||||
|
"korektury",
|
||||||
|
"korekturovanepdf"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_korekturovanepdf",
|
||||||
|
"korektury",
|
||||||
|
"korekturovanepdf"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_oprava",
|
||||||
|
"korektury",
|
||||||
|
"oprava"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_oprava",
|
||||||
|
"korektury",
|
||||||
|
"oprava"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_oprava",
|
||||||
|
"korektury",
|
||||||
|
"oprava"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_oprava",
|
||||||
|
"korektury",
|
||||||
|
"oprava"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_novinky",
|
||||||
|
"novinky",
|
||||||
|
"novinky"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_novinky",
|
||||||
|
"novinky",
|
||||||
|
"novinky"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_novinky",
|
||||||
|
"novinky",
|
||||||
|
"novinky"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_novinky",
|
||||||
|
"novinky",
|
||||||
|
"novinky"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_organizator",
|
||||||
|
"personalni",
|
||||||
|
"organizator"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_organizator",
|
||||||
|
"personalni",
|
||||||
|
"organizator"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_osoba",
|
||||||
|
"personalni",
|
||||||
|
"osoba"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_osoba",
|
||||||
|
"personalni",
|
||||||
|
"osoba"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_prijemce",
|
||||||
|
"personalni",
|
||||||
|
"prijemce"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_prijemce",
|
||||||
|
"personalni",
|
||||||
|
"prijemce"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_prijemce",
|
||||||
|
"personalni",
|
||||||
|
"prijemce"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_prijemce",
|
||||||
|
"personalni",
|
||||||
|
"prijemce"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_resitel",
|
||||||
|
"personalni",
|
||||||
|
"resitel"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_resitel",
|
||||||
|
"personalni",
|
||||||
|
"resitel"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_skola",
|
||||||
|
"personalni",
|
||||||
|
"skola"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_skola",
|
||||||
|
"personalni",
|
||||||
|
"skola"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_skola",
|
||||||
|
"personalni",
|
||||||
|
"skola"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_skola",
|
||||||
|
"personalni",
|
||||||
|
"skola"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_hlasovani",
|
||||||
|
"prednasky",
|
||||||
|
"hlasovani"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_hlasovani",
|
||||||
|
"prednasky",
|
||||||
|
"hlasovani"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_hlasovani",
|
||||||
|
"prednasky",
|
||||||
|
"hlasovani"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_hlasovani",
|
||||||
|
"prednasky",
|
||||||
|
"hlasovani"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_prednaska",
|
||||||
|
"prednasky",
|
||||||
|
"prednaska"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_prednaska",
|
||||||
|
"prednasky",
|
||||||
|
"prednaska"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_prednaska",
|
||||||
|
"prednasky",
|
||||||
|
"prednaska"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_prednaska",
|
||||||
|
"prednasky",
|
||||||
|
"prednaska"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_seznam",
|
||||||
|
"prednasky",
|
||||||
|
"seznam"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_seznam",
|
||||||
|
"prednasky",
|
||||||
|
"seznam"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_seznam",
|
||||||
|
"prednasky",
|
||||||
|
"seznam"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_seznam",
|
||||||
|
"prednasky",
|
||||||
|
"seznam"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_konfera",
|
||||||
|
"soustredeni",
|
||||||
|
"konfera"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_konfera",
|
||||||
|
"soustredeni",
|
||||||
|
"konfera"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_konfera",
|
||||||
|
"soustredeni",
|
||||||
|
"konfera"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_konfera",
|
||||||
|
"soustredeni",
|
||||||
|
"konfera"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_konfery_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"konfery_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_konfery_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"konfery_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_konfery_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"konfery_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_konfery_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"konfery_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_soustredeni",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_soustredeni",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_soustredeni",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_soustredeni",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_soustredeni_organizatori",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_organizatori"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_soustredeni_organizatori",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_organizatori"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_soustredeni_organizatori",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_organizatori"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_soustredeni_organizatori",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_organizatori"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_soustredeni_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_soustredeni_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_soustredeni_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_soustredeni_ucastnici",
|
||||||
|
"soustredeni",
|
||||||
|
"soustredeni_ucastnici"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_tag",
|
||||||
|
"taggit",
|
||||||
|
"tag"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_tag",
|
||||||
|
"taggit",
|
||||||
|
"tag"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_tag",
|
||||||
|
"taggit",
|
||||||
|
"tag"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_tag",
|
||||||
|
"taggit",
|
||||||
|
"tag"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_taggeditem",
|
||||||
|
"taggit",
|
||||||
|
"taggeditem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_taggeditem",
|
||||||
|
"taggit",
|
||||||
|
"taggeditem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_taggeditem",
|
||||||
|
"taggit",
|
||||||
|
"taggeditem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_taggeditem",
|
||||||
|
"taggit",
|
||||||
|
"taggeditem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_cislo",
|
||||||
|
"tvorba",
|
||||||
|
"cislo"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_cislo",
|
||||||
|
"tvorba",
|
||||||
|
"cislo"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_cislo",
|
||||||
|
"tvorba",
|
||||||
|
"cislo"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_cislo",
|
||||||
|
"tvorba",
|
||||||
|
"cislo"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_clanek",
|
||||||
|
"tvorba",
|
||||||
|
"clanek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_clanek",
|
||||||
|
"tvorba",
|
||||||
|
"clanek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_clanek",
|
||||||
|
"tvorba",
|
||||||
|
"clanek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_clanek",
|
||||||
|
"tvorba",
|
||||||
|
"clanek"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_deadline",
|
||||||
|
"tvorba",
|
||||||
|
"deadline"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_deadline",
|
||||||
|
"tvorba",
|
||||||
|
"deadline"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_deadline",
|
||||||
|
"tvorba",
|
||||||
|
"deadline"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_pohadka",
|
||||||
|
"tvorba",
|
||||||
|
"pohadka"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_pohadka",
|
||||||
|
"tvorba",
|
||||||
|
"pohadka"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_pohadka",
|
||||||
|
"tvorba",
|
||||||
|
"pohadka"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_pohadka",
|
||||||
|
"tvorba",
|
||||||
|
"pohadka"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_problem",
|
||||||
|
"tvorba",
|
||||||
|
"problem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_problem",
|
||||||
|
"tvorba",
|
||||||
|
"problem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_problem",
|
||||||
|
"tvorba",
|
||||||
|
"problem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_problem",
|
||||||
|
"tvorba",
|
||||||
|
"problem"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_rocnik",
|
||||||
|
"tvorba",
|
||||||
|
"rocnik"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_rocnik",
|
||||||
|
"tvorba",
|
||||||
|
"rocnik"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_rocnik",
|
||||||
|
"tvorba",
|
||||||
|
"rocnik"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_rocnik",
|
||||||
|
"tvorba",
|
||||||
|
"rocnik"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_tema",
|
||||||
|
"tvorba",
|
||||||
|
"tema"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_tema",
|
||||||
|
"tvorba",
|
||||||
|
"tema"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_tema",
|
||||||
|
"tvorba",
|
||||||
|
"tema"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_tema",
|
||||||
|
"tvorba",
|
||||||
|
"tema"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_uloha",
|
||||||
|
"tvorba",
|
||||||
|
"uloha"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_uloha",
|
||||||
|
"tvorba",
|
||||||
|
"uloha"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_uloha",
|
||||||
|
"tvorba",
|
||||||
|
"uloha"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_uloha",
|
||||||
|
"tvorba",
|
||||||
|
"uloha"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"add_nastaveni",
|
||||||
|
"various",
|
||||||
|
"nastaveni"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"delete_nastaveni",
|
||||||
|
"various",
|
||||||
|
"nastaveni"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"change_nastaveni",
|
||||||
|
"various",
|
||||||
|
"nastaveni"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"view_nastaveni",
|
||||||
|
"various",
|
||||||
|
"nastaveni"
|
||||||
|
]
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"model": "auth.group",
|
||||||
|
"pk": 1
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fields": {
|
||||||
|
"name": "resitel",
|
||||||
|
"permissions": [
|
||||||
|
[
|
||||||
|
"resitel",
|
||||||
|
"auth",
|
||||||
|
"user"
|
||||||
|
]
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"model": "auth.group",
|
||||||
|
"pk": 2
|
||||||
|
}
|
||||||
|
]
|
|
@ -73,7 +73,7 @@
|
||||||
"sort_order": 3,
|
"sort_order": 3,
|
||||||
"title": "Aktuální<br/> ročník",
|
"title": "Aktuální<br/> ročník",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_aktualni_zadani",
|
"url": "tvorba_aktualni_zadani",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -121,7 +121,7 @@
|
||||||
"sort_order": 5,
|
"sort_order": 5,
|
||||||
"title": "Archiv",
|
"title": "Archiv",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_archiv_rocniky",
|
"url": "tvorba_archiv_rocniky",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -289,7 +289,7 @@
|
||||||
"sort_order": 43,
|
"sort_order": 43,
|
||||||
"title": "Výsledková listina",
|
"title": "Výsledková listina",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_aktualni_vysledky",
|
"url": "tvorba_aktualni_vysledky",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -361,7 +361,7 @@
|
||||||
"sort_order": 20,
|
"sort_order": 20,
|
||||||
"title": "Proběhlo",
|
"title": "Proběhlo",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_seznam_soustredeni",
|
"url": "soustredeni_seznam",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -409,7 +409,7 @@
|
||||||
"sort_order": 23,
|
"sort_order": 23,
|
||||||
"title": "Osobní údaje",
|
"title": "Osobní údaje",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_resitel_edit",
|
"url": "personalni_resitel_edit",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -439,7 +439,7 @@
|
||||||
"sort_order": 36,
|
"sort_order": 36,
|
||||||
"title": "Nahrát řešení",
|
"title": "Nahrát řešení",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_nahraj_reseni",
|
"url": "odevzdavatko_nahraj_reseni",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -463,7 +463,7 @@
|
||||||
"sort_order": 35,
|
"sort_order": 35,
|
||||||
"title": "Témata",
|
"title": "Témata",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_archiv_temata",
|
"url": "tvorba_archiv_temata",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -589,7 +589,7 @@
|
||||||
"sort_order": 15,
|
"sort_order": 15,
|
||||||
"title": "Aktuální číslo",
|
"title": "Aktuální číslo",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_aktualni_zadani",
|
"url": "tvorba_aktualni_zadani",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -613,7 +613,7 @@
|
||||||
"sort_order": 24,
|
"sort_order": 24,
|
||||||
"title": "Čísla",
|
"title": "Čísla",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_archiv_rocniky",
|
"url": "tvorba_archiv_rocniky",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -721,7 +721,7 @@
|
||||||
"sort_order": 36,
|
"sort_order": 36,
|
||||||
"title": "Vložit řešení",
|
"title": "Vložit řešení",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_vloz_reseni",
|
"url": "odevzdavatko_vloz_reseni",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -804,7 +804,7 @@
|
||||||
"sort_order": 37,
|
"sort_order": 37,
|
||||||
"title": "Moje řešení",
|
"title": "Moje řešení",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_resitel_odevzdana_reseni",
|
"url": "odevzdavatko_resitel_odevzdana_reseni",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -828,7 +828,7 @@
|
||||||
"sort_order": 33,
|
"sort_order": 33,
|
||||||
"title": "Aktuální ročník",
|
"title": "Aktuální ročník",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_aktualni_rocnik",
|
"url": "tvorba_aktualni_rocnik",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -900,7 +900,7 @@
|
||||||
"sort_order": 46,
|
"sort_order": 46,
|
||||||
"title": "Ročník {{rocnik.rocnik}}",
|
"title": "Ročník {{rocnik.rocnik}}",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_rocnik rocnik.rocnik",
|
"url": "tvorba_rocnik rocnik.rocnik",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -924,7 +924,7 @@
|
||||||
"sort_order": 47,
|
"sort_order": 47,
|
||||||
"title": "Číslo {{ cislo.rocnik.rocnik }}.{{ cislo.poradi }}",
|
"title": "Číslo {{ cislo.rocnik.rocnik }}.{{ cislo.poradi }}",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_cislo cislo.rocnik.rocnik cislo.poradi",
|
"url": "tvorba_cislo cislo.rocnik.rocnik cislo.poradi",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -1007,7 +1007,18 @@
|
||||||
"access_guest": false,
|
"access_guest": false,
|
||||||
"access_loggedin": false,
|
"access_loggedin": false,
|
||||||
"access_perm_type": 1,
|
"access_perm_type": 1,
|
||||||
"access_permissions": [],
|
"access_permissions": [
|
||||||
|
[
|
||||||
|
"org",
|
||||||
|
"auth",
|
||||||
|
"user"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"resitel",
|
||||||
|
"auth",
|
||||||
|
"user"
|
||||||
|
]
|
||||||
|
],
|
||||||
"access_restricted": true,
|
"access_restricted": true,
|
||||||
"alias": null,
|
"alias": null,
|
||||||
"description": "",
|
"description": "",
|
||||||
|
@ -1050,7 +1061,7 @@
|
||||||
"sort_order": 52,
|
"sort_order": 52,
|
||||||
"title": "Nahrát řešení k nadproblému {{nadproblem_id}}",
|
"title": "Nahrát řešení k nadproblému {{nadproblem_id}}",
|
||||||
"tree": 1,
|
"tree": 1,
|
||||||
"url": "seminar_nahraj_reseni nadproblem_id",
|
"url": "odevzdavatko_nahraj_reseni nadproblem_id",
|
||||||
"urlaspattern": true
|
"urlaspattern": true
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
|
@ -1079,5 +1090,29 @@
|
||||||
},
|
},
|
||||||
"model": "sitetree.treeitem",
|
"model": "sitetree.treeitem",
|
||||||
"pk": 53
|
"pk": 53
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fields": {
|
||||||
|
"access_guest": false,
|
||||||
|
"access_loggedin": false,
|
||||||
|
"access_perm_type": 1,
|
||||||
|
"access_permissions": [],
|
||||||
|
"access_restricted": false,
|
||||||
|
"alias": null,
|
||||||
|
"description": "",
|
||||||
|
"hidden": false,
|
||||||
|
"hint": "",
|
||||||
|
"inbreadcrumbs": true,
|
||||||
|
"inmenu": true,
|
||||||
|
"insitetree": true,
|
||||||
|
"parent": 20,
|
||||||
|
"sort_order": 54,
|
||||||
|
"title": "Export do abstraktů sousu {{ soustredeni.id }}",
|
||||||
|
"tree": 1,
|
||||||
|
"url": "soustredeni_abstrakty soustredeni.id",
|
||||||
|
"urlaspattern": true
|
||||||
|
},
|
||||||
|
"model": "sitetree.treeitem",
|
||||||
|
"pk": 54
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
@ -1,622 +0,0 @@
|
||||||
[
|
|
||||||
{
|
|
||||||
"codename": "org",
|
|
||||||
"ct_app_label": "auth",
|
|
||||||
"ct_model": "user"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_flatpage",
|
|
||||||
"ct_app_label": "flatpages",
|
|
||||||
"ct_model": "flatpage"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_flatpage",
|
|
||||||
"ct_app_label": "flatpages",
|
|
||||||
"ct_model": "flatpage"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_flatpage",
|
|
||||||
"ct_app_label": "flatpages",
|
|
||||||
"ct_model": "flatpage"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_flatpage",
|
|
||||||
"ct_app_label": "flatpages",
|
|
||||||
"ct_model": "flatpage"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_galerie",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "galerie"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_galerie",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "galerie"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_galerie",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "galerie"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_galerie",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "galerie"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_obrazek",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "obrazek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_obrazek",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "obrazek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_obrazek",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "obrazek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_obrazek",
|
|
||||||
"ct_app_label": "galerie",
|
|
||||||
"ct_model": "obrazek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_fotkaheader",
|
|
||||||
"ct_app_label": "header_fotky",
|
|
||||||
"ct_model": "fotkaheader"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_fotkaheader",
|
|
||||||
"ct_app_label": "header_fotky",
|
|
||||||
"ct_model": "fotkaheader"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_fotkaheader",
|
|
||||||
"ct_app_label": "header_fotky",
|
|
||||||
"ct_model": "fotkaheader"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_fotkaurlvazba",
|
|
||||||
"ct_app_label": "header_fotky",
|
|
||||||
"ct_model": "fotkaurlvazba"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_fotkaurlvazba",
|
|
||||||
"ct_app_label": "header_fotky",
|
|
||||||
"ct_model": "fotkaurlvazba"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_fotkaurlvazba",
|
|
||||||
"ct_app_label": "header_fotky",
|
|
||||||
"ct_model": "fotkaurlvazba"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_komentar",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "komentar"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_komentar",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "komentar"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_komentar",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "komentar"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_komentar",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "komentar"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_korekturovanepdf",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "korekturovanepdf"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_korekturovanepdf",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "korekturovanepdf"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_korekturovanepdf",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "korekturovanepdf"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_korekturovanepdf",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "korekturovanepdf"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_oprava",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "oprava"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_oprava",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "oprava"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_oprava",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "oprava"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_oprava",
|
|
||||||
"ct_app_label": "korektury",
|
|
||||||
"ct_model": "oprava"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_hlasovani",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "hlasovani"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_hlasovani",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "hlasovani"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_hlasovani",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "hlasovani"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_hlasovani",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "hlasovani"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_prednaska",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "prednaska"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_prednaska",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "prednaska"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_prednaska",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "prednaska"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_prednaska",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "prednaska"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_seznam",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "seznam"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_seznam",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "seznam"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_seznam",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "seznam"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_seznam",
|
|
||||||
"ct_app_label": "prednasky",
|
|
||||||
"ct_model": "seznam"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_cislo",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "cislo"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_cislo",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "cislo"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_cislo",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "cislo"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_cislo",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "cislo"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_clanek",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "clanek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_clanek",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "clanek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_clanek",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "clanek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_clanek",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "clanek"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_deadline",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "deadline"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_deadline",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "deadline"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_deadline",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "deadline"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_konfera",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfera"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_konfera",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfera"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_konfera",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfera"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_konfera",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfera"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_konfery_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfery_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_konfery_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfery_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_konfery_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfery_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_konfery_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "konfery_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_nastaveni",
|
|
||||||
"ct_app_label": "various",
|
|
||||||
"ct_model": "nastaveni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_nastaveni",
|
|
||||||
"ct_app_label": "various",
|
|
||||||
"ct_model": "nastaveni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_nastaveni",
|
|
||||||
"ct_app_label": "various",
|
|
||||||
"ct_model": "nastaveni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_nastaveni",
|
|
||||||
"ct_app_label": "various",
|
|
||||||
"ct_model": "nastaveni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_novinky",
|
|
||||||
"ct_app_label": "novinky",
|
|
||||||
"ct_model": "novinky"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_novinky",
|
|
||||||
"ct_app_label": "novinky",
|
|
||||||
"ct_model": "novinky"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_novinky",
|
|
||||||
"ct_app_label": "novinky",
|
|
||||||
"ct_model": "novinky"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_novinky",
|
|
||||||
"ct_app_label": "novinky",
|
|
||||||
"ct_model": "novinky"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_organizator",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "organizator"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_organizator",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "organizator"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_osoba",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "osoba"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_osoba",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "osoba"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_pohadka",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "pohadka"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_pohadka",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "pohadka"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_pohadka",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "pohadka"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_pohadka",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "pohadka"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_prijemce",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "prijemce"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_prijemce",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "prijemce"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_prijemce",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "prijemce"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_prijemce",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "prijemce"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_problem",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "problem"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_problem",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "problem"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_problem",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "problem"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_problem",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "problem"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_resitel",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "resitel"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_resitel",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "resitel"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_rocnik",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "rocnik"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_rocnik",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "rocnik"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_rocnik",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "rocnik"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_rocnik",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "rocnik"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_skola",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "skola"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_skola",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "skola"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_skola",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "skola"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_skola",
|
|
||||||
"ct_app_label": "personalni",
|
|
||||||
"ct_model": "skola"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_soustredeni",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_soustredeni",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_soustredeni",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_soustredeni",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_soustredeni_organizatori",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_organizatori"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_soustredeni_organizatori",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_organizatori"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_soustredeni_organizatori",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_organizatori"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_soustredeni_organizatori",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_organizatori"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_soustredeni_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_soustredeni_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_soustredeni_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_soustredeni_ucastnici",
|
|
||||||
"ct_app_label": "soustredeni",
|
|
||||||
"ct_model": "soustredeni_ucastnici"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_tema",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "tema"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_tema",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "tema"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_tema",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "tema"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_tema",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "tema"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_uloha",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "uloha"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_uloha",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "uloha"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_uloha",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "uloha"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_uloha",
|
|
||||||
"ct_app_label": "seminar",
|
|
||||||
"ct_model": "uloha"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_tag",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "tag"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_tag",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "tag"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_tag",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "tag"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_tag",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "tag"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "add_taggeditem",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "taggeditem"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "change_taggeditem",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "taggeditem"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "delete_taggeditem",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "taggeditem"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"codename": "view_taggeditem",
|
|
||||||
"ct_app_label": "taggit",
|
|
||||||
"ct_model": "taggeditem"
|
|
||||||
}
|
|
||||||
]
|
|
|
@ -13,7 +13,6 @@ make install_venv
|
||||||
make install
|
make install
|
||||||
deploy_v2/pre_migration.py
|
deploy_v2/pre_migration.py
|
||||||
make deploy_test
|
make deploy_test
|
||||||
./manage.py load_org_permissions admin_org_prava.json
|
|
||||||
./manage.py loaddata data/*
|
./manage.py loaddata data/*
|
||||||
systemctl --user start mamweb-test.service
|
systemctl --user start mamweb-test.service
|
||||||
./manage.py generate_thumbnails
|
./manage.py generate_thumbnails
|
||||||
|
|
27
docs/css.rst
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
CSS (a další styly na webu)
|
||||||
|
===========================
|
||||||
|
|
||||||
|
Inspirován `css-trick článkem <https://css-tricks.com/methods-organize-css/>`_ jsem se rozhodl rozdělit
|
||||||
|
CSSka do
|
||||||
|
|
||||||
|
- Konstant (``constants.css``), které jsou využívány na mnoha místech CSSek
|
||||||
|
- Nastylování html tagů (``base.css``)
|
||||||
|
- Layoutu (``layout.css``), což je to, co určuje celkové rozložení stránky
|
||||||
|
- Jednotlivých prvků (``modules.css``)
|
||||||
|
|
||||||
|
Dále jsem separoval CSSka pro **galerii** (potřebuje hodně specifických stylů). Stejně tak **korekturovátko** má styly separátně.
|
||||||
|
|
||||||
|
Dále web (asi) používá externí frameworky (v separátních složkách – mají k sobě i JS a podobné věci):
|
||||||
|
|
||||||
|
- bootstrap: dělá nějaké basic stylování, *web je na něm hodně závislý* (například jsem zjistil, že bootstrap kdysi přidával ``font-size:14px``, bez čehož se web úplně rozpadnul) (také na něm běží mobilní meníčko, které navíc vyžaduje Popper, tedy bootstrap.bundle.js místo bootstrap.js)
|
||||||
|
|
||||||
|
Pak jsou tu ``mamweb-dev.css`` a ``printtable.css``, co jsem si ještě nerozmyslel, co s tím.
|
||||||
|
|
||||||
|
Pár myšlenek
|
||||||
|
------------
|
||||||
|
|
||||||
|
- Až na pár výjimek (galerii a korekturovátko) bych styly držel v jedné složce a málo souborech,
|
||||||
|
protože CSS šíleně dědí všechno možné
|
||||||
|
- Chce to dobře pojmenovávat třídy (speciálně aby bylo vidět, co ta třída dělá nebo kde se používá)
|
||||||
|
- Chce to hodně komentovat kód (speciálně tam, kde není splněn předchozí bod)
|
||||||
|
|
|
@ -9,12 +9,6 @@ static
|
||||||
------
|
------
|
||||||
Složka, kam django nakopíruje všechno ze složek static a pak na to z templatů / kódu jde ukazovat pomocí ``static``.
|
Složka, kam django nakopíruje všechno ze složek static a pak na to z templatů / kódu jde ukazovat pomocí ``static``.
|
||||||
|
|
||||||
_git_hooks
|
|
||||||
----------
|
|
||||||
Hooky do gitu pro kontrolu Pythoního stylu. Především ``flake8``.
|
|
||||||
|
|
||||||
Zbylo tu z minulosti mamwebu.
|
|
||||||
|
|
||||||
data
|
data
|
||||||
----
|
----
|
||||||
Obsahuje data, která patří do databáze, ale jsou přímo součástí webu jako
|
Obsahuje data, která patří do databáze, ale jsou přímo součástí webu jako
|
||||||
|
|
|
@ -30,6 +30,7 @@ Dokumentace (jak v ``docs/``, tak přímo v kódu) je psaná ve
|
||||||
zavislosti
|
zavislosti
|
||||||
sphinx
|
sphinx
|
||||||
skripty
|
skripty
|
||||||
|
zkratky
|
||||||
modules/modules
|
modules/modules
|
||||||
dalsi_soubory
|
dalsi_soubory
|
||||||
zapisy/zapisy
|
zapisy/zapisy
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
FIXME přepsat do rst, přidat i další věci a případně přesunout na wiki
|
||||||
Přidání obrázků do odměn:
|
Přidání obrázků do odměn:
|
||||||
admin -> flatpage odměn -> ikona přidat obrázek
|
admin -> flatpage odměn -> ikona přidat obrázek
|
||||||
záložka odeslat, vybrat obrázek, odeslat
|
záložka odeslat, vybrat obrázek, odeslat
|
|
@ -1,13 +1,15 @@
|
||||||
Sphinx na našem webu
|
Sphinx na našem webu
|
||||||
====================
|
====================
|
||||||
|
|
||||||
Dokumentace se zkompiluje příkazem ``make html`` ve složce ``doc``.
|
Dokumentace se zkompiluje příkazem ``make html`` ve složce ``docs``. (Musíte mít zapnutý virtualenv)
|
||||||
|
|
||||||
Složka ``modules`` je automaticiky generována a přegenerovávána. (**Nic v ní neupravovat!**)
|
Složka ``modules`` je automaticiky generována a přegenerovávána. (**Nic v ní neupravovat!**)
|
||||||
Jinak všechny rst, co jsou ve složce ``doc`` a jejích podsložkách nezačínajících podtržítkem, budou v dokumentaci a to je přesně to, co editovat pro změnu dokumentace (kromě dokumentace přímo v Pythonu).
|
Jinak všechny rst, co jsou ve složce ``docs`` a jejích podsložkách nezačínajících podtržítkem, budou v dokumentaci a to je přesně to, co editovat pro změnu dokumentace (kromě dokumentace přímo v Pythonu).
|
||||||
|
|
||||||
Sphinx se píše v rst: `Návod na syntaxi rst`_ `Cheat sheet`_
|
Sphinx se píše v rst: `Návod na syntaxi rst`_ `Cheat sheet`_
|
||||||
|
|
||||||
|
Pokud něco chcete protlačit do bočního meníčka, je potřeba to připsat do souboru ``docs/index.rst`` (Zatím není úplně konsensus nad tím, co tam má a nemá být, takže pokud si nejste jistí, cpěte tam *všechno* ☺)
|
||||||
|
|
||||||
To je snad vše, co je potřeba vědět k dokumentaci mamwebu. Následující sekce jsou o tom, co jsem provedl Sphinxu, aby to fungovalo:
|
To je snad vše, co je potřeba vědět k dokumentaci mamwebu. Následující sekce jsou o tom, co jsem provedl Sphinxu, aby to fungovalo:
|
||||||
|
|
||||||
.. _Návod na syntaxi rst: https://sphinx-tutorial.readthedocs.io/step-1/#sections
|
.. _Návod na syntaxi rst: https://sphinx-tutorial.readthedocs.io/step-1/#sections
|
||||||
|
|
|
@ -10,11 +10,9 @@ věci jako chybové hlášky a vzhled M&M stránek (menu, patička, atd.). Aktu
|
||||||
i veškeré csv.
|
i veškeré csv.
|
||||||
|
|
||||||
Další jsou pak jednotlivé aplikace (pokud něco hledáte, tak zřejmě chcete najít
|
Další jsou pak jednotlivé aplikace (pokud něco hledáte, tak zřejmě chcete najít
|
||||||
tu aplikaci, která tomu odpovídá, respektive se k ní dostat přes url), za
|
tu aplikaci, která tomu odpovídá, respektive se k ní dostat přes url).
|
||||||
zmínku stojí seminar, kde jsou takové ty věci, co zbyly. Plus jsou tam aktuálně
|
|
||||||
téměř všechny modely, protože je těžké je přesunout jinam.
|
|
||||||
|
|
||||||
**TLDR: Nevšímejte si složky data/ a souborů přímo v kořenové složce.**
|
**TLDR: Nevšímejte si složek data/ seminar/ a souborů přímo v kořenové složce.**
|
||||||
Kromě věcí potřebných ke gitu, :doc:`ke spuštění <vyvoj>` a fukci djanga,
|
Kromě věcí potřebných ke gitu, :doc:`ke spuštění <vyvoj>` a fukci djanga,
|
||||||
dalších drobností, lokální databáze a již zmíněných aplikací jsou tu ``data``,
|
dalších drobností, lokální databáze a již zmíněných aplikací jsou tu ``data``,
|
||||||
kde je takový ten obsah webu, co by se měl dát snadno měnit (tudíž musí být v
|
kde je takový ten obsah webu, co by se měl dát snadno měnit (tudíž musí být v
|
||||||
|
@ -22,6 +20,9 @@ databázi), tj. statické stránky, menu a obrázky v pozadí menu. Ten je třeb
|
||||||
měnit hlavně na produkci a sekundárně tady (může to dělat i newebař a nechcete
|
měnit hlavně na produkci a sekundárně tady (může to dělat i newebař a nechcete
|
||||||
přepsat jeho práci). Vše, co nejsou aplikace je popsáno :doc:`tady <dalsi_soubory>`.
|
přepsat jeho práci). Vše, co nejsou aplikace je popsáno :doc:`tady <dalsi_soubory>`.
|
||||||
|
|
||||||
|
Ještě je tu aplikace ``seminar/``, kde bylo původně skoro všechno, a tak nám
|
||||||
|
tam zbývá spoustu historických migrací (čehož se jen tak nezbavíme).
|
||||||
|
|
||||||
Základy djanga
|
Základy djanga
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
|
|
|
@ -116,7 +116,7 @@ Aktuálně: Jakýsi coding style zhruba existuje, není popsaný, šíří se li
|
||||||
- Nesmí být striktně vynucovaný
|
- Nesmí být striktně vynucovaný
|
||||||
- Musel by být hodně nastavitelný
|
- Musel by být hodně nastavitelný
|
||||||
- Nechceme mít kód plný `#NOQA: WTF42`
|
- Nechceme mít kód plný `#NOQA: WTF42`
|
||||||
- Nejspíš vždycky bude mít false positives (`seminar.utils.roman_numerals`) i false negatives (`seminar.models.tvorba.Cislo.posli_cislo_mailem`)
|
- Nejspíš vždycky bude mít false positives (`tvorba.utils.roman_numerals`) i false negatives (`tvorba.models.Cislo.posli_cislo_mailem`)
|
||||||
- Možná dobrý sluha, ale určitě špatný pán (also: špatná zkušenost ☺)
|
- Možná dobrý sluha, ale určitě špatný pán (also: špatná zkušenost ☺)
|
||||||
- __Důsledek:__ Hrozí, že těch falešných varování bude moc, čímž to ztratí smysl úplně
|
- __Důsledek:__ Hrozí, že těch falešných varování bude moc, čímž to ztratí smysl úplně
|
||||||
- Potenciálně by šlo aplikovat jen lokálně na změny?
|
- Potenciálně by šlo aplikovat jen lokálně na změny?
|
||||||
|
|
86
docs/zkratky.rst
Normal file
|
@ -0,0 +1,86 @@
|
||||||
|
Zkratky aplikací ve zdrojácích
|
||||||
|
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
|
||||||
|
|
||||||
|
Ve zdrojácích (zejména různé ``models.py``, ``views.py`` ap.) používáme spoustu
|
||||||
|
modelů. Někdy je praktičtější / někdo preferuje importovat celou aplikaci jako
|
||||||
|
jedno jméno a používat modely bez explicitních importů, tj::
|
||||||
|
|
||||||
|
# „hromadné“ importy:
|
||||||
|
import personalni.models as p
|
||||||
|
...
|
||||||
|
p.Organizator.objects.all()
|
||||||
|
|
||||||
|
# „explicitní“ importy:
|
||||||
|
from personalni.models import Organizator
|
||||||
|
...
|
||||||
|
Organizator.objects.all()
|
||||||
|
|
||||||
|
Na webschůzce 2024-11-05 jsme na toto téma otevřeli diskusi, tady je její závěr.
|
||||||
|
|
||||||
|
.. admonition:: Historické okénko
|
||||||
|
:class: note
|
||||||
|
|
||||||
|
Kdysi jsme měli (prakticky) všechny modely v jedné aplikaci, ``seminar``. Na
|
||||||
|
různých místech se pak ``seminar.models`` importovalo typicky jako ``s``
|
||||||
|
nebo jako ``m``.
|
||||||
|
|
||||||
|
Přirozeně, toto už nejde tak snadno, protože už neexistuje jedno místo, ze
|
||||||
|
kterého chceme tahat modely v kódu.
|
||||||
|
|
||||||
|
Konvence
|
||||||
|
========
|
||||||
|
|
||||||
|
Shodli jsme se, že nám rozhodně nevadí explicitní importy a z pohledu
|
||||||
|
čitelnosti je preferujeme. Nicméně při psaní kódu to některým webařům přijde
|
||||||
|
nepohodlné, takže očekáváme, že bude existovat spousta kódu, která bude chtít
|
||||||
|
importovat hromadně. Usnesli jsme se proto na následujících kanonických
|
||||||
|
zkratkách, aby se aplikace alespoň zkracovaly konzistentně.
|
||||||
|
|
||||||
|
V závorkách je uvedené případné jméno, ale nepředpokládáme, že někdo bude danou
|
||||||
|
aplikaci chtít importovat hromadně. Některé aplikace zkratku nemají, ty se
|
||||||
|
importují vždy pod plným jménem nebo explicitně.
|
||||||
|
|
||||||
|
.. list-table::
|
||||||
|
:header-rows: 1
|
||||||
|
|
||||||
|
* - Model
|
||||||
|
- Zkratka
|
||||||
|
* - ``aesop``
|
||||||
|
- ---
|
||||||
|
* - ``api``
|
||||||
|
- --- (``api``)
|
||||||
|
* - ``galerie``
|
||||||
|
- ``g``
|
||||||
|
* - ``header_fotky``
|
||||||
|
- --- (``hdr``)
|
||||||
|
* - ``korektury``
|
||||||
|
- ``kor``
|
||||||
|
* - ``novinky``
|
||||||
|
- ``nov``
|
||||||
|
* - ``odevzdavatko``
|
||||||
|
- ``odev``
|
||||||
|
* - ``personální``
|
||||||
|
- ``pers``/``p``
|
||||||
|
* - ``sifrovacka``
|
||||||
|
- (``sifr``)
|
||||||
|
* - ``soustredeni``
|
||||||
|
- ``sou``
|
||||||
|
* - ``treenode``
|
||||||
|
- ``tn``
|
||||||
|
* - ``tvorba``
|
||||||
|
- ``tv``
|
||||||
|
* - ``various``
|
||||||
|
- ``v``/``var``
|
||||||
|
* - ``vyroci``
|
||||||
|
- ---
|
||||||
|
* - ``vysledkovky``
|
||||||
|
- ``vysl``
|
||||||
|
|
||||||
|
|
||||||
|
.. admonition:: O všech modelech pod jedním jménem
|
||||||
|
:class: warning
|
||||||
|
|
||||||
|
Historické okénko výš zatajuje jeden detail: Při práci v shellu se hodí mít
|
||||||
|
modely k dispozici a nemuset přemýšlet nad dělením do aplikací, takže ve
|
||||||
|
skutečnosti existuje ``mamweb.vsechno``, jenž všechny modely obsahuje.
|
||||||
|
Z čitelnostních důvodů je ale *zakázáno* tento modul používat v kódu.
|
25
galerie/TODO
|
@ -1,25 +0,0 @@
|
||||||
========
|
|
||||||
| TODO |
|
|
||||||
|======|
|
|
||||||
|
|
||||||
Aktualni
|
|
||||||
* co s titulni fotkou
|
|
||||||
* do CSS
|
|
||||||
* nahledy
|
|
||||||
* nastylovat tabulku s nahledy
|
|
||||||
* komentare uz na nahledy?
|
|
||||||
* detail
|
|
||||||
* nahledy pred a po
|
|
||||||
* opravit prechodove sipky
|
|
||||||
* vyrobit prechodove sipky ve M&M-stylu
|
|
||||||
|
|
||||||
Dlouhodobe
|
|
||||||
* sipky na prechazeni mezi fotkami
|
|
||||||
* hromadne PRIDANI fotek do jiz existujici galerie
|
|
||||||
|
|
||||||
Fylozoficke
|
|
||||||
* zvolit velikosti velke a male fotky
|
|
||||||
* je potreba i jine razeni nez automaticky podle casu nebo staci podgalerie?
|
|
||||||
* napr. dve hry na dvou ruznych mistech ve stejny cas
|
|
||||||
* fotky od ucastniku ze hry (skupinky se pohybuji ve stejny cas, ale maji sled fotek) -- nestaci to pripadne vrazit do podgalerii?
|
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
#coding: utf-8
|
|
||||||
|
|
||||||
from galerie.models import Obrazek, Galerie
|
from galerie.models import Obrazek, Galerie
|
||||||
from django.contrib import admin
|
from django.contrib import admin
|
||||||
from django.http import HttpResponseRedirect
|
from django.http import HttpResponseRedirect
|
||||||
|
|
|
@ -1,47 +0,0 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
|
|
||||||
from autocomplete_light import shortcuts as autocomplete_light
|
|
||||||
|
|
||||||
from .models import Obrazek, Galerie
|
|
||||||
from .views import cesta_od_korene
|
|
||||||
|
|
||||||
|
|
||||||
class ObrazekAutocomplete(autocomplete_light.AutocompleteModelBase):
|
|
||||||
|
|
||||||
model = Obrazek
|
|
||||||
search_fields = ['nazev', 'popis']
|
|
||||||
split_words = True
|
|
||||||
limit_choices = 15
|
|
||||||
attrs = {
|
|
||||||
# This will set the input placeholder attribute:
|
|
||||||
'placeholder': u'Obrázek',
|
|
||||||
# This will set the yourlabs.Autocomplete.minimumCharacters
|
|
||||||
# options, the naming conversion is handled by jQuery
|
|
||||||
'data-autocomplete-minimum-characters': 1,
|
|
||||||
}
|
|
||||||
|
|
||||||
choice_html_format = '''
|
|
||||||
<span class="block" data-value="{}">
|
|
||||||
<span class="block">
|
|
||||||
{}
|
|
||||||
<span class="block">{}</span>
|
|
||||||
</span>
|
|
||||||
</span>
|
|
||||||
'''
|
|
||||||
|
|
||||||
def choice_label(self, obrazek):
|
|
||||||
cesta = "/".join(g.nazev for g in cesta_od_korene(obrazek.galerie))
|
|
||||||
popis = "{}<br>".format(obrazek.popis) if obrazek.popis else ""
|
|
||||||
return '{}<br>{}{}'.format(obrazek.nazev, popis, cesta)
|
|
||||||
|
|
||||||
def choice_html(self, obrazek):
|
|
||||||
"""Vrátí kus html i s obrázkem, které se pak ukazuje v nabídce"""
|
|
||||||
return self.choice_html_format.format(self.choice_value(obrazek),
|
|
||||||
obrazek.obrazek_maly_tag(), self.choice_label(obrazek))
|
|
||||||
|
|
||||||
widget_attrs={
|
|
||||||
'data-widget-maximum-values': 15,
|
|
||||||
'class': 'modern-style',
|
|
||||||
}
|
|
||||||
|
|
||||||
autocomplete_light.register(ObrazekAutocomplete)
|
|
|
@ -1,7 +1,4 @@
|
||||||
#coding: utf-8
|
|
||||||
|
|
||||||
from django import forms
|
from django import forms
|
||||||
from seminar.models import Soustredeni
|
|
||||||
|
|
||||||
class KomentarForm(forms.Form):
|
class KomentarForm(forms.Form):
|
||||||
komentar = forms.CharField(label = "Komentář:", max_length = 300, required=False)
|
komentar = forms.CharField(label = "Komentář:", max_length = 300, required=False)
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Generated by Django 1.11.20 on 2019-04-30 21:40
|
# Generated by Django 1.11.20 on 2019-04-30 21:40
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Generated by Django 1.11.21 on 2019-06-10 21:58
|
# Generated by Django 1.11.21 on 2019-06-10 21:58
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
# coding: utf-8
|
|
||||||
|
|
||||||
from django.db import models
|
from django.db import models
|
||||||
#from django.db.models import Q
|
#from django.db.models import Q
|
||||||
from imagekit.models import ImageSpecField
|
from imagekit.models import ImageSpecField
|
||||||
|
|
186
galerie/static/css/galerie.css
Normal file
|
@ -0,0 +1,186 @@
|
||||||
|
@charset "utf-8"; /* vynuť utf-8 */
|
||||||
|
|
||||||
|
/* Galerie */
|
||||||
|
|
||||||
|
|
||||||
|
/* velká fotka */
|
||||||
|
/* zmenšování spolu s oknem prohlížeče */
|
||||||
|
.galerie .obrazek, .titulni_obrazek {
|
||||||
|
max-width: 100%;
|
||||||
|
height: auto;
|
||||||
|
width: auto\9; /* ie8 */
|
||||||
|
}
|
||||||
|
|
||||||
|
.predchozi_obrazek{
|
||||||
|
position: absolute;
|
||||||
|
z-index: 1;
|
||||||
|
width: 33%;
|
||||||
|
height: 100%;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
}
|
||||||
|
.predchozi_obrazek:hover{
|
||||||
|
background-image: url("/static/galerie/prvky/predchozi.svg");
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
background-position: left center;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
}
|
||||||
|
.dalsi_obrazek{
|
||||||
|
position: absolute;
|
||||||
|
z-index: 1;
|
||||||
|
width: 33%;
|
||||||
|
height: 100%;
|
||||||
|
left: 67%;
|
||||||
|
top: 0;
|
||||||
|
}
|
||||||
|
.dalsi_obrazek:hover{
|
||||||
|
background-image: url("/static/galerie/prvky/dalsi.svg");
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
background-position: right center;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie {
|
||||||
|
position: relative;
|
||||||
|
text-align: center;
|
||||||
|
margin: 20px auto 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie h1 {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_hlavicka {
|
||||||
|
margin: 30px auto 30px auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.popis {
|
||||||
|
margin: 10px 10px 30px 0px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
#nahoru {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* titulní obrázek hlavní galerie soustředění */
|
||||||
|
|
||||||
|
.galerie_nahledy{
|
||||||
|
/*margin: 1em 0;*/
|
||||||
|
margin: auto;
|
||||||
|
padding: 10px;
|
||||||
|
text-align: center;
|
||||||
|
overflow: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_nahledy img {
|
||||||
|
margin: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_nahledy div.navigace {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_nahled, .podgalerie_nahled { /* frame */
|
||||||
|
display: block;
|
||||||
|
position: relative;
|
||||||
|
float: left;
|
||||||
|
width: 200px;
|
||||||
|
height: 200px;
|
||||||
|
text-align: center;
|
||||||
|
border: solid;
|
||||||
|
border-width: 1px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: var(--svetla-oranzova);
|
||||||
|
background-color: var(--barva-pozadi);
|
||||||
|
white-space: nowrap;
|
||||||
|
margin: 10px;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_nahled:hover, .podgalerie_nahled:hover {
|
||||||
|
background-color: var(--svetla-oranzova);
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
color: var(--tmava-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
.vystredeno{ /* helper */
|
||||||
|
display: inline-block;
|
||||||
|
height: 100%;
|
||||||
|
vertical-align: middle;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_nahled img {
|
||||||
|
vertical-align: middle;
|
||||||
|
max-height: 180px;
|
||||||
|
max-width: 180px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_nahled div {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0px;
|
||||||
|
width: 100%;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.podgalerie_nahled img {
|
||||||
|
margin-top: 20px;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
max-height: 125px;
|
||||||
|
max-width: 167px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.podgalerie_nahled .nazev_galerie {
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
top: 160px;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Odkazy na předchozí a následující podgalerii */
|
||||||
|
.galerie_predchozi_nasledujici {
|
||||||
|
overflow: auto;
|
||||||
|
margin: 10px auto 10px auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_predchozi_nasledujici .predchozi {
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.galerie_predchozi_nasledujici .nasledujici {
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* posune kotvu obrázku v galerii o oranžový pruh dolu, aby se pod ním obrázek neschovával */
|
||||||
|
/* https://stackoverflow.com/questions/10732690/offsetting-an-html-anchor-to-adjust-for-fixed-header */
|
||||||
|
.kotva_obrazku {
|
||||||
|
position: absolute;
|
||||||
|
width: 0;
|
||||||
|
height: 55px; /* viz #title */
|
||||||
|
margin-top: -55px; /* viz #title */
|
||||||
|
}
|
||||||
|
@media(max-width: 860px) {
|
||||||
|
.kotva_obrazku {
|
||||||
|
height: 3em; /* #FIXME nemám páru, jak zjistit výšku toho elementu */
|
||||||
|
margin-top: -3em; /* #FIXME */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* plus a minus tlacitka */
|
||||||
|
.mam-org-only-galerie {
|
||||||
|
background: var(--orgovska-svetla-fialova);
|
||||||
|
padding: 10px;
|
||||||
|
margin: 10px 10px 10px -20px;
|
||||||
|
border: #333 2px dashed;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mam-org-only-galerie a{
|
||||||
|
padding: 3px 5px;
|
||||||
|
margin: 5px;
|
||||||
|
border-radius: 20px;
|
||||||
|
background-color: var(--tmava-oranzova);;
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
float: left;
|
||||||
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
{% extends "base.html" %}
|
{% extends "galerie/base.html" %}
|
||||||
|
|
||||||
|
|
||||||
{% block nadpis1a %}
|
{% block nadpis1a %}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{% extends "base.html" %}
|
{% extends "galerie/base.html" %}
|
||||||
|
|
||||||
{% block nadpis1a %}
|
{% block nadpis1a %}
|
||||||
Galerie {{galerie.nazev}}
|
Galerie {{galerie.nazev}}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{% extends "base.html" %}
|
{% extends "galerie/base.html" %}
|
||||||
|
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
6
galerie/templates/galerie/base.html
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
{% extends "base.html" %}
|
||||||
|
{% load static %}
|
||||||
|
|
||||||
|
{% block custom_css %}
|
||||||
|
<link href="{% static 'css/galerie.css' %}?version=1" rel="stylesheet">
|
||||||
|
{% endblock %}
|
|
@ -1,14 +1,5 @@
|
||||||
"""
|
|
||||||
Soubor sloužící jako „router“, tj. zde se definují url adresy a na co ukazují:
|
|
||||||
|
|
||||||
- ``<int:pk>/`` :func:`~galerie.views.nahled`
|
|
||||||
- ``<int:pk>/<int:fotka>/`` :func:`~galerie.views.detail`
|
|
||||||
- ``<int:galerie>/new/`` :func:`~galerie.views.new_galerie`
|
|
||||||
- ``<int:galerie>/plus/<int:subgalerie>/`` :func:`~galerie.views.plus_galerie`
|
|
||||||
- ``<int:galerie>/minus/<int:subgalerie>/`` :func:`~galerie.views.minus_galerie`
|
|
||||||
"""
|
|
||||||
from django.urls import path
|
from django.urls import path
|
||||||
from seminar.utils import org_required
|
from personalni.utils import org_required
|
||||||
from . import views
|
from . import views
|
||||||
|
|
||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
# coding: utf-8
|
|
||||||
|
|
||||||
import random
|
import random
|
||||||
|
|
||||||
from django.http import HttpResponse, Http404
|
from django.http import HttpResponse, Http404
|
||||||
|
@ -8,7 +6,7 @@ from django.template import RequestContext
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
|
|
||||||
from galerie.models import Obrazek, Galerie
|
from galerie.models import Obrazek, Galerie
|
||||||
from seminar.models import Soustredeni
|
from soustredeni.models import Soustredeni
|
||||||
from galerie.forms import KomentarForm, NewGalerieForm
|
from galerie.forms import KomentarForm, NewGalerieForm
|
||||||
|
|
||||||
def zobrazit(galerie, request):
|
def zobrazit(galerie, request):
|
||||||
|
|
|
@ -1,14 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící k definici toho, co bude v adminu. Většinou pouhým zavoláním
|
|
||||||
funkce :func:`django.contrib.admin.site.register`, v případě, že chceme něco
|
|
||||||
upravit, tak jako třída rozšiřující :class:`django.contrib.admin.ModelAdmin`
|
|
||||||
s dekorátorem :func:`django.contrib.admin.register`.
|
|
||||||
|
|
||||||
Zde se definuje admin pro:
|
|
||||||
|
|
||||||
- :class:`~header_fotky.models.FotkaHeader`
|
|
||||||
- :class:`~header_fotky.models.FotkaUrlVazba`
|
|
||||||
"""
|
|
||||||
from django.contrib import admin
|
from django.contrib import admin
|
||||||
from django.contrib.admin import ModelAdmin
|
from django.contrib.admin import ModelAdmin
|
||||||
import header_fotky.models as m
|
import header_fotky.models as m
|
||||||
|
|
|
@ -1,6 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící k pojmenování a jiným nastavením djangovské aplikace.
|
|
||||||
"""
|
|
||||||
from django.apps import AppConfig
|
from django.apps import AppConfig
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,17 +1,3 @@
|
||||||
"""
|
|
||||||
Tento soubor slouží k definici databázového modelu.
|
|
||||||
|
|
||||||
Třídy rozšiřují většinou :class:`django.db.models.Model` a jejich atributy jsou
|
|
||||||
většinou sloupce v databázi (tj. nastaví se na hodnotu něčeho z :mod:`django.db.models`).
|
|
||||||
Na výběr jsou:
|
|
||||||
|
|
||||||
- :class:`django.db.models.TextField`
|
|
||||||
- :class:`django.db.models.ForeignKey`
|
|
||||||
- :class:`django.db.models.DateField`
|
|
||||||
- :class:`django.db.models.DateTimeField`
|
|
||||||
- :class:`django.db.models.ImageField`
|
|
||||||
- :class:`django.db.models.CharField`
|
|
||||||
"""
|
|
||||||
from django.core.exceptions import ValidationError
|
from django.core.exceptions import ValidationError
|
||||||
from django.db import models
|
from django.db import models
|
||||||
from django.utils import timezone
|
from django.utils import timezone
|
||||||
|
|
|
@ -1,11 +0,0 @@
|
||||||
- korektura potrebuje reakci
|
|
||||||
+ komentáře fixně na username
|
|
||||||
- používat skutečné jméno?
|
|
||||||
- vyžádat pozornost autora obsahu
|
|
||||||
- zvednout upload limit na 5MB
|
|
||||||
- sbalit a rozbalit korekturu
|
|
||||||
- nahrávání jiných věcí než PDF - kontrolovat?
|
|
||||||
- stylování
|
|
||||||
- seznam PDF - co zobrazovat?
|
|
||||||
|
|
||||||
|
|
|
@ -1,13 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící k definici toho, co bude v adminu. Většinou pouhým zavoláním
|
|
||||||
funkce :func:`django.contrib.admin.site.register`, v případě, že chceme něco
|
|
||||||
upravit, tak jako třída rozšiřující :class:`django.contrib.admin.ModelAdmin`
|
|
||||||
s dekorátorem :func:`django.contrib.admin.register`.
|
|
||||||
|
|
||||||
Zde se definuje admin pro:
|
|
||||||
|
|
||||||
- :class:`korektury.models.KorekturovanePDF`
|
|
||||||
"""
|
|
||||||
from django.contrib import admin
|
from django.contrib import admin
|
||||||
from reversion.admin import VersionAdmin
|
from reversion.admin import VersionAdmin
|
||||||
from korektury.models import KorekturovanePDF
|
from korektury.models import KorekturovanePDF
|
||||||
|
@ -15,7 +5,6 @@ from korektury.models import KorekturovanePDF
|
||||||
from django.core.mail import EmailMessage
|
from django.core.mail import EmailMessage
|
||||||
from django.urls import reverse
|
from django.urls import reverse
|
||||||
|
|
||||||
# Register your models here.
|
|
||||||
class KorekturovanePDFAdmin(VersionAdmin):
|
class KorekturovanePDFAdmin(VersionAdmin):
|
||||||
"""
|
"""
|
||||||
nastaví čas vložení (:attr:`~koretkury.models.KorekturovanePDF.cas`) a počet
|
nastaví čas vložení (:attr:`~koretkury.models.KorekturovanePDF.cas`) a počet
|
||||||
|
@ -36,12 +25,13 @@ class KorekturovanePDFAdmin(VersionAdmin):
|
||||||
fieldsets = [
|
fieldsets = [
|
||||||
(None,
|
(None,
|
||||||
{'fields':
|
{'fields':
|
||||||
['pdf', 'cas', 'org', 'stran', 'nazev', 'komentar', 'poslat_mail']}),
|
['pdf', 'cas', 'stran', 'nazev', 'orgove', 'komentar', 'poslat_mail']}),
|
||||||
# (u'PDF', {'fields': ['pdf']}),
|
# (u'PDF', {'fields': ['pdf']}),
|
||||||
]
|
]
|
||||||
list_display = ['nazev', 'cas', 'stran', 'org']
|
list_display = ['nazev', 'cas', 'stran']
|
||||||
list_filter = []
|
list_filter = []
|
||||||
search_fields = []
|
search_fields = []
|
||||||
|
autocomplete_fields = ['orgove']
|
||||||
|
|
||||||
def save_model(self, request, obj, form, change):
|
def save_model(self, request, obj, form, change):
|
||||||
"""
|
"""
|
||||||
|
|
|
@ -1,13 +1,3 @@
|
||||||
"""
|
|
||||||
Formuláře (:class:`django.forms.Form`) umožňují jednoduchou tvorbu formulářů,
|
|
||||||
které lze pak jednoduše dát do frontendu i zpracovat na backendu.
|
|
||||||
|
|
||||||
Pro přidání políčka do formuláře je potřeba
|
|
||||||
- mít v modelu tu položku, kterou chci upravovat
|
|
||||||
- přidat do views (prihlaskaView, resitelEditView)
|
|
||||||
- přidat do forms
|
|
||||||
- includovat do html
|
|
||||||
"""
|
|
||||||
from django import forms
|
from django import forms
|
||||||
|
|
||||||
class OpravaForm(forms.Form):
|
class OpravaForm(forms.Form):
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import models, migrations
|
from django.db import models, migrations
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Generated by Django 1.11.20 on 2019-04-30 21:40
|
# Generated by Django 1.11.20 on 2019-04-30 21:40
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Generated by Django 1.11.21 on 2019-06-10 21:58
|
# Generated by Django 1.11.21 on 2019-06-10 21:58
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
|
41
korektury/migrations/0024_vic_orgu_k_pdf.py
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
# Generated by Django 4.2.13 on 2024-06-11 23:53
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
def pridej_orgy(apps, schema_editor):
|
||||||
|
PDF = apps.get_model('korektury', 'KorekturovanePDF')
|
||||||
|
for pdf in PDF.objects.all(): # Tohle by asi mělo jít udělat pomocí update, ale moc práce a rychlé hledání taky nepomohlo.
|
||||||
|
if pdf.org is not None: pdf.orgove.add(pdf.org)
|
||||||
|
pdf.save() # ig?
|
||||||
|
|
||||||
|
def vyber_orga(apps, schema_editor):
|
||||||
|
PDF = apps.get_model('korektury', 'KorekturovanePDF')
|
||||||
|
for pdf in PDF.objects.all():
|
||||||
|
orgove = pdf.orgove.all()
|
||||||
|
if len(orgove) > 1:
|
||||||
|
raise migrations.exceptions.IrreversibleError(f'PDF {pdf.id} má víc než jednoho zodpovědného orga, nejde odmigrovat na verzi, která umí jen jednoho.')
|
||||||
|
if len(orgove) == 0:
|
||||||
|
pdf.org = None
|
||||||
|
else:
|
||||||
|
pdf.org = orgove[0]
|
||||||
|
pdf.save()
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('personalni', '0011_osloveni_vsechny_choices'),
|
||||||
|
('korektury', '0023_personalni_post_migrate'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='korekturovanepdf',
|
||||||
|
name='orgove',
|
||||||
|
field=models.ManyToManyField(blank=True, default=None, help_text='Zodpovědní organizátoři za obsah (chodí jim maily o nových korekturách)', to='personalni.organizator'),
|
||||||
|
),
|
||||||
|
migrations.RunPython(pridej_orgy, vyber_orga),
|
||||||
|
migrations.RemoveField(
|
||||||
|
model_name='korekturovanepdf',
|
||||||
|
name='org',
|
||||||
|
),
|
||||||
|
]
|
|
@ -1,19 +1,6 @@
|
||||||
"""
|
|
||||||
Tento soubor slouží k definici databázového modelu.
|
|
||||||
|
|
||||||
Třídy rozšiřují většinou :class:`django.db.models.Model` a jejich atributy jsou
|
|
||||||
většinou sloupce v databázi (tj. nastaví se na hodnotu něčeho z :mod:`django.db.models`).
|
|
||||||
Na výběr jsou:
|
|
||||||
|
|
||||||
- :class:`django.db.models.TextField`
|
|
||||||
- :class:`django.db.models.ForeignKey`
|
|
||||||
- :class:`django.db.models.DateField`
|
|
||||||
- :class:`django.db.models.DateTimeField`
|
|
||||||
- :class:`django.db.models.ImageField`
|
|
||||||
- :class:`django.db.models.CharField`
|
|
||||||
"""
|
|
||||||
import os
|
import os
|
||||||
from django.db import models
|
from django.db import models
|
||||||
|
from django.urls import reverse
|
||||||
from django.utils import timezone
|
from django.utils import timezone
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
from django.core.exceptions import ObjectDoesNotExist
|
from django.core.exceptions import ObjectDoesNotExist
|
||||||
|
@ -40,7 +27,6 @@ def generate_filename(self, filename):
|
||||||
clean)
|
clean)
|
||||||
return os.path.join(settings.KOREKTURY_PDF_DIR, fname)
|
return os.path.join(settings.KOREKTURY_PDF_DIR, fname)
|
||||||
|
|
||||||
|
|
||||||
#@reversion.register(ignore_duplicates=True)
|
#@reversion.register(ignore_duplicates=True)
|
||||||
class KorekturovanePDF(models.Model):
|
class KorekturovanePDF(models.Model):
|
||||||
class Meta:
|
class Meta:
|
||||||
|
@ -60,9 +46,9 @@ class KorekturovanePDF(models.Model):
|
||||||
|
|
||||||
pdf = models.FileField(u'PDF', upload_to = generate_filename)
|
pdf = models.FileField(u'PDF', upload_to = generate_filename)
|
||||||
|
|
||||||
org = models.ForeignKey(Organizator, blank=True,
|
orgove = models.ManyToManyField(Organizator, blank=True,
|
||||||
help_text='Zodpovědný organizátor za obsah',
|
help_text='Zodpovědní organizátoři za obsah (chodí jim maily o nových korekturách)',
|
||||||
null=True, default=None, on_delete=models.SET_NULL)
|
default=None)
|
||||||
|
|
||||||
stran = models.IntegerField(u'počet stran', help_text='Počet stran PDF',
|
stran = models.IntegerField(u'počet stran', help_text='Počet stran PDF',
|
||||||
default=0)
|
default=0)
|
||||||
|
@ -144,6 +130,9 @@ class KorekturovanePDF(models.Model):
|
||||||
except IndexError:
|
except IndexError:
|
||||||
return self.nazev
|
return self.nazev
|
||||||
|
|
||||||
|
def get_absolute_url(self):
|
||||||
|
return reverse('korektury', kwargs={'pdf': self.id})
|
||||||
|
|
||||||
|
|
||||||
@reversion.register(ignore_duplicates=True)
|
@reversion.register(ignore_duplicates=True)
|
||||||
class Oprava(models.Model):
|
class Oprava(models.Model):
|
||||||
|
|
Before Width: | Height: | Size: 697 B After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 717 B After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 702 B After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 617 B After Width: | Height: | Size: 1.1 KiB |
|
@ -1,3 +0,0 @@
|
||||||
from django.test import TestCase
|
|
||||||
|
|
||||||
# Create your tests here.
|
|
|
@ -35,24 +35,27 @@ def create_test_pdf(rnd, organizatori):
|
||||||
|
|
||||||
# TODO silent ghostscript (vypisuje odstavec za každou stránku…)
|
# TODO silent ghostscript (vypisuje odstavec za každou stránku…)
|
||||||
|
|
||||||
KorekturovanePDF.objects.create(
|
korekturovane_pdf = KorekturovanePDF.objects.create(
|
||||||
nazev='B', komentar='Neuronové sítě', org=rnd.choice(organizatori), pdf=gen_filename(filename='B.pdf')
|
nazev='B', komentar='Neuronové sítě', pdf=gen_filename(filename='B.pdf')
|
||||||
)
|
|
||||||
|
|
||||||
KorekturovanePDF.objects.create(
|
|
||||||
nazev='A', komentar='M&M: Jak řešit?', org=rnd.choice(organizatori), pdf=gen_filename(filename='A.pdf')
|
|
||||||
)
|
)
|
||||||
|
korekturovane_pdf.orgove.set((rnd.choice(organizatori),))
|
||||||
|
|
||||||
korekturovane_pdf = KorekturovanePDF.objects.create(
|
korekturovane_pdf = KorekturovanePDF.objects.create(
|
||||||
nazev='A', komentar='M&M: Jak řešit?', org=rnd.choice(organizatori), pdf=gen_filename(filename='A.pdf'),
|
nazev='A', komentar='M&M: Jak řešit?', pdf=gen_filename(filename='A.pdf')
|
||||||
|
)
|
||||||
|
korekturovane_pdf.orgove.set(rnd.sample(organizatori, 2))
|
||||||
|
|
||||||
|
KorekturovanePDF.objects.create(
|
||||||
|
nazev='A', komentar='M&M: Jak řešit?', pdf=gen_filename(filename='A.pdf'),
|
||||||
status='zanaseni'
|
status='zanaseni'
|
||||||
)
|
)
|
||||||
|
|
||||||
KorekturovanePDF.objects.create(
|
korekturovane_pdf = KorekturovanePDF.objects.create(
|
||||||
nazev='A', komentar='M&M: Jak řešit?', org=rnd.choice(organizatori), pdf=gen_filename(filename='A.pdf'),
|
nazev='A', komentar='M&M: Jak řešit?', pdf=gen_filename(filename='A.pdf'),
|
||||||
status='zastarale'
|
status='zastarale'
|
||||||
)
|
)
|
||||||
except (FileNotFoundError, Exception) as e:
|
korekturovane_pdf.orgove.set((rnd.choice(organizatori),))
|
||||||
|
except OSError as e:
|
||||||
# TODO najít správné chyby, které vyhazují různé systémy při neexistenci ImageMagick, nebo knihoven
|
# TODO najít správné chyby, které vyhazují různé systémy při neexistenci ImageMagick, nebo knihoven
|
||||||
logger.error(str(e))
|
logger.error(str(e))
|
||||||
logger.error(
|
logger.error(
|
||||||
|
|
|
@ -1,13 +1,5 @@
|
||||||
"""
|
|
||||||
Soubor sloužící jako „router“, tj. zde se definují url adresy a na co ukazují:
|
|
||||||
|
|
||||||
- ``korektury/`` (korektury_list) :class:`~korektury.views.KorekturySeskupeneListView`
|
|
||||||
- ``korektury/neseskupene/`` (korektury_neseskupene_list) :class:`~korektury.views.KorekturyAktualniListView`
|
|
||||||
- ``korektury/zastarale/`` (korektury_stare_list) :class:`~korektury.views.KorekturyZastaraleListView`
|
|
||||||
- ``korektury/<int:pdf>/`` (korektury) :class:`~korektury.views.KorekturyView`
|
|
||||||
"""
|
|
||||||
from django.urls import path
|
from django.urls import path
|
||||||
from seminar.utils import org_required
|
from personalni.utils import org_required
|
||||||
from . import views
|
from . import views
|
||||||
|
|
||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
|
|
|
@ -1,8 +1,3 @@
|
||||||
"""
|
|
||||||
Soubor sloužící k deklaraci jednotlivých „views“ (nejčastěji funkce beroucí request
|
|
||||||
a vracející :func:`django.shortcuts.render` respektive nějakou response, nebo
|
|
||||||
třídy většinou rozšiřující nějakou třídu z :mod:`django.views.generic`)
|
|
||||||
"""
|
|
||||||
from django.shortcuts import get_object_or_404, render
|
from django.shortcuts import get_object_or_404, render
|
||||||
from django.views import generic
|
from django.views import generic
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
|
@ -188,9 +183,9 @@ class KorekturyView(generic.TemplateView):
|
||||||
if email_komentujiciho:
|
if email_komentujiciho:
|
||||||
emails.add(email_komentujiciho)
|
emails.add(email_komentujiciho)
|
||||||
|
|
||||||
# zodpovedny org
|
# zodpovedni orgove
|
||||||
if oprava.pdf.org:
|
for org in oprava.pdf.orgove.all():
|
||||||
email_zobpovedny = oprava.pdf.org.osoba.email
|
email_zobpovedny = org.osoba.email
|
||||||
if email_zobpovedny:
|
if email_zobpovedny:
|
||||||
emails.add(email_zobpovedny)
|
emails.add(email_zobpovedny)
|
||||||
|
|
||||||
|
@ -199,13 +194,6 @@ class KorekturyView(generic.TemplateView):
|
||||||
if email:
|
if email:
|
||||||
emails.discard(email)
|
emails.discard(email)
|
||||||
|
|
||||||
if not settings.POSLI_MAILOVOU_NOTIFIKACI:
|
|
||||||
print("Poslal bych upozornění na tyto adresy: ", " ".join(emails))
|
|
||||||
print("---- Upozornění:")
|
|
||||||
print(text)
|
|
||||||
print("---- Konec upozornění")
|
|
||||||
return
|
|
||||||
|
|
||||||
EmailMessage(
|
EmailMessage(
|
||||||
subject=subject,
|
subject=subject,
|
||||||
body=text,
|
body=text,
|
||||||
|
|
|
@ -7,5 +7,4 @@ make/install_web
|
||||||
ensure_venv
|
ensure_venv
|
||||||
./manage.py testdata
|
./manage.py testdata
|
||||||
./manage.py loaddata data/*
|
./manage.py loaddata data/*
|
||||||
make/sync_prod_flatpages
|
#make/sync_prod_flatpages
|
||||||
./manage.py load_org_permissions deploy_v2/admin_org_prava.json
|
|
||||||
|
|
|
@ -95,7 +95,7 @@ function safe_checkout_branch {
|
||||||
echo >&2 "Změna v $SCRIPT, prosím pullni manuálně"
|
echo >&2 "Změna v $SCRIPT, prosím pullni manuálně"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
git checkout "$BRANCH"
|
git checkout "$BRANCH" --
|
||||||
git pull
|
git pull
|
||||||
git clean -f
|
git clean -f
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@ set -exuo pipefail
|
||||||
. make/lib.sh
|
. make/lib.sh
|
||||||
|
|
||||||
scp vue_frontend/webpack-stats.json "$GIMLI_LOGIN:$TESTWEB/vue_frontend/"
|
scp vue_frontend/webpack-stats.json "$GIMLI_LOGIN:$TESTWEB/vue_frontend/"
|
||||||
rsync -ave ssh seminar/static/seminar/vue "$GIMLI_LOGIN:$TESTWEB/seminar/static/seminar/"
|
rsync -ave ssh treenode/static/treenode/vue "$GIMLI_LOGIN:$TESTWEB/treenode/static/treenode/"
|
||||||
ssh "$GIMLI_LOGIN" "
|
ssh "$GIMLI_LOGIN" "
|
||||||
set -euxo pipefail
|
set -euxo pipefail
|
||||||
cd $TESTWEB
|
cd $TESTWEB
|
||||||
|
|
|
@ -5,5 +5,4 @@ set -exuo pipefail
|
||||||
|
|
||||||
ensure_web_installed
|
ensure_web_installed
|
||||||
|
|
||||||
./manage.py graph_models seminar | dot -Tpdf > schema_seminar.pdf
|
|
||||||
./manage.py graph_models -a -g | dot -Tpdf > schema_all.pdf
|
./manage.py graph_models -a -g | dot -Tpdf > schema_all.pdf
|
||||||
|
|
|
@ -7,17 +7,18 @@ import locale
|
||||||
from django.contrib import admin
|
from django.contrib import admin
|
||||||
from django.contrib.admin import AdminSite
|
from django.contrib.admin import AdminSite
|
||||||
from django.contrib.flatpages.models import FlatPage
|
from django.contrib.flatpages.models import FlatPage
|
||||||
|
import logging
|
||||||
|
|
||||||
# Note: we are renaming the original Admin and Form as we import them!
|
# Note: we are renaming the original Admin and Form as we import them!
|
||||||
from django.contrib.flatpages.admin import FlatPageAdmin as FlatPageAdminOld
|
from django.contrib.flatpages.admin import FlatPageAdmin as FlatPageAdminOld
|
||||||
from django.contrib.flatpages.admin import FlatpageForm as FlatpageFormOld
|
from django.contrib.flatpages.admin import FlatpageForm as FlatpageFormOld
|
||||||
|
|
||||||
from django import forms
|
from django import forms
|
||||||
from ckeditor_uploader.widgets import CKEditorUploadingWidget
|
from django_ckeditor_5.widgets import CKEditor5Widget
|
||||||
|
|
||||||
|
|
||||||
class FlatpageForm(FlatpageFormOld):
|
class FlatpageForm(FlatpageFormOld):
|
||||||
content = forms.CharField(widget=CKEditorUploadingWidget())
|
content = forms.CharField(widget=CKEditor5Widget())
|
||||||
class Meta:
|
class Meta:
|
||||||
model = FlatPage # this is not automatically inherited from FlatpageFormOld
|
model = FlatPage # this is not automatically inherited from FlatpageFormOld
|
||||||
exclude = []
|
exclude = []
|
||||||
|
@ -43,7 +44,7 @@ def get_app_list(self, request, app_label=None):
|
||||||
|
|
||||||
app_dict = self._build_app_dict(request, label=app_label)
|
app_dict = self._build_app_dict(request, label=app_label)
|
||||||
aplikace_nahore = [
|
aplikace_nahore = [
|
||||||
'seminar',
|
'tvorba',
|
||||||
'personalni',
|
'personalni',
|
||||||
'novinky',
|
'novinky',
|
||||||
'korektury',
|
'korektury',
|
||||||
|
@ -51,12 +52,18 @@ def get_app_list(self, request, app_label=None):
|
||||||
'prednasky',
|
'prednasky',
|
||||||
'soustredeni',
|
'soustredeni',
|
||||||
]
|
]
|
||||||
app_list = [app_dict[label] for label in aplikace_nahore] + [app_dict[label] for label in app_dict if label not in aplikace_nahore]
|
# Odhlášený admin má prázdný app_dict :-/
|
||||||
|
app_list = [app_dict[label] for label in aplikace_nahore if label in app_dict] + [app_dict[label] for label in app_dict if label not in aplikace_nahore]
|
||||||
|
|
||||||
|
|
||||||
# Sort the models alphabetically within each app.
|
# Sort the models alphabetically within each app.
|
||||||
|
try: # na macu nefunguje locale.strxfrm :-/ proto je tu try except block
|
||||||
for app in app_list:
|
for app in app_list:
|
||||||
app['models'].sort(key=lambda x: locale.strxfrm('žž' + x['name'].lower()) if (x['name'].endswith("(Node)")) else locale.strxfrm(x['name'].lower()))
|
app['models'].sort(key=lambda x: locale.strxfrm(x['name'].lower()))
|
||||||
|
except OSError as e:
|
||||||
|
# locale.strxfrm nefunguje na macu... :-/ -> neprovede se řazení
|
||||||
|
logger = logging.getLogger(__name__)
|
||||||
|
logger.error(e)
|
||||||
|
|
||||||
return app_list
|
return app_list
|
||||||
|
|
||||||
|
|
|
@ -1,88 +0,0 @@
|
||||||
from datetime import datetime, date
|
|
||||||
|
|
||||||
from django.conf import settings
|
|
||||||
from django.http import HttpResponse, HttpResponseRedirect
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class LoggedInHintCookieMiddleware(object):
|
|
||||||
"""Middleware to securely help with 'logged-in' detection for dual HTTP/HTTPS sites.
|
|
||||||
|
|
||||||
On insecure requests: Checks for a (non-secure) cookie settings.LOGGED_IN_HINT_COOKIE_NAME
|
|
||||||
and if present, redirects to HTTPS (same adress).
|
|
||||||
Note this usually breaks non-GET (POST) requests.
|
|
||||||
|
|
||||||
On secure requests: Updates cookie settings.LOGGED_IN_HINT_COOKIE_NAME to reflect
|
|
||||||
whether an user is logged in in the current session (cookie set to 'True' or cleared).
|
|
||||||
The cookie is set to expire at the same time as the sessionid cookie.
|
|
||||||
|
|
||||||
By default, LOGGED_IN_HINT_COOKIE_NAME = 'logged_in_hint'.
|
|
||||||
"""
|
|
||||||
|
|
||||||
def __init__(self):
|
|
||||||
if hasattr(settings, 'LOGGED_IN_HINT_COOKIE_NAME'):
|
|
||||||
self.cookie_name = settings.LOGGED_IN_HINT_COOKIE_NAME
|
|
||||||
else: self.cookie_name = 'logged_in_hint'
|
|
||||||
self.cookie_value = 'True'
|
|
||||||
|
|
||||||
def cookie_correct(self, request):
|
|
||||||
return self.cookie_name in request.COOKIES and request.COOKIES[self.cookie_name] == self.cookie_value
|
|
||||||
|
|
||||||
def process_request(self, request):
|
|
||||||
if not request.is_secure():
|
|
||||||
if self.cookie_correct(request):
|
|
||||||
# redirect insecure (assuming http) requests with hint cookie to https
|
|
||||||
url = request.build_absolute_uri()
|
|
||||||
assert url[:5] == 'http:'
|
|
||||||
return HttpResponseRedirect('https:' + url[5:])
|
|
||||||
return None
|
|
||||||
|
|
||||||
def process_response(self, request, response):
|
|
||||||
if request.is_secure():
|
|
||||||
# assuming full session info (as the conn. is secure)
|
|
||||||
try:
|
|
||||||
user = request.user
|
|
||||||
except AttributeError: # no user - ajax or other special request
|
|
||||||
return response
|
|
||||||
if user.is_authenticated():
|
|
||||||
if not self.cookie_correct(request):
|
|
||||||
expiry = None if request.session.get_expire_at_browser_close() else request.session.get_expiry_date()
|
|
||||||
response.set_cookie(self.cookie_name, value=self.cookie_value, expires=expiry, secure=False)
|
|
||||||
else:
|
|
||||||
if self.cookie_name in request.COOKIES:
|
|
||||||
response.delete_cookie(self.cookie_name)
|
|
||||||
return response
|
|
||||||
|
|
||||||
|
|
||||||
class vzhled:
|
|
||||||
|
|
||||||
def process_request(self, request):
|
|
||||||
return None
|
|
||||||
|
|
||||||
def process_view(self, request, view_func, view_args, view_kwargs):
|
|
||||||
#print "====== process_request ======"
|
|
||||||
#print view_func
|
|
||||||
#print view_args
|
|
||||||
#print view_kwargs
|
|
||||||
#print "============================="
|
|
||||||
return None
|
|
||||||
|
|
||||||
def process_template_response(self, request, response):
|
|
||||||
hodin = datetime.now().hour
|
|
||||||
if (hodin <= 6) or (hodin >= 14): # TODO 20
|
|
||||||
response.context_data['noc'] = True
|
|
||||||
else:
|
|
||||||
response.context_data['noc'] = False
|
|
||||||
return response
|
|
||||||
|
|
||||||
def process_response(self, request, response):
|
|
||||||
#hodin = datetime.now().hour
|
|
||||||
#if (hodin <= 6) or (hodin >= 14): # TODO 20
|
|
||||||
#response.context_data['noc'] = True
|
|
||||||
#else:
|
|
||||||
#response.context_data['noc'] = False
|
|
||||||
return response
|
|
||||||
|
|
||||||
|
|
||||||
##def process_exception(request, exception):
|
|
||||||
#pass
|
|
|
@ -54,7 +54,7 @@ SESSION_EXPIRE_AT_BROWSER_CLOSE = True
|
||||||
DOBA_ODHLASENI_PRI_ZASKRTNUTI_NEODHLASOVAT = 365 * 24 * 3600 # rok
|
DOBA_ODHLASENI_PRI_ZASKRTNUTI_NEODHLASOVAT = 365 * 24 * 3600 # rok
|
||||||
|
|
||||||
# View pro chybu s CSRF tokenem (např. se sušenkami)
|
# View pro chybu s CSRF tokenem (např. se sušenkami)
|
||||||
CSRF_FAILURE_VIEW = 'various.views.csrf_error'
|
CSRF_FAILURE_VIEW = 'various.views.csrf.csrf_error'
|
||||||
|
|
||||||
# Modules configuration
|
# Modules configuration
|
||||||
|
|
||||||
|
@ -68,9 +68,6 @@ MIDDLEWARE = (
|
||||||
'django.contrib.sessions.middleware.SessionMiddleware',
|
'django.contrib.sessions.middleware.SessionMiddleware',
|
||||||
'django.middleware.common.CommonMiddleware',
|
'django.middleware.common.CommonMiddleware',
|
||||||
'django.middleware.csrf.CsrfViewMiddleware',
|
'django.middleware.csrf.CsrfViewMiddleware',
|
||||||
# FIXME: rozbilo se při přechodu na Django 2.0, nevím, jestli
|
|
||||||
# se to dá zahodit bez náhrady
|
|
||||||
# 'mamweb.middleware.LoggedInHintCookieMiddleware',
|
|
||||||
'django.contrib.auth.middleware.AuthenticationMiddleware',
|
'django.contrib.auth.middleware.AuthenticationMiddleware',
|
||||||
'django.contrib.messages.middleware.MessageMiddleware',
|
'django.contrib.messages.middleware.MessageMiddleware',
|
||||||
'django.middleware.clickjacking.XFrameOptionsMiddleware',
|
'django.middleware.clickjacking.XFrameOptionsMiddleware',
|
||||||
|
@ -90,6 +87,7 @@ TEMPLATES = [
|
||||||
'header_fotky.context_processors.vzhled',
|
'header_fotky.context_processors.vzhled',
|
||||||
'various.context_processors.rozliseni',
|
'various.context_processors.rozliseni',
|
||||||
'various.context_processors.april',
|
'various.context_processors.april',
|
||||||
|
'various.context_processors.halloween',
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -112,8 +110,7 @@ INSTALLED_APPS = (
|
||||||
'reversion',
|
'reversion',
|
||||||
'django_countries',
|
'django_countries',
|
||||||
'solo',
|
'solo',
|
||||||
'ckeditor',
|
'django_ckeditor_5',
|
||||||
'ckeditor_uploader',
|
|
||||||
'taggit',
|
'taggit',
|
||||||
'dal',
|
'dal',
|
||||||
'dal_select2',
|
'dal_select2',
|
||||||
|
@ -134,6 +131,7 @@ INSTALLED_APPS = (
|
||||||
# MaMweb
|
# MaMweb
|
||||||
'mamweb',
|
'mamweb',
|
||||||
'seminar',
|
'seminar',
|
||||||
|
'tvorba',
|
||||||
'galerie',
|
'galerie',
|
||||||
'korektury',
|
'korektury',
|
||||||
'prednasky',
|
'prednasky',
|
||||||
|
@ -187,26 +185,98 @@ SUMMERNOTE_CONFIG = {
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
CKEDITOR_UPLOAD_PATH = "uploads/"
|
CKEDITOR_5_CUSTOM_CSS = "css/ckeditor5_fix.css"
|
||||||
CKEDITOR_IMAGE_BACKEND = 'pillow'
|
# customColorPalette = [
|
||||||
#CKEDITOR_JQUERY_URL = '//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js'
|
# {
|
||||||
CKEDITOR_CONFIGS = {
|
# 'color': 'hsl(4, 90%, 58%)',
|
||||||
|
# 'label': 'Red',
|
||||||
|
# },
|
||||||
|
# {
|
||||||
|
# 'color': 'hsl(340, 82%, 52%)',
|
||||||
|
# 'label': 'Pink',
|
||||||
|
# },
|
||||||
|
# {
|
||||||
|
# 'color': 'hsl(291, 64%, 42%)',
|
||||||
|
# 'label': 'Purple',
|
||||||
|
# },
|
||||||
|
# {
|
||||||
|
# 'color': 'hsl(262, 52%, 47%)',
|
||||||
|
# 'label': 'Deep Purple',
|
||||||
|
# },
|
||||||
|
# {
|
||||||
|
# 'color': 'hsl(231, 48%, 48%)',
|
||||||
|
# 'label': 'Indigo',
|
||||||
|
# },
|
||||||
|
# {
|
||||||
|
# 'color': 'hsl(207, 90%, 54%)',
|
||||||
|
# 'label': 'Blue',
|
||||||
|
# },
|
||||||
|
# ]
|
||||||
|
CKEDITOR_5_FILE_STORAGE = "various.storage.UploadStorage"
|
||||||
|
CKEDITOR_5_CONFIGS = {
|
||||||
'default': {
|
'default': {
|
||||||
'entities': False,
|
'language': 'cs',
|
||||||
'toolbar': [
|
'blockToolbar': [
|
||||||
['Source', 'ShowBlocks', '-', 'Maximize'],
|
'paragraph', 'heading1', 'heading2', 'heading3',
|
||||||
['Bold', 'Italic', 'Subscript', 'Superscript', '-', 'RemoveFormat'],
|
'|',
|
||||||
['NumberedList','BulletedList','-','Blockquote','-','JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
|
'bulletedList', 'numberedList',
|
||||||
['Link', 'Unlink', 'Anchor', '-', 'Image', 'Table', 'HorizontalRule'],
|
'|',
|
||||||
['Format'],
|
'blockQuote',
|
||||||
|
|
||||||
],
|
],
|
||||||
# 'toolbar': 'full',
|
'toolbar': ['sourceEditing', '|', 'heading', '|',
|
||||||
'height': '40em',
|
# 'outdent', 'indent', '|',
|
||||||
'width': '100%',
|
'bold', 'italic', 'link', 'underline', 'strikethrough',
|
||||||
'toolbarStartupExpanded': False,
|
'code',
|
||||||
'allowedContent' : True,
|
# 'subscript', 'superscript',
|
||||||
|
# 'highlight',
|
||||||
|
'|', 'codeBlock', 'insertImage',
|
||||||
|
'bulletedList', 'numberedList', 'todoList', '|',
|
||||||
|
# 'blockQuote', '|',
|
||||||
|
# 'fontSize', 'fontFamily', 'fontColor', 'fontBackgroundColor',
|
||||||
|
# 'mediaEmbed',
|
||||||
|
'removeFormat',
|
||||||
|
# 'insertTable',
|
||||||
|
],
|
||||||
|
'image': {
|
||||||
|
'toolbar': ['imageTextAlternative', '|', 'imageStyle:alignLeft',
|
||||||
|
'imageStyle:alignRight', 'imageStyle:alignCenter', 'imageStyle:side', '|'],
|
||||||
|
'styles': [
|
||||||
|
'full',
|
||||||
|
'side',
|
||||||
|
'alignLeft',
|
||||||
|
'alignRight',
|
||||||
|
'alignCenter',
|
||||||
|
]
|
||||||
|
|
||||||
},
|
},
|
||||||
|
# 'table': {
|
||||||
|
# 'contentToolbar': [ 'tableColumn', 'tableRow', 'mergeTableCells',
|
||||||
|
# 'tableProperties', 'tableCellProperties' ],
|
||||||
|
# 'tableProperties': {
|
||||||
|
# 'borderColors': customColorPalette,
|
||||||
|
# 'backgroundColors': customColorPalette,
|
||||||
|
# },
|
||||||
|
# 'tableCellProperties': {
|
||||||
|
# 'borderColors': customColorPalette,
|
||||||
|
# 'backgroundColors': customColorPalette,
|
||||||
|
# }
|
||||||
|
# },
|
||||||
|
'heading' : {
|
||||||
|
'options': [
|
||||||
|
{ 'model': 'paragraph', 'title': 'Paragraph', 'class': 'ck-heading_paragraph' },
|
||||||
|
{ 'model': 'heading1', 'view': 'h1', 'title': 'Heading 1', 'class': 'ck-heading_heading1' },
|
||||||
|
{ 'model': 'heading2', 'view': 'h2', 'title': 'Heading 2', 'class': 'ck-heading_heading2' },
|
||||||
|
{ 'model': 'heading3', 'view': 'h3', 'title': 'Heading 3', 'class': 'ck-heading_heading3' },
|
||||||
|
]
|
||||||
|
},
|
||||||
|
},
|
||||||
|
'list': {
|
||||||
|
'properties': {
|
||||||
|
'styles': 'true',
|
||||||
|
'startIndex': 'true',
|
||||||
|
'reversed': 'true',
|
||||||
|
},
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# Webpack loader
|
# Webpack loader
|
||||||
|
@ -280,11 +350,11 @@ LOGGING = {
|
||||||
'filters': ['Http404AsInfo'],
|
'filters': ['Http404AsInfo'],
|
||||||
},
|
},
|
||||||
|
|
||||||
'seminar.prihlaska.form':{
|
'personalni.prihlaska.form':{
|
||||||
'handlers': ['console','registration_logfile'],
|
'handlers': ['console','registration_logfile'],
|
||||||
'level': 'INFO'
|
'level': 'INFO'
|
||||||
},
|
},
|
||||||
'seminar.prihlaska.problem':{
|
'personalni.prihlaska.problem':{
|
||||||
'handlers': ['console','mail_registration','registration_error_log'],
|
'handlers': ['console','mail_registration','registration_error_log'],
|
||||||
'level': 'INFO'
|
'level': 'INFO'
|
||||||
},
|
},
|
||||||
|
@ -343,10 +413,7 @@ SEMINAR_KONFERY_DIR = os.path.join('konfery')
|
||||||
KOREKTURY_PDF_DIR = os.path.join('korektury', 'pdf')
|
KOREKTURY_PDF_DIR = os.path.join('korektury', 'pdf')
|
||||||
KOREKTURY_IMG_DIR = os.path.join('korektury', 'img')
|
KOREKTURY_IMG_DIR = os.path.join('korektury', 'img')
|
||||||
CISLO_IMG_DIR = os.path.join('cislo', 'img')
|
CISLO_IMG_DIR = os.path.join('cislo', 'img')
|
||||||
|
SOUSTREDENI_KONTAKTNICKY_DIR = os.path.join('soustredeni', 'kontaktnicky')
|
||||||
|
|
||||||
# E-MAIL NOTIFICATIONS
|
|
||||||
POSLI_MAILOVOU_NOTIFIKACI = False
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
|
|
||||||
import os.path
|
import os.path
|
||||||
|
|
||||||
#
|
#
|
||||||
|
@ -70,5 +68,4 @@ LOGGING['handlers']['registration_error_log']['filename'] = '/home/mam-web/logs/
|
||||||
|
|
||||||
|
|
||||||
# E-MAIL NOTIFICATIONS
|
# E-MAIL NOTIFICATIONS
|
||||||
POSLI_MAILOVOU_NOTIFIKACI = True
|
|
||||||
LOCAL_TEST_PROD = "prod"
|
LOCAL_TEST_PROD = "prod"
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
||||||
|
|
||||||
import os.path
|
import os.path
|
||||||
|
|
||||||
#
|
#
|
||||||
|
@ -74,7 +72,6 @@ LOGGING['handlers']['registration_error_log']['filename'] = '/home/mam-web/logs/
|
||||||
FILE_UPLOAD_PERMISSIONS = 0o440
|
FILE_UPLOAD_PERMISSIONS = 0o440
|
||||||
|
|
||||||
# Testování e-mailů
|
# Testování e-mailů
|
||||||
POSLI_MAILOVOU_NOTIFIKACI = True
|
|
||||||
EMAIL_BACKEND = 'various.mail_prefixer.PrefixingMailBackend'
|
EMAIL_BACKEND = 'various.mail_prefixer.PrefixingMailBackend'
|
||||||
# TODO Pouze na otestování testu… Zvolit konferu!
|
# TODO Pouze na otestování testu… Zvolit konferu!
|
||||||
# XXX: Je to pole, protože implementační detail backendu.
|
# XXX: Je to pole, protože implementační detail backendu.
|
||||||
|
|
12068
mamweb/static/bootstrap/css/bootstrap.css
vendored
Normal file
6314
mamweb/static/bootstrap/js/bootstrap.bundle.js
vendored
Normal file
102
mamweb/static/css/base.css
Normal file
|
@ -0,0 +1,102 @@
|
||||||
|
@charset "utf-8"; /* vynuť utf-8 */
|
||||||
|
|
||||||
|
/* Obecné styly pro html tagy */
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'OpenSans';
|
||||||
|
src: url("../fonts/OpenSans/OpenSans-Regular.ttf");
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* https://fontzone.net/font-details/qtghoulface-regular doplněný o diakritiku pomocí FontForge*/
|
||||||
|
@font-face {
|
||||||
|
font-family: 'GhoulFace';
|
||||||
|
src: url("../fonts/ghoul/ghoul.ttf");
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-size: 14px;
|
||||||
|
font-family: 'OpenSans';
|
||||||
|
background-color: var(--barva-pozadi);
|
||||||
|
min-height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
p {
|
||||||
|
/* zarovnání odstavců do bloku */
|
||||||
|
text-align: justify;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**** NADPISY ****/
|
||||||
|
h1, h2, h3, h4 { color: var(--tmava-oranzova); }
|
||||||
|
h5, h6 { color: black; }
|
||||||
|
|
||||||
|
h1, h2, h3, h4, h5, h6 {
|
||||||
|
font-variant: small-caps;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* TODO: odlišit 1 a 2 */
|
||||||
|
h1 { font-size: 200%; }
|
||||||
|
h2 { font-size: 200%; }
|
||||||
|
h3 { font-size: 160%; }
|
||||||
|
h4 { font-size: 140%; }
|
||||||
|
h5 { font-size: 140%; }
|
||||||
|
h6 { font-size: 120%; }
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
/*****************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** TLAČÍTKA ****/
|
||||||
|
a {
|
||||||
|
color: var(--tmava-oranzova);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
a:focus, a:hover, a:active {
|
||||||
|
color: var(--hlavni-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
.button {
|
||||||
|
margin: 10px 0 10px 0;
|
||||||
|
padding: 4px 0; /*vertikální centování textu*/
|
||||||
|
text-align: center;
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
font-size: 150%;
|
||||||
|
font-weight: bold;
|
||||||
|
font-variant: small-caps;
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
position: relative;
|
||||||
|
top: 2px;
|
||||||
|
left: 2px;
|
||||||
|
background-color: #df490e;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/******************/
|
||||||
|
|
||||||
|
/**** Další ****/
|
||||||
|
input[type="file"] {
|
||||||
|
max-width: 250px;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
/***************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** Divné (aneb nevím, co bylo cílem) ****/
|
||||||
|
h1 a:hover {
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
img {
|
||||||
|
filter: drop-shadow(0px 3px 3px rgba(0, 0, 0, 0.4));
|
||||||
|
max-width: 100%;
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
/*******************************************/
|
469
mamweb/static/css/bootstrap-theme.css
vendored
|
@ -1,469 +0,0 @@
|
||||||
/*!
|
|
||||||
* Bootstrap v3.3.1 (http://getbootstrap.com)
|
|
||||||
* Copyright 2011-2014 Twitter, Inc.
|
|
||||||
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
|
|
||||||
*/
|
|
||||||
|
|
||||||
.btn-default,
|
|
||||||
.btn-primary,
|
|
||||||
.btn-success,
|
|
||||||
.btn-info,
|
|
||||||
.btn-warning,
|
|
||||||
.btn-danger {
|
|
||||||
text-shadow: 0 -1px 0 rgba(0, 0, 0, .2);
|
|
||||||
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
|
|
||||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
|
|
||||||
}
|
|
||||||
.btn-default:active,
|
|
||||||
.btn-primary:active,
|
|
||||||
.btn-success:active,
|
|
||||||
.btn-info:active,
|
|
||||||
.btn-warning:active,
|
|
||||||
.btn-danger:active,
|
|
||||||
.btn-default.active,
|
|
||||||
.btn-primary.active,
|
|
||||||
.btn-success.active,
|
|
||||||
.btn-info.active,
|
|
||||||
.btn-warning.active,
|
|
||||||
.btn-danger.active {
|
|
||||||
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
|
|
||||||
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
|
|
||||||
}
|
|
||||||
.btn-default .badge,
|
|
||||||
.btn-primary .badge,
|
|
||||||
.btn-success .badge,
|
|
||||||
.btn-info .badge,
|
|
||||||
.btn-warning .badge,
|
|
||||||
.btn-danger .badge {
|
|
||||||
text-shadow: none;
|
|
||||||
}
|
|
||||||
.btn:active,
|
|
||||||
.btn.active {
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
.btn-default {
|
|
||||||
text-shadow: 0 1px 0 #fff;
|
|
||||||
background-image: -webkit-linear-gradient(top, #fff 0%, #e0e0e0 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #fff 0%, #e0e0e0 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#e0e0e0));
|
|
||||||
background-image: linear-gradient(to bottom, #fff 0%, #e0e0e0 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #dbdbdb;
|
|
||||||
border-color: #ccc;
|
|
||||||
}
|
|
||||||
.btn-default:hover,
|
|
||||||
.btn-default:focus {
|
|
||||||
background-color: #e0e0e0;
|
|
||||||
background-position: 0 -15px;
|
|
||||||
}
|
|
||||||
.btn-default:active,
|
|
||||||
.btn-default.active {
|
|
||||||
background-color: #e0e0e0;
|
|
||||||
border-color: #dbdbdb;
|
|
||||||
}
|
|
||||||
.btn-default:disabled,
|
|
||||||
.btn-default[disabled] {
|
|
||||||
background-color: #e0e0e0;
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
.btn-primary {
|
|
||||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #265a88 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #337ab7 0%, #265a88 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#265a88));
|
|
||||||
background-image: linear-gradient(to bottom, #337ab7 0%, #265a88 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff265a88', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #245580;
|
|
||||||
}
|
|
||||||
.btn-primary:hover,
|
|
||||||
.btn-primary:focus {
|
|
||||||
background-color: #265a88;
|
|
||||||
background-position: 0 -15px;
|
|
||||||
}
|
|
||||||
.btn-primary:active,
|
|
||||||
.btn-primary.active {
|
|
||||||
background-color: #265a88;
|
|
||||||
border-color: #245580;
|
|
||||||
}
|
|
||||||
.btn-primary:disabled,
|
|
||||||
.btn-primary[disabled] {
|
|
||||||
background-color: #265a88;
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
.btn-success {
|
|
||||||
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #419641 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #5cb85c 0%, #419641 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#419641));
|
|
||||||
background-image: linear-gradient(to bottom, #5cb85c 0%, #419641 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #3e8f3e;
|
|
||||||
}
|
|
||||||
.btn-success:hover,
|
|
||||||
.btn-success:focus {
|
|
||||||
background-color: #419641;
|
|
||||||
background-position: 0 -15px;
|
|
||||||
}
|
|
||||||
.btn-success:active,
|
|
||||||
.btn-success.active {
|
|
||||||
background-color: #419641;
|
|
||||||
border-color: #3e8f3e;
|
|
||||||
}
|
|
||||||
.btn-success:disabled,
|
|
||||||
.btn-success[disabled] {
|
|
||||||
background-color: #419641;
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
.btn-info {
|
|
||||||
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#2aabd2));
|
|
||||||
background-image: linear-gradient(to bottom, #5bc0de 0%, #2aabd2 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #28a4c9;
|
|
||||||
}
|
|
||||||
.btn-info:hover,
|
|
||||||
.btn-info:focus {
|
|
||||||
background-color: #2aabd2;
|
|
||||||
background-position: 0 -15px;
|
|
||||||
}
|
|
||||||
.btn-info:active,
|
|
||||||
.btn-info.active {
|
|
||||||
background-color: #2aabd2;
|
|
||||||
border-color: #28a4c9;
|
|
||||||
}
|
|
||||||
.btn-info:disabled,
|
|
||||||
.btn-info[disabled] {
|
|
||||||
background-color: #2aabd2;
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
.btn-warning {
|
|
||||||
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#eb9316));
|
|
||||||
background-image: linear-gradient(to bottom, #f0ad4e 0%, #eb9316 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #e38d13;
|
|
||||||
}
|
|
||||||
.btn-warning:hover,
|
|
||||||
.btn-warning:focus {
|
|
||||||
background-color: #eb9316;
|
|
||||||
background-position: 0 -15px;
|
|
||||||
}
|
|
||||||
.btn-warning:active,
|
|
||||||
.btn-warning.active {
|
|
||||||
background-color: #eb9316;
|
|
||||||
border-color: #e38d13;
|
|
||||||
}
|
|
||||||
.btn-warning:disabled,
|
|
||||||
.btn-warning[disabled] {
|
|
||||||
background-color: #eb9316;
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
.btn-danger {
|
|
||||||
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c12e2a));
|
|
||||||
background-image: linear-gradient(to bottom, #d9534f 0%, #c12e2a 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #b92c28;
|
|
||||||
}
|
|
||||||
.btn-danger:hover,
|
|
||||||
.btn-danger:focus {
|
|
||||||
background-color: #c12e2a;
|
|
||||||
background-position: 0 -15px;
|
|
||||||
}
|
|
||||||
.btn-danger:active,
|
|
||||||
.btn-danger.active {
|
|
||||||
background-color: #c12e2a;
|
|
||||||
border-color: #b92c28;
|
|
||||||
}
|
|
||||||
.btn-danger:disabled,
|
|
||||||
.btn-danger[disabled] {
|
|
||||||
background-color: #c12e2a;
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
.thumbnail,
|
|
||||||
.img-thumbnail {
|
|
||||||
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
|
|
||||||
box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
|
|
||||||
}
|
|
||||||
.dropdown-menu > li > a:hover,
|
|
||||||
.dropdown-menu > li > a:focus {
|
|
||||||
background-color: #e8e8e8;
|
|
||||||
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
|
|
||||||
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.dropdown-menu > .active > a,
|
|
||||||
.dropdown-menu > .active > a:hover,
|
|
||||||
.dropdown-menu > .active > a:focus {
|
|
||||||
background-color: #2e6da4;
|
|
||||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
|
|
||||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.navbar-default {
|
|
||||||
background-image: -webkit-linear-gradient(top, #fff 0%, #f8f8f8 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #fff 0%, #f8f8f8 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#f8f8f8));
|
|
||||||
background-image: linear-gradient(to bottom, #fff 0%, #f8f8f8 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-radius: 4px;
|
|
||||||
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
|
|
||||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
|
|
||||||
}
|
|
||||||
.navbar-default .navbar-nav > .open > a,
|
|
||||||
.navbar-default .navbar-nav > .active > a {
|
|
||||||
background-image: -webkit-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#dbdbdb), to(#e2e2e2));
|
|
||||||
background-image: linear-gradient(to bottom, #dbdbdb 0%, #e2e2e2 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdbdbdb', endColorstr='#ffe2e2e2', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
|
|
||||||
box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
|
|
||||||
}
|
|
||||||
.navbar-brand,
|
|
||||||
.navbar-nav > li > a {
|
|
||||||
text-shadow: 0 1px 0 rgba(255, 255, 255, .25);
|
|
||||||
}
|
|
||||||
.navbar-inverse {
|
|
||||||
background-image: -webkit-linear-gradient(top, #3c3c3c 0%, #222 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #3c3c3c 0%, #222 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#3c3c3c), to(#222));
|
|
||||||
background-image: linear-gradient(to bottom, #3c3c3c 0%, #222 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.navbar-inverse .navbar-nav > .open > a,
|
|
||||||
.navbar-inverse .navbar-nav > .active > a {
|
|
||||||
background-image: -webkit-linear-gradient(top, #080808 0%, #0f0f0f 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #080808 0%, #0f0f0f 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#080808), to(#0f0f0f));
|
|
||||||
background-image: linear-gradient(to bottom, #080808 0%, #0f0f0f 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff080808', endColorstr='#ff0f0f0f', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
|
|
||||||
box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
|
|
||||||
}
|
|
||||||
.navbar-inverse .navbar-brand,
|
|
||||||
.navbar-inverse .navbar-nav > li > a {
|
|
||||||
text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
|
|
||||||
}
|
|
||||||
.navbar-static-top,
|
|
||||||
.navbar-fixed-top,
|
|
||||||
.navbar-fixed-bottom {
|
|
||||||
border-radius: 0;
|
|
||||||
}
|
|
||||||
@media (max-width: 767px) {
|
|
||||||
.navbar .navbar-nav .open .dropdown-menu > .active > a,
|
|
||||||
.navbar .navbar-nav .open .dropdown-menu > .active > a:hover,
|
|
||||||
.navbar .navbar-nav .open .dropdown-menu > .active > a:focus {
|
|
||||||
color: #fff;
|
|
||||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
|
|
||||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.alert {
|
|
||||||
text-shadow: 0 1px 0 rgba(255, 255, 255, .2);
|
|
||||||
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
|
|
||||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
|
|
||||||
}
|
|
||||||
.alert-success {
|
|
||||||
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#c8e5bc));
|
|
||||||
background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #b2dba1;
|
|
||||||
}
|
|
||||||
.alert-info {
|
|
||||||
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#b9def0));
|
|
||||||
background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #9acfea;
|
|
||||||
}
|
|
||||||
.alert-warning {
|
|
||||||
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#f8efc0));
|
|
||||||
background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #f5e79e;
|
|
||||||
}
|
|
||||||
.alert-danger {
|
|
||||||
background-image: -webkit-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#e7c3c3));
|
|
||||||
background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #dca7a7;
|
|
||||||
}
|
|
||||||
.progress {
|
|
||||||
background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#f5f5f5));
|
|
||||||
background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.progress-bar {
|
|
||||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #286090 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #337ab7 0%, #286090 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#286090));
|
|
||||||
background-image: linear-gradient(to bottom, #337ab7 0%, #286090 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff286090', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.progress-bar-success {
|
|
||||||
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #449d44 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #5cb85c 0%, #449d44 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#449d44));
|
|
||||||
background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.progress-bar-info {
|
|
||||||
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#31b0d5));
|
|
||||||
background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.progress-bar-warning {
|
|
||||||
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#ec971f));
|
|
||||||
background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.progress-bar-danger {
|
|
||||||
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c9302c 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #d9534f 0%, #c9302c 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c9302c));
|
|
||||||
background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.progress-bar-striped {
|
|
||||||
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
|
|
||||||
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
|
|
||||||
background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
|
|
||||||
}
|
|
||||||
.list-group {
|
|
||||||
border-radius: 4px;
|
|
||||||
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
|
|
||||||
box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
|
|
||||||
}
|
|
||||||
.list-group-item.active,
|
|
||||||
.list-group-item.active:hover,
|
|
||||||
.list-group-item.active:focus {
|
|
||||||
text-shadow: 0 -1px 0 #286090;
|
|
||||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2b669a 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2b669a 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2b669a));
|
|
||||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2b669a 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2b669a', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #2b669a;
|
|
||||||
}
|
|
||||||
.list-group-item.active .badge,
|
|
||||||
.list-group-item.active:hover .badge,
|
|
||||||
.list-group-item.active:focus .badge {
|
|
||||||
text-shadow: none;
|
|
||||||
}
|
|
||||||
.panel {
|
|
||||||
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
|
|
||||||
box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
|
|
||||||
}
|
|
||||||
.panel-default > .panel-heading {
|
|
||||||
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
|
|
||||||
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.panel-primary > .panel-heading {
|
|
||||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
|
|
||||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.panel-success > .panel-heading {
|
|
||||||
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#d0e9c6));
|
|
||||||
background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.panel-info > .panel-heading {
|
|
||||||
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#c4e3f3));
|
|
||||||
background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.panel-warning > .panel-heading {
|
|
||||||
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#faf2cc));
|
|
||||||
background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.panel-danger > .panel-heading {
|
|
||||||
background-image: -webkit-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#ebcccc));
|
|
||||||
background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
}
|
|
||||||
.well {
|
|
||||||
background-image: -webkit-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
|
|
||||||
background-image: -o-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
|
|
||||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#e8e8e8), to(#f5f5f5));
|
|
||||||
background-image: linear-gradient(to bottom, #e8e8e8 0%, #f5f5f5 100%);
|
|
||||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
border-color: #dcdcdc;
|
|
||||||
-webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
|
|
||||||
box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
|
|
||||||
}
|
|
6331
mamweb/static/css/bootstrap.css
vendored
3
mamweb/static/css/ckeditor5_fix.css
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
.ck.ck-editor {
|
||||||
|
color: black !important; /* V tmavém módu zapomene CKEditor přepnout barvu textu. (Bílý text na bílém pozadí je best.) */
|
||||||
|
}
|
18
mamweb/static/css/constants.css
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
@charset "utf-8"; /* vynuť utf-8 */
|
||||||
|
|
||||||
|
/* Konstanty (převážně barvy) pro užití v dalších css */
|
||||||
|
|
||||||
|
:root {
|
||||||
|
--hlavni-oranzova: #e84e10;
|
||||||
|
--tmava-oranzova: #6f2509;
|
||||||
|
--svetla-oranzova: #f9d59e;
|
||||||
|
--svetlounka-oranzova: rgb(253, 237, 213);
|
||||||
|
|
||||||
|
--orgovska-fialova: #6a0043;
|
||||||
|
--orgovska-svetla-fialova: #eee4ec;
|
||||||
|
--resitelska-fialova: #f296b3;
|
||||||
|
--resitelska-svetla-fialova: #f2E5EF;
|
||||||
|
|
||||||
|
--barva-pozadi: #fffbf6;
|
||||||
|
}
|
||||||
|
|
581
mamweb/static/css/layout.css
Normal file
|
@ -0,0 +1,581 @@
|
||||||
|
@charset "utf-8"; /* vynuť utf-8 */
|
||||||
|
|
||||||
|
/* Rozložení webu a jeho prvky (hlavička, menu, footer) */
|
||||||
|
|
||||||
|
:root {
|
||||||
|
--footer-height: 200px;
|
||||||
|
--login-bar-height: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**** KONTEJNER ****/
|
||||||
|
div.kontejner {/* Ne container, aby se to netlouklo s bootstrapem. */
|
||||||
|
width: 970px;
|
||||||
|
margin: auto;
|
||||||
|
min-height: 100vh;
|
||||||
|
position: relative;
|
||||||
|
padding: 0;
|
||||||
|
|
||||||
|
.org-logged-in & {
|
||||||
|
margin-top: var(--login-bar-height);
|
||||||
|
}
|
||||||
|
|
||||||
|
& div.kontent-wrapper {
|
||||||
|
padding-bottom: var(--footer-height);
|
||||||
|
|
||||||
|
& div.kontent {
|
||||||
|
padding: 15px 30px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Roztáhne obsah z containeru na celou šířku obrazovky: */
|
||||||
|
.full_width {
|
||||||
|
width: 100vw;
|
||||||
|
margin-left: calc(-50vw + 485px);
|
||||||
|
|
||||||
|
/* Na úzkém displeji nechceme nic dělat. */
|
||||||
|
@media(max-width: 860px) {
|
||||||
|
margin-left: 0;
|
||||||
|
width: unset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*******************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** HLAVIČKA ****/
|
||||||
|
#title { /*dělá blbosti šířka, je to kvůli fixed pozici, zatím natvrdo, vyřešit*/
|
||||||
|
height: 55px;
|
||||||
|
width: 970px;
|
||||||
|
position: fixed;
|
||||||
|
z-index: 2048;
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
|
||||||
|
font-size: 28px;
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
font-weight: 400;
|
||||||
|
font-variant: small-caps;
|
||||||
|
text-align: center;
|
||||||
|
text-decoration: none;
|
||||||
|
padding-top: 8px;
|
||||||
|
text-shadow: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header {
|
||||||
|
position: relative;
|
||||||
|
background: url("../images/header/vikendovka.jpg") no-repeat center top; /* poměr 350:970, TODO: aby to nemuselo být přesně na pixely */
|
||||||
|
background-size: 100%;
|
||||||
|
top: 58px;
|
||||||
|
|
||||||
|
& img.logo {
|
||||||
|
width: 100%;
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
}
|
||||||
|
|
||||||
|
& img.logo-mobile {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
& .no-mobile {
|
||||||
|
background-size: contain;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/******************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** Footer ****/
|
||||||
|
#footer {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
width: 100%;
|
||||||
|
background: url("../images/mozaika-footer.svg") no-repeat top center;
|
||||||
|
height: var(--footer-height);
|
||||||
|
background-size: 100%;
|
||||||
|
filter: drop-shadow(5px 0px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
padding-top: 3.5%;
|
||||||
|
|
||||||
|
& p.license {
|
||||||
|
text-align: center;
|
||||||
|
font-weight: 400;
|
||||||
|
bottom: 0;
|
||||||
|
|
||||||
|
& a {
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
p.license-mobile {
|
||||||
|
display: none;
|
||||||
|
margin-bottom: 0;
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
position: relative;
|
||||||
|
display: block;
|
||||||
|
font-size: 90%;
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
padding: 5%;
|
||||||
|
text-align: justify;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/****************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** LOGIN BAR ****/
|
||||||
|
div.login-bar {
|
||||||
|
background: var(--orgovska-fialova);
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
position: fixed;
|
||||||
|
margin-top: calc(-1 * var(--login-bar-height));
|
||||||
|
min-height: var(--login-bar-height);
|
||||||
|
z-index: 4086;
|
||||||
|
|
||||||
|
padding-left: 5px;
|
||||||
|
padding-right: 5px;
|
||||||
|
|
||||||
|
& div {
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
|
||||||
|
& a.LOGIN-ref-admin {
|
||||||
|
display: inline;
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
}
|
||||||
|
|
||||||
|
& .LOGIN_napis-webarum {
|
||||||
|
display: inline;
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
float: right;
|
||||||
|
|
||||||
|
& a {
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
text-decoration: underline;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*******************/
|
||||||
|
|
||||||
|
|
||||||
|
/* stránka přes celý displej */
|
||||||
|
@media (max-width: 970px) {
|
||||||
|
div.kontejner {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#title {
|
||||||
|
width: 100%;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header {
|
||||||
|
background-size: 100%;
|
||||||
|
|
||||||
|
& img.logo {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#footer {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* malý tablet, mobil */
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
|
||||||
|
#hide-if-small.login-bar-flatpage {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#title {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header {
|
||||||
|
width: 100%;
|
||||||
|
top: 0;
|
||||||
|
background-image: none;
|
||||||
|
|
||||||
|
& img.logo {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
& img.logo-mobile {
|
||||||
|
display: block;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
filter: drop-shadow(0px 0 5px rgba(0, 0, 0, 0.4));
|
||||||
|
margin-bottom: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
|
& .no-mobile{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**** MENU ****/
|
||||||
|
ul.menu_mobile {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
nav.nav-button {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu {
|
||||||
|
width: 100%;
|
||||||
|
padding: 0;
|
||||||
|
margin-top: -5px; /* posune celé menu nahoru (pak potřeba zvětšit mezeru mezi menu a submenu) */
|
||||||
|
|
||||||
|
font-variant: small-caps;
|
||||||
|
|
||||||
|
& a {
|
||||||
|
text-decoration: none;
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 105%;
|
||||||
|
}
|
||||||
|
|
||||||
|
& li {
|
||||||
|
margin: 0;
|
||||||
|
display: inline-block;
|
||||||
|
width: 16.666667%;
|
||||||
|
text-align: center;
|
||||||
|
|
||||||
|
font-size: 140%;
|
||||||
|
font-weight: 400;
|
||||||
|
|
||||||
|
&>a:hover, &>a:active {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active>a {
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& ul.submenu {
|
||||||
|
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
margin-top: 10px; /* mezera mezi hlavním menu a submenu */
|
||||||
|
margin-bottom: 10px;
|
||||||
|
padding-top: 10px;
|
||||||
|
padding-bottom: 5px;
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
|
||||||
|
z-index: 50;
|
||||||
|
font-weight: 400;
|
||||||
|
|
||||||
|
& li {
|
||||||
|
width: auto;
|
||||||
|
padding: 0 20px 0 20px;
|
||||||
|
display: inline-block;
|
||||||
|
|
||||||
|
&>a {
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
text-decoration: none;
|
||||||
|
text-shadow: none;
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& ul.submenu li.active>a, & .parentactive ul li:first-child>a {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 970px) {
|
||||||
|
ul.menu {
|
||||||
|
font-size: 90%;
|
||||||
|
margin-top: -7px;
|
||||||
|
|
||||||
|
& li {
|
||||||
|
margin-top: 10px; /* posunutí textu hlavního menu níže */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.submenu {
|
||||||
|
margin-top: 8px; /* mezera mezi hlavním menu a submenu */
|
||||||
|
|
||||||
|
& li {
|
||||||
|
margin-top: 0; /* aby se spolu s textem hlavního menu neposunoval níže i text submenu */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px) {
|
||||||
|
ul.menu {
|
||||||
|
font-size: 80%;
|
||||||
|
margin-top: -2px;
|
||||||
|
|
||||||
|
& li {
|
||||||
|
margin-top: 10px; /* posunutí textu hlavního menu níže */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.submenu {
|
||||||
|
margin-top: 8px; /* mezera mezi hlavním menu a submenu */
|
||||||
|
|
||||||
|
& li {
|
||||||
|
margin-top: 0; /* aby se spolu s textem hlavního menu neposunoval níže i text submenu */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
ul.menu {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu_mobile {
|
||||||
|
display: block;
|
||||||
|
z-index: 10;
|
||||||
|
position: sticky;
|
||||||
|
font-variant: small-caps;
|
||||||
|
font-size: 150%;
|
||||||
|
font-weight: bold;
|
||||||
|
list-style-type: none;
|
||||||
|
padding-top: 3px;
|
||||||
|
padding-bottom: 3px;
|
||||||
|
padding-left: 12px;
|
||||||
|
|
||||||
|
& a {
|
||||||
|
&:active, &:hover, &:focus {
|
||||||
|
text-decoration: none;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& ul {
|
||||||
|
list-style-type: none;
|
||||||
|
font-size: 90%;
|
||||||
|
color: black; /*černé šipky submenu*/
|
||||||
|
|
||||||
|
& li {
|
||||||
|
&>a {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
&::before {
|
||||||
|
content: ' \276D '; /*https://www.w3schools.com/cssref/css_entities.asp*/
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& br {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
nav.nav-button {
|
||||||
|
display: block;
|
||||||
|
position: sticky;
|
||||||
|
position: -webkit-sticky;
|
||||||
|
top: 0;
|
||||||
|
z-index: 10;
|
||||||
|
}
|
||||||
|
|
||||||
|
#navbar-content {
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
button.navbar-button {
|
||||||
|
color: #f9d59e;
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
font-variant: small-caps;
|
||||||
|
font-size: 160%;
|
||||||
|
border-radius: 0;
|
||||||
|
border-width: 0;
|
||||||
|
width: 100%;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
button.navbar-button span::after {
|
||||||
|
content: ' \2261 ';
|
||||||
|
font-size: 120%;
|
||||||
|
}
|
||||||
|
|
||||||
|
li.dropdown div.submenu_mobile {
|
||||||
|
display: none;
|
||||||
|
--bs-dropdown-bg: var(--hlavni-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
li.dropdown div.submenu_mobile.show {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
} /* konec @media */
|
||||||
|
/**************/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**** ROZLIŠENÍ MEZI LOKÁLNÍM, TESTOVACÍM A PRODUKČNÍM WEBEM ****/
|
||||||
|
body.localweb, body.testweb, body.suprodweb {
|
||||||
|
&:before, &:after {
|
||||||
|
content: "";
|
||||||
|
position: fixed;
|
||||||
|
width: 20px;
|
||||||
|
height: 100%;
|
||||||
|
top: 0;
|
||||||
|
z-index: -1000;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before { left: 0; }
|
||||||
|
&:after { right: 0; }
|
||||||
|
}
|
||||||
|
|
||||||
|
body.localweb { &:before, &:after { background: greenyellow; } }
|
||||||
|
body.testweb { &:before, &:after { background: darkorange; } }
|
||||||
|
body.suprodweb { &:before, &:after { background: red; } }
|
||||||
|
/****************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** ZBYTEK ****/
|
||||||
|
/* (konkrétní stránky) */
|
||||||
|
|
||||||
|
/* Titulní stránka */
|
||||||
|
.titulnistrana {
|
||||||
|
display: flex;
|
||||||
|
text-align: justify;
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
& h1 { text-align: center; }
|
||||||
|
|
||||||
|
& .TITULNI_STRANA_zjistit_vic{
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
|
||||||
|
& hr {
|
||||||
|
display: none;
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& .TITULNI_STRANA_graf {
|
||||||
|
@media(max-width: 800px) {
|
||||||
|
padding-top: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
& .TITULNI_STRANA_graf-svg {
|
||||||
|
display: flex;
|
||||||
|
|
||||||
|
& #svg-graf {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
margin: 30px;
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
max-width: 500px;
|
||||||
|
padding: 10px;
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& .TITULNI_STRANA_obsah {
|
||||||
|
width: 66%;
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& .TITULNI_STRANA_vitej_titulka, & .TITULNI_STRANA_temata_titulka {
|
||||||
|
width: 49%;
|
||||||
|
padding: 10px;
|
||||||
|
display: table-cell;
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
width: 100%;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
& .TITULNI_STRANA_novinky {
|
||||||
|
width: 33%;
|
||||||
|
padding: 10px;
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
width: 100%;
|
||||||
|
max-width: 500px;
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
div.org-text {
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.odpocet {
|
||||||
|
margin: 20px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Stránky Aktuální ročník */
|
||||||
|
.stranka_aktualni_zadani {
|
||||||
|
text-align: center;
|
||||||
|
|
||||||
|
& #AKTUALNI_ZADADNI_obrazek {
|
||||||
|
margin-top: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
& div.AKTUALNI_ZADANI_termin {
|
||||||
|
text-align: center;
|
||||||
|
font-size: large;
|
||||||
|
font-weight: bold;
|
||||||
|
|
||||||
|
@media (max-width: 420px) {
|
||||||
|
font-size: small;
|
||||||
|
}
|
||||||
|
|
||||||
|
& .AKTUALNI_ZADANI_datum {
|
||||||
|
color: var(--hlavni-oranzova);
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#obrazek_cisla_archiv {
|
||||||
|
text-align: center;
|
||||||
|
margin: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Stránka Jak řešit */
|
||||||
|
.jakresit svg {
|
||||||
|
width: 33%;
|
||||||
|
padding: 10px;
|
||||||
|
filter: none;
|
||||||
|
|
||||||
|
@media(max-width: 860px) {
|
||||||
|
margin: auto;
|
||||||
|
display: grid;
|
||||||
|
width: 100%;
|
||||||
|
max-width: 360px;
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,38 +0,0 @@
|
||||||
/*
|
|
||||||
.pink {
|
|
||||||
background-color: #ffc0cb;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.borderized {
|
|
||||||
border-style: solid;
|
|
||||||
border-radius: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
padding-right: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.tnmenu {
|
|
||||||
float: right;
|
|
||||||
margin-right: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
div.parent {
|
|
||||||
border-width: 2px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.children {
|
|
||||||
border-width: 1px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.node_type {
|
|
||||||
background-color: #d4d4d4;
|
|
||||||
}
|
|
||||||
|
|
||||||
.hidden-tn {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*test*/
|
|
||||||
h1 {
|
|
||||||
color: chartreuse;
|
|
||||||
}
|
|
731
mamweb/static/css/mamweb_legacy.css
Normal file
|
@ -0,0 +1,731 @@
|
||||||
|
@charset "utf-8"; /* vynuť utf-8 */
|
||||||
|
|
||||||
|
@supports (-webkit-touch-callout: none) and (not (offset-position: normal)) {
|
||||||
|
|
||||||
|
.button {
|
||||||
|
margin: 10px 0 10px 0;
|
||||||
|
padding: 4px 0; /*vertikální centování textu*/
|
||||||
|
text-align: center;
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
font-size: 150%;
|
||||||
|
font-weight: bold;
|
||||||
|
font-variant: small-caps;
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
}
|
||||||
|
.button:hover {
|
||||||
|
position: relative;
|
||||||
|
top: 2px;
|
||||||
|
left: 2px;
|
||||||
|
background-color: #df490e;
|
||||||
|
}
|
||||||
|
/******************/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* Rozložení webu a jeho prvky (hlavička, menu, footer) */
|
||||||
|
|
||||||
|
/**** KONTEJNER ****/
|
||||||
|
div.kontejner { /* Ne container, aby se to netlouklo s bootstrapem. */
|
||||||
|
width: 970px;
|
||||||
|
margin: auto;
|
||||||
|
min-height: 100vh;
|
||||||
|
position: relative;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.org-logged-in div.kontejner {
|
||||||
|
margin-top: var(--login-bar-height);
|
||||||
|
}
|
||||||
|
|
||||||
|
div.kontejner div.kontent-wrapper {
|
||||||
|
padding-bottom: var(--footer-height);
|
||||||
|
}
|
||||||
|
|
||||||
|
div.kontejner div.kontent-wrapper div.kontent {
|
||||||
|
padding: 15px 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Roztáhne obsah z containeru na celou šířku obrazovky: */
|
||||||
|
.full_width {
|
||||||
|
width: 100vw;
|
||||||
|
margin-left: calc(-50vw + 485px);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Na úzkém displeji nechceme nic dělat. */
|
||||||
|
@media(max-width: 860px) {
|
||||||
|
.full_width {
|
||||||
|
margin-left: 0;
|
||||||
|
width: unset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*******************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** HLAVIČKA ****/
|
||||||
|
#header {
|
||||||
|
position: relative;
|
||||||
|
background: url("../images/header/vikendovka.jpg") no-repeat center top; /* poměr 350:970, TODO: aby to nemuselo být přesně na pixely */
|
||||||
|
background-size: 100%;
|
||||||
|
top: 58px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header img.logo {
|
||||||
|
width: 100%;
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
}
|
||||||
|
|
||||||
|
#header img.logo-mobile {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header .no-mobile {
|
||||||
|
background-size: contain;
|
||||||
|
}
|
||||||
|
/******************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** Footer ****/
|
||||||
|
#footer {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
width: 100%;
|
||||||
|
background: url("../images/mozaika-footer.svg") no-repeat top center;
|
||||||
|
height: var(--footer-height);
|
||||||
|
background-size: 100%;
|
||||||
|
filter: drop-shadow(5px 0px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
padding-top: 3.5%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#footer p.license {
|
||||||
|
text-align: center;
|
||||||
|
font-weight: 400;
|
||||||
|
bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
#footer p.license a {
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
#footer {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
p.license-mobile {
|
||||||
|
display: none;
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
p.license-mobile {
|
||||||
|
position: relative;
|
||||||
|
display: block;
|
||||||
|
font-size: 90%;
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
padding: 5%;
|
||||||
|
text-align: justify;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/****************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** LOGIN BAR ****/
|
||||||
|
div.login-bar {
|
||||||
|
background: var(--orgovska-fialova);
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
position: fixed;
|
||||||
|
margin-top: calc(-1 * var(--login-bar-height));
|
||||||
|
min-height: var(--login-bar-height);
|
||||||
|
z-index: 4086;
|
||||||
|
|
||||||
|
padding-left: 5px;
|
||||||
|
padding-right: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.login-bar div {
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.login-bar a.LOGIN-ref-admin {
|
||||||
|
display: inline;
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
}
|
||||||
|
|
||||||
|
div.login-bar .LOGIN_napis-webarum {
|
||||||
|
display: inline;
|
||||||
|
color: var(--barva-pozadi);
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.login-bar .LOGIN_napis-webarum a {
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
text-decoration: underline;
|
||||||
|
}
|
||||||
|
/*******************/
|
||||||
|
|
||||||
|
|
||||||
|
/* stránka přes celý displej */
|
||||||
|
@media (max-width: 970px) {
|
||||||
|
#header {
|
||||||
|
background-size: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header img.logo {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* malý tablet, mobil */
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
#header {
|
||||||
|
width: 100%;
|
||||||
|
top: 0;
|
||||||
|
background-image: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header img.logo {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header img.logo-mobile {
|
||||||
|
display: block;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
filter: drop-shadow(0px 0 5px rgba(0, 0, 0, 0.4));
|
||||||
|
margin-bottom: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header .no-mobile{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**** MENU ****/
|
||||||
|
|
||||||
|
ul.menu {
|
||||||
|
width: 100%;
|
||||||
|
padding: 0;
|
||||||
|
margin-top: -5px; /* posune celé menu nahoru (pak potřeba zvětšit mezeru mezi menu a submenu) */
|
||||||
|
|
||||||
|
font-variant: small-caps;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu a {
|
||||||
|
text-decoration: none;
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 105%;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu li {
|
||||||
|
margin: 0;
|
||||||
|
display: inline-block;
|
||||||
|
width: 16.666667%;
|
||||||
|
text-align: center;
|
||||||
|
|
||||||
|
font-size: 140%;
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu li >a:hover, >a:active {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu li.active>a {
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu ul.submenu {
|
||||||
|
background-color: var(--hlavni-oranzova);
|
||||||
|
margin-top: 10px; /* mezera mezi hlavním menu a submenu */
|
||||||
|
margin-bottom: 10px;
|
||||||
|
padding-top: 10px;
|
||||||
|
padding-bottom: 5px;
|
||||||
|
filter: drop-shadow(0px 5px 5px rgba(0, 0, 0, 0.4));
|
||||||
|
|
||||||
|
z-index: 50;
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu ul.submenu li {
|
||||||
|
width: auto;
|
||||||
|
padding: 0 20px 0 20px;
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu ul.submenu li >a {
|
||||||
|
color: var(--svetla-oranzova);
|
||||||
|
text-decoration: none;
|
||||||
|
text-shadow: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu ul.submenu li >a :hover {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu ul.submenu li.active>a, .parentactive ul li:first-child>a {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 970px) {
|
||||||
|
ul.menu {
|
||||||
|
font-size: 90%;
|
||||||
|
margin-top: -7px;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu li {
|
||||||
|
margin-top: 10px; /* posunutí textu hlavního menu níže */
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.submenu {
|
||||||
|
margin-top: 8px; /* mezera mezi hlavním menu a submenu */
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.submenu li {
|
||||||
|
margin-top: 0; /* aby se spolu s textem hlavního menu neposunoval níže i text submenu */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px) {
|
||||||
|
ul.menu {
|
||||||
|
font-size: 80%;
|
||||||
|
margin-top: -2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu li {
|
||||||
|
margin-top: 10px; /* posunutí textu hlavního menu níže */
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.submenu {
|
||||||
|
margin-top: 8px; /* mezera mezi hlavním menu a submenu */
|
||||||
|
}
|
||||||
|
ul.submenu li {
|
||||||
|
margin-top: 0; /* aby se spolu s textem hlavního menu neposunoval níže i text submenu */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
ul.menu {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu_mobile {
|
||||||
|
display: block;
|
||||||
|
z-index: 10;
|
||||||
|
position: sticky;
|
||||||
|
font-variant: small-caps;
|
||||||
|
font-size: 150%;
|
||||||
|
font-weight: bold;
|
||||||
|
list-style-type: none;
|
||||||
|
padding-top: 3px;
|
||||||
|
padding-bottom: 3px;
|
||||||
|
padding-left: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu_mobile a:active, ul.menu_mobile a:hover, ul.menu_mobile a:focus {
|
||||||
|
text-decoration: none;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu_mobile ul {
|
||||||
|
list-style-type: none;
|
||||||
|
font-size: 90%;
|
||||||
|
color: black; /*černé šipky submenu*/
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu_mobile ul li > a {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu_mobile ul li::before {
|
||||||
|
content: ' \276D '; /*https://www.w3schools.com/cssref/css_entities.asp*/
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.menu_mobile br {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
} /* konec @media */
|
||||||
|
/**************/
|
||||||
|
|
||||||
|
/**** ZBYTEK ****/
|
||||||
|
/* (konkrétní stránky) */
|
||||||
|
|
||||||
|
/* Titulní stránka */
|
||||||
|
.titulnistrana {
|
||||||
|
display: flex;
|
||||||
|
text-align: justify;
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
.titulnistrana {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.titulnistrana h1 { text-align: center; }
|
||||||
|
|
||||||
|
.titulnistrana .TITULNI_STRANA_zjistit_vic {
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.titulnistrana .TITULNI_STRANA_zjistit_vic hr {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
.titulnistrana .TITULNI_STRANA_zjistit_vic hr {
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px) {
|
||||||
|
.titulnistrana .TITULNI_STRANA_graf {
|
||||||
|
padding-top: 40px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.titulnistrana .TITULNI_STRANA_graf .TITULNI_STRANA_graf-svg {
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
||||||
|
.titulnistrana .TITULNI_STRANA_graf .TITULNI_STRANA_graf-svg #svg-graf {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
margin: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
.titulnistrana .TITULNI_STRANA_graf .TITULNI_STRANA_graf-svg #svg-graf {
|
||||||
|
max-width: 500px;
|
||||||
|
padding: 10px;
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.titulnistrana .TITULNI_STRANA_obsah {
|
||||||
|
width: 66%;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
.titulnistrana .TITULNI_STRANA_obsah {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.titulnistrana .TITULNI_STRANA_vitej_titulka, .TITULNI_STRANA_temata_titulka {
|
||||||
|
width: 49%;
|
||||||
|
padding: 10px;
|
||||||
|
display: table-cell;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
.titulnistrana .TITULNI_STRANA_vitej_titulka, .TITULNI_STRANA_temata_titulka {
|
||||||
|
width: 100%;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.titulnistrana .TITULNI_STRANA_novinky {
|
||||||
|
width: 33%;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px){
|
||||||
|
.titulnistrana .TITULNI_STRANA_novinky {
|
||||||
|
width: 100%;
|
||||||
|
max-width: 500px;
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Stránky Aktuální ročník */
|
||||||
|
.stranka_aktualni_zadani {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stranka_aktualni_zadani #AKTUALNI_ZADADNI_obrazek {
|
||||||
|
margin-top: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stranka_aktualni_zadani div.AKTUALNI_ZADANI_termin {
|
||||||
|
text-align: center;
|
||||||
|
font-size: large;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 420px) {
|
||||||
|
.stranka_aktualni_zadani div.AKTUALNI_ZADANI_termin {
|
||||||
|
font-size: small;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.stranka_aktualni_zadani .AKTUALNI_ZADANI_datum {
|
||||||
|
color: var(--hlavni-oranzova);
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Stránka Jak řešit */
|
||||||
|
.jakresit svg {
|
||||||
|
width: 33%;
|
||||||
|
padding: 10px;
|
||||||
|
filter: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 860px) {
|
||||||
|
.jakresit svg {
|
||||||
|
margin: auto;
|
||||||
|
display: grid;
|
||||||
|
width: 100%;
|
||||||
|
max-width: 360px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**** OZNAČENÍ NE-PUBLIC ČÁSTÍ ****/
|
||||||
|
.mam-org-only {
|
||||||
|
background: var(--orgovska-svetla-fialova);
|
||||||
|
padding: 10px;
|
||||||
|
margin: 10px -10px;
|
||||||
|
border: var(--orgovska-fialova) 2px dashed;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mam-org-only .mam-org-only {
|
||||||
|
border: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mam-org-only li {
|
||||||
|
padding: 3px 0;
|
||||||
|
margin: -2px 0;
|
||||||
|
}
|
||||||
|
/**********************************/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**** OTÁČECÍ KARTY ****/
|
||||||
|
/* (orgové, archiv) */
|
||||||
|
.flip-card {
|
||||||
|
perspective: 1000px; /* Remove this if you don't want the 3D effect */
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* This container is needed to position the front and back side */
|
||||||
|
.flip-card .flip-card-inner {
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
transition: transform 0.8s;
|
||||||
|
transform-style: preserve-3d;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Do an horizontal flip when you move the mouse over the flip box container */
|
||||||
|
.flip-card:hover .flip-card-inner {
|
||||||
|
transform: rotateY(180deg);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Position the front and back side */
|
||||||
|
.flip-card .flip-card-front, .flip-card-back {
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
-webkit-backface-visibility: hidden; /* Safari */
|
||||||
|
backface-visibility: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
.flip-card div.flip-card-foto, div.flip-card-foto img {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
|
||||||
|
/* Pokud je na přední straně něco proklikávacího (třeba celá fotka), tak na dotykových zařízeních nemůže proklikávat, aby se dalo otáčet */
|
||||||
|
@media(hover: none) {
|
||||||
|
.flip-card div.flip-card-foto, div.flip-card-foto img a { pointer-events: none; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Style the back side */
|
||||||
|
.flip-card-back {
|
||||||
|
transform: rotateY(180deg);
|
||||||
|
padding: 10px;
|
||||||
|
padding-top: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/***********************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** TABULKY ****/
|
||||||
|
|
||||||
|
/** Tabulka s čárami mezi sloupci **/
|
||||||
|
/* Např. výsledkovky */
|
||||||
|
|
||||||
|
.tabulka_oramovane_sloupce {
|
||||||
|
border: solid 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tabulka_oramovane_sloupce td:first-child, .tabulka_oramovane_sloupce th:first-child {
|
||||||
|
border-left: none;
|
||||||
|
border-right: solid 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tabulka_oramovane_sloupce td:nth-child(2), .tabulka_oramovane_sloupce th:nth-child(2) {
|
||||||
|
border-left: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tabulka_oramovane_sloupce td, .tabulka_oramovane_sloupce th {
|
||||||
|
padding: 0.1em 0.3em;
|
||||||
|
border-left: solid 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tabulka_oramovane_sloupce thead th, .tabulka_oramovane_sloupce thead td {
|
||||||
|
border-bottom: solid 1px;
|
||||||
|
}
|
||||||
|
/***********************************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Tabulka se střídajícími se barvami řádků **/
|
||||||
|
/* Skoro jakákoliv tabulka kromě výsledkovek */
|
||||||
|
|
||||||
|
.barevna_tabulka td th {
|
||||||
|
padding: 1px 10px 1px 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.barevna_tabulka tbody tr:nth-child(even), thead tr {
|
||||||
|
background: var(--svetlounka-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
.barevna_tabulka tbody tr:nth-child(odd) {
|
||||||
|
background: var(--barva-pozadi);
|
||||||
|
}
|
||||||
|
/**********************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Tabulka, kde první řádek a sloupec je pořád vidět **/
|
||||||
|
/* Např. tabulka odevzdaných řešení, nebo výsledkovky */
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem {
|
||||||
|
/* Omezí výšku a šířku, aby bylo příjemné na scrollování a zapne scrollování */
|
||||||
|
display: block;
|
||||||
|
width: fit-content; /* display: block; roztahuje na celou šířku */
|
||||||
|
max-height: 80vh;
|
||||||
|
overflow: auto;
|
||||||
|
max-width: 90%; /* (FIXME asi není potřeba u tabulek, co nejsou na celou obrazovku) */
|
||||||
|
margin-left: 5%; /* Vystředování (FIXME není potřeba u tabulek, co nejsou na celou obrazovku) */
|
||||||
|
|
||||||
|
border-collapse: separate; /* Pokud má tabulka orámování, je potřeba ho separovat, aby dodrželo position: sticky; */
|
||||||
|
border-spacing: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Uchytí první řádek */
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem thead tr {
|
||||||
|
position: sticky;
|
||||||
|
top: 0;
|
||||||
|
z-index: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Uchytí první sloupec */
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem td:first-child, .tabulka_s_uchycenym_radkem_a_sloupcem th:first-child {
|
||||||
|
position: sticky;
|
||||||
|
left: 0;
|
||||||
|
background: inherit; /* (Snad) zneprůhlední první sloupec */
|
||||||
|
z-index: 1;
|
||||||
|
}
|
||||||
|
/*******************************************************/
|
||||||
|
|
||||||
|
/** Tabulka mající všechna ohraničení **/
|
||||||
|
.plne_ohranicena_tabulka {
|
||||||
|
border-collapse: collapse;
|
||||||
|
}
|
||||||
|
|
||||||
|
.plne_ohranicena_tabulka tr th, .plne_ohranicena_tabulka tr td {
|
||||||
|
border: 1px solid black;
|
||||||
|
padding: 1px 10px 1px 10px;
|
||||||
|
}
|
||||||
|
/***************************************/
|
||||||
|
|
||||||
|
/** Výsledkovky **/
|
||||||
|
.vysledkovka, .tabulka_oramovane_sloupce td:first-child, .vysledkovka, .tabulka_oramovane_sloupce th:first-child { position: unset; }
|
||||||
|
.vysledkovka, .tabulka_oramovane_sloupce td:nth-child(2), .vysledkovka, .tabulka_oramovane_sloupce th:nth-child(2) {
|
||||||
|
border-right: solid 1px;
|
||||||
|
|
||||||
|
position: sticky;
|
||||||
|
left: 0;
|
||||||
|
background: inherit; /* (Snad) zneprůhlední druhý sloupec */
|
||||||
|
z-index: 1;
|
||||||
|
}
|
||||||
|
.vysledkovka, .tabulka_oramovane_sloupce td:nth-child(3), .vysledkovka, .tabulka_oramovane_sloupce th:nth-child(3) {
|
||||||
|
border-left: none;
|
||||||
|
}
|
||||||
|
/*****************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Tabulka mých (řešitelových) řešení **/
|
||||||
|
.moje_reseni tr th, .moje_reseni tr td {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.moje_reseni tr td.problem { text-align: left; }
|
||||||
|
/****************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Detail řešení **/
|
||||||
|
.bodovani>input {
|
||||||
|
width: 4em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.bodovani>input::placeholder {
|
||||||
|
color: lightgray;
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.bodovani>input::-webkit-input-placeholder { /* Edge */
|
||||||
|
color: lightgray;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*******************/
|
||||||
|
/*****************/
|
||||||
|
|
||||||
|
|
||||||
|
.novinka .novinka_obrazek {
|
||||||
|
margin: 10px 0 10px 0;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.novinka .novinka_datum {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.novinka .novinka_autor {
|
||||||
|
text-align: right;
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**** FORMULÁŘE ****/
|
||||||
|
div.gdpr {
|
||||||
|
font-size: 6pt;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.gdpr p {
|
||||||
|
font-size: 6pt;
|
||||||
|
margin-bottom: .66em;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*******************/
|
||||||
|
|
||||||
|
|
||||||
|
}
|
507
mamweb/static/css/modules.css
Normal file
|
@ -0,0 +1,507 @@
|
||||||
|
@charset "utf-8"; /* vynuť utf-8 */
|
||||||
|
|
||||||
|
/* Bloky použité na webu */
|
||||||
|
|
||||||
|
|
||||||
|
.horizonatlni_scrollovani { overflow-x: auto; }
|
||||||
|
|
||||||
|
/* Používá se pro podproblémy ve výsledkovkách -- zesvětlí se daný sloupec */
|
||||||
|
.zesvetleni { color: gray; }
|
||||||
|
|
||||||
|
|
||||||
|
/**** OZNAČENÍ NE-PUBLIC ČÁSTÍ ****/
|
||||||
|
.mam-org-only {
|
||||||
|
background: var(--orgovska-svetla-fialova);
|
||||||
|
padding: 10px;
|
||||||
|
margin: 10px -10px;
|
||||||
|
border: var(--orgovska-fialova) 2px dashed;
|
||||||
|
|
||||||
|
& .mam-org-only {
|
||||||
|
/* Vnitřní rámečky mají být taky vidět */
|
||||||
|
border-width: 1px;
|
||||||
|
background-color: rgba(0, 0, 0, 0.06);
|
||||||
|
}
|
||||||
|
|
||||||
|
& li {
|
||||||
|
padding: 3px 0;
|
||||||
|
margin: -2px 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.mam-resitel-only {
|
||||||
|
background: var(--resitelska-svetla-fialova);
|
||||||
|
padding: 10px;
|
||||||
|
margin: 10px -10px;
|
||||||
|
border: var(--resitelska-fialova) 2px dashed;
|
||||||
|
|
||||||
|
& .mam-resitel-only {
|
||||||
|
/* Vnitřní rámečky mají být taky vidět */
|
||||||
|
border-width: 1px;
|
||||||
|
background-color: rgba(0, 0, 0, 0.06);
|
||||||
|
}
|
||||||
|
|
||||||
|
& li {
|
||||||
|
padding: 3px 0;
|
||||||
|
margin: -2px 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/**********************************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** ZAŠKRTÁVÁTKO ****/
|
||||||
|
/* Select2 používaný hlavně multiple selectem. Přidání checkboxů a změna barvy. */
|
||||||
|
/* Podle https://stackoverflow.com/a/48290544 */
|
||||||
|
/* U autocomplete.ModelSelect2Multiple vyžaduje 'data-dropdown-css-class': 's2m-se-zaskrtavatky' */
|
||||||
|
.s2m-se-zaskrtavatky .select2-results__option[aria-selected=true]:before {
|
||||||
|
content: '☑ ';
|
||||||
|
padding: 0 0 0 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.s2m-se-zaskrtavatky .select2-results__option[aria-selected=false]:before {
|
||||||
|
content: '◻ ';
|
||||||
|
padding: 0 0 0 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Oranžové zvýraznění v Select2 */
|
||||||
|
.select2-results__option--highlighted {
|
||||||
|
background-color: var(--hlavni-oranzova) !important;
|
||||||
|
}
|
||||||
|
/**********************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** OTÁČECÍ KARTY ****/
|
||||||
|
/* (orgové, archiv) */
|
||||||
|
.flip-card {
|
||||||
|
perspective: 1000px; /* Remove this if you don't want the 3D effect */
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
|
||||||
|
/* This container is needed to position the front and back side */
|
||||||
|
& .flip-card-inner {
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
transition: transform 0.8s;
|
||||||
|
transform-style: preserve-3d;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Do an horizontal flip when you move the mouse over the flip box container */
|
||||||
|
&:hover .flip-card-inner {
|
||||||
|
transform: rotateY(180deg);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Position the front and back side */
|
||||||
|
& .flip-card-front, & .flip-card-back {
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
-webkit-backface-visibility: hidden; /* Safari */
|
||||||
|
backface-visibility: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
& div.flip-card-foto, & div.flip-card-foto img {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
|
||||||
|
/* Pokud je na přední straně něco proklikávacího (třeba celá fotka), tak na dotykových zařízeních nemůže proklikávat, aby se dalo otáčet */
|
||||||
|
@media(hover: none) {
|
||||||
|
& a { pointer-events: none; }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Style the back side */
|
||||||
|
& .flip-card-back {
|
||||||
|
transform: rotateY(180deg);
|
||||||
|
padding: 10px;
|
||||||
|
padding-top: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.flip-card-back {
|
||||||
|
background-color: var(--svetla-oranzova);
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
.otaceci_cisla .flip-card-back {
|
||||||
|
background-color: white;
|
||||||
|
color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Otáčecí karta musí mít kolem sebe nějaké místo a mívá nějaký nadpis */
|
||||||
|
.flip_card_container {
|
||||||
|
display: inline-block;
|
||||||
|
width: 30%;
|
||||||
|
min-width: 300px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/** Jednotlivá použití **/
|
||||||
|
.seznam_orgu, .seznam_archiv, .rozcestnik_temat {
|
||||||
|
text-align: center; /* zarovná karty na střed */
|
||||||
|
}
|
||||||
|
|
||||||
|
.seznam_orgu .flip-card {
|
||||||
|
width: 200px;
|
||||||
|
height: 250px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.seznam_orgu .flip_card_container h3 {
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.seznam_archiv .flip-card {
|
||||||
|
width: 210px;
|
||||||
|
height: 298px;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.cisla-v-rocniku .flip-card {
|
||||||
|
width: 144px;
|
||||||
|
height: 205px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cisla-v-rocniku .flip_card_container {
|
||||||
|
width: 15%;
|
||||||
|
min-width: 165px;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.rozcestnik_temat .flip-card {
|
||||||
|
width: 300px;
|
||||||
|
height: 300px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.rozcestnik_temat .flip_card_container {
|
||||||
|
width: 40%;
|
||||||
|
min-width: 350px;
|
||||||
|
padding-bottom: 20px;
|
||||||
|
}
|
||||||
|
/************************/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* karty archiv */
|
||||||
|
|
||||||
|
div.popis_rocniku {
|
||||||
|
text-align: left;
|
||||||
|
font-weight: bold;
|
||||||
|
margin: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
div.popis_rocniku a, div.cislo_odkazy a {
|
||||||
|
font-weight: bold;
|
||||||
|
color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.popis_rocniku a:hover,
|
||||||
|
div.cislo_odkazy a:hover {
|
||||||
|
color: var(--tmava-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
div.cislo_odkazy ul {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* karty orgů */
|
||||||
|
div.org_email {
|
||||||
|
margin-bottom: 10px;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
/***********************/
|
||||||
|
|
||||||
|
|
||||||
|
/**** TABULKY ****/
|
||||||
|
|
||||||
|
/** Tabulka s čárami mezi sloupci **/
|
||||||
|
/* Např. výsledkovky */
|
||||||
|
|
||||||
|
.tabulka_oramovane_sloupce {
|
||||||
|
border: solid 2px;
|
||||||
|
|
||||||
|
& td, & th {
|
||||||
|
&:first-child, &:first-child {
|
||||||
|
border-left: none;
|
||||||
|
border-right: solid 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:nth-child(2), &:nth-child(2) {
|
||||||
|
border-left: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
padding: 0.1em 0.3em;
|
||||||
|
border-left: solid 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
& thead { & th, & td {
|
||||||
|
border-bottom: solid 1px;
|
||||||
|
} }
|
||||||
|
}
|
||||||
|
/***********************************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Tabulka se střídajícími se barvami řádků **/
|
||||||
|
/* Skoro jakákoliv tabulka kromě výsledkovek */
|
||||||
|
|
||||||
|
.barevna_tabulka {
|
||||||
|
& td th {
|
||||||
|
padding: 1px 10px 1px 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
& tbody tr:nth-child(even), & thead tr {
|
||||||
|
background: var(--svetlounka-oranzova);
|
||||||
|
}
|
||||||
|
|
||||||
|
& tbody tr:nth-child(odd) {
|
||||||
|
background: var(--barva-pozadi);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/**********************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Tabulka, kde první řádek a sloupec je pořád vidět **/
|
||||||
|
/* Např. tabulka odevzdaných řešení, nebo výsledkovky */
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem {
|
||||||
|
/* Omezí výšku a šířku, aby bylo příjemné na scrollování a zapne scrollování */
|
||||||
|
display: block;
|
||||||
|
width: fit-content; /* display: block; roztahuje na celou šířku */
|
||||||
|
max-height: 80vh;
|
||||||
|
overflow: auto;
|
||||||
|
max-width: 90%; /* (FIXME asi není potřeba u tabulek, co nejsou na celou obrazovku) */
|
||||||
|
margin-left: 5%; /* Vystředování (FIXME není potřeba u tabulek, co nejsou na celou obrazovku) */
|
||||||
|
|
||||||
|
border-collapse: separate; /* Pokud má tabulka orámování, je potřeba ho separovat, aby dodrželo position: sticky; */
|
||||||
|
border-spacing: 0;
|
||||||
|
|
||||||
|
/* Uchytí první řádek */
|
||||||
|
& thead tr {
|
||||||
|
position: sticky;
|
||||||
|
top: 0;
|
||||||
|
z-index: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Uchytí první sloupec */
|
||||||
|
& td, & th { &:first-child {
|
||||||
|
position: sticky;
|
||||||
|
left: 0;
|
||||||
|
background: inherit; /* (Snad) zneprůhlední první sloupec */
|
||||||
|
z-index: 1;
|
||||||
|
} }
|
||||||
|
}
|
||||||
|
|
||||||
|
/* (Snad) zneprůhlednění prvního řádku (a sloupce) FIXME: tohle je trochu hack a potenciálně může něco rozbít */
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem,
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem thead,
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem tbody,
|
||||||
|
.tabulka_s_uchycenym_radkem_a_sloupcem tr,
|
||||||
|
.kontejner,
|
||||||
|
.kontent-wrapper,
|
||||||
|
.kontent
|
||||||
|
{
|
||||||
|
background: inherit;
|
||||||
|
}
|
||||||
|
/*******************************************************/
|
||||||
|
|
||||||
|
/** Tabulka mající všechna ohraničení **/
|
||||||
|
.plne_ohranicena_tabulka {
|
||||||
|
border-collapse: collapse;
|
||||||
|
|
||||||
|
& tr { & th, & td {
|
||||||
|
border: 1px solid black;
|
||||||
|
padding: 1px 10px 1px 10px;
|
||||||
|
} }
|
||||||
|
}
|
||||||
|
/***************************************/
|
||||||
|
|
||||||
|
/** Tabulka odevzdaných a došlých řešení **/
|
||||||
|
.tabulka_doslych_reseni td {
|
||||||
|
min-width: 8em; /* Nastřeleno, aby se řádky s řešeními nezalamovaly. */
|
||||||
|
}
|
||||||
|
/******************************************/
|
||||||
|
|
||||||
|
/** Výsledkovky **/
|
||||||
|
.vysledkovka, .tabulka_oramovane_sloupce {
|
||||||
|
& td, & th {
|
||||||
|
&:first-child { position: unset; }
|
||||||
|
|
||||||
|
&:nth-child(2) {
|
||||||
|
border-right: solid 1px;
|
||||||
|
|
||||||
|
position: sticky;
|
||||||
|
left: 0;
|
||||||
|
background: inherit; /* (Snad) zneprůhlední druhý sloupec */
|
||||||
|
z-index: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:nth-child(3) {
|
||||||
|
border-left: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*****************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Tabulka mých (řešitelových) řešení **/
|
||||||
|
.moje_reseni tr {
|
||||||
|
& th, & td {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
& td.problem { text-align: left; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Různá šířka problému */
|
||||||
|
.odevzdanareseni_mid, .odevzdanareseni_small, .odevzdanareseni_mini { display: none; }
|
||||||
|
|
||||||
|
@media (max-width: 970px) {
|
||||||
|
.odevzdanareseni_big { display: none; }
|
||||||
|
.odevzdanareseni_mid { display: table-cell; }
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px) {
|
||||||
|
.odevzdanareseni_mid { display: none; }
|
||||||
|
.odevzdanareseni_small { display: table-cell; }
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
.odevzdanareseni_small { display: none; }
|
||||||
|
.odevzdanareseni_mini { display: table-cell; }
|
||||||
|
}
|
||||||
|
/****************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/** Detail řešení **/
|
||||||
|
.bodovani>input {
|
||||||
|
width: 4em;
|
||||||
|
|
||||||
|
&::placeholder {
|
||||||
|
color: lightgray;
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
&::-webkit-input-placeholder { /* Edge */
|
||||||
|
color: lightgray;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* td obsahující křížek v detailu řešení se nesmí smrštit na 0 */
|
||||||
|
td:has(.smazat_hodnoceni) {
|
||||||
|
min-width: 20px;
|
||||||
|
padding: 3px;
|
||||||
|
}
|
||||||
|
/*******************/
|
||||||
|
/*****************/
|
||||||
|
|
||||||
|
|
||||||
|
.novinka {
|
||||||
|
& .novinka_obrazek {
|
||||||
|
margin: 10px 0 10px 0;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
& .novinka_datum {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
& .novinka_autor {
|
||||||
|
text-align: right;
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**** FORMULÁŘE ****/
|
||||||
|
/* přihláška a další formuláře */
|
||||||
|
|
||||||
|
table.form td, table.form tr {
|
||||||
|
table-layout: fixed;
|
||||||
|
word-wrap: break-word;
|
||||||
|
padding: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
table#reseni.form td, table#reseni.form tr {
|
||||||
|
display: inline-table;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 650px) {
|
||||||
|
table.form td, table.form tr {
|
||||||
|
display: inherit;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width: 800px) {
|
||||||
|
table#reseni.form td, table#reseni.form tr {
|
||||||
|
display: inline-grid;
|
||||||
|
max-width: 300px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-with-comment{
|
||||||
|
position:relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-comment{
|
||||||
|
display:none;
|
||||||
|
text-shadow: 0 1px 0 #fff;
|
||||||
|
background-color: #f0f0f0 ;
|
||||||
|
position:absolute;
|
||||||
|
z-index:100;
|
||||||
|
border-width:1px;
|
||||||
|
border-color: #dbdbdb;
|
||||||
|
border-style:solid;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding:3px;
|
||||||
|
top:50px;
|
||||||
|
left:10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-with-comment:hover span.field-comment{
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
input {
|
||||||
|
margin: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
textarea.feedback {
|
||||||
|
margin: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
ul.form {
|
||||||
|
list-style-type: none;
|
||||||
|
padding-left: 0;
|
||||||
|
}
|
||||||
|
label.field-label {
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
|
label.field-required {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
.field-error {
|
||||||
|
font-size: 14px;
|
||||||
|
color: red;
|
||||||
|
}
|
||||||
|
ul.form li{
|
||||||
|
margin-bottom: 3px;
|
||||||
|
}
|
||||||
|
div.gdpr {
|
||||||
|
font-size: 6pt;
|
||||||
|
|
||||||
|
& p {
|
||||||
|
font-size: 6pt;
|
||||||
|
margin-bottom: .66em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* registrace */
|
||||||
|
label[for=id_skola] {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*******************/
|
||||||
|
|