Postponed (maintainer needs more info)
Project:
Lost & found issues
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
15 Nov 2012 at 12:47 UTC
Updated:
30 Nov 2012 at 15:40 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
yannickooI attached the module from kervi so that everybody can take a look and could create a patch.
Comment #2
dgastudio commentedWorking features:
1. hide empty terms. (it becomes a little bit slow on huge taxonomies)
2. add a counter of related nodes to each term. (it becomes a little bit slow on huge taxonomies)
3. unique id for each widget
TODO: add settings to select a content to coun/filter.
please, review.
Comment #3
ipwa commented@kervi the unique id makes a alot of sense tome
hiding empty terms is a great little feature
having a counter is handy in some cases, some people may not want it
I suggest having the hiding and the counter as settings, just a single on/off checkbox which activates/desactivates the fature
Comment #4
dgastudio commentedehm. it's already in options..
Comment #5
yannickooPlease remove all the tabs in the patch...
Comment #6
dgastudio commenteddone
Comment #7
yannickooThere is a space.
The coding standards say that you have to put a space after the "if".
When you have a single line comment you should use // instead of /* */
Comment #8
ser_house commentedWhy need all these features?
1. hide empty terms.
Well, give to user ability select only terms having nodes it very good idea, I think.
But what will happen if hide empty terms option is enabled and all taxonomy terms in current vocabulary are empty? Or only one term has some nodes?
2. add a counter of related nodes to each term.
Only for visual effect?
3. unique id for each widget
Why need it?
4. Why need TODO: filter by content type?
Comment #9
Sk8erPeter commentedWhen adding a "Content: Hierarchical Taxonomy Filter" exposed filter, sometimes I would just like to let the user filter the FIRST parent element of the term.
For example:
In this case, I would only like to let the user select from "first test parent", "second test parent", "third test parent", "fourth test parent", and that's all, I don't want to let users select (and see) any children terms.
Could you provide an opportunity in the filter settings to be able to limit the depth of search?
Thanks in advance!
===
EDIT: BTW, there's another built-in filter called "Content: Has taxonomy terms (with depth)", which can also be exposed, BUT in this case, unfortunately all the children elements get displayed in the select list too.
Comment #10
ser_house commented@Sk8erPeter:
So, it won't be "hierarchical select", won't it?
Comment #11
Sk8erPeter commented@ser_house: hmm, yes, in this case, the select procedure itself wouldn't be "hierarchical" - when for example disabling the display of the children elements (having this ability when exposing this filter), the user could just select the top/first element of the hierarchy.
Just like when you having the exposed filter of this module, but using the browser with JavaScript turned off. :) (This way there is no AJAX communication.)
Use-case: When categorizing stuffs on your site, the user would just be able to select the main category.
As a summary: having the ability to limit the maximum depth of the search (even if a term has children terms!).
Comment #12
ser_house commentedSk8erPeter, please, open the new issue for your request.
Comment #13
Sk8erPeter commented@ser_house, good point ;)
I created a feature request issue here: #1845802: Being able to limit the maximum depth of the hierarchical search (even if a term has children terms!).
Thanks in advance! :)
Comment #14
ser_house commentedSo, I did not get answers for my questions (#8) therefore I'm postponing this issue as "postponed (maintainer needs more info)".
Comment #15
Sk8erPeter commentedOK, let me share some ideas until kervi answers.
1. The exposed filter could then be hidden if it's not needed, because these terms are not assigned to any nodes at all.
2. I don't understand the question. This way the user can see how many children does a category have.
3. Hmm, dunno.
I would rather encourage being able to add our own classes to these exposed filters for easier CSS-styling (not just the optional 'container-inline' class).
4. I didn't quite understand the original idea of kervi: "TODO: add settings to select a content to coun/filter. ".
Comment #16
ser_house commented@Sk8erPeter:
1. If we have only an own filter on form and we make it hidden what will be on the form? There will be only button?
Just I don't imagine as the hiding would look in some cases.
2. I mean that this is a matter of convenience, not necessity. On the other hand, if we won't hide empty terms then we could show to user that these terms are empty.
3. Each widget has own id now, as example:
id=edit-terms3-wrapper,id=edit-terms4-wrapper4. ...
Main question: What can do with the empty terms? It's not enought corny hide.
I'm suggest only show to user the count nodes.
Comment #17
dgastudio commentedso, the effect is the same, after press submit, there are no result. And, i don't think that somebody is going to use terms without any content associated.
why? hierarchical select have it and any big eshop have a counter of results.
Becouse there are problems if you use 2 HST of different views on same page.
4. Why need TODO: filter by content type?becouse for now, the counter/empty terms filter it works for any kind of content type associated with the term. It will be great to use content type selected as filter in views. Or add a option to HST options panel.
Comment #18
Sk8erPeter commented@kervi: I absolutely agree with points 1-3.
But I don't really understand the 4th. Why is having the ability to filter for ALL the content types a problem?
There's already a built-in "Content: Type" filter in Views, which can also be exposed, so this shouldn't mean a problem.
Comment #19
ser_house commented1. I still doubt, but let's do it and see how it would. OK.
2. OK
3. Yeah, I didn't think about it. OK.
4. We postpone it until, I think.
So, I will test it as soon as have time.
Comment #20
dgastudio commentedSk8erPeter and ser_house, about 4.
for now, the counter is a simply function that count all the nodes related with term. it not depends from View for now.
i mean, you can create a View of users, add HST, add counter, but it will count all NODES related to term.
so, this is becouse i want to add a simple function to count only nodes of selected content type.
Comment #21
ser_house commentedComment #22
Sk8erPeter commented@kervi: oh, OK, I understand now, this makes sense, and this would be a great feature.
Comment #23
ser_house commented@Sk8erPeter: I don't need more info.
Comment #24
Sk8erPeter commented@ser_house: oops, changing the status wasn't intentional.
Comment #25
dgastudio commentedthat do you think?
Comment #26
ser_house commentedI think main purpose the filter was solve one problem.
And now it acquires more and more code, more and more options.
I think it doesn't make the module better, only more knotty (I mean code, of course).
But adding the option for effects it's interesting. I think :)
Comment #27
ser_house commented1. Done.
2. Done.
3. Done.
4. I need more clarification.
Comment #28
marcoka commenteddid a test with the new stuff on my install, everything seems fine so far.
Comment #28.0
marcoka commentedadding list of new features