Added missing migrations
This commit is contained in:
parent
2e317e529f
commit
3faf519a49
|
@ -227,7 +227,7 @@ class Bill(models.Model):
|
|||
if self.is_open:
|
||||
prefix = 'O{}'.format(prefix)
|
||||
year = timezone.now().strftime("%Y")
|
||||
bills = cls.objects.filter(number__regex=r'^%s%s[1-9]+' % (prefix, year)
|
||||
bills = cls.objects.filter(number__regex=r'^%s%s[1-9]+' % (prefix, year))
|
||||
last_number = bills.order_by('-number').values_list('number', flat=True).first()
|
||||
if last_number is None:
|
||||
last_number = 0
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('plans', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='rate',
|
||||
name='plan',
|
||||
field=models.ForeignKey(related_name='rates', to='plans.Plan', blank=True, null=True, verbose_name='plan'),
|
||||
),
|
||||
]
|
Loading…
Reference in New Issue