0

We have a set of JSON data coming back from an API that we pass to WDR via the report.dataSource field in the initial configuration. One of these columns is a string that doesn't render in the normal display. However, the data is there and if we export Excel the column is shown there is well.

This columns still renders for most users, and we can't repro it in our dev environment. It's just a single client that we know of thats experiencing this.

What are some reasons this might be happening?


We tried changing the data, passing in different values, and specifying the data type in dataSource.mapping.

None of these had any effect

1 Answers1

0

Such behavior can happen when there are multiple WebDataRocks components on the page using the exportTo API call from the webdatarocks instance. In this case, webdatarocks will be equal to the last initialized component. Hence, the export result will correspond to the slice from the last WDR instance, which may differ from the previous.

If this is the case, you should use the names of WebDataRocks instances to access API calls of different components:

let pivot1 = new WebDataRocks({
  //config
});
let pivot2 = new WebDataRocks({
  //config
});
//Export first pivot
pivot1.exportTo('excel');
//Export second pivot
pivot2.exportTo('excel');
  • Thanks, sadly I don't think this is our problem. We've only got one instance running and we don't call the export methods ourselves. Just the export button from the toolbar. – Ada Palmer Nov 07 '22 at 17:21