diff --git a/tbx/services/migrations/0024_serviceareapage.py b/tbx/services/migrations/0024_serviceareapage.py new file mode 100644 index 000000000..50d2349f4 --- /dev/null +++ b/tbx/services/migrations/0024_serviceareapage.py @@ -0,0 +1,93 @@ +# Generated by Django 4.2.16 on 2025-01-09 13:53 + +from django.db import migrations, models +import django.db.models.deletion +import tbx.core.utils.fields + + +class Migration(migrations.Migration): + + dependencies = [ + ("images", "0001_initial"), + ("wagtailcore", "0094_alter_page_locale"), + ("people", "0011_update_theme_colour_choices"), + ("services", "0023_update_theme_colour_choices"), + ] + + operations = [ + migrations.CreateModel( + name="ServiceAreaPage", + fields=[ + ( + "page_ptr", + models.OneToOneField( + auto_created=True, + on_delete=django.db.models.deletion.CASCADE, + parent_link=True, + primary_key=True, + serialize=False, + to="wagtailcore.page", + ), + ), + ( + "navigation_text", + models.CharField( + blank=True, + help_text="\n Text entered here will appear instead of the page title in the navigation menu.\n For top-level menu items do this in the navigaiton settings instead.\n ", + max_length=255, + ), + ), + ("social_text", models.CharField(blank=True, max_length=255)), + ( + "theme", + models.CharField( + blank=True, + choices=[ + ("", "None"), + ("theme-coral", "Coral"), + ("theme-nebuline", "Nebuline"), + ("theme-lagoon", "Lagoon"), + ("theme-green", "Green"), + ], + max_length=25, + ), + ), + ("subtitle", models.CharField(max_length=255)), + ("body", tbx.core.utils.fields.StreamField(block_lookup={})), + ( + "contact", + models.ForeignKey( + blank=True, + help_text="The contact will be applied to this page's footer and all of its descendants.\nIf no contact is selected, it will be derived from this page's ancestors, eventually falling back to the default contact.", + null=True, + on_delete=django.db.models.deletion.SET_NULL, + related_name="+", + to="people.contact", + ), + ), + ( + "social_image", + models.ForeignKey( + blank=True, + null=True, + on_delete=django.db.models.deletion.SET_NULL, + related_name="+", + to="images.customimage", + ), + ), + ( + "division", + models.ForeignKey( + blank=True, + null=True, + on_delete=django.db.models.deletion.SET_NULL, + to="divisions.divisionpage", + ), + ), + ], + options={ + "abstract": False, + }, + bases=("wagtailcore.page", models.Model), + ), + ]