|
|
@ -7,7 +7,6 @@ import com.fr.design.mainframe.template.info.TemplateInfo; |
|
|
|
import com.fr.design.mainframe.template.info.TemplateProcessInfo; |
|
|
|
import com.fr.design.mainframe.template.info.TemplateProcessInfo; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
import com.fr.log.FineLoggerFactory; |
|
|
|
import com.fr.log.FineLoggerFactory; |
|
|
|
import com.fr.plugin.chart.vanchart.VanChart; |
|
|
|
|
|
|
|
import com.fr.stable.ProductConstants; |
|
|
|
import com.fr.stable.ProductConstants; |
|
|
|
import com.fr.stable.StableUtils; |
|
|
|
import com.fr.stable.StableUtils; |
|
|
|
import com.fr.stable.StringUtils; |
|
|
|
import com.fr.stable.StringUtils; |
|
|
@ -57,36 +56,29 @@ public class ChartInfoCollector extends AbstractPointCollector<ChartInfo> { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void collection(ChartProvider chartProvider, String createTime, boolean isReuse) { |
|
|
|
public void collection(ChartProvider chartProvider, String createTime, boolean isReuse) { |
|
|
|
if (chartProvider instanceof VanChart) { |
|
|
|
collection(chartProvider.getChartUuid(), chartProvider.getID(), createTime, isReuse); |
|
|
|
VanChart vanChart = (VanChart) chartProvider; |
|
|
|
|
|
|
|
collection(vanChart.getUuid(), vanChart.getID(), createTime, isReuse); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 新建图表,保存状态 |
|
|
|
* 新建图表,保存状态 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void collection(String chartId, String chartType, String createTime, boolean isReuse) { |
|
|
|
public void collection(String chartId, String chartType, String createTime, boolean isReuse) { |
|
|
|
if (!shouldCollectInfo()) { |
|
|
|
if (!shouldCollectInfo() || StringUtils.isEmpty(chartId)) { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
ChartInfo chartInfo = ChartInfo.newInstance(chartId, chartType, createTime, true, isReuse); |
|
|
|
ChartInfo chartInfo = ChartInfo.newInstance(chartId, chartType, createTime, true, isReuse); |
|
|
|
chartInfoCacheMap.put(chartId, chartInfo); |
|
|
|
chartInfoCacheMap.put(chartId, chartInfo); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void updateChartPropertyTime(ChartProvider chartProvider) { |
|
|
|
public void updateChartPropertyTime(ChartProvider chartProvider) { |
|
|
|
if (chartProvider instanceof VanChart) { |
|
|
|
updateChartPropertyTime(chartProvider.getChartUuid(), chartProvider.getID()); |
|
|
|
VanChart vanChart = (VanChart) chartProvider; |
|
|
|
|
|
|
|
updateChartPropertyTime(vanChart.getUuid(), vanChart.getID()); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 图表编辑,更新编辑时间 |
|
|
|
* 图表编辑,更新编辑时间 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void updateChartPropertyTime(String chartId, String chartType) { |
|
|
|
public void updateChartPropertyTime(String chartId, String chartType) { |
|
|
|
if (!shouldCollectInfo()) { |
|
|
|
if (!shouldCollectInfo() || StringUtils.isEmpty(chartId)) { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
ChartInfo chartInfo = getOrCreateChartInfo(chartId, chartType, null); |
|
|
|
ChartInfo chartInfo = getOrCreateChartInfo(chartId, chartType, null); |
|
|
@ -99,17 +91,14 @@ public class ChartInfoCollector extends AbstractPointCollector<ChartInfo> { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void updateChartTypeTime(ChartProvider chartProvider, String oldType) { |
|
|
|
public void updateChartTypeTime(ChartProvider chartProvider, String oldType) { |
|
|
|
if (chartProvider instanceof VanChart) { |
|
|
|
updateChartTypeTime(chartProvider.getChartUuid(), chartProvider.getID(), oldType); |
|
|
|
VanChart vanChart = (VanChart) chartProvider; |
|
|
|
|
|
|
|
updateChartTypeTime(vanChart.getUuid(), vanChart.getID(), oldType); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 图表类型变化,更新类型和类型确认时间 |
|
|
|
* 图表类型变化,更新类型和类型确认时间 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void updateChartTypeTime(String chartId, String chartType, String oldType) { |
|
|
|
public void updateChartTypeTime(String chartId, String chartType, String oldType) { |
|
|
|
if (!shouldCollectInfo()) { |
|
|
|
if (!shouldCollectInfo() || StringUtils.isEmpty(chartId)) { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -143,18 +132,14 @@ public class ChartInfoCollector extends AbstractPointCollector<ChartInfo> { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void checkTestChart(ChartProvider chartProvider) { |
|
|
|
public void checkTestChart(ChartProvider chartProvider) { |
|
|
|
if (chartProvider instanceof VanChart) { |
|
|
|
|
|
|
|
checkTestChart((VanChart) chartProvider); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void checkTestChart(VanChart vanChart) { |
|
|
|
|
|
|
|
if (!shouldCollectInfo()) { |
|
|
|
if (!shouldCollectInfo()) { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
boolean testChart = vanChart.isTestChart(); |
|
|
|
ChartInfo chartInfo = chartInfoCacheMap.get(chartProvider.getChartUuid()); |
|
|
|
ChartInfo chartInfo = chartInfoCacheMap.get(vanChart.getUuid()); |
|
|
|
if (chartInfo != null) { |
|
|
|
chartInfo.setTestChart(testChart); |
|
|
|
boolean testChart = chartProvider.isTestChart(); |
|
|
|
|
|
|
|
chartInfo.setTestChart(testChart); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|