Steps to recreate:

  1. Create a View with two separate blocks
  2. Add an exposed Views SHS filter to both blocks
  3. Place both blocks on the same page
  4. Result: The second filter will not function

This was true regardless of if Autosubmit was enabled or not.

Thanks for a lifesaver of a module, btw!

Files: 
CommentFileSizeAuthor
#5 Screen shot 2013-03-07 at 7.23.08 AM.jpg117.75 KBcovenantd

Comments

Status:Active» Needs work

Will have a look at it ...

Thanks - happy to help too if you want to point me in the right direction, just wasn't quite sure where to start looking.

Any luck looking into this? I'd be glad to have a go at it if you have pointers?

Looks like we've got identical controls and IDs for the two elements - however, that is true for all Views filters input/form fields when there are two embedded Views of the same type so in theory it should still work. My first guess right now is we have some JS that needs to narrow things down by the View DOM ID first before picking up the actual controller. For reference...

First Occurence (view-dom-id-1c824bdf3bfb33d4aa2fe80ade42b787 | form ID = views-exposed-form-manage-questions-embed-1)

<div id="edit-shs-term-node-tid-depth-wrapper" class="views-exposed-widget views-widget-filter-shs_term_node_tid_depth">
  <label for="edit-shs-term-node-tid-depth">My Label</label>
  <div class="views-widget">
    <div class="form-item form-type-textfield form-item-shs-term-node-tid-depth shs-wrapper-processed">
      <input class="element-invisible shs-enabled form-text ctools-auto-submit-processed shs-processed" type="text" id="edit-shs-term-node-tid-depth" name="shs_term_node_tid_depth" value="All" size="60" maxlength="128">
      <select id="edit-shs-term-node-tid-depth-select-1" class="shs-select shs-select-level-1" style="display: inline-block;">
        <option value="0">- None -</option>
        <option value="1">Option 1</option>
        <option value="141">Option 2</option>
        ...
        <option value="1526">Option 8</option>
      </select>
    </div>
  </div>
</div>

(Input ID = edit-shs-term-node-tid-depth | name = shs_term_node_tid_depth)
(Select ID = edit-shs-term-node-tid-depth-select-1)

Second Occurence (view-dom-id-796843cdedd06326b830018f9879316e | form ID = views-exposed-form-manage-questions-embed-2)

<div id="edit-shs-term-node-tid-depth-wrapper" class="views-exposed-widget views-widget-filter-shs_term_node_tid_depth">
  <label for="edit-shs-term-node-tid-depth">My Label</label>
  <div class="views-widget">
    <div class="form-item form-type-textfield form-item-shs-term-node-tid-depth shs-wrapper-processed">
      <input class="element-invisible shs-enabled form-text ctools-auto-submit-processed shs-processed" type="text" id="edit-shs-term-node-tid-depth" name="shs_term_node_tid_depth" value="All" size="60" maxlength="128">
      <select id="edit-shs-term-node-tid-depth-select-1" class="shs-select shs-select-level-1" style="display: inline-block;">
        <option value="0">- None -</option>
        <option value="1">Option 1</option>
        <option value="141">Option 2</option>
        ...
        <option value="1526">Option 8</option>
      </select>
    </div>
  </div>
</div>

(Input ID = edit-shs-term-node-tid-depth | name = shs_term_node_tid_depth)
(Select ID = edit-shs-term-node-tid-depth-select-1)

Now to track down the possible rogue JS...(pointers on where to look still welcome! :)

StatusFileSize
new117.75 KB

Hmm...so just came up with a dead-simple workaround I can't believe didn't hit me sooner: change the Filter identifier!

I did that (see attached screenshot for any folks coming later who aren't sure what that means) and voila - we're in business!

Still might be a "bug" to pursue with getting View-driven selection in the JS, but at least there is a workaround for now/ever.

For reference, this Views issue is tangentially related to all this #832026: Multiple copies of a view embedded on a page - trouble with exposed filters.

Filter identifier change

Thanks for you detailled reports and sorry for my silence. I'm very busy right now so I didn't had a chance to look at this.
Regarding you latest comment: using the same identifiers may cause problems even without using SHS since each view using this identifier may think "hey, I know this" and try to filter its results based on the given value.
So I think its best practise not to use the same identifier in views displayed on the same page ...

As soon as I've got more time I will try to provide a solution so SHS didn't fail in this cases.

Status:Needs work» Closed (won't fix)

Marking this as won't fix for now since Simple heirarchical select could not differentiate between both fields if the identifier is the same.