related tags: fix AI tags not showing rating tags.

* Fix the suggested tags list in the related tags box not showing rating tags.
* Fix the suggested tags list showing tags that have been aliased to another tag.
This commit is contained in:
evazion
2022-07-02 19:05:12 -05:00
parent 483f311428
commit 9000fa63bc
4 changed files with 20 additions and 4 deletions

View File

@@ -5,12 +5,14 @@
</h3>
<ul class="tag-list simple-tag-list">
<% ai_tags.each do |t| %>
<% ai_tags.each do |ai_tag| %>
<li class="flex items-center space-x-1">
<input type="checkbox" tabindex="-1">
<span>
<% t = ai_tag.is_aliased? ? ai_tag.aliased_tag : ai_tag.tag %>
<%= link_to t.pretty_name, posts_path(tags: t.name), class: "search-tag tag-type-#{t.category}", "data-tag-name": t.name %>
<%= tag.span "#{t.score}%", class: "text-muted text-xs" %>
<%= tag.span "#{ai_tag.score}%", class: "text-muted text-xs" %>
</span>
</li>
<% end %>