# Generated by Django 2.2.10 on 2020-02-26 15:24

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('payments', '0003_auto_20200226_0838'),
    ]

    operations = [
        migrations.RenameField(
            model_name='billpayment',
            old_name='amount',
            new_name='value',
        ),
        migrations.RemoveField(
            model_name='meterrecord',
            name='is_active',
        ),
        migrations.AddField(
            model_name='bill',
            name='total_value',
            field=models.DecimalField(decimal_places=2, default=0, max_digits=8, verbose_name='Total value'),
        ),
        migrations.AddField(
            model_name='meter',
            name='is_active',
            field=models.BooleanField(default=True, verbose_name='Is active'),
        ),
        migrations.AlterField(
            model_name='bill',
            name='number',
            field=models.CharField(max_length=32, unique=True, verbose_name='Bill number'),
        ),
        migrations.AlterUniqueTogether(
            name='bill',
            unique_together=set(),
        ),
        migrations.CreateModel(
            name='BillLine',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('previous_debt', models.DecimalField(decimal_places=2, default=0, max_digits=8, verbose_name='Bill value')),
                ('value', models.DecimalField(decimal_places=2, default=0, max_digits=8, verbose_name='Bill value')),
                ('bill', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='payments.Bill', verbose_name='Bill')),
                ('service', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='payments.Service', verbose_name='Service')),
            ],
            options={
                'verbose_name': 'BillLine',
                'verbose_name_plural': 'BillLines',
            },
        ),
        migrations.RemoveField(
            model_name='bill',
            name='amount',
        ),
        migrations.RemoveField(
            model_name='bill',
            name='created_by',
        ),
        migrations.RemoveField(
            model_name='bill',
            name='date_updated',
        ),
        migrations.RemoveField(
            model_name='bill',
            name='service',
        ),
    ]

# Generated by Django 2.2.10 on 2020-02-26 15:24

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('payments', '0003_auto_20200226_0838'),
    ]

    operations = [
        migrations.RenameField(
            model_name='billpayment',
            old_name='amount',
            new_name='value',
        ),
        migrations.RemoveField(
            model_name='meterrecord',
            name='is_active',
        ),
        migrations.AddField(
            model_name='bill',
            name='total_value',
            field=models.DecimalField(decimal_places=2, default=0, max_digits=8, verbose_name='Total value'),
        ),
        migrations.AddField(
            model_name='meter',
            name='is_active',
            field=models.BooleanField(default=True, verbose_name='Is active'),
        ),
        migrations.AlterField(
            model_name='bill',
            name='number',
            field=models.CharField(max_length=32, unique=True, verbose_name='Bill number'),
        ),
        migrations.AlterUniqueTogether(
            name='bill',
            unique_together=set(),
        ),
        migrations.CreateModel(
            name='BillLine',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('previous_debt', models.DecimalField(decimal_places=2, default=0, max_digits=8, verbose_name='Bill value')),
                ('value', models.DecimalField(decimal_places=2, default=0, max_digits=8, verbose_name='Bill value')),
                ('bill', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='payments.Bill', verbose_name='Bill')),
                ('service', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='payments.Service', verbose_name='Service')),
            ],
            options={
                'verbose_name': 'BillLine',
                'verbose_name_plural': 'BillLines',
            },
        ),
        migrations.RemoveField(
            model_name='bill',
            name='amount',
        ),
        migrations.RemoveField(
            model_name='bill',
            name='created_by',
        ),
        migrations.RemoveField(
            model_name='bill',
            name='date_updated',
        ),
        migrations.RemoveField(
            model_name='bill',
            name='service',
        ),
    ]

# Generated by Django 2.2.10 on 2020-02-26 15:24