fix: use parent id for card anchor
This commit is contained in:
parent
53d09a057e
commit
21a6f86402
2 changed files with 3 additions and 3 deletions
|
@ -19,7 +19,7 @@
|
|||
<relative-time datetime="{{ thread.created_at }}" precision="day">{{ thread.created_at }}</relative-time>
|
||||
</a>
|
||||
<span>·</span>
|
||||
<a href="{{ url_for('threads.thread', id=thread['id']) + '#' + thread['id'] }}">Anchor</a>
|
||||
<a href="{{ url_for('threads.thread', id=parent_id) + '#' + thread['id'] }}">Anchor</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -253,12 +253,12 @@
|
|||
<a href="{{url_for('threads.home')}}">Back</a>
|
||||
</div>
|
||||
{% for thread in threads %}
|
||||
{% with thread=thread, is_thread=threads|length > 1 %}
|
||||
{% with thread=thread, parent_id=thread.id, is_thread=threads|length > 1 %}
|
||||
{% include "card.html" %}
|
||||
{% endwith %}
|
||||
{% if thread.descendants is defined %}
|
||||
{% for descendant in thread.descendants %}
|
||||
{% with thread=descendant %}
|
||||
{% with thread=descendant, parent_id=thread.id %}
|
||||
{% include "card.html" %}
|
||||
{% endwith %}
|
||||
{% endfor %}
|
||||
|
|
Loading…
Reference in a new issue