ParamQuery grid support forum

General Category => Help for ParamQuery Pro => Topic started by: vinay.narasapurapu on September 08, 2020, 05:56:41 pm

Title: Grid data is not updating on change of new data
Post by: vinay.narasapurapu on September 08, 2020, 05:56:41 pm
Hi,

I am using react verion where i am trying to feed data by external search. i cant see the new data on grid.

public componentDidUpdate(previousProps, previousState) {

    if (JSON.stringify(previousProps.Data) !== JSON.stringify(this.props.Data)) {   
     
      CurrentClass.pqGridObj.data = this.props.Data; //CurrentClass.pqGridObj.options.dataModel.data = this.props.Data;
      CurrentClass.pqGridObj.refreshDataAndView();
    }
  }
Title: Re: Grid data is not updating on change of new data
Post by: paramvir on September 08, 2020, 07:09:41 pm
Please follow this react example on updating grid data:

https://stackblitz.com/edit/paramquery-react-switch-data

Kindly share a test case via stackblitz if you still face any issues.
Title: Re: Grid data is not updating on change of new data
Post by: vinay.narasapurapu on September 08, 2020, 07:44:18 pm
Thank you it resolved the issue