commit
7f0d1a7973
@ -37,4 +37,6 @@ public interface ExtPanelGroupMapper {
|
||||
List<RelationDTO> queryPanelRelation(@Param("panelId") String panelId, @Param("userId") Long userId);
|
||||
|
||||
List<PanelGroup> listPanelByUser(@Param("userId") long userId);
|
||||
|
||||
String queryPanelName(@Param("panelId") String panelId);
|
||||
}
|
||||
|
||||
@ -366,4 +366,8 @@
|
||||
)
|
||||
group by pg.id
|
||||
</select>
|
||||
|
||||
<select id="queryPanelName" resultType="java.lang.String">
|
||||
select `name` from `panel_group` where `id` = #{panelId}
|
||||
</select>
|
||||
</mapper>
|
||||
|
||||
@ -9,7 +9,6 @@ import io.dataease.commons.model.AuthURD;
|
||||
import io.dataease.commons.utils.*;
|
||||
import io.dataease.dto.PermissionProxy;
|
||||
import io.dataease.dto.chart.ViewOption;
|
||||
import io.dataease.dto.panel.PanelGroupDTO;
|
||||
import io.dataease.ext.ExtTaskMapper;
|
||||
import io.dataease.job.sechedule.ScheduleManager;
|
||||
import io.dataease.job.sechedule.strategy.TaskHandler;
|
||||
@ -271,8 +270,8 @@ public class EmailTaskHandler extends TaskHandler implements Job {
|
||||
emailService.sendWithImageAndFiles(recipients, emailTemplateDTO.getTitle(), contentStr, bytes, files);
|
||||
} else {
|
||||
bytes = emailXpackService.printPdf(url, token, xpackPixelEntity, false, true);
|
||||
PanelGroupDTO panelInfo = CommonBeanFactory.getBean(PanelGroupService.class).findOne(panelId);
|
||||
String pdfFileName = panelInfo.getName() + "pdf";
|
||||
String panelName = CommonBeanFactory.getBean(PanelGroupService.class).getPanelName(panelId);
|
||||
String pdfFileName = panelName + ".pdf";
|
||||
emailService.sendPdfWithFiles(recipients, emailTemplateDTO.getTitle(), contentStr, bytes, files, pdfFileName);
|
||||
}
|
||||
|
||||
|
||||
@ -135,9 +135,9 @@ public class ViewExportExcel {
|
||||
for (int i = 0; i < headKeys.size(); i++) {
|
||||
String key = headKeys.get(i);
|
||||
Object val = row.get(key);
|
||||
if (ObjectUtils.isEmpty(val))
|
||||
if (ObjectUtils.isEmpty(val)) {
|
||||
tempList.add(StringUtils.EMPTY);
|
||||
if (fieldTypes.get(i) == 3) {
|
||||
} else if (fieldTypes.get(i) == 3) {
|
||||
tempList.add(filterInvalidDecimal(val.toString()));
|
||||
} else {
|
||||
tempList.add(val.toString());
|
||||
@ -160,4 +160,10 @@ public class ViewExportExcel {
|
||||
}
|
||||
return sourceNumberStr;
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
List<String> list = new ArrayList<>();
|
||||
list.add(null);
|
||||
System.out.println(111);
|
||||
}
|
||||
}
|
||||
|
||||
@ -21,7 +21,6 @@ import io.dataease.dto.chart.ChartViewDTO;
|
||||
import io.dataease.dto.dataset.DataSetGroupDTO;
|
||||
import io.dataease.dto.dataset.DataSetTableDTO;
|
||||
import io.dataease.dto.dataset.DataSetTaskDTO;
|
||||
import io.dataease.plugins.common.dto.dataset.DataTableInfoDTO;
|
||||
import io.dataease.dto.panel.PanelExport2App;
|
||||
import io.dataease.dto.panel.PanelGroupDTO;
|
||||
import io.dataease.dto.panel.PanelTemplateFileDTO;
|
||||
@ -32,6 +31,7 @@ import io.dataease.listener.util.CacheUtils;
|
||||
import io.dataease.plugins.common.base.domain.*;
|
||||
import io.dataease.plugins.common.base.mapper.*;
|
||||
import io.dataease.plugins.common.constants.DeTypeConstants;
|
||||
import io.dataease.plugins.common.dto.dataset.DataTableInfoDTO;
|
||||
import io.dataease.plugins.common.exception.DataEaseException;
|
||||
import io.dataease.plugins.common.request.chart.ChartExtFilterRequest;
|
||||
import io.dataease.plugins.common.request.permission.DatasetRowPermissionsTreeItem;
|
||||
@ -329,6 +329,10 @@ public class PanelGroupService {
|
||||
DeLogUtils.save(sysLogDTO);
|
||||
}
|
||||
|
||||
public String getPanelName(String panelId) {
|
||||
return extPanelGroupMapper.queryPanelName(panelId);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @param panelId
|
||||
@ -722,10 +726,10 @@ public class PanelGroupService {
|
||||
composePermission.add(customFilterPermission);
|
||||
}
|
||||
dataSetExportRequest.setExpressionTree(gson.toJson(permissionsTreeObjFilter));
|
||||
} else if(StringUtils.isNotEmpty(permissionsTreeObjCustomsFilter.getLogic())){
|
||||
} else if (StringUtils.isNotEmpty(permissionsTreeObjCustomsFilter.getLogic())) {
|
||||
dataSetExportRequest.setExpressionTree(customFilter);
|
||||
}
|
||||
dataSetExportRequest.setFilename(request.getViewName()+"-details");
|
||||
dataSetExportRequest.setFilename(request.getViewName() + "-details");
|
||||
|
||||
return dataSetExportRequest;
|
||||
}
|
||||
|
||||
@ -314,6 +314,7 @@ export default {
|
||||
hasDataPermission('export', this.$store.state.panel.panelInfo.privileges) &&
|
||||
this.chart &&
|
||||
this.chart.dataFrom !== 'template' &&
|
||||
this.chart.type === 'table-pivot' &&
|
||||
JSON.parse(this.chart.customAttr).size?.tableLayoutMode !== 'tree'
|
||||
},
|
||||
enlargeShow() {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user