wangwei 6 年之前
父节点
当前提交
7738ab7f8a

+ 2 - 0
examcloud-core-basic-api-provider/src/main/java/cn/com/qmth/examcloud/core/basic/api/controller/CourseController.java

@@ -14,6 +14,7 @@ import javax.servlet.http.HttpServletResponse;
 
 import org.apache.commons.collections.CollectionUtils;
 import org.apache.commons.fileupload.disk.DiskFileItem;
+import org.apache.commons.io.FileUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.data.domain.Page;
@@ -405,6 +406,7 @@ public class CourseController extends ControllerSupport {
 
 		exportFile("课程列表-" + getRootOrgId() + ".xlsx", file);
 
+		FileUtils.deleteQuietly(file);
 	}
 
 	/**