Implement user and channel tags for intersections
This commit is contained in:
parent
f0c548db6f
commit
a56042376c
|
@ -101,6 +101,11 @@
|
||||||
<i class="fa-solid fa-user" aria-hidden="true"></i>
|
<i class="fa-solid fa-user" aria-hidden="true"></i>
|
||||||
</span>
|
</span>
|
||||||
{{ user }}
|
{{ user }}
|
||||||
|
{% if channel in num_users %}
|
||||||
|
<span class="tag">
|
||||||
|
{{ num_chans|index:user }}
|
||||||
|
</span>
|
||||||
|
{% endif %}
|
||||||
</a>
|
</a>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
|
@ -112,6 +117,11 @@
|
||||||
<i class="fa-solid fa-hashtag" aria-hidden="true"></i>
|
<i class="fa-solid fa-hashtag" aria-hidden="true"></i>
|
||||||
</span>
|
</span>
|
||||||
{{ channel }}
|
{{ channel }}
|
||||||
|
{% if nick in num_chans %}
|
||||||
|
<span class="tag">
|
||||||
|
{{ num_users|index:channel }}
|
||||||
|
</span>
|
||||||
|
{% endif %}
|
||||||
</a>
|
</a>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -2,6 +2,7 @@ from django import template
|
||||||
|
|
||||||
register = template.Library()
|
register = template.Library()
|
||||||
|
|
||||||
|
|
||||||
@register.filter
|
@register.filter
|
||||||
def index(h, key):
|
def index(h, key):
|
||||||
return h[key]
|
return h[key]
|
Loading…
Reference in New Issue