Vue-instantsearch: compose a link to filter a result and switching between two indices

Created on 13 Nov 2017  Â·  8Comments  Â·  Source: algolia/vue-instantsearch

Hello,
Currently facing 2 issues at the moment. I have to 2 indices(groups and students). Groups Indice contains group details and list of students under it.

first, I want to compose a URL/route in such a way when I click on a group, it will take students index page which will be filtered by group.

secondly, I defined a facet age on my student index. switching between the 2 indices page(groups and students) using, i got an error Error in render: "Error: age is not present in facets or disjunctiveFacets". I don't know what went wrong but when I do a hard refresh, the age filter will display. Note: I'm using ais-range-input component for the age facet.

After Hard refresh.

image

After switching between group page and student page

image

Most helpful comment

@iamraphson could you create a small repo with the code so that we can run it?
I don't see any obvious things that could be problematic in the above code so we would have to run it.

Maybe @samouss can help on this one.

All 8 comments

Is there any chance you could share a isolated example to re-produce this?

It think this is related to the way we remove facets when components get destroyed.

@rayrutjes sure

 <ais-range-input attribute-name="age" :class-names="{
                                            'ais-range-input__input': 'form-control',
                                            'ais-range-input__submit': 'btn btn-success range_submit'
                                            }"></ais-range-input>
 <router-link to="/group" class="btn btn-lg btn-info"><i
                                            class="fa fa-fw fa-group"></i>
                                        <span class="text">Groups</span></router-link>
                                    <router-link to="/" class="btn btn-lg btn-info active"><i
                                            class="fa fa-fw fa-user"></i>
                                        <span class="text">Student</span></router-link>



md5-967da750b8beb42088bf92f51018ccb2





md5-b70df2262dcf9c976c5945356915954e


@rayrutjes how will I compose the URL please in such a way that it will go to the other index, filtered.

@iamraphson could you create a small repo with the code so that we can run it?
I don't see any obvious things that could be problematic in the above code so we would have to run it.

Maybe @samouss can help on this one.

@rayrutjes thanks

Hi @samouss ..can i invite to a private repo?

@rayrutjes I think something is wrong with ais-range-input component. I tried it with ais-price-range component, I switch between pages and it worked fine with no error.

@rayrutjes @samouss sent a mail to [email protected]. please kindly help. This's urgent

This issue seems to have been resolved after messaging support

Was this page helpful?
0 / 5 - 0 ratings

Related issues

foufrix picture foufrix  Â·  5Comments

francoischalifour picture francoischalifour  Â·  3Comments

samouss picture samouss  Â·  3Comments

fi0 picture fi0  Â·  3Comments

socieboy picture socieboy  Â·  5Comments