moayadnajd / nativescript-filter-select

A NativeScript plugin to provide an listview widget to select AND filter items
http://codeobia.com
Other
37 stars 19 forks source link

Problem with clear filter select #49

Open leosilvestre7 opened 6 years ago

leosilvestre7 commented 6 years ago

not function the function clear when delete selected options

moayadnajd commented 6 years ago

@leosilvestre7 please explain more details i didn't understand the problem here

leosilvestre7 commented 6 years ago

I want to update the filter with data already pre-selected but not updated

COMPONENT this.personService.getPerson(this.person.id).subscribe( dataPerson => { this.person.userAcademicGrades = dataPerson['userAcademicGrades']; const academic_grades = this.returnAcademicGrades(this.person); this.gradesSelected = (academic_grades.length > 0) ? academic_grades : [];

VIEW <FilterSelect [items]="levelList" (change)="onitemselected($event)" hint="Lista de grados" modal_title="GRADOS DISPONIBLES" search_param="name" primary_key="id" searchHint="Buscar por nombre" [selected]="gradesSelected" selectText="Elegir Grado" doneText="Guardar" closeText="Cerrar">

"gradesSelected" is the parameter that is updated with each person search and should load the items already selected but this does not happen, it always stays stuck what I look for first and is never updated.

moayadnajd commented 5 years ago

@leosilvestre7 sorry i am busy .. did you solve it ?