- Added dedicated route and view for reading individual notifications (/account/notifications/read) - Ensured notification is only marked as read if it hasn't already been - Updated Notification model to use Subject and Body fields - Fixed field references in templates (Title → Subject, Message → Body) - Updated topbar dropdown to use correct field names and display logic - Gracefully handle "notification not found" cases in template output - Ensured consistent template parsing with layout and topbar inclusion - Improved error logging for better diagnosis
23 lines
746 B
HTML
23 lines
746 B
HTML
{{ define "content" }}
|
|
<h2>Login</h2>
|
|
<form method="POST" action="/login" class="form">
|
|
{{ .CSRFField }}
|
|
|
|
<div class="mb-3">
|
|
<label for="username">Username:</label>
|
|
<input type="text" name="username" id="username" required class="form-control">
|
|
</div>
|
|
|
|
<div class="mb-3">
|
|
<label for="password">Password:</label>
|
|
<input type="password" name="password" id="password" required class="form-control">
|
|
</div>
|
|
|
|
<div class="form-check mb-3">
|
|
<input type="checkbox" name="remember" id="remember" class="form-check-input">
|
|
<label for="remember" class="form-check-label">Remember Me</label>
|
|
</div>
|
|
|
|
<button type="submit" class="btn btn-primary">Login</button>
|
|
</form>
|
|
{{ end }} |