From c506d9fcfaa5e5a7bb469fa0a6905cfe7e209d3c Mon Sep 17 00:00:00 2001 From: George Lacey Date: Tue, 26 Jul 2022 15:25:27 +0100 Subject: [PATCH] Add field to allow repo hiding --- borgweb/borg/migrations/0003_label_visible.py | 18 ++++++++++++++++++ borgweb/borg/models/label.py | 1 + 2 files changed, 19 insertions(+) create mode 100644 borgweb/borg/migrations/0003_label_visible.py diff --git a/borgweb/borg/migrations/0003_label_visible.py b/borgweb/borg/migrations/0003_label_visible.py new file mode 100644 index 0000000..7c1b094 --- /dev/null +++ b/borgweb/borg/migrations/0003_label_visible.py @@ -0,0 +1,18 @@ +# Generated by Django 4.0.6 on 2022-07-26 15:24 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('borg', '0002_location'), + ] + + operations = [ + migrations.AddField( + model_name='label', + name='visible', + field=models.BooleanField(default=True), + ), + ] diff --git a/borgweb/borg/models/label.py b/borgweb/borg/models/label.py index 2ca2c0a..788c010 100644 --- a/borgweb/borg/models/label.py +++ b/borgweb/borg/models/label.py @@ -3,6 +3,7 @@ from django.db import models class Label(models.Model): label = models.TextField(blank=True, unique=True) + visible = models.BooleanField(default=True) def __str__(self): return self.label