feat(newsletter): Add subscription confirmation email functionality
- Implemented `send_subscription_confirmation` function to send a confirmation email upon subscription. - Added a default HTML template for the confirmation email in settings. - Updated the newsletter management page to handle subscription and unsubscription actions. - Created new templates for embedding contact and newsletter forms. - Added styles for the new templates and unified CSS styles across the application. - Updated tests to reflect changes in the newsletter management API endpoints.
This commit is contained in:
@@ -4,27 +4,14 @@
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Admin Login</title>
|
||||
<link rel="stylesheet" href="/static/css/styles.css" />
|
||||
<style>
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
margin: 40px;
|
||||
}
|
||||
form {
|
||||
.login-form {
|
||||
max-width: 300px;
|
||||
margin: auto;
|
||||
margin: 40px auto;
|
||||
}
|
||||
input {
|
||||
display: block;
|
||||
.login-form input {
|
||||
margin: 10px 0;
|
||||
padding: 8px;
|
||||
width: 100%;
|
||||
}
|
||||
button {
|
||||
padding: 10px;
|
||||
background: #007bff;
|
||||
color: white;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
.flash {
|
||||
color: red;
|
||||
@@ -34,13 +21,22 @@
|
||||
<body>
|
||||
<h1>Admin Login</h1>
|
||||
{% with messages = get_flashed_messages() %} {% if messages %}
|
||||
<div class="flash">
|
||||
<div class="message error">
|
||||
{% for message in messages %} {{ message }} {% endfor %}
|
||||
</div>
|
||||
{% endif %} {% endwith %}
|
||||
<form method="post">
|
||||
<input type="text" name="username" placeholder="Username" required />
|
||||
<input type="password" name="password" placeholder="Password" required />
|
||||
<form method="post" class="login-form">
|
||||
<div class="form-group">
|
||||
<input type="text" name="username" placeholder="Username" required />
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<input
|
||||
type="password"
|
||||
name="password"
|
||||
placeholder="Password"
|
||||
required
|
||||
/>
|
||||
</div>
|
||||
<button type="submit">Login</button>
|
||||
</form>
|
||||
</body>
|
||||
|
||||
Reference in New Issue
Block a user