Forums Forums Search & Filter Pro Checkboxes – Parent/Child Hiearchy Post Count

  • This topic has 2 replies, 2 voices, and was last updated 9 years ago by Anonymous.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Anonymous
    #28258

    Great plugin!

    In search panel, when a user checks a parent item, I feel it should then auto-check all the child items below to indicate these are being searched too, how do we get that to work? Cheers.

    Ross Moderator
    #28281

    Hey Doug

    Technically this is not true, a result doesn’t have to be in a child to be in a parent.

    So selecting just the parent, will search only inside the parent and not the children.

    So in this use case this is correct.

    If you must auto-tick the children the you’ll have to write some custom JS that does this – a brief outline of the logic:

    1) Detect when input type = checkbox is changed
    2) Figure out if it is a parent, if it is:
    3) loop through all the children and set them to the same checked state as the parent

    Its not too tricky to do and sounds like a nice option to add to the plugin further down the line.

    Thanks

    Anonymous
    #28354

    Ok thanks Ross, will check it out

Viewing 3 posts - 1 through 3 (of 3 total)