forked from ckan/ckan-docker
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Temporarily display only the license. Future updates will incorporate…
… URL and title. #50
- Loading branch information
1 parent
96d1c4a
commit f275bae
Showing
1 changed file
with
33 additions
and
0 deletions.
There are no files selected for viewing
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,33 @@ | ||
{% macro license_string(pkg_dict) %} | ||
{% if pkg_dict.license %} | ||
<span property="dc:rights">{{ pkg_dict.license }}</span> | ||
{% else %} | ||
<span>{{ _('No License Provided') }}</span> | ||
{% endif %} | ||
{% endmacro %} | ||
|
||
{% block license %} | ||
{% if text_only %} | ||
{{ license_string(pkg_dict) }} | ||
{% else %} | ||
{% block license_wrapper %} | ||
<section class="module module-narrow module-shallow license"> | ||
{% block license_title %} | ||
<h2 class="module-heading"><i class="fa fa-lock"></i> {{ _('License') }}</h2> | ||
{% endblock %} | ||
{% block license_content %} | ||
<p class="module-content"> | ||
{% block license_content_inner %} | ||
{{ license_string(pkg_dict) }} | ||
{% if pkg_dict.isopen %} | ||
<a href="http://opendefinition.org/okd/" title="{{ _('This dataset satisfies the Open Definition.') }}"> | ||
<img class="open-data" src="{{ h.url_for_static('/base/images/od_80x15_blue.png') }}" alt="[Open Data]" /> | ||
</a> | ||
{% endif %} | ||
{% endblock %} | ||
</p> | ||
{% endblock %} | ||
</section> | ||
{% endblock %} | ||
{% endif %} | ||
{% endblock %} |