Javascript 正在显示我的Jqplot饼图,饼图中的小表没有任何颜色

Javascript 正在显示我的Jqplot饼图,饼图中的小表没有任何颜色,javascript,asp.net-mvc-3,jqplot,Javascript,Asp.net Mvc 3,Jqplot,我在asp.net MVC 3 web应用程序中使用Jqplot饼图,但问题是饼图中包含图表标签的小表格显示时没有任何颜色。 那么我如何解决这个问题呢?。 提前感谢您的帮助。 溴 编辑 谢谢你善意的回复,是的,我已经包括了这些文件,但仍然没有显示颜色。下面是我的MVC 3 asp.net web应用程序中的代码(饼图显示了两个值;喜欢考试的学生占没有提供任何评分的学生的百分比) $(文档).ready(函数(){ 风险值数据=[ ['Number of Like',@ViewBag.Count

我在asp.net MVC 3 web应用程序中使用Jqplot饼图,但问题是饼图中包含图表标签的小表格显示时没有任何颜色。 那么我如何解决这个问题呢?。 提前感谢您的帮助。 溴

编辑

谢谢你善意的回复,是的,我已经包括了这些文件,但仍然没有显示颜色。下面是我的MVC 3 asp.net web应用程序中的代码(饼图显示了两个值;喜欢考试的学生占没有提供任何评分的学生的百分比)


$(文档).ready(函数(){
风险值数据=[
['Number of Like',@ViewBag.CountRate],'Other',@ViewBag.Other]
];
var plot1=jQuery.jqplot('r1',[data],
{
系列默认值:{
渲染器:jQuery.jqplot.pierender,
渲染器选项:{
showDataLabels:true
}
},
图例:{show:true,位置:'e'}
}
);
});

是否正在加载所有必需的js文件?听起来你好像失踪了:

jqplot.pointLabels.min.js
添加以下内容:

("~/scripts/jqPlot/jquery.jqplot.min.js")
("~/scripts/jqPlot/plugins/jqplot.pieRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.donutRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.barRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.categoryAxisRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.pointLabels.min.js")

您正在加载所有必需的js文件吗?听起来你好像失踪了:

jqplot.pointLabels.min.js
添加以下内容:

("~/scripts/jqPlot/jquery.jqplot.min.js")
("~/scripts/jqPlot/plugins/jqplot.pieRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.donutRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.barRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.categoryAxisRenderer.min.js")
("~/scripts/jqPlot/plugins/jqplot.pointLabels.min.js")
jqPlot并没有非常强烈地提到它,但它确实提到了包含css文件

要使用jqPlot,请包括jquery、jqPlot jquery插件、jqPlot css 文件和可选的excanvas脚本,用于在您的web中提供IE支持 页面

所以你需要包括
jquery.jqplot.min.css

<link rel="stylesheet" href="/jqplot/jquery.jqplot.min.css">

另外,jqPlot建议使用css来定制颜色等,请参见

jqPlot没有非常强烈地提到它,但它确实提到了包含css文件

要使用jqPlot,请包括jquery、jqPlot jquery插件、jqPlot css 文件和可选的excanvas脚本,用于在您的web中提供IE支持 页面

所以你需要包括
jquery.jqplot.min.css

<link rel="stylesheet" href="/jqplot/jquery.jqplot.min.css">


jqPlot还建议使用css定制颜色等,请参见

谢谢;是的,我已经包括了这些文件,但是仍然没有显示颜色。谢谢;是的,我已经包括了这些文件,但是仍然没有显示颜色。我有同样的问题。你最后明白了吗?我也有同样的问题。你最后明白了吗?