It seems to me that the logic that regulates how the subcategories are displayed within a term page is faulty.

The term page tries to display the nodes that belong to a sub-category. There are two settings for this:

1- Resource count threshold to display subcategories
If a category has fewer than this number of resources, the directory will try to display the resources available in subcategories.

2- Number of resources to display for each visible subcategory
If subcategories are visible, how many resources for each subcategory should be displayed?

The first setting says that if there are too many nodes in a category, the subcategory will NOT be displayed at all, not even a link to it. This is really buggy.

The second setting is only applicable if the result to the 1st one is true, then if there are dozens of sub-categories, each will display the first n nodes within them.

I am browsing the different sites using this module, and I donnot see any where this leads to a beautiful, readable navigation between nodes and (sub-)categories.
http://www.roadcarvin.com/directory
http://exodusdev.com/directory (you have few subcategories, and in many pages, the nodes are not all listed and there is no pager).
http://amadorable.com/directory

The following site, though, has themed the display function to create a nice display which I believe should be the default behaviour of the module:
http://www.ent.iastate.edu/list/
See in particular in the 'Entomological Subdiscipline' vocabulary -> 'Biology, Ecology and Behavior' term.
http://www.ent.iastate.edu/list/directory/107
links to the sub-categories are simply listed at the top, above the list of nodes belonging to the current term.

This is what I had in mind.

So, I suggest that
* we remove the two above mentioned settings (create _update() function to unset variables).
* we create a new themable function that will display a link to the sub-categories. Being themable this function can be overruled by the theme.
* the output of this function can be displayed at the top of the listing of nodes.

Ok?

Comments

beginner’s picture

Example of what's wrong.

See: http://www.roadcarvin.com/directory
see at Image galleries > Other photos which has 2 sub-categories.
http://www.roadcarvin.com/directory/183 does not give any indication that subcategories exist.

while 'Racing photos' has no nodes on its own, but two sub-categories with nodes. Then and only then the subcategories get displayed:
http://www.roadcarvin.com/directory/113

Compare the readability of the two following pages:
http://www.roadcarvin.com/directory/28
http://www.ent.iastate.edu/list/directory/117 (here, I would write 'sub-categories' instead of 'categories').

mcurry’s picture

I'm really glad that those sites serve as good examples of what's wrong with the module :D

I agree with your proposed changes, based on my understanding at present.

beginner’s picture

Assigned: Unassigned » beginner
Status: Active » Fixed
StatusFileSize
new17.1 KB

I committed this big patch.

The term list on the main page and on the term page has a unified look: they use the same function.

I tried to retain the presentation in two columns on the main page despite the fact that I use <ul> elements to theme the list of nested terms, but it is going to cause even more problems later (especially if we add - as I have been asked to do - some javascript to collapse some sections on the main page: how to have two evenly distributed columns?).

I am going to remove this two-column presentation very soon.

This issue is fixed.

Anonymous’s picture

Status: Fixed » Closed (fixed)