Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fix: remove outdated c. references #144

Merged
merged 2 commits into from
Feb 5, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions ckanext/switzerland/templates/showcase/manage_datasets.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
<div class="module-content">
{% set title_string = 'title_string_' ~ h.lang() %}
{% set facets = {
'fields': c.fields_grouped,
'search': c.search_facets,
'titles': c.facet_titles,
'translated_fields': c.translated_fields,
'remove_field': c.remove_field }
'fields': fields_grouped,
'search': search_facets,
'titles': facet_titles,
'translated_fields': translated_fields,
'remove_field': remove_field }
%}
{% set sorting = [
(_('Relevance'), 'score desc, metadata_modified desc'),
Expand All @@ -28,15 +28,15 @@
(_('Last Modified'), 'metadata_modified desc'),
(_('Popular'), 'views_recent desc') if g.tracking_enabled else (false, false) ]
%}
{% snippet 'snippets/search_form.html', type='dataset', query=c.q, sorting=sorting, sorting_selected=c.sort_by_selected, count=c.page.item_count, facets=facets, show_empty=request.args, error=c.query_error, fields=c.fields %}
{% snippet 'snippets/search_form.html', type='dataset', query=q, sorting=sorting, sorting_selected=sort_by_selected, count=page.item_count, facets=facets, show_empty=request.args, error=query_error, fields=fields %}
</div>

<div class="row row2">
<section class="span6">
<div class="module-content">
<h3 class="page-heading">{{ _('Datasets available to add to this showcase') }}</h3>
{% block package_search_results_list %}
{% if c.page.items %}
{% if page.items %}
<form method="POST" data-module="basic-form">
{{ h.csrf_input() if 'csrf_input' in h }}
{#{% block errors %}{{ form.errors(error_summary) }}{% endblock %}#}
Expand All @@ -57,7 +57,7 @@ <h3 class="page-heading">{{ _('Datasets available to add to this showcase') }}</
</tr>
</thead>
<tbody>
{% for package in c.page.items %}
{% for package in page.items %}
{% set truncate = truncate or 180 %}
{% set truncate_title = truncate_title or 80 %}
{% set title = h.parse_and_localize(package.title) or package.name %}
Expand All @@ -78,10 +78,10 @@ <h3 class="dataset-heading">
</tr>
{% endfor %}
</tbody>
{% if c.page.pager() %}
{% if page.pager() %}
<tfoot>
<tr>
<td colspan="2" class="ckanext_showcase_pagination_footer">{{ c.page.pager(q=c.q) }}</td>
<td colspan="2" class="ckanext_showcase_pagination_footer">{{ page.pager(q=q) }}</td>
</tr>
</tfoot>
{% endif %}
Expand All @@ -97,7 +97,7 @@ <h3 class="dataset-heading">
<section class="span6">
<div class="module-content">
<h3 class="page-heading">{{ _('Datasets in this showcase') }}</h3>
{% if c.showcase_pkgs %}
{% if showcase_pkgs %}
<form method="POST" data-module="basic-form">
{{ h.csrf_input() if 'csrf_input' in h }}
<table class="table table-bordered table-header table-hover table-bulk-edit table-edit-hover" data-module="table-selectable-rows">
Expand All @@ -117,7 +117,7 @@ <h3 class="page-heading">{{ _('Datasets in this showcase') }}</h3>
</tr>
</thead>
<tbody>
{% for package in c.showcase_pkgs %}
{% for package in showcase_pkgs %}
{% set truncate = truncate or 180 %}
{% set truncate_title = truncate_title or 80 %}
{% set title = h.parse_and_localize(package.title) or package.name %}
Expand Down
2 changes: 1 addition & 1 deletion ckanext/switzerland/tests/test_ftp_storage_adapter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# encoding: utf-8

"""Tests for the ckanext.switzerland.ftp_helper.py """
"""Tests for the ckanext.switzerland.ftp_helper.py"""

import logging
import os
Expand Down
Loading