Tomas "Jethro" Pokorny
8 years ago
4 changed files with 125 additions and 11 deletions
@ -1,7 +1,16 @@ |
|||
from django.contrib import admin |
|||
from reversion.admin import VersionAdmin |
|||
|
|||
from models import Prednaska, Seznam, Hlasovani |
|||
from models import Prednaska, Hlasovani |
|||
|
|||
admin.site.register(Seznam) |
|||
admin.site.register(Prednaska) |
|||
admin.site.register(Hlasovani) |
|||
|
|||
class PrednaskaAdmin(VersionAdmin): |
|||
# fieldsets = [ |
|||
# (None, {'fields': ['pdf', 'cas', 'stran', 'nazev', 'komentar']}), |
|||
# ] |
|||
list_display = ['nazev', 'org', 'obor'] |
|||
list_filter = ['org','obor'] |
|||
search_fields = [] |
|||
|
|||
admin.site.register(Prednaska,PrednaskaAdmin) |
|||
|
@ -0,0 +1,64 @@ |
|||
# -*- coding: utf-8 -*- |
|||
from __future__ import unicode_literals |
|||
|
|||
from django.db import migrations, models |
|||
|
|||
|
|||
class Migration(migrations.Migration): |
|||
|
|||
dependencies = [ |
|||
('prednasky', '0002_auto_20160417_2347'), |
|||
] |
|||
|
|||
operations = [ |
|||
migrations.RenameModel( |
|||
old_name='Seznam', |
|||
new_name='Seznam_old', |
|||
), |
|||
migrations.AlterModelOptions( |
|||
name='hlasovani', |
|||
options={'ordering': ['ucastnik', 'prednaska'], 'verbose_name': 'Hlasov\xe1n\xed', 'verbose_name_plural': 'Hlasov\xe1n\xed'}, |
|||
), |
|||
migrations.AlterModelOptions( |
|||
name='prednaska', |
|||
options={'ordering': ['org', 'nazev'], 'verbose_name': 'P\u0159edn\xe1\u0161ka', 'verbose_name_plural': 'P\u0159edn\xe1\u0161ky'}, |
|||
), |
|||
migrations.AddField( |
|||
model_name='prednaska', |
|||
name='popis', |
|||
field=models.TextField(help_text=b'Neve\xc5\x99ejn\xc3\xbd popis pro ostatn\xc3\xad orgy', null=True, verbose_name=b'Popis pro orgy'), |
|||
), |
|||
migrations.AlterField( |
|||
model_name='hlasovani', |
|||
name='id', |
|||
field=models.AutoField(serialize=False, primary_key=True), |
|||
), |
|||
migrations.AlterField( |
|||
model_name='prednaska', |
|||
name='anotace', |
|||
field=models.TextField(help_text=b'Ve\xc5\x99ejn\xc3\xa1 anotace v hlasov\xc3\xa1n\xc3\xad', null=True, verbose_name=b'Anotace'), |
|||
), |
|||
migrations.AlterField( |
|||
model_name='prednaska', |
|||
name='id', |
|||
field=models.AutoField(serialize=False, primary_key=True), |
|||
), |
|||
migrations.AlterField( |
|||
model_name='prednaska', |
|||
name='obor', |
|||
field=models.CharField(help_text=b'Podmno\xc5\xbeina MFIOB', max_length=5, verbose_name=b'Obor'), |
|||
), |
|||
migrations.AlterField( |
|||
model_name='prednaska', |
|||
name='seznam', |
|||
field=models.ForeignKey(to='prednasky.Seznam'), |
|||
), |
|||
migrations.AlterModelTable( |
|||
name='hlasovani', |
|||
table='prednasky_hlasovani', |
|||
), |
|||
migrations.AlterModelTable( |
|||
name='prednaska', |
|||
table='prednasky_prednaska', |
|||
), |
|||
] |
Loading…
Reference in new issue