Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/73.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Struts 2 jquery插件,图表插件不支持类别_Jquery_Struts2_Flot_Struts2 Jquery_Struts2 Jquery Chart - Fatal编程技术网

Struts 2 jquery插件,图表插件不支持类别

Struts 2 jquery插件,图表插件不支持类别,jquery,struts2,flot,struts2-jquery,struts2-jquery-chart,Jquery,Struts2,Flot,Struts2 Jquery,Struts2 Jquery Chart,Struts 2 jQuery插件版本3.6中的图表组件似乎不支持sjc:chart的category插件 我想在图表中使用带有“字符串”x轴的Flot,最好的解决方案是使用jquery.Flot.categories.js(如中所述) 当我查看一些strutsjquery插件code时,我发现jquery.chart.struts2.js没有使用这个插件,另一方面jquery.flot.categories.js文件在struts2-jquery-chart-plugin-3.7.1.jar文

Struts 2 jQuery插件版本3.6中的图表组件似乎不支持
sjc:chart
category
插件

我想在图表中使用带有“字符串”x轴的
Flot,最好的解决方案是使用
jquery.Flot.categories.js
(如中所述)

当我查看一些
strutsjquery插件
code时,我发现
jquery.chart.struts2.js
没有使用这个插件,另一方面
jquery.flot.categories.js
文件在
struts2-jquery-chart-plugin-3.7.1.jar
文件中


请让我知道我怎样才能修好它?!我想我可以扩展使用过的jquery对象(可能是
$.struts2\u jquery\u chart
)并添加它,但不知道如何添加

它很容易修复,只需修改您的
jquery.chart.struts2.js
并添加以下代码即可

if((o.xaxis&&o.xaxis.mode==“categories”)| |(o.yaxis&&o.yaxis.mode==“categories”)){
require(“js/flot/jquery.flot.categories”+self.minSuffix+“.js”);
} 
如果您想知道如何在Struts2 jQuery插件中使用自定义主题,您应该阅读以下内容

参考文献:


这同样有效
jQuery.struts2_jQuery.require(“js/flot/jQuery.flot.categories”+jQuery.struts2_jQuery.minSuffix+”.js”)给我