Browse Source

Pull request #10518: REPORT-80695 【模板全局级别查找替换二期】 迭代bug修复

Merge in DESIGN/design from ~DESTINY.LIN/design:release/11.0 to release/11.0

* commit 'd217d2a03597da020b6b5802bdcffc67a22cc2a6':
  REPORT-83498 单元格-格式-常规选中替换会提示查找内容不符
  REPORT-83501 多次替换时,下一次会覆盖上一次替换的记录
  REPORT-83339 设置项-切换模板后,数据集的查找结果还是上一个模板的
release/11.0
Destiny.Lin-林锦龙 2 years ago
parent
commit
b0a7453c1f
  1. 2
      designer-realize/src/main/java/com/fr/design/actions/replace/action/setting/CellFormatType.java
  2. 2
      designer-realize/src/main/java/com/fr/design/actions/replace/action/setting/action/SearchDSColumnAction.java
  3. 6
      designer-realize/src/main/java/com/fr/design/actions/replace/ui/ITReplaceMainDialog.java

2
designer-realize/src/main/java/com/fr/design/actions/replace/action/setting/CellFormatType.java

@ -61,7 +61,7 @@ public enum CellFormatType {
@Override
public boolean isEverChanged(Info info, String inputStr, String extraStr) {
CellElement cellElement = (CellElement) info.getContent().getReplaceObject();
return (cellElement.getStyle() != null && cellElement.getStyle().getFormat() == null);
return !(cellElement.getStyle() != null && cellElement.getStyle().getFormat() == null);
}
},
/**

2
designer-realize/src/main/java/com/fr/design/actions/replace/action/setting/action/SearchDSColumnAction.java

@ -39,8 +39,8 @@ public class SearchDSColumnAction implements SearchAction {
content.setShowStr(dataName);
content.setTemplateName(jTemplate.getTemplateName());
dsColumnInfos.add(new DataSourceInfo(content));
setDsColumnInfos(dsColumnInfos);
}
setDsColumnInfos(dsColumnInfos);
}
public List<DataSourceInfo> getDsColumnInfos() {

6
designer-realize/src/main/java/com/fr/design/actions/replace/ui/ITReplaceMainDialog.java

@ -514,7 +514,7 @@ public class ITReplaceMainDialog extends UIDialog {
String thirdStr = GeneralUtils.objectToString(northPane.getReplaceExtraSettingComboBox().getSelectedItem());
HistoryTemplateListCache.getInstance().getCurrentEditingTemplate().fireTargetModified(true);
for (Info info : searchSettingResultList) {
if (info.getContent().isSelected()) {
if (isSupportReplace(info)) {
SettingController controller = SettingController.match(firstStr);
if (controller != null) {
controller.replace(info, secondStr, thirdStr);
@ -549,6 +549,10 @@ public class ITReplaceMainDialog extends UIDialog {
}
}
}
private boolean isSupportReplace(Info info) {
return info.getContent().isSelected() && !info.getContent().isReplaced();
}
private boolean isSelectSearch(int optionSelected) {
return optionSelected == NONE;

Loading…
Cancel
Save