Author Topic: How to update an entire column of pq grid data  (Read 1910 times)

rushabhwadkar

  • Newbie
  • *
  • Posts: 7
    • View Profile
How to update an entire column of pq grid data
« on: December 08, 2020, 07:58:23 pm »
We are having 3 columns in PQ grid as below -
  • ID
  • Timestamp
  • Log

The timestamp column contains timestamp in UTC format. Our requirement is to change the timestamp based on the timezone selected by the user from UI. Is there a way to change the column data easily and refresh the view? What would you suggest?

Briefly speaking, If change the timezone to America/New York, I want to run a function which would fetch the data from PQGrid and change the column timestamp value based on the Timezone and update the data in the PQ Grid.

Note - Having the backend to send the updated data is not feasible so we're just currently targeting having the logic on the client side only.

rushabhwadkar

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: How to update an entire column of pq grid data
« Reply #1 on: December 09, 2020, 10:23:05 am »
Please reply. It's urgent.

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6136
    • View Profile
Re: How to update an entire column of pq grid data
« Reply #2 on: December 09, 2020, 10:27:56 am »
Just iterate ( loop ) through dataModel.data array and update the column values followed by refresh method.