KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

Bug found #2025

Open Richb201 opened this topic on on Apr 13, 2021 - 16 comments

Richb201 commented on Apr 13, 2021

All of a sudden when i bring up my app I get this:

var _loaded = false; function CHART_loaded() { _loaded = true; } This is not from my code. I guess it is from Koolreport?

KoolReport commented on Apr 13, 2021

What type of chart you use over there? May I see the code of that chart.

Richb201 commented on Apr 13, 2021
//for 3way pie chart by employee count
        $sql="
        SELECT t.title, t.employee_count 
        FROM titles as t
        WHERE t.email='$email' AND t.campaign= '$campaign'
        ORDER BY t.title ASC
        ";
        $this->src('substantiator')
            ->query($sql)
            ->pipe($this->dataStore("titles_pie"));

// 3 way pie chart by $

        $sql="
       SELECT t.risk, SUM(e.w2_wages) as total_wages
        FROM employees e
        JOIN titles t ON e.employee_title=t.title
        WHERE e.campaign='$campaign'AND e.email='$email'
        GROUP BY risk;
        ";
        $this->src('substantiator')
            ->query($sql)
            ->pipe($this->dataStore("titles_pie2"));

    }

and the .view

    <div class="row">
        <div class="col-lg-3">
            <?php
            PieChart::create(array(
                    "title"=>"% of total wages by risk",
                    "dataSource"=>$this->dataStore("titles_pie2"),
                    "columns"=>array("risk","total_wages"),
                    "options"=>array("is3D"=>true,"forceIFrame"=>true)
                )
            );
            ?>
        </div>

        <div class="col-lg-3">
            <?php
            PieChart::create(array(
                    "title"=>"% employee wages by title",
                    "dataSource"=>$this->dataStore("titles_pie"),
                    "columns"=>array("title","employee_count"),
                    "options"=>array("is3D"=>true),
                    "forceIFrame"=>true
                )
            );
            ?>
        </div>
KoolReport commented on Apr 14, 2021

That's strange that it is not from our code as well. It could be from google chart itself. Anyway, please right click on the text there and open inspector. Let me see what it say over there. It could contain clue to the error of the chart.

Richb201 commented on Apr 14, 2021

I am not sure where to look. Here are a bunch of screenshots from the inspect.

KoolReport commented on Apr 14, 2021

You right click on the text "var _loaded .... " on the screen and open the inspector. I want to see where is text is generated. Your above image does not have those information.

Richb201 commented on Apr 14, 2021

Uncaught ReferenceError: CHART_loaded is not defined

Is that your variable?

Richb201 commented on Apr 15, 2021

Not mine! Is it yours?

KoolReport commented on Apr 16, 2021

It is not from our code as well. Is there any way that you can duplicate the issue and make it online. Please send me the url of the page via our email, I would like to inspect it.

Richb201 commented on Apr 16, 2021

I am getting it up on AWS. When it is up there I will give you the URL.

Michael Brown commented on Apr 19, 2021

I can confirm this is a Google Charts bug. The exact same string showed up in my directly-used Google Charts Gauge components a few days ago. I found your post with a Google search. I can't find anywhere that has provided a workaround yet, we need to get Google to fix this ASAP.

http://mike-land.com/Solar_Hua_Hin/solar_hua_hin.html

KoolReport commented on Apr 19, 2021

Thank you Michael for your information. I will inform our dev.team to find the work around together with contacting Google as well.

Michael Brown commented on Apr 19, 2021

I opened an issue about it here. Feel free to pile on!

https://github.com/google/google-visualization-issues/issues/2904

KoolReport commented on Apr 19, 2021

Thats great

KoolReport commented on Apr 20, 2021

Thank you Michael to file a issue there. The workaround for this issue in KoolReport will be:

  1. Locate the file koolreport/core/widgets/google/Chart.php
  2. Change $stability = "current"; to $stability = "49";

Basically we fix the version of library to 49 and avoid using current version of google chart.

Thank you very much.

Richb201 commented on Apr 20, 2021

Done. Still there. I deleted the browser cache. Still there. Anything else?

KoolReport commented on Apr 20, 2021

May be you could try to continue lowering the version to see how.

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
None yet

None