tallybill/main/migrations/0005_copy_datetime_back.py
2019-08-17 02:05:08 +02:00

22 lines
478 B
Python

# Generated by Django 2.2.4 on 2019-08-16 16:22
from django.db import migrations
def combine_names(apps, schema_editor):
OutgoingInvoice = apps.get_model('main', 'OutgoingInvoice')
for inv in OutgoingInvoice.objects.all():
inv.date = inv.date_new
inv.save()
class Migration(migrations.Migration):
dependencies = [
('main', '0004_outgoinginvoice_alter_date'),
]
operations = [
migrations.RunPython(combine_names),
]