Author Topic: JavaScript for complex filter implementation (.. or .. or) AND (.. or .. or)  (Read 1965 times)

kjvjung

  • Pro Deluxe
  • Newbie
  • *
  • Posts: 33
    • View Profile
Hello!

What do I need to fix to get the same results as attachments by editing the URL below?
What JavaScript should I fix?

https://paramquery.com/pro/demos/filter

Or open up examples of these complex filters.

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Mixing toolbar filtering and header filtering is not a good idea, it looks confusing.

As for the attachment, since there is no two way data binding, you have to update the filter textbox value in the toolbar manually.

Code: [Select]
//use filter event.
filter: function(){
var value = this.getColumn({dataIndx: 'contacttitle'}).filter.value,
$filterText = this.toolbar().find(".filterValue"),
oldVal = $filterText.val();
if(value != oldVal){
$filterText.val(value);
}
},
« Last Edit: August 29, 2017, 04:15:37 pm by paramquery »