Im trying to make a search from my component when the customer select an option. But my component its not loading the data when I use filters on it but without filters it work... This is my code.
My component country-list.js
import Ember from 'ember';
export default Ember.Component.extend({
store: Ember.inject.service(),
iso3: null,
valuesIso: null,
actions: {
countryIso() {
this.set("iso3", this.$("#whohow option:selected").val());
const filcode = this.$("#whohow option:selected").val();
this.set("valuesIso", this.get('store').findAll('country').then((iso) => {
return iso.get('ccode') === filcode;
}));
}
}
});
My index.hbs calling my component
my component handlebars country-list.hbs
<select name="whohow" id="whohow" class="form-control" onChange=>
<option value=''></option>
</select>
Aucun commentaire:
Enregistrer un commentaire