Skip to content
Snippets Groups Projects
Commit b8716281 authored by chbaeh's avatar chbaeh
Browse files

ODPSH-51: change organization layout

parent 486271e4
No related branches found
No related tags found
No related merge requests found
......@@ -108,10 +108,16 @@ class OdshPlugin(plugins.SingletonPlugin, DefaultTranslation, DefaultDatasetForm
'groups': _('Kategorie')})
def organization_facets(self, facets_dict, organization_type, package_type):
return facets_dict
return OrderedDict({'organization': _('Herausgeber'),
'res_format': _('Dateiformat'),
'license_title': _('Lizenz'),
'groups': _('Kategorie')})
def group_facets(self, facets_dict, group_type, package_type):
return facets_dict
return OrderedDict({'organization': _('Herausgeber'),
'res_format': _('Dateiformat'),
'license_title': _('Lizenz'),
'groups': _('Kategorie')})
def _fields(self):
# return ['title','notes','tag_string']
......
......@@ -73,6 +73,21 @@ h1{
padding-bottom: 5px;
}
#organization-datasets-search-form,
.with-bottom-line
{
border-bottom: 2px solid #dbdbdb;
}
#organization-datasets-search-form h2 {
color:black;
font-size:18px;
}
.organizaion-full-description{
padding-bottom: 50px;
}
.organization-list-title .search-form {
padding-bottom: 0px;
margin-bottom: 0px;
......@@ -140,7 +155,7 @@ input[type=radio], input[type=checkbox] {
}
.primary {
padding-left: 10px;
padding-left: 20px;
}
.primary.organization {
......@@ -895,7 +910,15 @@ label:after {
.pagination ul > li > a:hover,
.pagination ul > li > a:focus,
.pagination ul > .active > a,
.pagination ul > .active > span {
.pagination ul > .active > span,
.pagination ul > li:first-child.active > a,
.pagination ul > li:first-child.active > span,
.pagination ul > li:first-child.active > a:hover,
.pagination ul > li:first-child.active > span:hover,
.pagination ul > li:last-child.active > a,
.pagination ul > li:last-child.active > span,
.pagination ul > li:last-child.active > a:hover,
.pagination ul > li:last-child.active > span:hover {
background-color: #003064;
color: white;
}
......@@ -960,3 +983,10 @@ label:after {
text-align: left;
display: inherit;
}
@media (min-width: 768px){
.span9 div.module-content {
padding-left: 0px;
}
}
\ No newline at end of file
{% extends "organization/read_base.html" %}
{% block page_primary_action %}
{% if h.check_access('package_create', {'owner_org': c.group_dict.id}) %}
{% link_for _('Add Dataset'), controller='package', action='new', group=c.group_dict.id, class_='btn btn-primary',
icon='plus-square' %}
{% endif %}
{% endblock %}
{% block primary_content_inner %}
{% block groups_search_form %}
{% set facets = {
'fields': c.fields_grouped,
'search': c.search_facets,
'titles': c.facet_titles,
'translated_fields': c.translated_fields,
'remove_field': c.remove_field }
%}
{% set sorting = [
(_('Relevance'), 'score desc, metadata_modified desc'),
(_('Name Ascending'), 'title_string asc'),
(_('Name Descending'), 'title_string desc'),
(_('Last Modified'), 'metadata_modified desc'),
(_('Popular'), 'views_recent desc') if g.tracking_enabled else (false, false) ]
%}
{% snippet 'snippets/search_form.html', form_id='organization-datasets-search-form', type='dataset', query=c.q,
sorting=sorting, sorting_selected=c.sort_by_selected, count=c.page.item_count, facets=facets, placeholder=_('Search
datasets...'), show_empty=request.params, fields=c.fields, force_title=_('Datasets') %}
{% endblock %}
{% block packages_list %}
{% if c.page.items %}
{{ h.snippet('snippets/package_list.html', packages=c.page.items) }}
{% endif %}
{% endblock %}
{% block page_pagination %}
{{ c.page.pager(q=c.q) }}
{% endblock %}
{% endblock %}
{% block organization_facets %}
{% set url = h.url_for(c.group_dict.type ~ '_read', action='read', id=c.group_dict.id) %}
<div class="filters">
<div class="container-fluid filter-reset">
<div class="filter-reset-label"><span>Filter:</span></div>
<div class="filter-reset-box"><a href="{{url}}">zurücksetzen</a></button></div>
</div>
<div>
{% for facet in c.facet_titles %}
{{ h.snippet('snippets/facet_list.html', title=c.facet_titles[facet], name=facet,
extras={'id':c.group_dict.id}) }}
{% endfor %}
</div>
<a class="close no-text hide-filters"><i class="fa fa-times-circle"></i><span class="text">close</span></a>
</div>
{% endblock %}
\ No newline at end of file
{% extends "page.html" %}
{% block subtitle %}{{ c.group_dict.display_name }} - {{ _('Organizations') }}{% endblock %}
{% block breadcrumb_content %}
<li>{% link_for _('Organizations'), controller='organization', action='index' %}</li>
<li class="active">{% link_for c.group_dict.display_name|truncate(35), controller='organization', action='read',
id=c.group_dict.name %}</li>
{% endblock %}
{% block content_action %}
{% endblock %}
{% block page_header %}
<div class="odsh-dataset-heading">
<div class="pull-right">
{% if h.check_access('organization_update', {'id': c.group_dict.id}) %}
{% link_for _('Manage'), controller='organization', action='edit', id=c.group_dict.name, class_='btn',
icon='wrench' %}
{% endif %}
</div>
<h2> {{ c.group_dict.title or c.group_dict.name }} </h2>
</div>
{% if c.group_dict.description %}
<p class="organizaion-full-description with-bottom-line">
{{ h.markdown_extract(c.group_dict.description) }}
</p>
{% else %}
<p class="empty">{{ _('There is no description for this organization') }}</p>
{% endif %}
{% endblock %}
{% block secondary_content %}
{% block organization_facets %}{% endblock %}
{% endblock %}
{% block links %}
{{ super() }}
{% include "organization/snippets/feeds.html" %}
{% endblock %}
\ No newline at end of file
......@@ -36,8 +36,8 @@ Example:
</a>
</div>
{% endblock %}
{% block description %}
{% if not hide_description %}
{% block description %}
{% if organization.description %}
<p>
{{ h.markdown_extract(organization.description, 180) }}
......@@ -46,8 +46,8 @@ Example:
{% else %}
<p class="empty">{{ _('There is no description for this organization') }}</p>
{% endif %}
{% endif %}
{% endblock %}
{% endif %}
{% if show_nums %}
{% block nums %}
<div class="nums">
......
......@@ -39,7 +39,11 @@
{% block search_title %}
{% if not error %}
{% if force_title %}
<h2>{{force_title }}</h2>
{% else %}
<h2>{% snippet 'snippets/search_result_text.html', query=query, count=count, type=type %}</h2>
{% endif %}
{% else %}
<h2>Error</h2>
{% endif %}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment