diff options
author | Tor Andersson <tor@ccxvii.net> | 2021-11-09 21:26:10 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2021-11-09 22:59:49 +0100 |
commit | 86ee8f02d4230199378eb055a5a89c15844208c9 (patch) | |
tree | b994aa12092c2993541bfcd787cf67ff80347a8e /views/message_outbox.ejs | |
parent | eb12dd7700dfceff88d8d68acc720d86cdf90e05 (diff) | |
download | server-86ee8f02d4230199378eb055a5a89c15844208c9.tar.gz |
Messages.
Diffstat (limited to 'views/message_outbox.ejs')
-rw-r--r-- | views/message_outbox.ejs | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/views/message_outbox.ejs b/views/message_outbox.ejs new file mode 100644 index 0000000..c460bd3 --- /dev/null +++ b/views/message_outbox.ejs @@ -0,0 +1,23 @@ +<%- include('header', { title: "Outbox" }) %> +<style> +table { width: 100%; max-width: 50em; } +tr.unread { background-color: lemonchiffon; } +td.to { width: 5em; } +td.time { text-align: right; width: 5em; } +td a { color:black; text-decoration: none; } +</style> +<p> +» <a href="/message/send">Send message</a> +<br> +» <a href="/inbox">Inbox</a> +<table> +<tr><th>To<th>Subject<th>Date +<% if (messages.length > 0) { messages.forEach((row) => { %> +<tr class="<%- row.read ? "read" : "unread" %>"> +<td class="nowrap to"><%= row.to_name %> +<td class="subject"><a href="/message/read/<%- row.message_id %>"><%= row.subject %></a> +<td class="nowrap time"><%= row.time %> +<% }); } else { %> +<tr><td colspan="3">No messages</td> +<% } %> +</table> |