Our blazing fast Grid component built with pure JavaScript


Post by tjmeal »

Dear all,

I have the following column > if you will see on video attached > on that column i have show among other thinks the Date & Time > when i am updating the time > i need to update the order of the transfers sorting them by date time > At the video case when i update 12.40 to 11.40 it should go above 12.00 record.

The think is that i don't have dateTime column > can you show me how can i sort that type:template column ?

Thanks

      {
        type: 'template',
        field: "template",
        flex: 0.7,
        text: 'Services',
        filterable: false,
        autoHeight: true,
        minWidth: 250,
        readOnly: true,
        template: ({record}) => {
          if (record.serviceType === WS_TYPES.SERVICE_TYPE_TRANSFER) {
            return gridTransferItem(record)
          } else if (record.serviceType === WS_TYPES.SERVICE_TYPE_REQUEST) {
            return gridTransferRequestItem(record);
          }
        },
      },

Post by ghulam.ghous »

Please use the sortable to define your custom sorter, you can use the full data from the record.

https://bryntum.com/products/grid/docs/api/Grid/column/DateColumn#config-sortable


Post by tjmeal »

Hey,

It seems not to get triggered ?

Attachments
Screen Recording 2025-05-08 at 21.07.31.mov
(5.32 MiB) Downloaded 10 times

Post by ghulam.ghous »

You will have to set this config: https://bryntum.com/products/grid/docs/api/Core/data/mixin/StoreSort#config-reapplySortersOnUpdate

store : {
reapplySortersOnUpdate : true
}

Post by tjmeal »

Thank you very much.


Post Reply