Commit c63905b5 authored by hongguangwu's avatar hongguangwu

MVP1.6.6-预入职相关_导出优化

parent f9d8c0b6
...@@ -79,8 +79,8 @@ public class FileUploadController { ...@@ -79,8 +79,8 @@ public class FileUploadController {
"\t\t\t@ApiImplicitParam(name = \"domain\", value = \"实体id(传入就插入对应关系,用于编辑)\", required = false, paramType = \"form\")\n" + "\t\t\t@ApiImplicitParam(name = \"domain\", value = \"实体id(传入就插入对应关系,用于编辑)\", required = false, paramType = \"form\")\n" +
"\t") "\t")
@PostMapping(value = "/uploadFileReturnAtta") @PostMapping(value = "/uploadFileReturnAtta")
public R<TAttaInfo> uploadFileReturnAtta(@RequestBody MultipartFile file, String filePath, Integer type, String domain) throws IOException { public R<TAttaInfo> uploadFileReturnAtta(@RequestBody MultipartFile file, String filePath, Integer type, String domainId) throws IOException {
return fileUploadService.uploadFileReturnAtta(file,filePath,type,domain); return fileUploadService.uploadFileReturnAtta(file,filePath,type,domainId);
} }
/** /**
......
...@@ -17,7 +17,7 @@ public interface FileUploadService { ...@@ -17,7 +17,7 @@ public interface FileUploadService {
R<FileVo> uploadImg(MultipartFile file, String filePath, Integer type, String domain) throws IOException; R<FileVo> uploadImg(MultipartFile file, String filePath, Integer type, String domain) throws IOException;
R<TAttaInfo> uploadFileReturnAtta(MultipartFile file, String filePath, Integer type, String domain) throws IOException; R<TAttaInfo> uploadFileReturnAtta(MultipartFile file, String filePath, Integer type, String domainId) throws IOException;
R<FileVo> createQrCode(String domainId, String url, String name); R<FileVo> createQrCode(String domainId, String url, String name);
} }
...@@ -40,7 +40,7 @@ public class FileUploadServiceImpl implements FileUploadService { ...@@ -40,7 +40,7 @@ public class FileUploadServiceImpl implements FileUploadService {
private final QrCodeUtil codeUtil; private final QrCodeUtil codeUtil;
@Override @Override
public R<TAttaInfo> uploadFileReturnAtta(MultipartFile file, String filePath, Integer type, String domain) throws IOException { public R<TAttaInfo> uploadFileReturnAtta(MultipartFile file, String filePath, Integer type, String domainId) throws IOException {
if (null == file) { if (null == file) {
return R.failed("文件删除异常,请重新上传!"); return R.failed("文件删除异常,请重新上传!");
} }
...@@ -70,7 +70,7 @@ public class FileUploadServiceImpl implements FileUploadService { ...@@ -70,7 +70,7 @@ public class FileUploadServiceImpl implements FileUploadService {
attaInfo = initUnitAttaForInsert(fileName, key, file.getSize()); attaInfo = initUnitAttaForInsert(fileName, key, file.getSize());
attaInfo.setRelationType(String.valueOf(type)); attaInfo.setRelationType(String.valueOf(type));
try { try {
attaInfo.setDomainId(domain); attaInfo.setDomainId(domainId);
Set<String> dbAuthsSet = new HashSet<>(); Set<String> dbAuthsSet = new HashSet<>();
Collection<? extends GrantedAuthority> authorities = AuthorityUtils Collection<? extends GrantedAuthority> authorities = AuthorityUtils
......
...@@ -1325,7 +1325,6 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE ...@@ -1325,7 +1325,6 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
attaEmp.setCreateTime(LocalDateTime.now()); attaEmp.setCreateTime(LocalDateTime.now());
attaEmpList.add(attaEmp); attaEmpList.add(attaEmp);
} }
tAttaInfoService.saveOrUpdateBatch(attaList);
tAttaInfoService.saveBatch(attaEmpList); tAttaInfoService.saveBatch(attaEmpList);
} }
return R.ok("成功!"); return R.ok("成功!");
......
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