|
@@ -112,12 +112,13 @@ public class ResumeController extends BaseController
|
|
String originalFilename = file.getOriginalFilename();
|
|
String originalFilename = file.getOriginalFilename();
|
|
String suffix = originalFilename.substring(originalFilename.lastIndexOf("."));
|
|
String suffix = originalFilename.substring(originalFilename.lastIndexOf("."));
|
|
String fileName = FileUploadUtils.upload(path, file);
|
|
String fileName = FileUploadUtils.upload(path, file);
|
|
|
|
+ String newFileName = com.ruoyi.common.utils.file.FileUtils.getName(fileName);
|
|
|
|
|
|
// 上传位置
|
|
// 上传位置
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd");
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd");
|
|
String ymd = sdf.format(new Date());
|
|
String ymd = sdf.format(new Date());
|
|
String lastPath = "/" + ymd + "/";
|
|
String lastPath = "/" + ymd + "/";
|
|
- String fileUrl = path + lastPath + fileName;
|
|
|
|
|
|
+ String fileUrl = path + lastPath + newFileName;
|
|
|
|
|
|
if(suffix.equals(".doc")||suffix.equals(".docx")){
|
|
if(suffix.equals(".doc")||suffix.equals(".docx")){
|
|
List<String> content = null;
|
|
List<String> content = null;
|
|
@@ -134,7 +135,6 @@ public class ResumeController extends BaseController
|
|
Resume resume = ResumeAnalysisUtil.toResumeAnalysis(content);
|
|
Resume resume = ResumeAnalysisUtil.toResumeAnalysis(content);
|
|
//处理文件信息
|
|
//处理文件信息
|
|
String url = serverConfig.getUrl() + fileName;
|
|
String url = serverConfig.getUrl() + fileName;
|
|
- String newFileName = com.ruoyi.common.utils.file.FileUtils.getName(fileName);
|
|
|
|
ResumeFile resumeFile = new ResumeFile();
|
|
ResumeFile resumeFile = new ResumeFile();
|
|
resumeFile.setUploadPath(url);
|
|
resumeFile.setUploadPath(url);
|
|
resumeFile.setUploadName(newFileName);
|
|
resumeFile.setUploadName(newFileName);
|