From f972745ac092a1657d40d9fb01f7c68508a7c416 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Mon, 3 Oct 2022 16:30:13 +0200 Subject: Add contact list with friends and blacklisted users. --- views/user.pug | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'views/user.pug') diff --git a/views/user.pug b/views/user.pug index 4c26716..545d1ab 100644 --- a/views/user.pug +++ b/views/user.pug @@ -25,9 +25,19 @@ html p Member since #{who.ctime}. p Last seen #{who.atime}. - if user + + if user && (who.user_id !== user.user_id) p a(href="/message/send/"+who.name) Send message + br + if relation > 0 + a(href="/contact/remove-user/"+who.name) Remove from friends + else if relation < 0 + a(href="/contact/remove-user/"+who.name) Remove from blacklist + else + a(href="/contact/add-friend/"+who.name) Add to friends + br + a(href="/contact/add-enemy/"+who.name) Blacklist user if open_games.length > 0 h2 Open -- cgit v1.2.3