Features Added: 🔥 Modern Chat System: - Real-time messaging with modern Tailwind CSS design - Post-linked discussions for adventure sharing - Chat categories (general, technical-support, adventure-planning) - Mobile-responsive interface with gradient backgrounds - JavaScript polling for live message updates 🎯 Comprehensive Admin Panel: - Chat room management with merge capabilities - Password reset system with email templates - User management with admin controls - Chat statistics and analytics dashboard - Room binding to posts and categorization �� Mobile API Integration: - RESTful API endpoints at /api/v1/chat - Session-based authentication for mobile apps - Comprehensive endpoints for rooms, messages, users - Mobile app compatibility (React Native, Flutter) 🛠️ Technical Improvements: - Enhanced database models with ChatRoom categories - Password reset token system with email verification - Template synchronization fixes for Docker deployment - Migration scripts for database schema updates - Improved error handling and validation 🎨 UI/UX Enhancements: - Modern card-based layouts matching app design - Consistent styling across chat and admin interfaces - Mobile-optimized touch interactions - Professional gradient designs and glass morphism effects 📚 Documentation: - Updated README with comprehensive API documentation - Added deployment instructions for Docker (port 8100) - Configuration guide for production environments - Mobile integration examples and endpoints This update transforms the platform into a comprehensive motorcycle adventure community with modern chat capabilities and professional admin management tools.
183 lines
5.3 KiB
HTML
183 lines
5.3 KiB
HTML
{% extends "base.html" %}
|
|
|
|
{% block title %}Reset Your Password - Moto Adventure{% endblock %}
|
|
|
|
{% block content %}
|
|
<div class="auth-container">
|
|
<div class="auth-card">
|
|
<div class="auth-header">
|
|
<img src="{{ url_for('static', filename='images/logo.png') }}" alt="Moto Adventure" class="auth-logo">
|
|
<h2>Reset Your Password</h2>
|
|
<p class="text-muted">Enter your new password below</p>
|
|
</div>
|
|
|
|
<div class="auth-body">
|
|
{% with messages = get_flashed_messages(with_categories=true) %}
|
|
{% if messages %}
|
|
{% for category, message in messages %}
|
|
<div class="alert alert-{{ 'danger' if category == 'error' else category }} alert-dismissible fade show" role="alert">
|
|
{{ message }}
|
|
<button type="button" class="btn-close" data-bs-dismiss="alert"></button>
|
|
</div>
|
|
{% endfor %}
|
|
{% endif %}
|
|
{% endwith %}
|
|
|
|
<!-- User Info -->
|
|
<div class="alert alert-info">
|
|
<i class="fas fa-user"></i>
|
|
Resetting password for: <strong>{{ user.nickname }}</strong> ({{ user.email }})
|
|
</div>
|
|
|
|
<form method="POST">
|
|
{{ form.hidden_tag() }}
|
|
|
|
<div class="form-group mb-3">
|
|
{{ form.password.label(class="form-label") }}
|
|
{{ form.password(class="form-control") }}
|
|
{% if form.password.errors %}
|
|
<div class="text-danger small mt-1">
|
|
{% for error in form.password.errors %}
|
|
<div>{{ error }}</div>
|
|
{% endfor %}
|
|
</div>
|
|
{% endif %}
|
|
<div class="form-text">
|
|
Password must be at least 8 characters long and contain both letters and numbers.
|
|
</div>
|
|
</div>
|
|
|
|
<div class="form-group mb-4">
|
|
{{ form.password2.label(class="form-label") }}
|
|
{{ form.password2(class="form-control") }}
|
|
{% if form.password2.errors %}
|
|
<div class="text-danger small mt-1">
|
|
{% for error in form.password2.errors %}
|
|
<div>{{ error }}</div>
|
|
{% endfor %}
|
|
</div>
|
|
{% endif %}
|
|
</div>
|
|
|
|
<div class="d-grid">
|
|
{{ form.submit(class="btn btn-primary btn-lg") }}
|
|
</div>
|
|
</form>
|
|
</div>
|
|
|
|
<div class="auth-footer">
|
|
<div class="text-center">
|
|
<a href="{{ url_for('auth.login') }}" class="text-decoration-none">
|
|
<i class="fas fa-arrow-left"></i> Back to Login
|
|
</a>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Security Features -->
|
|
<div class="container mt-4">
|
|
<div class="row justify-content-center">
|
|
<div class="col-md-6">
|
|
<div class="card border-warning">
|
|
<div class="card-body text-center">
|
|
<h6 class="card-title text-warning">
|
|
<i class="fas fa-shield-alt"></i> Security Notice
|
|
</h6>
|
|
<p class="card-text small text-muted mb-0">
|
|
This reset link can only be used once and will expire soon.
|
|
After resetting your password, you'll be able to log in immediately.
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<style>
|
|
.auth-container {
|
|
min-height: 100vh;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
|
padding: 20px;
|
|
}
|
|
|
|
.auth-card {
|
|
background: white;
|
|
border-radius: 15px;
|
|
box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
|
|
width: 100%;
|
|
max-width: 400px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.auth-header {
|
|
text-align: center;
|
|
padding: 40px 30px 30px;
|
|
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
|
color: white;
|
|
}
|
|
|
|
.auth-logo {
|
|
width: 60px;
|
|
height: 60px;
|
|
margin-bottom: 20px;
|
|
border-radius: 50%;
|
|
border: 3px solid white;
|
|
}
|
|
|
|
.auth-header h2 {
|
|
margin-bottom: 10px;
|
|
font-weight: 600;
|
|
}
|
|
|
|
.auth-body {
|
|
padding: 30px;
|
|
}
|
|
|
|
.auth-footer {
|
|
padding: 20px 30px;
|
|
background-color: #f8f9fa;
|
|
text-align: center;
|
|
}
|
|
|
|
.form-control {
|
|
border-radius: 8px;
|
|
border: 2px solid #e9ecef;
|
|
padding: 12px 15px;
|
|
transition: all 0.3s ease;
|
|
}
|
|
|
|
.form-control:focus {
|
|
border-color: #667eea;
|
|
box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
|
|
}
|
|
|
|
.btn-primary {
|
|
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
|
border: none;
|
|
border-radius: 8px;
|
|
padding: 12px;
|
|
font-weight: 600;
|
|
transition: all 0.3s ease;
|
|
}
|
|
|
|
.btn-primary:hover {
|
|
transform: translateY(-1px);
|
|
box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
|
|
}
|
|
|
|
@media (max-width: 576px) {
|
|
.auth-container {
|
|
padding: 10px;
|
|
}
|
|
|
|
.auth-header, .auth-body {
|
|
padding: 20px;
|
|
}
|
|
}
|
|
</style>
|
|
{% endblock %}
|