日期:2014-05-17  浏览次数:20639 次

struts1中页面怎么获得后台的数据
我在页面上调用EntryDwrService层用这个方法想获取到totalCount的值,请问该怎么得到?
  public int getAllElementsNum(int nodeid){
List<String> count = dwrMethodService.getAllElementsNum(nodeid);
int totalCount = count.size();
return totalCount;
}

我在页面上用这样的方法应该得不到吧var totalNum = EntryDwrService.getAllElementsNum(),请朋友们指点下 谢谢!

------解决方案--------------------
EntryDwrService.getAllElementsNum(nodeid, function(totalNum){});