Revision cb0e91e4
Added by Serghei Mihai almost 11 years ago
| README.rst | ||
|---|---|---|
|
The configuration variable ``ckanext.ozwillo_theme.plugin.ozwillo_url`` must be
|
||
|
set(for example to https://ozwillo-preprod.eu)
|
||
|
|
||
|
The configuration variable ``ckanext.ozwillo_theme.plugin.ozwillo_portal_url``
|
||
|
must be set(for example to https://portal.ozwillo-preprod.eu)
|
||
|
|
||
|
------------
|
||
|
Installation
|
||
| ckanext/ozwillo_theme/plugin.py | ||
|---|---|---|
|
def update_config(self, config_):
|
||
|
set_global('ckan.ozwillo_url',
|
||
|
pconfig.get('%s.ozwillo_url' % __name__))
|
||
|
set_global('ckan.ozwillo_portal_url',
|
||
|
pconfig.get('%s.ozwillo_portal_url' % __name__))
|
||
|
|
||
|
toolkit.add_template_directory(config_, 'templates')
|
||
|
toolkit.add_public_directory(config_, 'public')
|
||
| ckanext/ozwillo_theme/templates/header.html | ||
|---|---|---|
|
<div class="t3-navbar navbar-collapse collapse">
|
||
|
<ul class="nav navbar-nav">
|
||
|
<li class="item-107 current"> <a class="logo" href="{{ g.ozwillo_url }}/{{current_lang}}"><img src="/img/logo-100.png" alt="{% trans %}Home{% endtrans %}"></a>
|
||
|
</li><li class="item-108"> <a class="nav-apps" href="{{ g.ozwillo_url }}/{{current_lang}}/store?ui_locales={{current_lang}}">{% trans %}Catalog{% endtrans %}</a>
|
||
|
</li><li class="item-108"> <a class="nav-apps" href="{{ g.ozwillo_portal_url }}/{{current_lang}}/store?ui_locales={{current_lang}}">{% trans %}Catalog{% endtrans %}</a>
|
||
|
</li>
|
||
|
<li class="item-119 deeper dropdown parent">
|
||
|
<a class="dropdown-toggle nav-data" href="#" data-toggle="dropdown">{% trans %}Data{% endtrans %}<b class="caret"></b></a>
|
||
| ... | ... | |
|
{% if c.userobj %}
|
||
|
<a class="btn navbar-btn" href="{{ h.url_for('/user/slo') }}">{% trans %}Log out{% endtrans %}</a>
|
||
|
{% else %}
|
||
|
<a class="btn navbar-btn" href="{{ g.ozwillo_url }}/{{current_lang}}/my">{% trans %}Log in{% endtrans %}</a>
|
||
|
<a class="btn navbar-btn" href="{{ g.ozwillo_portal_url }}/{{current_lang}}/my">{% trans %}Log in{% endtrans %}</a>
|
||
|
{% endif %}
|
||
|
</li>
|
||
|
<li class="item-112 deeper dropdown parent"><a class="dropdown-toggle" href="/en/oz/discover" data-toggle="dropdown">{% trans %}Discover{% endtrans %}<b class="caret"></b></a>
|
||
Also available in: Unified diff
distinct url for ozwillo portal