Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Generated by Django 5.1.7 on 2025-03-22 18:19
- import django.core.validators
- from django.db import migrations, models
- class Migration(migrations.Migration):
- initial = True
- dependencies = []
- operations = [
- migrations.CreateModel(
- name="Brand",
- fields=[
- (
- "id",
- models.BigAutoField(
- auto_created=True,
- primary_key=True,
- serialize=False,
- verbose_name="ID",
- ),
- ),
- ("name", models.CharField(max_length=64)),
- ("website", models.URLField()),
- ("created_at", models.DateTimeField()),
- ("updated_at", models.DateTimeField()),
- ],
- options={
- "verbose_name": "Brand",
- "verbose_name_plural": "Brands",
- "db_table": "brands",
- "managed": False,
- },
- ),
- migrations.CreateModel(
- name="BrandRelationship",
- fields=[
- (
- "id",
- models.BigAutoField(
- auto_created=True,
- primary_key=True,
- serialize=False,
- verbose_name="ID",
- ),
- ),
- ("order", models.IntegerField()),
- ("path", models.CharField(max_length=255)),
- ],
- options={
- "verbose_name": "Brand Relationship",
- "verbose_name_plural": "Brand Relationships",
- "db_table": "brands_rels",
- "managed": False,
- },
- ),
- migrations.CreateModel(
- name="CmsEvent",
- fields=[
- ("id", models.AutoField(primary_key=True, serialize=False)),
- (
- "event_uuid",
- models.CharField(
- editable=False,
- help_text="Read-only UUID for the event",
- max_length=36,
- unique=True,
- ),
- ),
- (
- "name",
- models.CharField(
- help_text="Enter the name of the event", max_length=128
- ),
- ),
- (
- "description",
- models.JSONField(
- default=dict,
- help_text="Provide a detailed description of the event",
- ),
- ),
- (
- "venue",
- models.CharField(
- blank=True,
- help_text="Enter the venue name (optional)",
- max_length=255,
- null=True,
- ),
- ),
- (
- "city",
- models.CharField(
- blank=True,
- help_text="Enter the city (optional)",
- max_length=255,
- null=True,
- ),
- ),
- (
- "locality",
- models.CharField(
- blank=True,
- help_text="Enter the locality (optional)",
- max_length=255,
- null=True,
- ),
- ),
- (
- "google_maps_link",
- models.URLField(
- help_text="Enter the Google Maps link for the event",
- validators=[django.core.validators.URLValidator()],
- ),
- ),
- (
- "google_form_link",
- models.URLField(
- help_text="Enter the Google Maps link for the event",
- validators=[django.core.validators.URLValidator()],
- ),
- ),
- (
- "payment_link",
- models.URLField(
- help_text="Enter the Google Maps link for the event",
- validators=[django.core.validators.URLValidator()],
- ),
- ),
- (
- "is_online_and_offline",
- models.BooleanField(
- default=False,
- help_text="Check this if an offline event is also streamed online.",
- ),
- ),
- (
- "start_date",
- models.DateTimeField(
- help_text="Event start date with time and timezone"
- ),
- ),
- (
- "end_date",
- models.DateTimeField(
- blank=True,
- help_text="Event end date with time and timezone",
- null=True,
- ),
- ),
- (
- "start_time",
- models.CharField(
- blank=True,
- help_text="Enter the start time (e.g., HH:MM)",
- max_length=10,
- null=True,
- ),
- ),
- (
- "end_time",
- models.CharField(
- blank=True,
- help_text="Enter the end time (e.g., HH:MM)",
- max_length=10,
- null=True,
- ),
- ),
- (
- "deleted",
- models.BooleanField(
- default=False, help_text="Mark this if the event is deleted."
- ),
- ),
- (
- "is_online",
- models.BooleanField(
- default=False,
- help_text="Check this if the event is an online event.",
- ),
- ),
- (
- "location",
- models.JSONField(
- default=dict,
- help_text="Provide structured location data for the event",
- ),
- ),
- (
- "price",
- models.IntegerField(
- help_text="Enter the price of the event",
- validators=[django.core.validators.MinValueValidator(0)],
- ),
- ),
- ],
- options={
- "verbose_name": "CMS Event",
- "verbose_name_plural": "CMS Events",
- "db_table": "events",
- "managed": False,
- },
- ),
- migrations.CreateModel(
- name="Form",
- fields=[
- ("id", models.AutoField(primary_key=True, serialize=False)),
- (
- "title",
- models.CharField(help_text="Enter the form title", max_length=255),
- ),
- (
- "submit_button_label",
- models.CharField(
- help_text="Enter the submit button label (e.g., Submit, Register)",
- max_length=255,
- ),
- ),
- (
- "confirmation_type",
- models.CharField(
- choices=[("message", "Message"), ("redirect", "Redirect")],
- help_text="Select the type of confirmation after form submission",
- max_length=10,
- ),
- ),
- (
- "confirmation_message",
- models.JSONField(
- blank=True,
- help_text="Provide a confirmation message in JSON format if confirmation type is 'Message'",
- null=True,
- ),
- ),
- (
- "redirect_url",
- models.URLField(
- blank=True,
- help_text="Provide a redirect URL if confirmation type is 'Redirect'",
- max_length=2048,
- null=True,
- ),
- ),
- (
- "updated_at",
- models.DateTimeField(
- auto_now=True,
- help_text="Timestamp when the form was last updated",
- ),
- ),
- (
- "created_at",
- models.DateTimeField(
- auto_now_add=True,
- help_text="Timestamp when the form was created",
- ),
- ),
- ],
- options={
- "verbose_name": "Form",
- "verbose_name_plural": "Forms",
- "db_table": "forms",
- "managed": False,
- },
- ),
- migrations.CreateModel(
- name="FormSubmission",
- fields=[
- ("id", models.AutoField(primary_key=True, serialize=False)),
- (
- "updated_at",
- models.DateTimeField(
- auto_now=True,
- help_text="Timestamp when the submission was last updated",
- ),
- ),
- (
- "created_at",
- models.DateTimeField(
- auto_now_add=True,
- help_text="Timestamp when the submission was created",
- ),
- ),
- ],
- options={
- "verbose_name": "Form Submission",
- "verbose_name_plural": "Form Submissions",
- "db_table": "form_submissions",
- "managed": False,
- },
- ),
- migrations.CreateModel(
- name="Media",
- fields=[
- (
- "id",
- models.BigAutoField(
- auto_created=True,
- primary_key=True,
- serialize=False,
- verbose_name="ID",
- ),
- ),
- ("alt", models.CharField(max_length=255)),
- ("prefix", models.CharField(max_length=255)),
- ("updated_at", models.DateTimeField(auto_now=True)),
- ("created_at", models.DateTimeField(auto_now_add=True)),
- ("url", models.URLField(blank=True, null=True)),
- (
- "thumbnail_url",
- models.URLField(blank=True, db_column="thumbnail_u_r_l", null=True),
- ),
- ("filename", models.CharField(max_length=255)),
- (
- "mimetype",
- models.CharField(
- blank=True, db_column="mime_type", max_length=128, null=True
- ),
- ),
- (
- "filesize",
- models.DecimalField(
- blank=True, decimal_places=2, max_digits=20, null=True
- ),
- ),
- (
- "width",
- models.DecimalField(
- blank=True, decimal_places=2, max_digits=10, null=True
- ),
- ),
- (
- "height",
- models.DecimalField(
- blank=True, decimal_places=2, max_digits=10, null=True
- ),
- ),
- (
- "focal_x",
- models.DecimalField(
- blank=True, decimal_places=2, max_digits=5, null=True
- ),
- ),
- (
- "focal_y",
- models.DecimalField(
- blank=True, decimal_places=2, max_digits=5, null=True
- ),
- ),
- ],
- options={
- "verbose_name": "Media",
- "verbose_name_plural": "Media",
- "db_table": "media",
- "managed": False,
- },
- ),
- migrations.CreateModel(
- name="ShoppingCategory",
- fields=[
- (
- "id",
- models.BigAutoField(
- auto_created=True,
- primary_key=True,
- serialize=False,
- verbose_name="ID",
- ),
- ),
- ("name", models.CharField(max_length=64, unique=True)),
- ],
- options={
- "verbose_name": "Shopping Category",
- "verbose_name_plural": "Shopping Categories",
- "db_table": "shopping_categories",
- "managed": False,
- },
- ),
- ]
Advertisement
Add Comment
Please, Sign In to add comment