Commit 5933e107 authored by 陈宏杰's avatar 陈宏杰

encryptFile

parent 47c2d419
......@@ -3,21 +3,17 @@ package cn.quantgroup.report.controller;
import cn.quantgroup.report.response.GlobalResponse;
import cn.quantgroup.report.service.baihang.BaiHangFileReportService;
import cn.quantgroup.report.service.baihang.BaiHangZhuDaiService;
import cn.quantgroup.report.service.common.CommonQueryService;
import cn.quantgroup.report.service.manualTool.CleanningTransactionLogService;
import cn.quantgroup.report.service.manualTool.ManualToolService;
import cn.quantgroup.report.utils.DateUtils;
import com.alibaba.fastjson.JSON;
import com.google.common.base.Stopwatch;
import com.google.common.collect.ImmutableMap;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.Date;
import java.io.File;
import java.util.Map;
import java.util.concurrent.TimeUnit;
@Slf4j
@RestController
......@@ -168,4 +164,15 @@ public class ManualToolController {
}
}
@RequestMapping("/encryptFile")
public String encryptFile(String filePath){
try {
File file = new File(filePath);
fileReportService.encryptFile(file.getAbsolutePath());
return "SUCCESS";
}catch (Exception e){
return e.getMessage();
}
}
}
......@@ -348,4 +348,8 @@ public class BaiHangFileReportService {
}
return str.replaceAll("-","").replaceAll(":","").replaceAll(" ","");
}
public void encryptFile(String filePath){
createFile(filePath);
}
}
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