Skip to content

Commit

Permalink
Merge branch 'resource-metadata' into staging
Browse files Browse the repository at this point in the history
  • Loading branch information
RabiaSajjad committed Oct 22, 2024
2 parents efd8346 + 74178f8 commit 587628d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
1 change: 1 addition & 0 deletions changes/1523.changes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Display resource metadata such as Language, Format etc. on the resource page under 'Additional Information'.
23 changes: 18 additions & 5 deletions ckanext/canada/templates/scheming/package/resource_read.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,23 @@ <h2 id="additional-info">{{ _('Additional Information') }}</h2>

{% block additional_info_table_head %}{% endblock %}

{%- block resource_last_updated -%}{%- endblock -%}

{% block resource_metadata_last_updated %}{% endblock %}

{% block resource_more_items %}{% endblock %}

{% block resource_fields %}{% endblock %}
{%- block resource_fields -%}
{%- for field in schema.resource_fields -%}
{%- if field.field_name not in exclude_fields
and field.display_snippet is not none
and res[field.field_name] -%}
<tr>
<th scope="row">
{{- h.scheming_language_text(field.label) -}}
</th>
<td>
{%- snippet 'scheming/snippets/display_field.html',
field=field, data=res, entity_type='dataset',
object_type=dataset_type -%}
</td>
</tr>
{%- endif -%}
{%- endfor -%}
{%- endblock -%}

0 comments on commit 587628d

Please sign in to comment.