Ver Fonte

后端联调

weiwenhai há 7 anos atrás
pai
commit
3dfcb50cd8

+ 4 - 5
examcloud-core-questions-service/src/main/java/cn/com/qmth/examcloud/core/questions/service/impl/ExtractConfigFileServiceImpl.java

@@ -131,11 +131,10 @@ public class ExtractConfigFileServiceImpl implements ExtractConfigFileService {
 	@Override
 	public void saveExtractConfigAndBuildPaperFile(ExtractConfig extractConfig,Integer isbuildFile,User user) throws Exception {
 		//查询试卷导出设置
-		/* 调卷规则保存,不需要查询试卷结构
 		ExportStructure exportStructure = null;
 		if(isbuildFile==1){
 			exportStructure = exportStructureService.findStructureByExamId(extractConfig.getExamId()+"");
-		}*/
+		}
 		//生成试卷
 		Map<String, String> finishedPaperIdMap = extractConfigService.saveExtractConfig(extractConfig,user);
     	if(isbuildFile==1){
@@ -151,7 +150,7 @@ public class ExtractConfigFileServiceImpl implements ExtractConfigFileService {
     		while(iterator.hasNext()){
     			Entry<String,String> entry = iterator.next();
     			String paperId = entry.getValue();
-    			uploadPaperFile(extractConfig,paperId,user);
+    			uploadPaperFile(extractConfig,paperId,exportStructure,user);
     		}
     	}
 	}
@@ -164,13 +163,13 @@ public class ExtractConfigFileServiceImpl implements ExtractConfigFileService {
 	 * @param accessUser
 	 * @throws Exception
 	 */
-	private void uploadPaperFile(ExtractConfig extractConfig,String paperId,User user) throws Exception {
+	private void uploadPaperFile(ExtractConfig extractConfig,String paperId,ExportStructure exportStructure,User user) throws Exception {
 		ExportServiceManage esm = exportServiceManageRepo.findByOrgName(user.getRootOrgName());
 		if(esm == null){
 			esm = exportServiceManageRepo.findByOrgName("陕西师范大学");
 		}
     	ExportPaperAbstractService exportPaperAbstractService = (ExportPaperAbstractService) SpringContextUtils.getBeanById(esm.getExportServiceName());
-    	exportPaperAbstractService.uploadFile(extractConfig,paperId,user);
+    	exportPaperAbstractService.uploadFile(extractConfig,paperId,exportStructure,user);
 	}
 	
     @Override

+ 2 - 2
examcloud-core-questions-starter/src/main/java/cn/com/qmth/examcloud/core/questions/starter/config/DefaultWebMvcConfigurerAdapter.java

@@ -133,9 +133,9 @@ public class DefaultWebMvcConfigurerAdapter extends WebMvcConfigurerAdapter {
 		String[] exclusions = new String[]{
 				".*/export/.*",
 //				".*/importPaper/.*",
-//				"^.*/import.*$",
+//				"^.*/import.*$",/extractQues/
 				".*/ecs_ques/extract/.*",
-				".*/ecs_ques/extractQues/.*",
+				".*/extractQues/.*",
 				".*/ecs_ques/checkObjective/.*",
 				"ecs_ques/uploadRadio",
 				"pdf","ecs_ques/paper",