Page 1 of 2

jqPlot date graph

Posted: Sun Jan 19, 2014 11:03 pm
by Lau

Hi Appery team,

I have followed your other tutorials on getting my app working with jqPlot as seen here:
https://getsatisfaction.com/apperyio/...

I was able to get line charts working fine in the app but what I really need is to use Date charts.

I am using jqPlot for date charts as per here:
http://www.jqplot.com/tests/date-axes...

This is giving me an error when I load my app page:
Image

Any help?


jqPlot date graph

Posted: Sun Jan 19, 2014 11:17 pm
by Igor

Hi,

Did you add jqplot.dateAxisRenderer.min.js plugin into the project?


jqPlot date graph

Posted: Sun Jan 19, 2014 11:28 pm
by Lau

I added jqplot.dateAxisRenderer.js


jqPlot date graph

Posted: Mon Jan 20, 2014 2:53 am
by Igor

Can you post app public link so we can test it?


jqPlot date graph

Posted: Mon Jan 20, 2014 3:17 am
by Lau

http://appery.io/app/mobile-frame?src...

login is c/c
From app menu go to My Graph


jqPlot date graph

Posted: Tue Jan 21, 2014 10:20 am
by Maryna Brodina

Hello! Sorry for a late reply. Delete files of jqplot.cursor and jqplot.dateaxisrenderer scripts. You need jquery.jqplot.min.js only.


jqPlot date graph

Posted: Tue Jan 21, 2014 6:18 pm
by Lau

Hello!

The code I am using is from this example page:
http://www.jqplot.com/tests/date-axes...

The code is at the bottom of the page:

$(document).ready(function(){
var line1=[['2008-06-30 8:00AM',4], ['2008-7-30 8:00AM',6.5], ['2008-8-30 8:00AM',5.7], ['2008-9-30 8:00AM',9], ['2008-10-30 8:00AM',8.2]];
var plot2 = $.jqplot('chart2', [line1], {
title:'Customized Date Axis',
gridPadding:{right:35},
axes:{
xaxis:{
renderer:$.jqplot.DateAxisRenderer,
tickOptions:{formatString:'%b %#d, %y'},
min:'May 30, 2008',
tickInterval:'1 month'
}
},
series:[{lineWidth:4, markerOptions:{style:'square'}}]
});
});

Are you sure I dont need DateAxisRenderer ??


jqPlot date graph

Posted: Thu Jan 23, 2014 1:41 pm
by Kateryna Grynko

Hi Lau,

You need DateAxisRenderer. Please add it after jquery.jqplot.min.js as it uses jquery.jqplot.min.js
That is, in your scrypt list jquery.jqplot.min.js should go before jqplot.dateAxisRenderer.min.js


jqPlot date graph

Posted: Thu Jan 23, 2014 11:49 pm
by Lau

Many thanks, this solved my problem.


jqPlot date graph

Posted: Sun Mar 29, 2015 5:42 pm
by George6656971

Kateryna,
I have deleted and added these manytimes in the UI and cannot figure out how to make the dateaxisrenderer to be last. It seems Appery automatically orders it backwards. here is a snapshot!

Image