Ok giant, 100% rendered, thank you.

Em quarta-feira, 8 de junho de 2016 10:33:11 UTC-3, Daniel LaLiberte 
escreveu:
>
> You have extra calls of google.charts.load(), which is not supported yet 
> in the 'current' version.
> You call google.setOnLoadCallback() which doesn't exist.
>
> I cleaned up your code here  https://jsfiddle.net/dlaliberte/r5eygwny/ 
> but it still doesn't run because it requires your local data.
>
> On Wed, Jun 8, 2016 at 8:27 AM, Wilson Rogério Braun <brau...@gmail.com 
> <javascript:>> wrote:
>
>> Hello,
>> someone could give a hint, as I am trying to deploy my graphics and I can 
>> not render with the new versions google chart:
>> Down version that does not render:
>>
>> <script type="text/javascript" src="
>> https://www.gstatic.com/charts/loader.js";></script>
>>     <script type="text/javascript">  
>>         var value;
>>         google.charts.load('current', { 'packages': ['corechart'] });
>>         google.setOnLoadCallback(function () { drawtable('') });
>>         $(document).ready(function () {
>>             value = $("#animal").val();
>>             if (value != undefined) {
>>                 drawtable(value);
>>             }
>>             $("#animal").change(function () {
>>                 value = $(this).val();
>>                 drawtable(value);
>>             });
>>         });
>> function drawtable(codigo){
>>         google.charts.load('current', { 'packages': ['corechart'] });
>>         google.charts.setOnLoadCallback(function(){ drawchart('')});     
>>   
>>         var url = '/Programa_Nutricao/Principal/EvolucaoPeso/' + codigo;
>>         $.get(url, {},
>>               function (data) {
>>                   var tdata = new google.visualization.DataTable();
>>                   tdata.addColumn('date', 'data_atividade');
>>                   tdata.addColumn('number', 'peso_kg');
>>                   for (var i = 0; i < data.length; i++) {
>>                       if (data[i].data_atividade != null)
>>                           
>> tdata.addRow([ToJavaScriptDate(data[i].data_atividade), 
>> parseFloat(data[i].peso_kg)]);
>>                   }
>>                   var options = {
>>                       width: 700,
>>                       height: 500,
>>                       vAxis: { title: "PESO (kg)", minValue: '0.5' },
>>                       hAxis: { title: "DATA", textStyle: { fontSize: 10 } 
>> },
>>                       legend: { position: "none" },
>>                       curveType: 'function'
>>                   };
>>                   var chart = new 
>> google.visualization.LineChart(document.getElementById('EvolucaoPeso'));
>>                   chart.draw(tdata, options);
>>               });
>> }
>>     </script>
>> <div id="EvolucaoPeso" style="width: 900px; height: 500px"></div>
>>
>> Under the old version that renders:
>>
>>  <script type="text/javascript" src="https://www.google.com/jsapi
>> "></script>
>>     <script type="text/javascript" src="//
>> ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
>>     <script type="text/javascript">
>>     var value;
>>     google.load("visualization", "1", { packages: ["table", "corechart"] 
>> });
>>     google.setOnLoadCallback(function () { drawtable('') });
>>     $(document).ready(function () {
>>         value = $("#animal").val();
>>         if (value != undefined) {
>>             drawtable(value);
>>         }
>>         $("#animal").change(function () {
>>             value = $(this).val();
>>             drawtable(value);
>>         });
>>     });
>>   
>>     function drawtable(codigo) {  
>>
>> google.setOnLoadCallback(function () { drawchart('') });
>>         var url = '/Programa_Nutricao/Principal/EvolucaoPeso/' + codigo;
>>         $.get(url, {},
>>               function (data) {
>>                   var tdata = new google.visualization.DataTable();
>>                   tdata.addColumn('date', 'data_atividade');
>>                   tdata.addColumn('number', 'peso_kg');
>>                   for (var i = 0; i < data.length; i++) {
>>                       if (data[i].data_atividade != null)
>>                           
>> tdata.addRow([ToJavaScriptDate(data[i].data_atividade), 
>> parseFloat(data[i].peso_kg)]);
>>                   }
>>                   var options = {
>>                       width: 700,
>>                       height: 500,
>>                       vAxis: { title: "PESO (kg)", minValue: '0.5' },
>>                       hAxis: { title: "DATA", textStyle: { fontSize: 10 } 
>> },
>>                       legend: { position: "none" },
>>                       curveType: 'function'
>>                   };
>>                   var chart = new 
>> google.visualization.LineChart(document.getElementById('EvolucaoPeso'));
>>                   chart.draw(tdata, options);
>>               });
>>  }
>>
>>
>>     </script>
>>
>> <div id="EvolucaoPeso" style="width: 900px; height: 500px"></div>
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Google Visualization API" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to google-visualization-api+unsubscr...@googlegroups.com 
>> <javascript:>.
>> To post to this group, send email to google-visua...@googlegroups.com 
>> <javascript:>.
>> Visit this group at 
>> https://groups.google.com/group/google-visualization-api.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/google-visualization-api/ac8e22bf-980a-474b-9c47-27bdd06879bf%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/google-visualization-api/ac8e22bf-980a-474b-9c47-27bdd06879bf%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> -- 
> Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2>
> dlali...@google.com <javascript:>   5CC, Cambridge MA
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-visualization-api+unsubscr...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-visualization-api/29936b36-cad4-46da-aa95-5ddd50674840%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to