Email config, email template and more!
This commit is contained in:
112
quotes/migrations/0001_initial.py
Normal file
112
quotes/migrations/0001_initial.py
Normal file
@@ -0,0 +1,112 @@
|
||||
# Generated by Django 4.2.27 on 2025-12-03 23:22
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
import quotes.models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
initial = True
|
||||
|
||||
dependencies = []
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name="Submission",
|
||||
fields=[
|
||||
(
|
||||
"id",
|
||||
models.BigAutoField(
|
||||
auto_created=True,
|
||||
primary_key=True,
|
||||
serialize=False,
|
||||
verbose_name="ID",
|
||||
),
|
||||
),
|
||||
(
|
||||
"email",
|
||||
models.EmailField(
|
||||
help_text="Email of the person who submitted the quote request",
|
||||
max_length=254,
|
||||
),
|
||||
),
|
||||
(
|
||||
"description",
|
||||
models.TextField(
|
||||
help_text="Notes, comments, or description provided by the submitter"
|
||||
),
|
||||
),
|
||||
(
|
||||
"submitted_at",
|
||||
models.DateTimeField(
|
||||
auto_now_add=True, help_text="When the submission was created"
|
||||
),
|
||||
),
|
||||
(
|
||||
"expiration_time",
|
||||
models.DateTimeField(
|
||||
default=quotes.models.default_expiration_time,
|
||||
help_text="When this submission expires (default 20 days from submission)",
|
||||
),
|
||||
),
|
||||
],
|
||||
options={
|
||||
"verbose_name": "Submission",
|
||||
"verbose_name_plural": "Submissions",
|
||||
"ordering": ["-submitted_at"],
|
||||
},
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name="SubmissionFile",
|
||||
fields=[
|
||||
(
|
||||
"id",
|
||||
models.BigAutoField(
|
||||
auto_created=True,
|
||||
primary_key=True,
|
||||
serialize=False,
|
||||
verbose_name="ID",
|
||||
),
|
||||
),
|
||||
(
|
||||
"original_filename",
|
||||
models.CharField(
|
||||
help_text="Original filename as uploaded by the user",
|
||||
max_length=255,
|
||||
),
|
||||
),
|
||||
(
|
||||
"path",
|
||||
models.CharField(
|
||||
help_text="Path relative to /data/uploads (e.g., 'filename.pdf')",
|
||||
max_length=500,
|
||||
),
|
||||
),
|
||||
(
|
||||
"file_size",
|
||||
models.PositiveIntegerField(help_text="Size of the file in bytes"),
|
||||
),
|
||||
(
|
||||
"uploaded_at",
|
||||
models.DateTimeField(
|
||||
auto_now_add=True, help_text="When the file was uploaded"
|
||||
),
|
||||
),
|
||||
(
|
||||
"submission",
|
||||
models.ForeignKey(
|
||||
help_text="The submission this file belongs to",
|
||||
on_delete=django.db.models.deletion.CASCADE,
|
||||
related_name="files",
|
||||
to="quotes.submission",
|
||||
),
|
||||
),
|
||||
],
|
||||
options={
|
||||
"verbose_name": "Submission File",
|
||||
"verbose_name_plural": "Submission Files",
|
||||
"ordering": ["uploaded_at"],
|
||||
},
|
||||
),
|
||||
]
|
||||
0
quotes/migrations/__init__.py
Normal file
0
quotes/migrations/__init__.py
Normal file
Reference in New Issue
Block a user