63 lines
2.9 KiB
Python
63 lines
2.9 KiB
Python
# -*- coding: utf-8 -*-
|
|
from __future__ import unicode_literals
|
|
|
|
from django.db import models, migrations
|
|
import korektury.models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
|
]
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name='KorekturovanePDF',
|
|
fields=[
|
|
('id', models.AutoField(serialize=False, primary_key=True)),
|
|
('pdf', models.FileField(upload_to=korektury.models.generate_filename, verbose_name='pdf')),
|
|
],
|
|
options={
|
|
'db_table': 'korekturovane_cislo',
|
|
'verbose_name': 'PDF k oprav\xe1m',
|
|
'verbose_name_plural': 'PDF k oprav\xe1m',
|
|
},
|
|
bases=(models.Model,),
|
|
),
|
|
migrations.CreateModel(
|
|
name='Oprava',
|
|
fields=[
|
|
('id', models.AutoField(serialize=False, primary_key=True)),
|
|
('strana', models.IntegerField(help_text=b'Strana s opravou (od 0)', verbose_name='strana s opravou')),
|
|
('x', models.IntegerField(verbose_name='x-ov\xe1 sou\u0159adnice bugu')),
|
|
('y', models.IntegerField(verbose_name='y-ov\xe1 sou\u0159adnice bugu')),
|
|
('status', models.CharField(default=b'k_oprave', max_length=16, verbose_name='stav opravy', choices=[(b'k_oprave', 'K oprav\u011b'), (b'opraveno', 'Opraveno'), (b'smazano', 'Smaz\xe1no')])),
|
|
('autor', models.TextField(help_text=b'Autor opravy', verbose_name='autor opravy', blank=True)),
|
|
('text', models.TextField(help_text=b'Text opravy', verbose_name='text opravy', blank=True)),
|
|
],
|
|
options={
|
|
'ordering': ['y', 'x'],
|
|
'db_table': 'opravy',
|
|
'verbose_name': 'Oprava',
|
|
'verbose_name_plural': 'Opravy',
|
|
},
|
|
bases=(models.Model,),
|
|
),
|
|
migrations.CreateModel(
|
|
name='OpravaKomentar',
|
|
fields=[
|
|
('id', models.AutoField(serialize=False, primary_key=True)),
|
|
('cas', models.DateTimeField(help_text=b'\xc4\x8cas zad\xc3\xa1n\xc3\xad koment\xc3\xa1\xc5\x99e', verbose_name='\u010das koment\xe1\u0159e')),
|
|
('autor', models.TextField(help_text=b'Autor koment\xc3\xa1\xc5\x99e', verbose_name='autor koment\xe1\u0159e', blank=True)),
|
|
('text', models.TextField(help_text=b'Text koment\xc3\xa1\xc5\x99e', verbose_name='text koment\xe1\u0159e', blank=True)),
|
|
('oprava', models.ForeignKey(to='korektury.Oprava', on_delete=models.CASCADE)),
|
|
],
|
|
options={
|
|
'ordering': ['cas'],
|
|
'db_table': 'opravy_komentare',
|
|
'verbose_name': 'Koment\xe1\u0159 k oprav\u011b',
|
|
'verbose_name_plural': 'Koment\xe1\u0159e k oprav\u011b',
|
|
},
|
|
bases=(models.Model,),
|
|
),
|
|
]
|