Update snapshots with sum db columns
This commit is contained in:
parent
02eb781492
commit
c083fff07e
4 changed files with 87 additions and 30 deletions
|
@ -0,0 +1,34 @@
|
|||
# Generated by Django 4.1.4 on 2022-12-29 20:56
|
||||
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
("main", "0017_alter_transaction_account"),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name="snapshot",
|
||||
name="diff",
|
||||
field=models.DecimalField(
|
||||
decimal_places=2,
|
||||
default=0,
|
||||
editable=False,
|
||||
max_digits=12,
|
||||
verbose_name="Différence",
|
||||
),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="snapshot",
|
||||
name="account",
|
||||
field=models.ForeignKey(
|
||||
on_delete=django.db.models.deletion.CASCADE,
|
||||
to="main.account",
|
||||
verbose_name="Account",
|
||||
),
|
||||
),
|
||||
]
|
24
nummi/main/migrations/0019_snapshot_sum.py
Normal file
24
nummi/main/migrations/0019_snapshot_sum.py
Normal file
|
@ -0,0 +1,24 @@
|
|||
# Generated by Django 4.1.4 on 2022-12-29 20:57
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
("main", "0018_snapshot_diff_alter_snapshot_account"),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name="snapshot",
|
||||
name="sum",
|
||||
field=models.DecimalField(
|
||||
decimal_places=2,
|
||||
default=0,
|
||||
editable=False,
|
||||
max_digits=12,
|
||||
verbose_name="Transaction difference",
|
||||
),
|
||||
),
|
||||
]
|
Loading…
Add table
Add a link
Reference in a new issue