% if PraiseTread.praised(activity) %>
赞
<% num = activity.praise_tread_cache ? activity.praise_tread_cache.praise_num : 0 %>
<%= (num.nil? ? 0 : num) > 0 ? "(#{(num.nil? ? 0 : num)})" : "" %>
<% else %>
已赞
<% num = activity.praise_tread_cache ? activity.praise_tread_cache.praise_num : 0 %>
<%= (num.nil? ? 0 : num) > 0 ? "(#{(num.nil? ? 0 : num)})" : "" %>
<% end %>