asterisk2billing.org http://forum.asterisk2billing.org/ |
|
Dashboard is blank http://forum.asterisk2billing.org/viewtopic.php?f=21&t=5980 |
Page 1 of 2 |
Author: | dbbrito [ Wed Aug 05, 2009 1:33 pm ] |
Post subject: | Dashboard is blank |
A2billing installed 1.4.1 and everything is working 100%, but the Dashboard is blank, is missing some dependency? Somebody help me? Thanks |
Author: | areski [ Wed Aug 05, 2009 5:05 pm ] |
Post subject: | Re: Dashboard is blank |
you can maybe check the apache logs! make sure u run php version >= 5.2 |
Author: | cg180759 [ Thu Aug 06, 2009 5:00 pm ] |
Post subject: | Re: Dashboard is blank |
ah, so kha?! thanks |
Author: | Lt_Flash [ Wed Feb 17, 2010 5:01 am ] |
Post subject: | Re: Dashboard is blank |
Dashboard was working in 1.4.1, then upgraded to 1.5.1 and dashboard graphs are blank now. Today upgraded to 1.6.0 - still no luck. Installed 1.6.0 from a scratch on another machine, which has PHP 5.3.1 - still dashboards are all blank. I believe there is some problem with JavaScript code? Here is the generated code: Code: <td width="33%" valign="top" class="tableBodyRight"> <div class="dashbox"> <div class="dashtitle" > CALLS INFO TODAY </div> Total Calls : <font style="color:#EE6564;" > 1 </font> <br/> :: Answered : 1 :: Busy : 0 :: Unanswered : 0<br/> :: Cancelled : 0 :: Congestion : 0 :: Unavailable : 0<br/> <br/> Sell : <font style="color:#EE6564;" > 0.006667 </font> aud <br/> Cost : <font style="color:#EE6564;" > 0.00067 </font> aud <br/> Profit : <font style="color:#EE6564;" > 0.005997 </font> aud <br/> Duration : <font style="color:#EE6564;" > 4 </font> sec <br/> <br/> <center><b>Report by</b></center><br/> <center>Days <input id="view_call_day" type="radio" class="period_calls_graph" name="view_call" value="day" > Months <input id="view_call_month" type="radio" class="period_calls_graph" name="view_call" value="month"></center> <br/> <b>Call type :</b><br/> <input id="call_answer" type="radio" class="update_calls_graph" name="mode_call" value="answered"> Answered <input id="call_incomplet" type="radio" class="update_calls_graph" name="mode_call" value="incomplet"> Incomplete <input id="call_times" type="radio" class="update_calls_graph" name="mode_call" value="times"> Duration <br/> <input id="call_sell" type="radio" class="update_calls_graph" name="mode_call" value="sell"> Sell <input id="call_buy" type="radio" class="update_calls_graph" name="mode_call" value="buy"> Cost <input id="call_profit" type="radio" class="update_calls_graph" name="mode_call" value="profit"> Profit<br/> <br/> <div id="call_graph" class="dashgraph" style="margin-left: auto;margin-right: auto;"></div> <script id="source" language="javascript" type="text/javascript"> $(document).ready(function () { var format = ""; var x_format = ""; var width= Math.min($("#call_graph").parent("div").width(),$("#call_graph").parent("div").innerWidth()); var period_val=""; $("#call_graph").width(width-10); $("#call_graph").height(Math.floor(width/2)); $('.update_calls_graph').click(function () { $.getJSON("modules/calls_lastmonth.php", { type: this.id , view_type : period_val }, function(data){ var graph_max = data.max; var graph_data = new Array(); for (i = 0; i < data.data.length; i++) { graph_data[i] = new Array(); graph_data[i][0]= parseInt(data.data[i][0]); graph_data[i][1]= data.data[i][1] } //alert(graph_data); format = data.format; plot_graph_calls(graph_data,graph_max); }); }); $('.period_calls_graph').change(function () { period_val = $(this).val(); if($(this).val() == "month" ) x_format ="%b"; else x_format ="%d-%m"; $('.update_calls_graph:checked').click(); }); $('#view_call_day').click(); $('#view_call_day').change(); function plot_graph_calls(data,max){ var d= data; var max_data = (max+5-(max%5)); var min_month = 1250431200000; var max_month = 1267362000000; var min_day = 1265677920000; var max_day = 1266411600000; if(period_val=="month"){ var min_graph = min_month; var max_graph = max_month; var bar_width = 28*24 * 60 * 60 * 1000; }else{ var min_graph = min_day; var max_graph = max_day; var bar_width = 24 * 60 * 60 * 1000; } $.plot($("#call_graph"), [ { data: d, bars: { show: true, barWidth: bar_width, align: "centered" } } ], { xaxis: { mode: "time", timeformat: x_format, ticks :6, min : min_graph, max : max_graph }, yaxis: { max:max_data, minTickSize: 1, tickDecimals:0 },selection: { mode: "y" }, grid: { hoverable: true,clickable: true} }); } $('#call_profit').click(); function showTooltip(x, y, contents) { $('<div id="tooltip">' + contents + '</div>').css( { position: 'absolute', display: 'none', top: y + 5, left: x + 5, border: '1px solid #fdd', padding: '2px', 'background-color': '#fee', opacity: 0.80 }).appendTo("body").fadeIn(200); } var previousPoint = null; $("#call_graph").bind("plothover", function (event, pos, item) { if (item) { if (previousPoint != item.datapoint) { previousPoint = item.datapoint; $("#tooltip").remove(); if (format=="time"){ var y = item.datapoint[1].toFixed(0); var hour= Math.floor(y/3600); var min= Math.floor(y/60)%60; var sec= y%60; showTooltip(item.pageX, item.pageY, hour+"h "+min+"m "+sec+"s<br/>("+y+" sec)"); }else if(format=="money"){ var y = item.datapoint[1].toFixed(2); showTooltip(item.pageX, item.pageY, y+" aud"); }else{ var y = item.datapoint[1].toFixed(0); showTooltip(item.pageX, item.pageY, y); } } } else { $("#tooltip").remove(); previousPoint = null; } }); }); </script> <br/> </div> Any ideas? |
Author: | areski [ Wed Feb 17, 2010 9:56 am ] |
Post subject: | Re: Dashboard is blank |
If there is a javascript error you might see that easily from Firefox, give a try and see what happen. Also I might advice you to check your apache logs, it might tell you if you have a php error or dependencies missing. Yours, /Areski |
Author: | Lt_Flash [ Wed Feb 17, 2010 11:37 am ] |
Post subject: | Re: Dashboard is blank |
I don't see any JavaScript errors neither in Firefox, nor in IE. The only errors in apache logs are: Code: [Wed Feb 17 22:27:51 2010] [error] [client ] File does not exist: /var/www/html/a2bill/admin/Public/templates/default/images/OSicon/.png, referer: https://a2bill/admin/Public/dashboard.php [Wed Feb 17 22:27:53 2010] [error] [client ] PHP Warning: file_get_contents(templates/default/footer.tpl) [<a href='function.file-get-contents'>function.file-get-contents</a>]: failed to open stream: No such file or directory in /var/www/html/a2bill/common/lib/Misc.php on line 1408, referer: https:///a2bill/admin/Public/dashboard.php [Wed Feb 17 22:27:53 2010] [error] [client ] PHP Warning: file_get_contents(templates/default/footer.tpl) [<a href='function.file-get-contents'>function.file-get-contents</a>]: failed to open stream: No such file or directory in /var/www/html/a2bill/common/lib/Misc.php on line 1408, referer: https:///a2bill/admin/Public/dashboard.php [Wed Feb 17 22:27:53 2010] [error] [client ] PHP Warning: file_get_contents(templates/default/footer.tpl) [<a href='function.file-get-contents'>function.file-get-contents</a>]: failed to open stream: No such file or directory in /var/www/html/a2bill/common/lib/Misc.php on line 1408, referer: https:///a2bill/admin/Public/dashboard.php [Wed Feb 17 22:27:54 2010] [error] [client ] PHP Warning: file_get_contents(templates/default/footer.tpl) [<a href='function.file-get-contents'>function.file-get-contents</a>]: failed to open stream: No such file or directory in /var/www/html/a2bill/common/lib/Misc.php on line 1408, referer: https:///a2bill/admin/Public/dashboard.php I belive that these errors shouldn't affect dashboard functionality.... |
Author: | admin [ Wed Feb 17, 2010 11:48 am ] |
Post subject: | Re: Dashboard is blank |
On which Distro are you ? Did you remove the file : "templates/default/footer.tpl" ? Yours, /Areski |
Author: | Lt_Flash [ Wed Feb 17, 2010 11:51 am ] |
Post subject: | Re: Dashboard is blank |
admin wrote: On which Distro are you ? Did you remove the file : "templates/default/footer.tpl" ? Yours, /Areski Mandriava 2010.0. No, I didn't remove any files, I've just unpacked new version 1.6.0 and put folders admin, customer, agent, common and webservice into /var/www/html/a2bill. DocumentRoot is /var/www/html. |
Author: | Lt_Flash [ Wed Feb 17, 2010 11:55 am ] |
Post subject: | Re: Dashboard is blank |
Here are all the files which contain footer.tpl in its name: Code: /var/www/html/a2bill/admin/Public/templates/default/footer.tpl /var/www/html/a2bill/admin/templates_c/%%0E^0E4^0E407559%%footer.tpl.php /var/www/html/a2bill/agent/Public/templates/default/footer.tpl /var/www/html/a2bill/customer/templates/default/footer.tpl /var/www/html/a2bill/customer/templates/default/signup_footer.tpl /var/www/html/a2bill/customer/templates_c/%%01^019^019F0DED%%signup_footer.tpl.php /var/www/html/a2bill/customer/templates_c/%%0E^0E4^0E407559%%footer.tpl.php /var/www/html/a2bill.old/admin/Public/templates/default/footer.tpl /var/www/html/a2bill.old/admin/templates_c/%%0E^0E4^0E407559%%footer.tpl.php /var/www/html/a2bill.old/agent/Public/templates/default/footer.tpl /var/www/html/a2bill.old/agent/templates_c/%%0E^0E4^0E407559%%footer.tpl.php /var/www/html/a2bill.old/customer/templates/default/footer.tpl /var/www/html/a2bill.old/customer/templates/default/signup_footer.tpl /var/www/html/a2bill.old/customer/templates_c/%%01^019^019F0DED%%signup_footer.tpl.php /var/www/html/a2bill.old/customer/templates_c/%%0E^0E4^0E407559%%footer.tpl.php Double-checked ownership - everything's seems to be correct. Still I get that error. Maybe it's because a2billing is in subfolder? But still - how does that affect dashboard?? And it seems it still loads footer.tpl, because I can see </body></html> in dashboard page source code. |
Author: | Lt_Flash [ Tue Feb 23, 2010 1:15 pm ] |
Post subject: | Re: Dashboard is blank |
So? No ideas? Is generated JavaScript code correct? Help me, please. |
Author: | arpitrmodi [ Sat May 08, 2010 2:09 pm ] |
Post subject: | Re: Dashboard is blank |
Hello, I was facing the same issue on one of my server and i have got this issue fixed. If you will see the solution then you might laugh loudly but thats the fact. Solution : just set display_errors = Off in /etc/php.ini and restart apache service and and you are done simple enough, right? okay, please try it out. Hope this helps anybody. Thanks Everyone, Arpit modi |
Author: | Lt_Flash [ Sun May 09, 2010 1:36 am ] |
Post subject: | Re: Dashboard is blank |
You are absolutely right! Turned off display errors and dashboard now works! LOL )) Very convinient )) Thanks mate! |
Author: | arpitrmodi [ Thu May 13, 2010 1:36 pm ] |
Post subject: | Re: Dashboard is blank |
Great buddy..... Thanks, Arpit modi |
Author: | sobek [ Thu Feb 23, 2012 10:04 am ] |
Post subject: | Re: Dashboard is blank |
I still don't belive but it Works LoL |
Author: | arpitrmodi [ Thu Feb 23, 2012 10:08 am ] |
Post subject: | Re: Dashboard is blank |
LOL No worries, As long as it works |
Page 1 of 2 | All times are UTC |
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |