Finished months balance except the below tables
This commit is contained in:
@@ -0,0 +1,67 @@
|
||||
# Generated by Django 5.1.5 on 2026-01-07 11:29
|
||||
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('sheets', '0010_excelentry_constant_300_excelentry_druckkorrektur_and_more'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='betriebskosten',
|
||||
name='kostentyp',
|
||||
field=models.CharField(choices=[('sach', 'Sachkosten'), ('ln2', 'LN2'), ('helium', 'Helium'), ('inv', 'Inventar')], max_length=10, verbose_name='Kostentyp'),
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='MonthlySheet',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('year', models.IntegerField()),
|
||||
('month', models.IntegerField()),
|
||||
('created_at', models.DateTimeField(auto_now_add=True)),
|
||||
('updated_at', models.DateTimeField(auto_now=True)),
|
||||
],
|
||||
options={
|
||||
'ordering': ['year', 'month'],
|
||||
'unique_together': {('year', 'month')},
|
||||
},
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='Cell',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('table_type', models.CharField(choices=[('top_left', 'Top Left Table'), ('top_right', 'Top Right Table'), ('bottom_1', 'Bottom Table 1'), ('bottom_2', 'Bottom Table 2'), ('bottom_3', 'Bottom Table 3')], max_length=20)),
|
||||
('row_index', models.IntegerField()),
|
||||
('column_index', models.IntegerField()),
|
||||
('value', models.DecimalField(blank=True, decimal_places=6, max_digits=15, null=True)),
|
||||
('formula', models.TextField(blank=True)),
|
||||
('is_formula', models.BooleanField(default=False)),
|
||||
('data_type', models.CharField(choices=[('number', 'Number'), ('text', 'Text'), ('date', 'Date')], default='number', max_length=20)),
|
||||
('client', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='sheets.client')),
|
||||
('sheet', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='cells', to='sheets.monthlysheet')),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='CellReference',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('source_cell', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='dependents', to='sheets.cell')),
|
||||
('target_cell', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='dependencies', to='sheets.cell')),
|
||||
],
|
||||
options={
|
||||
'unique_together': {('source_cell', 'target_cell')},
|
||||
},
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='cell',
|
||||
index=models.Index(fields=['sheet', 'table_type', 'row_index'], name='sheets_cell_sheet_i_511238_idx'),
|
||||
),
|
||||
migrations.AlterUniqueTogether(
|
||||
name='cell',
|
||||
unique_together={('sheet', 'client', 'table_type', 'row_index', 'column_index')},
|
||||
),
|
||||
]
|
||||
34
sheets/migrations/0012_tableconfig_rowcalculation.py
Normal file
34
sheets/migrations/0012_tableconfig_rowcalculation.py
Normal file
@@ -0,0 +1,34 @@
|
||||
# Generated by Django 6.0.1 on 2026-02-01 11:03
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('sheets', '0011_alter_betriebskosten_kostentyp_monthlysheet_cell_and_more'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='TableConfig',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('table_type', models.CharField(choices=[('top_left', 'Top Left Table'), ('top_right', 'Top Right Table'), ('bottom_1', 'Bottom Table 1'), ('bottom_2', 'Bottom Table 2'), ('bottom_3', 'Bottom Table 3')], max_length=20, unique=True)),
|
||||
('calculations', models.JSONField(default=dict)),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='RowCalculation',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('table_type', models.CharField(choices=[('top_left', 'Top Left Table'), ('top_right', 'Top Right Table'), ('bottom_1', 'Bottom Table 1'), ('bottom_2', 'Bottom Table 2'), ('bottom_3', 'Bottom Table 3')], max_length=20)),
|
||||
('row_index', models.IntegerField()),
|
||||
('formula', models.TextField()),
|
||||
('description', models.CharField(blank=True, max_length=200)),
|
||||
],
|
||||
options={
|
||||
'unique_together': {('table_type', 'row_index')},
|
||||
},
|
||||
),
|
||||
]
|
||||
BIN
sheets/migrations/__pycache__/0001_initial.cpython-313.pyc
Normal file
BIN
sheets/migrations/__pycache__/0001_initial.cpython-313.pyc
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
sheets/migrations/__pycache__/__init__.cpython-313.pyc
Normal file
BIN
sheets/migrations/__pycache__/__init__.cpython-313.pyc
Normal file
Binary file not shown.
Reference in New Issue
Block a user