Forum Home › Forums › Development and Integration › Elastic Report and Chart Export function through iPad
- This topic has 10 replies, 2 voices, and was last updated 6 years, 6 months ago by
Boon Chang.
-
AuthorPosts
-
January 31, 2019 at 2:59 am #4960
Boon Chang
ParticipantDear Mikhail,
I have a customer who have bought iPads to be used for a RapidSCADA system.
It has come to our knowledge that the Elastic Report are not able to be exported and the ‘Export’ option also does not appear in the Chart window.It seems that normal reports such as Minute Data report are functioning normally on the iPad.
Is it due to the licensing of Elastic Report and Chart Pro which limits the function on iPad?
Is there any way to enable these functions on the iPads?The reason the iPads were bought were so that there would be flexibility to accessing the system other than from a PC.
What suggestions would you recommend? Replace the newly bought iPads with Android tablets?Thank you.
January 31, 2019 at 2:55 pm #4962Mikhail
ModeratorHello,
Replace the newly bought iPads with Android tablets?
I would not like this way.
Minute Data report are functioning normally on the iPad.
This is interesting. My iPad can’t open Minute report. What application opens this report on your iPad?
Is it due to the licensing of Elastic Report and Chart Pro which limits the function on iPad?
Is there any way to enable these functions on the iPads?Only technical reason. The cause is that iPad has no internal location to save report files. May be this changed since the reports were developed. We should try to run them and see what happens.
January 31, 2019 at 2:57 pm #4963Mikhail
ModeratorLet’s play with Elastic Report.
Open C:\SCADA\ScadaWeb\plugins\ElasticReport\js\elasticrep.js
Find the code:if (scada.utils.iOS()) { // disable Excel and PDF formats for iOS $("#rbHtmlFormat").prop("checked", true); $("#rbExcelFormat").prop("disabled", true); $("#divExcelFormat").addClass("disabled"); $("#rbPdfFormat").prop("disabled", true); $("#divPdfFormat").addClass("disabled"); } else { var format = localStorage.getItem(FORMAT_ITEM_NAME); // switch to stored format if (format == "PDF") { $("#rbPdfFormat").prop("checked", true); } else if (format == "HTML") { $("#rbHtmlFormat").prop("checked", true); } }
January 31, 2019 at 2:58 pm #4964Mikhail
Moderatorreplace the first line of the fragment to
if (false && scada.utils.iOS())The features should be enabled on iPad. How do they work?
February 1, 2019 at 11:09 am #4965Boon Chang
ParticipantDear Mikhail,
I did the change.
The following were the results:
At Elastic Report page, I am able to click on the ‘Get Report’ button and download the HTML report.
However, I am unable to click on the select-box for the formats ‘Excel’, ‘PDF’, ‘HTML’. And the HTML report was downloaded because the select-box of HTML is ticked by default.Chart still no Export option.
This is tried both in Safari and through Chrome App on iPhone.
Thank you.
February 1, 2019 at 2:37 pm #4968Mikhail
ModeratorHello,
However, I am unable to click on the select-box for the formats ‘Excel’, ‘PDF’, ‘HTML’.
The old scripts may be cached. Can you clear browser cache on iPad?
February 7, 2019 at 1:37 am #4974Boon Chang
ParticipantDear Mikhail,
I have cleared the cache and tried on Safari and Google Chrome App on an iPhone.
iPad is not available for trying at the moment.Here are the results:
I am still unable to click on the select-box at Elastic report page.
Chart export option still unavailable.Also, the HTML format which is available for download is in a slightly different format from the original PDF format. The format is smaller than original when printed out on A4 paper.
Thank you.
February 8, 2019 at 9:29 am #4975Boon Chang
ParticipantI see that the script is written such that the Excel and PDF formats will be disabled if iOS device is used, thus making HTML the default format.
Is there a way to make PDF the default format instead?
I tried changing the code to:
if (false && scada.utils.iOS()) {
// disable Excel and HTML formats for iOS
$(“#rbPdfFormat”).prop(“checked”, true);
$(“#rbExcelFormat”).prop(“disabled”, true);
$(“#divExcelFormat”).addClass(“disabled”);
$(“#rbHtmlFormat”).prop(“disabled”, true);
$(“#divHtmlFormat”).addClass(“disabled”);but the default checked box is still HTML.
February 8, 2019 at 9:47 am #4976Boon Chang
ParticipantDear Mikhail,
I had made a mistake on my part. I made the changes you had mentioned to the wrong elasticrep.js file.
Right now, the Elastic Report page is fully functional when viewed using iOS device.
Thank you.Do you have any idea how to address the issue of ‘Export’ option not appearing in the Chart window when viewed using iOS device?
February 8, 2019 at 1:56 pm #4977Mikhail
ModeratorHello,
Right now, the Elastic Report page is fully functional when viewed using iOS device.
I am very glad. What application is used by iPad to open PDF and Excel?
Do you have any idea how to address the issue of ‘Export’ option not appearing in the Chart window when viewed using iOS device?
Open C:\SCADA\ScadaWeb\plugins\ChartPro\js\chartproform.js
Find$("#hlExport").parent().addClass("hidden"); // hide Export menu item
and comment or remove it.February 11, 2019 at 1:24 am #4979Boon Chang
ParticipantDear Mikhail,
Thank you very much. The Export option is now appearing in the Chart window as well.I think the customer is using Adobe Reader and Microsoft Excel to open the PDF and Excel files.
-
AuthorPosts
- You must be logged in to reply to this topic.