jqplot: “this.proxy.getTime is not a function” / date input parser?

自作多情 提交于 2019-12-04 14:50:01

...sorry, after reading the documentation the 3rd time, I found the error: The date input format is wrong. I though, that tickOptions:{formatString:'%Y-%m-%d.%H:%M:%S'} will define "how to parse the input data". But it is only relevant for displaying the data, not for parsing the input string.

But on this "formatString" you can guess, how jqPlot will parse the input date. So i had to change the input format to something like that: 2011-09-18 02:00:00

Byt the way: is there any jqplot option, to define how to parse the input date format?

The errors is caused when jqPlot does not recognise the date format. The string format is auto detected (probably by the standard Date method).

To fix this, correct the string format, for example: 12/25/12 for December 25th, 2012.

Change "2010-12-25.14:19:47" to "25-12-10". I don't know how to include the time :/

Clément Vétillard

I recently had exactly the same problem (convert a Timestamp Unix to use it with JQPlote).

I noticed that nobody here has found the whole date format used by JQPlot. So, for future users who will come here for the solution:

yyyy/mm/dd h:mm

Found on JQPlot's website

Notice that the hour can be displayed with only one digit or two.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!