Forráskód Böngészése

新增新版考勤导入模版

anderx 1 éve%!(EXTRA string=óta)
szülő
commit
e74ccf0110

+ 2 - 5
ruoyi-admin/src/main/java/com/ruoyi/web/controller/project/ProjectTaskController.java

@@ -508,16 +508,13 @@ public class ProjectTaskController extends BaseController {
     @Log(title = "项目管理", businessType = BusinessType.IMPORT)
     @ApiOperation("考勤打卡导入模版")
     public void importClockDataTemplate(HttpServletResponse response){
-        try
-        {
+        try{
             String realFileName = System.currentTimeMillis() + "_考勤模版".substring("考勤模版".indexOf("_") + 1);
             String filePath = RuoYiConfig.getDownloadPath() + "考勤模版.xlsx";
             response.setContentType(MediaType.APPLICATION_OCTET_STREAM_VALUE);
             FileUtils.setAttachmentResponseHeader(response, realFileName);
             FileUtils.writeBytes(filePath, response.getOutputStream());
-        }
-        catch (Exception e)
-        {
+        }catch (Exception e){
             throw new ServiceException("下载文件失败", HttpStatus.SC_BAD_REQUEST);
         }
     }