Dear visitor, despite the COVID-19 outbreak, our team continues operating at full speed.

Also, here is the form where you can apply for a special discount and we will contact you with possible options. Stay safe and continue achieving your business goals.

Fill the form
Get Free Trial
Get Free Trial

Update from 2.7 to 2.8 – setReport blanks grid – no message

Closed
Brendan Fry asked on May 20, 2020

Hi,
This is not a question but may help others.
I was testing updating to 2.8 from our current 2.7 and when I load a previously saved report (only structure – no data).
Previously I was informed when saving a report to do
var layout = _flexMonster.getReport();
layout.dataSource.data = [];
However now before setReport you need to 
delete layout.dataSource.data;
or you get a blank report with no warnings/messages.
Thanks
Brendan

2 answers

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster May 21, 2020

Hello,
 
Thank you for sharing your observations on our forum.
 
Our team would like to kindly draw your attention to the showEmptyData property of the options object.
It defines the component’s behavior in case of an empty data source. Flexomontser handles the empty data in two ways:

  • when showEmptyData is set to true, the component will show an empty grid and trigger a dataerror event for an empty CSV/JSON file, a JSON file with an empty array, or an empty inline JSON array. For an empty CSV data source with the defined header, the component will show the slice with empty data cells.
  • when showEmptyData is set to false, the component will show a message “Data source is empty” and trigger a dataerror event for all mentioned types of the empty data source.Default value: true.

 
Please see an example demonstrating usage of the mentioned property.
More about the options object and its properties can be found in our documentation.
 
Do not hesitate to contact us in case additional questions occur.
 
Kind regards,
Illia

Public
Brendan Fry May 21, 2020

Hi, 
Thanks for the info.
Brendan

This question is now closed