# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.db import models, migrations


class Migration(migrations.Migration):

    dependencies = [
        ('seminar', '0018_problemnavrh_problemzadany'),
    ]

    operations = [
        migrations.AddField(
            model_name='rocnik',
            name='rocnik_n',
            field=models.IntegerField(default=0, verbose_name='\u010d\xedslo ro\u010dn\xedku'),
            preserve_default=False,
        ),
        migrations.RunSQL(
            sql="update seminar_rocniky set rocnik_n = cast (rocnik as integer)",
            reverse_sql='update seminar_rocniky set rocnik_n = cast (rocnik as nvarchar(16))',
        ),
        migrations.RemoveField(
            model_name='rocnik',
            name='rocnik',
        ),
        migrations.RenameField(
            model_name='rocnik',
            old_name='rocnik_n',
            new_name='rocnik',
        ),
    ]