Comments (3)
If you have more than 20, but not a ton I do have a workaround:
The underlying issue is that the organization list display controller (in base ckan) is set to return a specified number of items per page. It searches and finds the matching organizations (limited to 21 items per page) and passes them to the hierarchy plugin to display. The hierarchy plugin then tries to build the tree, but it is missing pieces because of the per page limit.
The easiest solution is to edit the CKAN group controller here to be a number larger than your number of organizations:
https://github.com/ckan/ckan/blob/197f9b19254dad3056d1418d4bbfc5c604b39c4e/ckan/controllers/group.py#L144
FYI, It looks like future versions of CKAN will use the datasets_per_page config variable to determine the limit.
from ckanext-hierarchy.
Is there a work around for this as I have the same problem?
from ckanext-hierarchy.
Thanks for the tip but when you think about it, pagination don't make sens with this module as it will always break the display of the tree.
I tried to use the following in templates/organization/index.html of the ckan core module:
{% snippet "organization/snippets/organization_list.html", organizations=organizations, show_capacity=True %}
This will display the whole tree. Unfortunatly, when I use search, highlight of results dont work. So for the moment, your solution works better but I'm sure it can be fixed in this module.
from ckanext-hierarchy.
Related Issues (20)
- Organization activity stream page gives 404 HOT 1
- create parent via api HOT 5
- Paging is broken in organization pages HOT 4
- not working on CKAN 2.5.1 HOT 2
- speedbump HOT 1
- Not working on CKAN 2.8 or higher HOT 6
- Include children's dataset HOT 3
- JSTree implementation HOT 1
- Extra entries when searching organizations
- Organization sorting HOT 1
- Template tag `resource` vs `asset` heuristic struggles with CKAN '2.10.0a0'
- Helper 'check_ckan_version' has not been defined HOT 4
- Missing/incoherent git tags HOT 3
- Remove `resource` tags since they were deprecated HOT 2
- Pagination still breaks tree
- Where are the relations of parent and child organizations stored? HOT 1
- Switch between views HOT 3
- Manage hierarchy via API HOT 1
- Exception: menu item `organization_activity` need parameter `offset` HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ckanext-hierarchy.