diff options
author | Vitaly Takmazov | 2020-01-31 16:49:39 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2020-01-31 16:49:39 +0300 |
commit | 3db482e11fc3cd7b299909d847e39f7f9ed88064 (patch) | |
tree | c4eb752c664562f4b45eafe3c9e85cb3f275886f | |
parent | 58c0ca3a79c9ad61184666a13e262499a5789bd1 (diff) |
Fix buttons, part 2
-rw-r--r-- | src/main/resources/templates/views/partial/message.html | 12 | ||||
-rw-r--r-- | src/main/resources/templates/views/thread.html | 12 |
2 files changed, 16 insertions, 8 deletions
diff --git a/src/main/resources/templates/views/partial/message.html b/src/main/resources/templates/views/partial/message.html index 132d1ea2..63ac9eb4 100644 --- a/src/main/resources/templates/views/partial/message.html +++ b/src/main/resources/templates/views/partial/message.html @@ -37,17 +37,21 @@ <a href="/{{ msg.mid }}" class="a-like msg-button"> <span class="msg-button-icon"> <i data-icon="ei-heart" data-size="s"></i> - {% if msg.likes > 0 %} {{ msg.likes }}{% endif %} + {% if msg.likes > 0 %} {{ msg.likes }} + {% else %} + <span> {{ i18n("messages","message.recommend") }}</span> + {% endif %} </span> - <span> {{ i18n("messages","message.recommend") }}</span> </a> {% elseif visitor.uid > 0 %} <a href="/post?body=!+%23{{ msg.mid }}" class="a-like msg-button"> <span class="msg-button-icon"> <i data-icon="ei-heart" data-size="s"></i> - {% if msg.likes > 0 %} {{ msg.likes }}{% endif %} + {% if msg.likes > 0 %} {{ msg.likes }} + {% else %} + <span> {{ i18n("messages","message.recommend") }}</span> + {% endif %} </span> - <span> {{ i18n("messages","message.recommend") }}</span> </a> {% else %} <a href="/login" class="a-login msg-button"> diff --git a/src/main/resources/templates/views/thread.html b/src/main/resources/templates/views/thread.html index 21c5a23c..f1563a7c 100644 --- a/src/main/resources/templates/views/thread.html +++ b/src/main/resources/templates/views/thread.html @@ -44,17 +44,21 @@ <a href="/{{ msg.mid }}" class="a-like msg-button"> <span class="msg-button-icon"> <i data-icon="ei-heart" data-size="s"></i> - {% if msg.Likes > 0 %} {{ msg.Likes }}{% endif %} + {% if msg.Likes > 0 %} {{ msg.Likes }} + {% else %} + <span> {{ i18n("messages","message.recommend") }}</span> + {% endif %} </span> - <span> {{ i18n("messages","message.recommend") }}</span> </a> {% elseif visitor.uid > 0 %} <a href="/post?body=!+%23{{ msg.mid }}" class="a-like msg-button"> <span class="msg-button-icon"> <i data-icon="ei-heart" data-size="s"></i> - {% if msg.Likes > 0 %} {{ msg.Likes }}{% endif %} + {% if msg.Likes > 0 %} {{ msg.Likes }} + {% else %} + <span> {{ i18n("messages","message.recommend") }}</span> + {% endif %} </span> - <span> {{ i18n("messages","message.recommend") }}</span> </a> {% else %} <a href="/login" class="a-login msg-button"> |