0

也许有人可以帮助我。我在使用 SmartGWT 方法“setShowGridSummary”时遇到问题,当我尝试设置此属性时,此方法会引发调用异常。

我的代码如下所示:

 private void parseSummaryData(ArrayList<LinkedHashMap<String, String>> summaryMetaData) {
    ListGridField[] listGridFields = cachedFields;

    ClientSummaryData clientSummaryData = new ClientSummaryData();

    for (ListGridField listGridField : listGridFields) {
        String gridName = listGridField.getName();
        for (LinkedHashMap<String, String> column : summaryMetaData) {
            String columnName = column.get("columnName");
            if (columnName.equals(gridName)) {
                if (column.containsKey("setValue")) {  
                    listGridField.setShowGridSummary(true);
                    listGridField.setSummaryValue(column.get("setValue"));
                    clientSummaryData.setShowGridSummary(true);
                    clientSummaryData.setNoAggregating(false);
                } else {
                    clientSummaryData = parseClientSummaries(column, listGridField, clientSummaryData);
                }
            }
        }
    }
    this.setShowGridSummary(clientSummaryData.isShowGridSummary());
    this.setShowGroupSummary(clientSummaryData.isShowGroupSummary());
    this.setShowGroupSummaryInHeader(clientSummaryData.isShowGroupSummaryInHeader());
}

还有一件事——当这一切发生时,我设法找到了这个 JavaScriptException:this.sourceWidget.completeFields 是未定义的

4

0 回答 0