Refactor code structure and remove redundant changes

This commit is contained in:
pacnpal
2025-11-09 16:31:34 -05:00
parent 2884bc23ce
commit eb68cf40c6
1080 changed files with 27361 additions and 56687 deletions

View File

@@ -0,0 +1,102 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{% block title %}ThrillWiki{% endblock %}</title>
<style>
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
line-height: 1.6;
color: #333;
max-width: 600px;
margin: 0 auto;
padding: 20px;
background-color: #f5f5f5;
}
.email-container {
background-color: #ffffff;
border-radius: 8px;
padding: 30px;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.header {
text-align: center;
padding-bottom: 20px;
border-bottom: 2px solid #22c55e;
margin-bottom: 30px;
}
.logo {
font-size: 32px;
font-weight: bold;
color: #22c55e;
margin: 0;
}
.tagline {
color: #666;
font-size: 14px;
margin: 5px 0 0 0;
}
.content {
color: #333;
font-size: 16px;
}
.button {
display: inline-block;
padding: 12px 24px;
background-color: #22c55e;
color: #ffffff !important;
text-decoration: none;
border-radius: 6px;
margin: 20px 0;
font-weight: 600;
}
.button:hover {
background-color: #16a34a;
}
.footer {
margin-top: 40px;
padding-top: 20px;
border-top: 1px solid #e5e5e5;
font-size: 12px;
color: #666;
text-align: center;
}
.info-box {
background-color: #f0fdf4;
border-left: 4px solid #22c55e;
padding: 15px;
margin: 20px 0;
border-radius: 4px;
}
.warning-box {
background-color: #fef3c7;
border-left: 4px solid #f59e0b;
padding: 15px;
margin: 20px 0;
border-radius: 4px;
}
</style>
</head>
<body>
<div class="email-container">
<div class="header">
<h1 class="logo">🎢 ThrillWiki</h1>
<p class="tagline">The Ultimate Roller Coaster Database</p>
</div>
<div class="content">
{% block content %}{% endblock %}
</div>
<div class="footer">
<p>This email was sent by ThrillWiki.</p>
<p>
If you have any questions, please contact us at
<a href="mailto:support@thrillwiki.com">support@thrillwiki.com</a>
</p>
<p>&copy; {% now "Y" %} ThrillWiki. All rights reserved.</p>
</div>
</div>
</body>
</html>

View File

@@ -0,0 +1,40 @@
{% extends "emails/base.html" %}
{% block title %}New Contact Submission{% endblock %}
{% block content %}
<h2 style="color: #dc2626; margin-bottom: 20px;">🔔 New Contact Submission</h2>
<p>A new contact form submission has been received and requires attention.</p>
<div style="background-color: #fef2f2; padding: 15px; border-radius: 8px; border-left: 4px solid #dc2626; margin: 20px 0;">
<p style="margin: 5px 0;"><strong>Ticket:</strong> {{ ticket_number }}</p>
<p style="margin: 5px 0;"><strong>Category:</strong> {{ category }}</p>
<p style="margin: 5px 0;"><strong>Status:</strong> Pending Review</p>
</div>
<h3 style="color: #374151; margin-top: 25px;">Contact Information</h3>
<div style="background-color: #f9fafb; padding: 15px; border-radius: 8px;">
<p style="margin: 5px 0;"><strong>Name:</strong> {{ name }}</p>
<p style="margin: 5px 0;"><strong>Email:</strong> <a href="mailto:{{ email }}">{{ email }}</a></p>
</div>
<h3 style="color: #374151; margin-top: 25px;">Subject</h3>
<p style="background-color: #f3f4f6; padding: 15px; border-radius: 8px;">{{ subject }}</p>
<h3 style="color: #374151; margin-top: 25px;">Message</h3>
<div style="background-color: #f9fafb; padding: 15px; border-left: 4px solid #2563eb; margin: 15px 0;">
{{ message|linebreaks }}
</div>
<div style="margin-top: 30px; padding: 20px; background-color: #eff6ff; border-radius: 8px;">
<p style="margin: 0 0 15px 0;"><strong>Quick Actions:</strong></p>
<a href="{{ admin_url }}" style="display: inline-block; background-color: #2563eb; color: white; padding: 12px 24px; text-decoration: none; border-radius: 6px; font-weight: bold;">
View in Admin Panel →
</a>
</div>
<p style="margin-top: 20px; font-size: 14px; color: #6b7280;">
This is an automated notification. Please respond to the ticket through the admin panel.
</p>
{% endblock %}

View File

@@ -0,0 +1,28 @@
{% extends "emails/base.html" %}
{% block title %}Contact Form Received{% endblock %}
{% block content %}
<h2 style="color: #2563eb; margin-bottom: 20px;">Thank You for Contacting Us</h2>
<p>Hi {{ name }},</p>
<p>We've received your message and have created a support ticket for tracking purposes.</p>
<div style="background-color: #f3f4f6; padding: 15px; border-radius: 8px; margin: 20px 0;">
<p style="margin: 5px 0;"><strong>Ticket Number:</strong> {{ ticket_number }}</p>
<p style="margin: 5px 0;"><strong>Category:</strong> {{ category }}</p>
<p style="margin: 5px 0;"><strong>Subject:</strong> {{ subject }}</p>
</div>
<p><strong>Your Message:</strong></p>
<div style="background-color: #f9fafb; padding: 15px; border-left: 4px solid #2563eb; margin: 15px 0;">
{{ message|linebreaks }}
</div>
<p>Our team will review your message and respond as soon as possible. You can reference your ticket number ({{ ticket_number }}) in any follow-up communications.</p>
<p>If you need to add more information to your ticket, please reply to this email with your ticket number in the subject line.</p>
<p>Thank you for being part of the ThrillWiki community!</p>
{% endblock %}

View File

@@ -0,0 +1,30 @@
{% extends "emails/base.html" %}
{% block title %}Support Ticket Resolved{% endblock %}
{% block content %}
<h2 style="color: #16a34a; margin-bottom: 20px;">✅ Your Support Ticket Has Been Resolved</h2>
<p>Hi {{ name }},</p>
<p>Good news! Your support ticket has been resolved by our team.</p>
<div style="background-color: #f0fdf4; padding: 15px; border-radius: 8px; border-left: 4px solid #16a34a; margin: 20px 0;">
<p style="margin: 5px 0;"><strong>Ticket Number:</strong> {{ ticket_number }}</p>
<p style="margin: 5px 0;"><strong>Subject:</strong> {{ subject }}</p>
<p style="margin: 5px 0;"><strong>Resolved By:</strong> {{ resolved_by }}</p>
</div>
<p>We hope we were able to address your concerns satisfactorily. If you have any follow-up questions or if the issue persists, please don't hesitate to reach out by replying to this email or submitting a new contact form.</p>
<div style="margin-top: 30px; padding: 20px; background-color: #eff6ff; border-radius: 8px;">
<p style="margin: 0 0 10px 0;"><strong>Need More Help?</strong></p>
<p style="margin: 0; font-size: 14px;">You can reference ticket number <strong>{{ ticket_number }}</strong> in any future communications about this issue.</p>
</div>
<p style="margin-top: 25px;">Thank you for your patience and for being part of the ThrillWiki community!</p>
<p style="margin-top: 20px; font-size: 14px; color: #6b7280;">
If you're satisfied with how your ticket was handled, we'd love to hear your feedback. Your input helps us improve our support services.
</p>
{% endblock %}

View File

@@ -0,0 +1,50 @@
{% extends "emails/base.html" %}
{% block title %}Submission Approved - ThrillWiki{% endblock %}
{% block content %}
<h2>Great News! Your Submission Was Approved ✅</h2>
<p>Hello {{ submission.user.first_name|default:submission.user.email }},</p>
<p>Your submission has been reviewed and approved by our moderation team. Your contributions help make ThrillWiki more accurate and comprehensive!</p>
<div class="info-box">
<p><strong>Submission Details:</strong></p>
<ul style="margin: 10px 0; padding-left: 20px;">
<li><strong>Title:</strong> {{ submission.title }}</li>
<li><strong>Type:</strong> {{ submission.get_submission_type_display }}</li>
<li><strong>Entity:</strong> {{ submission.entity }}</li>
<li><strong>Submitted:</strong> {{ submission.submitted_at|date:"F d, Y g:i A" }}</li>
<li><strong>Reviewed by:</strong> {{ submission.reviewed_by.email }}</li>
<li><strong>Items approved:</strong> {{ submission.items.approved.count }}</li>
</ul>
</div>
{% if submission.description %}
<h3>Your Description:</h3>
<p style="background: #f5f5f5; padding: 15px; border-radius: 4px; font-style: italic;">
"{{ submission.description }}"
</p>
{% endif %}
<div style="text-align: center; margin: 30px 0;">
<a href="{{ submission_url }}" class="button">View Submission</a>
</div>
<h3>What happens next?</h3>
<p>Your changes are now live on ThrillWiki and visible to all users. Here's what you can do:</p>
<ul style="margin: 10px 0; padding-left: 20px;">
<li>View the updated entity page to see your changes</li>
<li>Submit more updates to other entities</li>
<li>Share your contributions with the community</li>
</ul>
<div class="info-box">
<p><strong>📊 Contribution Stats:</strong></p>
<p>You've made <strong>{{ user_submission_count }}</strong> submission(s) to ThrillWiki. Thank you for helping us maintain the most accurate roller coaster database!</p>
</div>
<p style="margin-top: 30px;">Keep up the great work!</p>
<p><strong>The ThrillWiki Moderation Team</strong></p>
{% endblock %}

View File

@@ -0,0 +1,67 @@
{% extends "emails/base.html" %}
{% block title %}Submission Requires Changes - ThrillWiki{% endblock %}
{% block content %}
<h2>Your Submission Needs Revision ⚠️</h2>
<p>Hello {{ submission.user.first_name|default:submission.user.email }},</p>
<p>Thank you for your contribution to ThrillWiki. After careful review, our moderation team has determined that your submission requires some changes before it can be approved.</p>
<div class="warning-box">
<p><strong>Submission Details:</strong></p>
<ul style="margin: 10px 0; padding-left: 20px;">
<li><strong>Title:</strong> {{ submission.title }}</li>
<li><strong>Type:</strong> {{ submission.get_submission_type_display }}</li>
<li><strong>Entity:</strong> {{ submission.entity }}</li>
<li><strong>Submitted:</strong> {{ submission.submitted_at|date:"F d, Y g:i A" }}</li>
<li><strong>Reviewed by:</strong> {{ submission.reviewed_by.email }}</li>
</ul>
</div>
{% if submission.rejection_reason %}
<h3>Reason for Rejection:</h3>
<p style="background: #fef3c7; padding: 15px; border-radius: 4px; border-left: 4px solid #f59e0b;">
{{ submission.rejection_reason }}
</p>
{% endif %}
<h3>Common Reasons for Rejection:</h3>
<ul style="margin: 10px 0; padding-left: 20px;">
<li>Insufficient or inaccurate information</li>
<li>Missing required sources or citations</li>
<li>Duplicate submission</li>
<li>Information doesn't match our verification standards</li>
<li>Photos don't meet quality guidelines</li>
</ul>
<div style="text-align: center; margin: 30px 0;">
<a href="{{ submission_url }}" class="button">Review Your Submission</a>
</div>
<h3>What you can do:</h3>
<ol style="margin: 10px 0; padding-left: 20px;">
<li>Review the moderator's feedback carefully</li>
<li>Gather additional information or sources if needed</li>
<li>Submit a new, corrected version</li>
<li>Contact the moderation team if you have questions</li>
</ol>
<div class="info-box">
<p><strong>💡 Tips for Successful Submissions:</strong></p>
<ul style="margin: 10px 0; padding-left: 20px;">
<li>Double-check all information before submitting</li>
<li>Include sources when possible</li>
<li>Provide clear descriptions of your changes</li>
<li>Follow our submission guidelines</li>
</ul>
</div>
<p style="margin-top: 30px;">We appreciate your contributions and look forward to your revised submission!</p>
<p><strong>The ThrillWiki Moderation Team</strong></p>
<p style="font-size: 12px; color: #666; margin-top: 20px;">
<em>Questions about this decision? Reply to this email or contact us at support@thrillwiki.com</em>
</p>
{% endblock %}

View File

@@ -0,0 +1,47 @@
{% extends "emails/base.html" %}
{% block title %}Reset Your Password - ThrillWiki{% endblock %}
{% block content %}
<h2>Password Reset Request</h2>
<p>Hello {{ user.first_name|default:user.email }},</p>
<p>We received a request to reset the password for your ThrillWiki account.</p>
<div class="info-box">
<p><strong>Account:</strong> {{ user.email }}</p>
<p><strong>Request time:</strong> {{ request_time|date:"F d, Y g:i A" }}</p>
</div>
<p>Click the button below to reset your password:</p>
<div style="text-align: center; margin: 30px 0;">
<a href="{{ reset_url }}" class="button">Reset Password</a>
</div>
<p style="font-size: 14px; color: #666;">
Or copy and paste this link into your browser:<br>
<code style="background: #f5f5f5; padding: 5px 10px; display: inline-block; margin-top: 5px; border-radius: 4px; word-break: break-all;">{{ reset_url }}</code>
</p>
<div class="warning-box">
<p><strong>⚠️ Security Notice:</strong></p>
<ul style="margin: 10px 0; padding-left: 20px;">
<li>This link will expire in <strong>{{ expiry_hours }} hours</strong></li>
<li>This link can only be used once</li>
<li>If you didn't request this reset, you can safely ignore this email</li>
</ul>
</div>
<h3>Didn't request this?</h3>
<p>If you didn't request a password reset, your account may be at risk. Please:</p>
<ol style="margin: 10px 0; padding-left: 20px;">
<li>Log in to your account immediately</li>
<li>Change your password as a precaution</li>
<li>Contact our support team if you notice any suspicious activity</li>
</ol>
<p style="margin-top: 30px;">Stay safe!</p>
<p><strong>The ThrillWiki Team</strong></p>
{% endblock %}

View File

@@ -0,0 +1,45 @@
{% extends "emails/base.html" %}
{% block title %}Welcome to ThrillWiki{% endblock %}
{% block content %}
<h2>Welcome to ThrillWiki, {{ user.first_name|default:user.email }}! 🎢</h2>
<p>Thank you for joining the world's most comprehensive roller coaster database. We're excited to have you as part of our community!</p>
<div class="info-box">
<p><strong>Your account details:</strong></p>
<ul style="margin: 10px 0; padding-left: 20px;">
<li>Email: {{ user.email }}</li>
<li>Account created: {{ user.date_joined|date:"F d, Y" }}</li>
</ul>
</div>
<h3>What you can do on ThrillWiki:</h3>
<ul style="margin: 20px 0; padding-left: 20px;">
<li>📊 Browse detailed information about theme parks worldwide</li>
<li>🎢 Explore roller coasters and their specifications</li>
<li>🏢 Discover ride manufacturers and their creations</li>
<li>📸 Upload photos of your park visits</li>
<li>✏️ Submit updates and corrections to improve our database</li>
<li>⭐ Track your favorite parks and rides</li>
</ul>
<div style="text-align: center; margin: 30px 0;">
<a href="{{ site_url }}" class="button">Start Exploring</a>
</div>
<h3>Get Started:</h3>
<p>Here are some tips to make the most of your ThrillWiki experience:</p>
<ol style="margin: 10px 0; padding-left: 20px;">
<li>Complete your profile to personalize your experience</li>
<li>Search for your favorite theme parks</li>
<li>Contribute to the community by submitting corrections</li>
<li>Share your park photos with other enthusiasts</li>
</ol>
<p style="margin-top: 30px;">If you have any questions or need help getting started, don't hesitate to reach out to our support team.</p>
<p>Happy coaster hunting!</p>
<p><strong>The ThrillWiki Team</strong></p>
{% endblock %}