Our blazing fast Grid component built with pure JavaScript


Post by tjmeal »

Dear all,

I hope this ticket finds you well.

I am facing a weird problem which i dont why it happens.

If you check my video attached > when the search field is utilised the UI not get updated.

What is on the video>

1) Make multiple updates on driver column (which changes also the status column) > and the UI works perfectly
2) The moment i filter the grid using the search field > the up is not get updated
3) If i click X button on search bar and remove the filter > and all the records are visible again > the UI is updated and shows the corrects values.

Before we start to dig deeper, I would like to ask if have you faced any similar behaviour with any other project?

Attachments
Screen Recording 2025-04-17 at 12.10.35.mov
(3.16 MiB) Downloaded 10 times

Post by ghulam.ghous »

So what you need is to re-apply the filters whenever a record is updated. We have a config for that: https://bryntum.com/products/grid/docs/api/Core/data/Store#config-reapplyFilterOnUpdate

Please set it to true on the store:

new Grid({
      store: {
             reapplyFilterOnUpdate : true
      }
})

Post by tjmeal »

Hello,

Thanks for your reply but the issue on the video attached seems to be resolved with "reapplyFilterOnAdd: true" is that normal ?

Also, i have a field startDate > how can i sort the grid by startDate and lock it (so the user won't be able to remove the sort) ?

I have configure the store like bellow

  store: {
    data: [],
    modelClass: GridMyModel,
    autoCommit: false,

reapplyFilterOnAdd: true,
reapplySortersOnAdd: {
  fields:["startDate"]
},

reapplyFilterOnUpdate: false,
reapplySortersOnUpdate: {
  fields:["startDate"]
},
sorters: [
  {field: "startDate", ascending: true},
]
  },
Attachments
Screen Recording 2025-04-17 at 21.08.34.mov
(2.6 MiB) Downloaded 9 times

Post by mats »

Thanks for your reply but the issue on the video attached seems to be resolved with "reapplyFilterOnAdd: true" is that normal ?

Yes if you don't set this to true, new records will be filtered out unless they match your filter.

Also, i have a field startDate > how can i sort the grid by startDate and lock it (so the user won't be able to remove the sort) ?

Please never post multiple questions in one thread.


Post by tjmeal »

Okay,

Thank you very much !!


Post Reply