This repository has been archived by the owner on Mar 5, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Stop using included page for contacts & people
- Loading branch information
Showing
2 changed files
with
111 additions
and
3 deletions.
There are no files selected for viewing
110 changes: 110 additions & 0 deletions
110
contacts_and_people/templates/contacts_and_people/contacts_and_people.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
{% extends entity.get_template %} | ||
{% comment %} | ||
|
||
Extends the base page template, and includes the main_page_body_file specified in the view. | ||
|
||
{% endcomment %} | ||
{% load typogrify_tags entity_tags thumbnail placeholder_tags %} | ||
|
||
{% block title %} | ||
<title>{{ title }}</title> | ||
{% endblock %} | ||
|
||
{% block col_class %} | ||
{% with is_menu_node="True" %} | ||
{{ block.super }} | ||
{% endwith %} | ||
{% endblock col_class %} | ||
|
||
{% block skip_and_language %} | ||
{% endblock %} | ||
|
||
{% if pagetitle %} | ||
{% block pagetitle %} | ||
<h{{PAGE_TITLE_HEADING_LEVEL}}>{{ pagetitle|typogrify }}</h{{PAGE_TITLE_HEADING_LEVEL}}> | ||
{% endblock pagetitle %} | ||
{% endif %} | ||
|
||
{% block main_page_body %} | ||
|
||
{% thumbnail entity.image.file entity_image_size crop subject_location=entity.image.subject_location as image %} | ||
|
||
{% block arkestra_content %} | ||
|
||
<div class="row columns2"> | ||
{% render_placeholder intro_page_placeholder %} | ||
|
||
<div class="column firstcolumn"> | ||
<div class = ""> | ||
<h{{ IN_BODY_HEADING_LEVEL }}>Contact information</h{{ IN_BODY_HEADING_LEVEL }}> | ||
<dl class="not-indented"> | ||
{% include "includes/key_contacts.html" %} | ||
{% with entity_map_size as map_size %} | ||
{% include "includes/contact_information.html" %} | ||
{% endwith %} | ||
</dl> | ||
{% if image %}<img src="{{ image.url }}" alt = "" class="right"/>{% endif %} | ||
</div> | ||
</div> | ||
|
||
{% if entity.get_people_with_roles or initials_list or people %} | ||
<div class="column lastcolumn"> | ||
{% block people_search %} | ||
<h{{ IN_BODY_HEADING_LEVEL }}>Person search</h{{ IN_BODY_HEADING_LEVEL }}> | ||
<form action="" method="GET" class="filter-form"> | ||
{% for field in search_fields %} | ||
<div> | ||
<label for="{{ field.field_name }}"> | ||
<span class="label-text">{{ field.field_label }}:</span> | ||
</label> | ||
|
||
<input placeholder="{{ field.placeholder }}" type="search" name="{{ field.field_name }}" value="{{ field.value }}"> <input type="submit" value="Search"> | ||
|
||
</div> | ||
{% endfor %} | ||
</form> | ||
{% endblock people_search %} | ||
{% if search %} | ||
{% if people_qs %} | ||
{% with people_qs as people %} | ||
{% include "includes/people_with_roles.html" %} | ||
{% endwith %} | ||
{% else %} | ||
<p>No matching results</p> | ||
{% endif %} | ||
{% else %} | ||
{% if entity.get_key_people %} | ||
<div class=""> | ||
<h{{ IN_BODY_HEADING_LEVEL }}>Key people</h{{ IN_BODY_HEADING_LEVEL }}> | ||
{% regroup entity.get_key_people by role as roles %} | ||
<dl class="not-indented personlist"> | ||
{% for role in roles %} | ||
<dt>{{ role.grouper }}</dt> | ||
{% for person in role.list %} | ||
{% thumbnail person.person.image.file person_thumbnail_size subject_location=person.person.image.subject_location crop as personimage %} | ||
<dd class="row"><a href ="{{ person.person.get_absolute_url }}">{{person.person}}{% if personimage %} <img class="right" alt="" src="{{ personimage.url }}" />{% endif %}</a></dd> | ||
{% endfor %} | ||
{% endfor %} | ||
</dl> | ||
</div> | ||
{% endif %} | ||
{% endif %} | ||
{% if initials_list %} | ||
<h{{ IN_BODY_HEADING_LEVEL }}>All people A-Z by surname</h{{ IN_BODY_HEADING_LEVEL }}> | ||
<ul class= "index"> | ||
{% for initial in initials_list %} | ||
<li><a href="{% url contact-people-letter entity.slug,initial|lower %}">{{ initial }}</a></li> | ||
{% endfor %} | ||
</ul> | ||
{% endif %} | ||
{% if people %} | ||
<h{{ IN_BODY_HEADING_LEVEL }}>{{ people_list_heading }}</h{{ IN_BODY_HEADING_LEVEL }}> | ||
{% include "includes/people_with_roles.html" %} | ||
{% endif %} | ||
</div> | ||
{% endif %} | ||
</div> | ||
{% endblock arkestra_content %} | ||
|
||
|
||
{% endblock main_page_body %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters