|
|
|
@ -11,7 +11,7 @@ import com.fr.design.constants.UIConstants;
|
|
|
|
|
import com.fr.design.data.BasicTableDataTreePane; |
|
|
|
|
import com.fr.design.data.BasicTableDataUtils; |
|
|
|
|
import com.fr.design.data.DesignTableDataManager; |
|
|
|
|
import com.fr.design.data.DesignerStrategyConfigUtils; |
|
|
|
|
import com.fr.design.data.StrategyConfigAttrUtils; |
|
|
|
|
import com.fr.design.data.tabledata.StoreProcedureWorkerListener; |
|
|
|
|
import com.fr.design.data.tabledata.tabledatapane.AbstractTableDataPane; |
|
|
|
|
import com.fr.design.data.tabledata.tabledatapane.DBTableDataPane; |
|
|
|
@ -291,10 +291,10 @@ public class TableDataTreePane extends BasicTableDataTreePane {
|
|
|
|
|
editingConfig.setDsName(tdName); |
|
|
|
|
if (!ComparatorUtils.equals(oldName, tdName)) { |
|
|
|
|
//重命名
|
|
|
|
|
DesignerStrategyConfigUtils.removeStrategyConfig(oldName); |
|
|
|
|
StrategyConfigAttrUtils.removeStrategyConfig(oldName); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
DesignerStrategyConfigUtils.addStrategyConfig(editingConfig); |
|
|
|
|
StrategyConfigAttrUtils.addStrategyConfig(editingConfig); |
|
|
|
|
} |
|
|
|
|
((DBTableData) td).setDsName(tdName); |
|
|
|
|
} |
|
|
|
@ -588,7 +588,7 @@ public class TableDataTreePane extends BasicTableDataTreePane {
|
|
|
|
|
if (wrapper.getTableData() instanceof DBTableData) { |
|
|
|
|
DBTableData td = (DBTableData) wrapper.getTableData(); |
|
|
|
|
|
|
|
|
|
StrategyConfig config = DesignerStrategyConfigUtils.getStrategyConfig(wrapper.getTableDataName()); |
|
|
|
|
StrategyConfig config = StrategyConfigAttrUtils.getStrategyConfig(wrapper.getTableDataName()); |
|
|
|
|
if (config == null) { |
|
|
|
|
result.put(td, td.isShare() ? ESDStatus.SINGLE_ON : ESDStatus.SINGLE_OFF); |
|
|
|
|
} else { |
|
|
|
@ -632,14 +632,14 @@ public class TableDataTreePane extends BasicTableDataTreePane {
|
|
|
|
|
StrategyConfig strategyConfig = getOrCreateStrategyConfig(dsName); |
|
|
|
|
strategyConfig.setEnable(true); |
|
|
|
|
strategyConfig.setUseGlobal(false); |
|
|
|
|
DesignerStrategyConfigUtils.addStrategyConfig(strategyConfig); |
|
|
|
|
StrategyConfigAttrUtils.addStrategyConfig(strategyConfig); |
|
|
|
|
DesignerContext.getDesignerFrame().getSelectedJTemplate().fireTargetModified(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private @NotNull StrategyConfig getOrCreateStrategyConfig(String dsName) { |
|
|
|
|
StrategyConfig config = DesignerStrategyConfigUtils.getStrategyConfig(dsName); |
|
|
|
|
StrategyConfig config = StrategyConfigAttrUtils.getStrategyConfig(dsName); |
|
|
|
|
|
|
|
|
|
if (config == null) { |
|
|
|
|
config = StrategyConfigHelper.createStrategyConfig(true); |
|
|
|
@ -680,7 +680,7 @@ public class TableDataTreePane extends BasicTableDataTreePane {
|
|
|
|
|
StrategyConfig strategyConfig = getOrCreateStrategyConfig(dsName); |
|
|
|
|
strategyConfig.setEnable(false); |
|
|
|
|
strategyConfig.setUseGlobal(false); |
|
|
|
|
DesignerStrategyConfigUtils.addStrategyConfig(strategyConfig); |
|
|
|
|
StrategyConfigAttrUtils.addStrategyConfig(strategyConfig); |
|
|
|
|
DesignerContext.getDesignerFrame().getSelectedJTemplate().fireTargetModified(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
@ -814,7 +814,7 @@ public class TableDataTreePane extends BasicTableDataTreePane {
|
|
|
|
|
checkButtonEnabled(); |
|
|
|
|
|
|
|
|
|
//删掉缓存配置
|
|
|
|
|
DesignerStrategyConfigUtils.removeStrategyConfig(selectedNO.getName()); |
|
|
|
|
StrategyConfigAttrUtils.removeStrategyConfig(selectedNO.getName()); |
|
|
|
|
|
|
|
|
|
// 如果一个模版是平台开启,这个数据集的配置不会存xml,预览模版时直接从全局配置copy,这样
|
|
|
|
|
// 导致删除的时候StrategyConfigsAttrSavedHook没有通过前后配置比较感知数据集被删除,因此不会发出事件让其失效
|
|
|
|
|