Browse Source

REPORT-97399

master
Mata.Li 7 years ago
parent
commit
37f3c96c58
  1. 13
      designer-base/src/main/java/com/fr/design/gui/icombobox/LazyComboBox.java
  2. 6
      designer-realize/src/main/java/com/fr/design/dscolumn/SelectedDataColumnPane.java

13
designer-base/src/main/java/com/fr/design/gui/icombobox/LazyComboBox.java

@ -36,10 +36,6 @@ public abstract class LazyComboBox extends UIComboBox implements PopupMenuListen
*/ */
private Object initialSelected = null; private Object initialSelected = null;
//数据集和模板的名称
private String oldDsName;
private String oldTemplateName;
protected LazyComboBox() { protected LazyComboBox() {
super(); super();
@ -58,15 +54,6 @@ public abstract class LazyComboBox extends UIComboBox implements PopupMenuListen
*/ */
public abstract Object[] load(); public abstract Object[] load();
public void changeLoaded(String dsName, String templateName){
if (!StringUtils.equals(dsName, oldDsName) || !StringUtils.equals(templateName, oldTemplateName)){
this.setLoaded(false);
oldDsName = dsName;
oldTemplateName = templateName;
}
}
@Override @Override
public void setSelectedItem(Object anObject) { public void setSelectedItem(Object anObject) {
initialSelected = anObject; initialSelected = anObject;

6
designer-realize/src/main/java/com/fr/design/dscolumn/SelectedDataColumnPane.java

@ -238,12 +238,10 @@ public class SelectedDataColumnPane extends BasicPane {
String dsColumnName = TableDataColumn.getColumnName(dsColumn.getColumn()); String dsColumnName = TableDataColumn.getColumnName(dsColumn.getColumn());
columnNameComboBox.setSelectedItem(dsColumnName); columnNameComboBox.setSelectedItem(dsColumnName);
ps = dsColumn.getParameters(); ps = dsColumn.getParameters();
//模板名称
String templateName = HistoryTemplateListPane.getInstance().getCurrentEditingTemplate().getEditingFILE().getName();
addListener(); addListener();
//比较上一次的数据集名称和模板名称,不一样的话需要加载 //重新设置需要加载
columnNameComboBox.changeLoaded(dsName, templateName); columnNameComboBox.setLoaded(false);
} }
/** /**

Loading…
Cancel
Save