Browse Source

REPORT-79845 同一个多结果数据集equals为false的问题

new-design
rinoux 2 years ago
parent
commit
ec3e355d6c
  1. 2
      designer-base/src/main/java/com/fr/design/data/BasicTableDataTreePane.java
  2. 19
      designer-base/src/main/java/com/fr/design/data/tabledata/wrapper/MultiResultTableDataWrapper.java

2
designer-base/src/main/java/com/fr/design/data/BasicTableDataTreePane.java

@ -444,7 +444,7 @@ public abstract class BasicTableDataTreePane extends DockingView implements Resp
((MultiResultTableData<?>) (((TableDataWrapper) data).getTableData())).resetDataModelList();
if (data instanceof MultiResultTableDataWrapper) {
MultiResultTableDataWrapper oldSdw = ((MultiResultTableDataWrapper) data);
MultiResultTableDataWrapper newSdw = new MultiResultTableDataWrapper((MultiResultTableData<?>) oldSdw.getTableData(), oldSdw.getTableDataName(), oldSdw.getDataModelName());
MultiResultTableDataWrapper newSdw = new MultiResultTableDataWrapper((MultiResultTableData<?>) oldSdw.getTableData(), oldSdw.getMultiResultTableDataName(), oldSdw.getTableDataName());
newSdw.previewData(MultiResultTableDataWrapper.PREVIEW_ONE);
} else {
MultiResultTableData<?> tableData = (MultiResultTableData<?>) ((TableDataWrapper) data).getTableData();

19
designer-base/src/main/java/com/fr/design/data/tabledata/wrapper/MultiResultTableDataWrapper.java

@ -287,7 +287,8 @@ public final class MultiResultTableDataWrapper implements TableDataWrapper {
@Override
public String getTableDataName() {
return tableDataName;
// todo 这里返回数据集结果名称,带_的
return dataModelName;
}
public String getDataModelName() {
@ -299,6 +300,15 @@ public final class MultiResultTableDataWrapper implements TableDataWrapper {
return tableData;
}
/**
* 获取当前节点所属可编辑的数据集名称
* @return
*/
public String getMultiResultTableDataName() {
return tableDataName;
}
/**
* 是否异常
*
@ -312,9 +322,10 @@ public final class MultiResultTableDataWrapper implements TableDataWrapper {
@Override
public boolean equals(Object obj) {
return obj instanceof MultiResultTableDataWrapper
&& ComparatorUtils.equals(this.dataModelName, ((MultiResultTableDataWrapper) obj).getTableDataName())
&& ComparatorUtils.equals(this.tableData, ((MultiResultTableDataWrapper) obj).getTableData())
&& ComparatorUtils.equals(this.tableDataName, ((MultiResultTableDataWrapper) obj).getTableDataName());
&& ComparatorUtils.equals(this.getDataModelName(), ((MultiResultTableDataWrapper) obj).getDataModelName())
&& ComparatorUtils.equals(this.getTableData(), ((MultiResultTableDataWrapper) obj).getTableData())
&& ComparatorUtils.equals(this.getMultiResultTableDataName(), ((MultiResultTableDataWrapper) obj).getMultiResultTableDataName())
&& ComparatorUtils.equals(this.getTableDataName(), ((MultiResultTableDataWrapper) obj).getTableDataName());
}

Loading…
Cancel
Save