Struts 2 jquery插件,图表插件不支持类别
Struts 2 jQuery插件版本3.6中的图表组件似乎不支持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文
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”)代码>给我