Skip to content

Commit

Permalink
Merge branch 'main' into INTR-447-export-search-as-csv
Browse files Browse the repository at this point in the history
  • Loading branch information
david-okeke1337 authored Dec 12, 2024
2 parents 16649b0 + 16808f7 commit 8c7fb3d
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 23 deletions.
43 changes: 21 additions & 22 deletions src/peoplefinder/templates/peoplefinder/profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -144,28 +144,27 @@ <h1 class="text-large" data-testid="full-name">{{ profile.full_name }}</h1>
<div class="dwds-content-list content-item">
<div class="content-main">
<div class="content-body content-body-space-padding content-stack">
{% if is_users_profile or current_tab.values %}
<div class="dwds-button-group">
{% for profile_section_dict in profile_section_dicts %}
<a class="dwds-button dwds-button--navigation {% if current_tab.value == profile_section_dict.profile_section.value %}active{% endif %}"
href="{{ profile_section_dict.url }}">{{ profile_section_dict.title }}</a>
{% endfor %}
</div>

<div class="content-stack">
<h2>{{ current_tab.title }}</h2>
{% if current_tab.values %}
<dl>
{% for value in current_tab.values %}
<dt>{{ value.1 }}</dt>
<dd>
{{ value.2 }}
</dd>
{% endfor %}
</dl>
{% endif %}
</div>
{% endif %}
<div class="dwds-button-group">
{% for profile_section_dict in profile_section_dicts %}
<a class="dwds-button dwds-button--navigation {% if current_tab.value == profile_section_dict.profile_section.value %}active{% endif %}"
href="{{ profile_section_dict.url }}">{{ profile_section_dict.title }}</a>
{% endfor %}
</div>
<div class="content-stack">
<h2>{{ current_tab.title }}</h2>
{% if current_tab.values %}
<dl>
{% for value in current_tab.values %}
<dt>{{ value.1 }}</dt>
<dd>
{{ value.2 }}
</dd>
{% endfor %}
</dl>
{% else %}
<p>{{ profile.first_name }} hasn't listed any {{ current_tab.title|lower }}.</p>
{% endif %}
</div>
</div>
</div>
</div>
Expand Down
1 change: 0 additions & 1 deletion src/peoplefinder/views/profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ def get_context_data(self, **kwargs: dict) -> dict:
profile = context["profile"]
roles = profile.roles.select_related("team").all()

context["is_users_profile"] = bool(self.request.user == profile.user)
context["roles"] = roles
context["title"] = profile.full_name

Expand Down

0 comments on commit 8c7fb3d

Please sign in to comment.