希望你是摇滚乐,但我需要一个小帮助。我正在处理vaadin portlet,我需要创建一个vaadin图表(示例)。我下载了所需的jars (vaadin-charts-vaadin6-1.1.7.jar和gson-2.2.1.jar),并创建了一个应用程序,如下所示:
@SuppressWarnings("serial")
public class UserloginchartApplication extends Application {
public void init() {
Window window = new Window();
setMainWindow(window);
Chart chart = new Chart(ChartType.BAR);
window.setModal(true);
window.addComponent(chart);
}
}在tomcat服务器上编译和部署后,我在UI上得到以下错误
Widgetset不包含com.vaadin.addon.charts.Chart的实现。检查它的@ClientWidget映射,widgetsets GWT模块描述文件,并重新编译您的widgetset。如果您已经下载了vaadin附加组件包,您可能需要参考附加组件说明。未呈现的UIDL:-Unrendered UIDL -com.vaadin.addon.charts.Chart(找不到客户端实现) id=PID3 height=400px width=100.0% confState={“-com.vaadin.addon.charts.Chart”:{ "type":"bar“},"series":[],"exporting":{ "enabled":false }}
谁能告诉我步骤,以实现/创建vaadin图表在救生艇。
提前感谢:
-Vikash
发布于 2014-10-08 21:09:42
问题是vaadin.addon.charts有一些客户端小部件没有包含在默认的小部件集中,那么您需要重新编译您的小部件集。如果你使用的是maven like build toll,你可以这样做:
<plugin>
<groupId>com.vaadin</groupId>
<artifactId>vaadin-maven-plugin</artifactId>
<version>${vaadin.plugin.version}</version>
<configuration>
<gwtSdkFirstInClasspath>true</gwtSdkFirstInClasspath>
<extraJvmArgs>-Xmx512M -Xss1024k</extraJvmArgs>
<!-- <runTarget>mobilemail</runTarget> -->
<!-- We are doing "inplace" but into subdir VAADIN/widgetsets. This way
compatible with Vaadin eclipse plugin. -->
<webappDirectory>${basedir}/src/main/webapp/VAADIN/widgetsets</webappDirectory>
<hostedWebapp>${basedir}/src/main/webapp/VAADIN/widgetsets</hostedWebapp>
<noServer>true</noServer>
<!-- Remove draftCompile when project is ready -->
<draftCompile>false</draftCompile>
<compileReport>true</compileReport>
<style>OBF</style>
<strict>true</strict>
<runTarget>http://localhost:8080/</runTarget>
</configuration>
<executions>
<execution>
<configuration>
<!-- if you don't specify any modules, the plugin will find them -->
<!-- <modules> <module>com.vaadin.demo.mobilemail.gwt.ColorPickerWidgetSet</module>
</modules> <gwtSdkFirstInClasspath>true</gwtSdkFirstInClasspath> -->
</configuration>
<goals>
<goal>resources</goal>
<goal>update-widgetset</goal>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>https://stackoverflow.com/questions/26257385
复制相似问题