|
|
@ -22,7 +22,7 @@ public class CptAndCptxCompatibilityUtil { |
|
|
|
FILE editingFILE = jTemplate.getEditingFILE(); |
|
|
|
FILE editingFILE = jTemplate.getEditingFILE(); |
|
|
|
String path = editingFILE.getPath(); |
|
|
|
String path = editingFILE.getPath(); |
|
|
|
//只有在旧文件是cptx文件并且新文件是cpt文件时才会改变报表引擎属性
|
|
|
|
//只有在旧文件是cptx文件并且新文件是cpt文件时才会改变报表引擎属性
|
|
|
|
boolean isCptxConvertToCpt = oldName.endsWith(".cptx") && path.endsWith(".cpt"); |
|
|
|
boolean isCptxConvertToCpt = FileExtension.CPTX.matchExtension(oldName) && FileExtension.CPT.matchExtension(path); |
|
|
|
if (isCptxConvertToCpt && !changeFrEngineAttr(jTemplate)){ |
|
|
|
if (isCptxConvertToCpt && !changeFrEngineAttr(jTemplate)){ |
|
|
|
isCptxConvertToCpt = false; |
|
|
|
isCptxConvertToCpt = false; |
|
|
|
} |
|
|
|
} |
|
|
@ -83,6 +83,6 @@ public class CptAndCptxCompatibilityUtil { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
private static boolean isEngineXEnable(LayerReportAttr layerReportAttr, String fileName){ |
|
|
|
private static boolean isEngineXEnable(LayerReportAttr layerReportAttr, String fileName){ |
|
|
|
return (layerReportAttr!= null && layerReportAttr.isClientPaging() && layerReportAttr.getEngineState() == 0) || FileExtension.CPTX.matchExtension(fileName); |
|
|
|
return (layerReportAttr!= null && layerReportAttr.isClientPaging() && layerReportAttr.getEngineState() == LayerReportAttr.ENGINE_X) || FileExtension.CPTX.matchExtension(fileName); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|