ajax dwr 调用对象问题
<script type= 'text/javascript ' src= ' <%=request.getContextPath()%> /dwr/interface/reportTable.js '> </script>
<script type= 'text/javascript ' src= ' <%=request.getContextPath()%> /dwr/interface/reportField.js '> </script>
<script type= 'text/javascript ' src= ' <%=request.getContextPath()%> /dwr/engine.js '> </script>
<script type= 'text/javascript ' src= ' <%=request.getContextPath()%> /dwr/util.js '> </script>
reportTable.setCode(DWRUtil.getValue(code));
reportTable.setName(DWRUtil.getValue(fname));
reportTable.setDataType(DWRUtil.getValue(length));
reportTable.setPrecision(DWRUtil.getValue(precision));
reportTable.addField(reportTable);
错误提示:Missing method or missing parameter converters: reportTable.addField
该方法存在,应该是缺少参数转换,求高手怎么能转换为reportTable对象呢??给出详细代码:)还是dwr不支持直接对对象进行处理?注:reportTable是定义的对象
------解决方案--------------------在dwr.xml中配置 <convert> 标签:
<convert converter= "bean " match= "数组中每个元素的类型 ">
</convert>