|
|
@@ -55,9 +55,14 @@ public class ShowIndicatorService {
|
|
|
String fields = "", otherFields = "";
|
|
|
String sort = indicatorConfigInfo.getSort();
|
|
|
String condition = getCondition(filters, indicatorConfigInfo.getxField().getColumnRename(), indicatorConfigInfo.getyField().getColumnRename());
|
|
|
- String tableName = chartsUtilService.getSqlStr(token, indicatorConfigInfo.getId(), 0) + " emp ";
|
|
|
+ String tableName = chartsUtilService.getSqlStr(token, indicatorConfigInfo.getId(), 0);
|
|
|
+ tableName = tableName==""?"":tableName+" emp ";
|
|
|
String operate = CalculationJudgeUtil.Judge(indicatorConfigInfo.getyField().getShowDataType());
|
|
|
chartsDataInfo.setChartsColumnConfig(chartsConfigMapper.getChartsColumn(indicatorConfigInfo.getId()));
|
|
|
+ /* 参数校验 */
|
|
|
+ if (StringUtils.isEmpty(tableName)){
|
|
|
+ return new RepEntity(RepCode.NoAuthority);
|
|
|
+ }
|
|
|
if (ObjectUtils.isEmpty(indicatorConfigInfo.getxField())) {
|
|
|
fields += operate.contains("distinct") ? " count(" + indicatorConfigInfo.getyField().getColumnRename() + ") as \"value\" " : operate + "(" + indicatorConfigInfo.getyField().getColumnRename() + ") as \"value\" ";
|
|
|
}else {
|