Přidání účastnického poplatku v nastavení
This commit is contained in:
parent
a8160214cb
commit
2c9c1dc8e1
2 changed files with 22 additions and 0 deletions
18
seminar/migrations/0108_nastaveni_cena_sous.py
Normal file
18
seminar/migrations/0108_nastaveni_cena_sous.py
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
# Generated by Django 3.2.16 on 2022-11-14 20:51
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('seminar', '0107_zmrazenavysledkovka'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='nastaveni',
|
||||||
|
name='cena_sous',
|
||||||
|
field=models.IntegerField(default=1000, verbose_name='Účastnický poplatek za soustředění'),
|
||||||
|
),
|
||||||
|
]
|
|
@ -718,6 +718,10 @@ class Nastaveni(SingletonModel):
|
||||||
aktualni_cislo = models.ForeignKey(Cislo, verbose_name='Aktuální číslo',
|
aktualni_cislo = models.ForeignKey(Cislo, verbose_name='Aktuální číslo',
|
||||||
null=False, on_delete=models.PROTECT)
|
null=False, on_delete=models.PROTECT)
|
||||||
|
|
||||||
|
cena_sous = models.IntegerField(null=False,
|
||||||
|
verbose_name="Účastnický poplatek za soustředění",
|
||||||
|
default=1000)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def aktualni_rocnik(self):
|
def aktualni_rocnik(self):
|
||||||
return self.aktualni_cislo.rocnik
|
return self.aktualni_cislo.rocnik
|
||||||
|
|
Loading…
Reference in a new issue