bjorn2404 / jQuery-Store-Locator-Plugin

A store locator plugin using Google Maps API version 3
MIT License
495 stars 235 forks source link

Category Search Broken #93

Closed enrmbigg closed 8 years ago

enrmbigg commented 8 years ago

When searching with categories if you search first an select a few categories, upon unchecking the search filter the results are limited to those previously whittled down.

enrmbigg commented 8 years ago

Example

London: restaurants
Paris: restaurants 
Berlin

restaurants ticked shows

London: restaurants
Paris: restaurants 

Then after the search with restaurant unchecked shows, only those previous two when Berlin should now be available again

London: restaurants
Paris: restaurants 
bjorn2404 commented 8 years ago

I'm not sure I follow. Do you have an example link?

enrmbigg commented 8 years ago

Sorry currently I don't am afraid, am terrible at explain sometimes aha,

Let me try again.

So after doing a search with some categories checked I expect the full list of retailers to be available upon the next search but it seems that it takes the results from the previous search and uses that and not the original list

bjorn2404 commented 8 years ago

With the categories still checked? It works that way so that options can be selected before the initial search.

enrmbigg commented 8 years ago

it seems to error on line 1885 saying "Cannot read property 'distance' of undefined" after the intial search

bjorn2404 commented 8 years ago

Can you send an example link? You can email it to bjorn2404@gmail.com if you'd rather not post it here.

enrmbigg commented 8 years ago

Hi Bjorn,

Sorry its been a while,

So it looks like using a checkbox for the categories is a little funky. If you do a search with i few categories selected, then untick and search it doesn't clear the filters in the js it seems

example error

enrmbigg commented 8 years ago

Figured it out, bh-sl-filters need to exist on the filters otherwise you fail to un select filters