Commit 719521a3 authored by liuChang's avatar liuChang

bug修复

parent 7fc4ec02
......@@ -47,13 +47,7 @@ public class ExportService {
private String EXPORT_BACK_URL;
public AjaxResult aptitudeFile(MultipartFile file) throws Exception {
int exportCount = 1;
if (RedisUtils.hasKey("aptitudeFileExportCount")){
exportCount = RedisUtils.getCacheObject("aptitudeFileExportCount");
if (exportCount>=3000){
return AjaxResult.error("每天最多导出3次");
}
}
ComposeQueryDto composeQueryDto = new ComposeQueryDto();
//识别Excel内容
......@@ -87,8 +81,6 @@ public class ExportService {
composeQueryDto.setExportBackUrl(EXPORT_BACK_URL);
composeQueryDto.setExportExeclName(fileName);
dskOpenApiUtil.requestBody("/operate/export/zjyj/aptitude", BeanUtil.beanToMap(composeQueryDto,false,false));
RedisUtils.setCacheObject("aptitudeFileExportCount",exportCount+1);
RedisUtils.expire("aptitudeFileExportCount", Duration.ofHours(24));
return AjaxResult.success();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment