-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- each has own plugin: odn_theme_ic, odn_theme_pc - added template css for each catalog - displaying actor name in header moved from "base" theme to IC theme plugin - added change log file
- Loading branch information
1 parent
190de1f
commit f0de88b
Showing
14 changed files
with
120 additions
and
46 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,8 @@ | ||
--------- | ||
Changelog | ||
--------- | ||
|
||
v1.2.0-SNAPSHOT 2015-9-11 | ||
|
||
Features: | ||
* added plugins for Internal and Public Catalog themes, where the odn_theme plugin is a common base |
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
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
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
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,7 @@ | ||
# this is a namespace package | ||
try: | ||
import pkg_resources | ||
pkg_resources.declare_namespace(__name__) | ||
except ImportError: | ||
import pkgutil | ||
__path__ = pkgutil.extend_path(__path__, __name__) |
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,16 @@ | ||
''' | ||
Created on 11.9.2015 | ||
@author: mvi | ||
''' | ||
import ckan.plugins as plugins | ||
import ckan.plugins.toolkit as toolkit | ||
|
||
class OdnThemeICPlugin(plugins.SingletonPlugin): | ||
'''ODN theme plugin for Internal Catalog | ||
''' | ||
plugins.implements(plugins.IConfigurer) | ||
|
||
def update_config(self, config): | ||
toolkit.add_template_directory(config, 'templates') # html (jinja2) | ||
toolkit.add_public_directory(config, 'public') # css and js |
Empty file.
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,9 @@ | ||
{% ckan_extends %} | ||
|
||
{%- block custom_styles %} | ||
<link rel="stylesheet" href="{{h.url_for_static('/css/odn_theme_ic.css')}}" /> | ||
{{ super() }} | ||
{% endblock %} | ||
|
||
|
||
|
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,39 @@ | ||
{% ckan_extends %} | ||
|
||
{% block header_account_logged %} | ||
{% if c.userobj.sysadmin %} | ||
<li> | ||
<a href="{{ h.url_for(controller='admin', action='index') }}" title="{{ _('Sysadmin settings') }}"> | ||
<i class="icon-legal"></i> | ||
</a> | ||
</li> | ||
{% endif %} | ||
<li> | ||
<a href="{{ h.url_for(controller='user', action='read', id=c.userobj.name) }}" class="image" title="{{ _('View profile') }}"> | ||
{{ h.gravatar((c.userobj.email_hash if c and c.userobj else ''), size=22) }} | ||
<span class="username">{{ h.user_display_name() }}</span> | ||
</a> | ||
</li> | ||
{% set new_activities = h.new_activities() %} | ||
<li class="notifications {% if new_activities > 0 %}notifications-important{% endif %}"> | ||
{% set notifications_tooltip = ngettext('Dashboard (%(num)d new item)', 'Dashboard (%(num)d new items)', new_activities) %} | ||
<a href="{{ h.url_for(controller='user', action='dashboard') }}" title="{{ notifications_tooltip }}"> | ||
<i class="icon-dashboard"></i> | ||
<span>{{ new_activities }}</span> | ||
</a> | ||
</li> | ||
{% block header_account_settings_link %} | ||
<li> | ||
<a href="{{ h.url_for(controller='user', action='edit', id=c.userobj.name) }}" title="{{ _('Edit settings') }}"> | ||
<i class="icon-cog"></i> | ||
</a> | ||
</li> | ||
{% endblock %} | ||
{% block header_account_log_out_link %} | ||
<li> | ||
<a href="{{ h.url_for('/user/_logout') }}" title="{{ _('Log out') }}"> | ||
<i class="icon-signout"></i> | ||
</a> | ||
</li> | ||
{% endblock %} | ||
{% endblock %} |
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,7 @@ | ||
# this is a namespace package | ||
try: | ||
import pkg_resources | ||
pkg_resources.declare_namespace(__name__) | ||
except ImportError: | ||
import pkgutil | ||
__path__ = pkgutil.extend_path(__path__, __name__) |
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,16 @@ | ||
''' | ||
Created on 11.9.2015 | ||
@author: mvi | ||
''' | ||
import ckan.plugins as plugins | ||
import ckan.plugins.toolkit as toolkit | ||
|
||
class OdnThemePCPlugin(plugins.SingletonPlugin): | ||
'''ODN theme plugin for Public Catalog | ||
''' | ||
plugins.implements(plugins.IConfigurer) | ||
|
||
def update_config(self, config): | ||
toolkit.add_template_directory(config, 'templates') # html (jinja2) | ||
toolkit.add_public_directory(config, 'public') # css and js |
Empty file.
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,9 @@ | ||
{% ckan_extends %} | ||
|
||
{%- block custom_styles %} | ||
<link rel="stylesheet" href="{{h.url_for_static('/css/odn_theme_pc.css')}}" /> | ||
{{ super() }} | ||
{% endblock %} | ||
|
||
|
||
|
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