compute plan grouping

This commit is contained in:
Tobias Brunner 2025-05-23 17:09:02 +02:00
parent 3896636f9b
commit 19b36b9a2c
No known key found for this signature in database
7 changed files with 284 additions and 93 deletions

View file

@ -0,0 +1,52 @@
# Generated by Django 5.2 on 2025-05-23 14:45
import django.db.models.deletion
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("services", "0027_alter_category_options_alter_discounttier_options_and_more"),
]
operations = [
migrations.CreateModel(
name="ComputePlanGroup",
fields=[
(
"id",
models.BigAutoField(
auto_created=True,
primary_key=True,
serialize=False,
verbose_name="ID",
),
),
("name", models.CharField(max_length=200)),
("description", models.TextField(blank=True)),
(
"node_label",
models.CharField(
help_text="Kubernetes node label for this group", max_length=100
),
),
("order", models.IntegerField(default=0)),
],
options={
"ordering": ["name"],
},
),
migrations.AddField(
model_name="computeplan",
name="group",
field=models.ForeignKey(
blank=True,
help_text="Group this compute plan belongs to",
null=True,
on_delete=django.db.models.deletion.SET_NULL,
related_name="compute_plans",
to="services.computeplangroup",
),
),
]