Extension Grouphierarchy Sddi


Extension Basics

Title
Grouphierarchy Sddi
Name
ckanext-grouphierarchy-sddi
Type
Public extension
Description
The **ckanext-grouphierarchy-sddi** extension enhances CKAN's group management capabilities by intr
CKAN versions

~2.8.0, ~2.9.0

Show details
Download-Url (zip)
Last commit
a year ago (2024-04-17 10:38:14)
Url to repo
Category
Visualization & Analytics


Background Infos

Description (long)
Show details

ckanext-grouphierarchy

Overview

This extension is based on the ckanext-hierarchy extension. The ckanext-grouphierarchy-sddi extension requires ckanext-hierarchy extension. The ckanext-grouphierarchy-sddi extension is tested with v1.2.0 of the ckanext-hierarchy extension.

The ckanext-grouphierarchy provides a new field on the group edit form to select a parent group. This new hierarchical arrangement of groups is displayed using templates in this extension, instead of the usual list. An group page also displays the section of the tree. This version (0.2) of this extension also supports the group labeling on the dataset page and on the search page where the datasets are listed. Please note the labeling is only for the main group [id=’main-categories’] including 9 sub-groups/children.

Forms (hierachy_form plugin):

  • /group/new
  • /group/edit/{id}

Templates (hierarchy_display plugin):

  • /group - now shows the group hierarchy instead of list
  • /group/about/{id} - now also shows the relevant part of the hierarchy

Please note that the categories of groups are hard coded. github.com/tum-gis/ckanext-grouphierarchy-sddi/blob/master/ckanext/grouphierarchy/templates/group/snippets/group_list.html

Snippets (used by hierarchy_display and ckanext-scheming):

  • /scheming/form_snippets/group_hierarchy.html

You can use this extension with CKAN as it is, enabling both plugins. Or if you use an extension to customise the form already with an IGroupForm, then you will want to only use the hierarchy_display plugin, and copy bits of the hierarchy_form into your own. If you have your own templates then you can use the snippets (or logic functions) that this extension provides to display the trees.

In order to make hierarchy works with ckanext-scheming you need to enable just hierarchy_display and then use corresponding form_snippet in

Version
1.1.4
Version release date
2024-04-17
Contact name
Chair of Geoinformatics, Technical University of Munich
Contakt email
(not set)
Contact Url
(not set)


Installation Guide

Configuration hints

Install the extension in your python environment.

$ . /usr/lib/ckan/default/bin/activate
(pyenv) $ cd /usr/lib/ckan/default/src
(pyenv) $ pip install -e "git+https://tum-gis/ckanext-grouphierarchy-sddi.git#egg=ckanext-grouphierarchy-sddi"

Then change your CKAN ini file (e.g. development.ini or production.ini). Note that display_group should come before form_group

ckan.plugins = stats text_view recline_view ... display_group
Plugins to configure (ckan.ini)
stats text_view recline_view
CKAN Settings (ckan.ini)
# ckanext.grouphierarchy.init_data=/path/to/init_data.json
# ckanext.grouphierarchy.init_data=init_data.json
# ckanext.grouphierarchy.init_data=my_init_data.json
# ckanext.grouphierarchy.init_data=https://url/to/init_data.json
DB migration to be executed
(not set)
<< back to Extensions