diff --git a/templates/notifications/dashboard.html b/templates/notifications/dashboard.html new file mode 100644 index 0000000..3425fbd --- /dev/null +++ b/templates/notifications/dashboard.html @@ -0,0 +1,89 @@ +{% extends "shared/base.html" %} +{% load static %} + +{% block content %} +{% include "shared/navbar.html" %} + +
+
+
+

Notifications

+ View All +
+ + +
+
+
Pending
+
{{ pending_count }}
+
Waiting to be sent
+
+ +
+
Sent
+
{{ sent_count }}
+
Successfully delivered
+
+ +
+
Failed
+
{{ failed_count }}
+
Need attention
+
+
+ + +
+
+

Recent Notifications

+ View All +
+
+ + + + + + + + + + + + {% for n in recent_notifications %} + + + + + + + + {% empty %} + + + + {% endfor %} + +
RecipientSubjectStatusCreatedSent At
{{ n.recipient }} + + {{ n.subject }} + + + + {{ n.get_status_display }} + + + {{ n.created_at|date:"M d, Y H:i" }} + + {% if n.sent_at %}{{ n.sent_at|date:"M d, Y H:i" }}{% else %}-{% endif %} +
No notifications yet.
+
+
+
+
+{% endblock %} + + diff --git a/templates/notifications/notification_detail.html b/templates/notifications/notification_detail.html new file mode 100644 index 0000000..71b4aa1 --- /dev/null +++ b/templates/notifications/notification_detail.html @@ -0,0 +1,71 @@ +{% extends "shared/base.html" %} +{% load static %} + +{% block content %} +{% include "shared/navbar.html" %} + +
+
+
+

Notification Detail

+
+ +
+
+

Recipient

+

{{ notification.recipient }}

+
+ +
+

Subject

+

{{ notification.subject }}

+
+ +
+

Status

+ + {{ notification.get_status_display }} + +
+ +
+
+

Created At

+

+ {{ notification.created_at|date:"M d, Y H:i" }} +

+
+
+

Sent At

+

+ {% if notification.sent_at %}{{ notification.sent_at|date:"M d, Y H:i" }}{% else %}-{% endif %} +

+
+
+ +
+

Message

+
{{ notification.message }}
+
+ + {% if notification.content_object %} +
+

Related Object

+

+ {{ notification.content_type }} — ID {{ notification.object_id }} +

+
+ {% endif %} + + +
+
+
+{% endblock %} + + diff --git a/templates/notifications/notification_list.html b/templates/notifications/notification_list.html new file mode 100644 index 0000000..96bd326 --- /dev/null +++ b/templates/notifications/notification_list.html @@ -0,0 +1,63 @@ +{% extends "shared/base.html" %} +{% load static %} + +{% block content %} +{% include "shared/navbar.html" %} + +
+
+
+

All Notifications

+ Back to Dashboard +
+ +
+
+ + + + + + + + + + + + {% for n in notifications %} + + + + + + + + {% empty %} + + + + {% endfor %} + +
RecipientSubjectStatusCreatedSent At
{{ n.recipient }} + + {{ n.subject }} + + + + {{ n.get_status_display }} + + + {{ n.created_at|date:"M d, Y H:i" }} + + {% if n.sent_at %}{{ n.sent_at|date:"M d, Y H:i" }}{% else %}-{% endif %} +
No notifications found.
+
+
+
+
+{% endblock %} + +