Commit 4fd48bde authored by huyuchen's avatar huyuchen

huyc 项目档案代码提交

parent ed2e66d9
......@@ -30,7 +30,6 @@ import com.yifu.cloud.plus.v1.yifu.archives.service.TElecEmployeeInfoService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeInfoService;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.SecurityConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.util.ClassUtils;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.common.core.vo.FileVo;
......@@ -40,10 +39,8 @@ import lombok.RequiredArgsConstructor;
import org.apache.commons.fileupload.FileItem;
import org.apache.commons.fileupload.FileItemFactory;
import org.apache.commons.fileupload.disk.DiskFileItemFactory;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.stereotype.Service;
import org.springframework.util.ResourceUtils;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.commons.CommonsMultipartFile;
......@@ -95,10 +92,8 @@ public class TElecEmployeeInfoServiceImpl extends ServiceImpl<TElecEmployeeInfoM
@Override
public R importZip(MultipartFile zipFile){
try {
// String pathName = ResourceUtils.getURL("classpath:").getPath() + "unloap/";
// String dec = ResourceUtils.getURL("classpath:").getPath() + "unloap/";
String pathName = ClassUtils.getDefaultClassLoader().getResource("").getPath();
String dec = ClassUtils.getDefaultClassLoader().getResource("").getPath();
String pathName = System.getProperty("java.io.tmpdir");
String dec = System.getProperty("java.io.tmpdir");
File file1 = new File(pathName);
//如果文件夹不存在 创建文件夹
if (!file1.exists()) {
......
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