feat: added get_profile_url function to get the profile url in templates

This takes care of generating the correct profile URL depending on the
`profile_url_prefix` setting.

Issue #192
This commit is contained in:
Anand Chitipothu
2021-09-07 16:57:35 +05:30
parent 77c4b53b71
commit a0b77f5d08
9 changed files with 13 additions and 15 deletions

View File

@@ -3,7 +3,7 @@
<div class="d-flex align-items-center muted-text">
{% set member = frappe.get_doc("User", reply.owner) %}
{{ widgets.Avatar(member=member, avatar_class="avatar-small")}}
<a class="button-links ml-2" href="/user/{{ member.username }}">
<a class="button-links ml-2" href="{{ get_profile_url(member.username) }}">
{{ member.full_name }}
</a>
<div class="ml-2 frappe-timestamp" data-timestamp="{{ reply.creation }}"> just now </div>