Browse Source

Merge branch 'develop' into test

okenkove_obalky
Jonas Havelka 2 years ago
parent
commit
6346f0ec4a
  1. 1
      Makefile
  2. 3
      README.md
  3. 2
      korektury/admin.py
  4. 6
      personalni/templates/personalni/profil/orgorozcestnik.html

1
Makefile

@ -34,6 +34,7 @@ install_web: venv_check
pip install --upgrade setuptools
# Instalace závislostí webu
pip install -r requirements.txt --upgrade
# Pro vygenerování tesdat spusť ./manage.py testdata
# Po vygenerování testdat spusť ./manage.py loaddata data/*, ať máš menu a další modely
# Pro synchronizaci flatpages spusť make sync_prod_flatpages

3
README.md

@ -18,6 +18,9 @@ Run the following commands:
. env/bin/activate
make install_web
Pokud install_web říká Error: pg_config executable not found. nainstaluj si libpq-dev
Pokud chybová hláška obsahuje #include <Python.h>, nainstaluj si python3-dev
After finishing development, run "deactivate".
Make commands

2
korektury/admin.py

@ -28,7 +28,7 @@ class KorekturovanePDFAdmin(VersionAdmin):
readonly_fields = ['cas', 'stran']
def get_readonly_fields(self, request, obj=None):
""" Nevím, proč to tu je - Jidáš """
""" Když pdf existuje, tak nedovolím měnit ani pdf."""
if obj:
return self.readonly_fields + ['pdf']
return self.readonly_fields

6
personalni/templates/personalni/profil/orgorozcestnik.html

@ -48,21 +48,21 @@
<h3> Témata </h3>
<ul>
{% for t in temata %}
<li> {{ t }} </li>
<li><a href="{{ t.admin_url }}">{{ t }}</a></li>
{% endfor %}
</ul>
<h3> Úlohy </h3>
<ul>
{% for u in ulohy %}
<li> {{ u }} </li>
<li><a href="{{ u.admin_url }}">{{ u }}</a></li>
{% endfor %}
</ul>
<h3> Články </h3>
<ul>
{% for c in clanky %}
<li> {{ c }} </li>
<li><a href="{{ c.admin_url }}">{{ c }}</a></li>
{% endfor %}
</ul>

Loading…
Cancel
Save