ting.yin 8 éve
szülő
commit
2bea1d2b8b

+ 1 - 1
exam-work-api/src/main/java/cn/com/qmth/examcloud/service/examwork/api/ExamStudentApi.java

@@ -109,7 +109,7 @@ public class ExamStudentApi {
     }
     
     @ApiOperation(value="照片检验",notes = "检验")
-    @PostMapping("/photo_check")
+    @PostMapping("/exam_student/photo_check")
     public ResponseEntity photoCheck(@RequestParam Long examId){
     	try {
     		List<ErrorMsg> errorMsgs = examStudentService.photoCheck(examId);

+ 1 - 1
exam-work-api/src/main/java/cn/com/qmth/examcloud/service/examwork/service/ExamStudentService.java

@@ -265,7 +265,7 @@ public class ExamStudentService {
 			JSONArray faceArray = face.getJSONArray("face");
 			if (faceArray.length() > 0) {
 				//人脸识别成功
-				studentService.updatePhoto(identityNumber);
+//				studentService.updatePhoto(identityNumber);
 			} else {
 				error = new ErrorMsg(identityNumber + JPG + "不能被识别人脸,请换一张清晰的照片重新上传!");
 			}

+ 8 - 8
exam-work-api/src/main/java/cn/com/qmth/examcloud/service/examwork/service/rpc/StudentService.java

@@ -15,13 +15,13 @@ import cn.com.qmth.examcloud.service.examwork.service.rpc.client.StudentClient;
 @Service
 public class StudentService {
 
-	@Autowired
-	StudentClient studentClient;
-
-	public Student updatePhoto(String identityNumber) {
-		String json = studentClient.updatePhoto(identityNumber);
-		Student domain = GsonUtil.getInstanceByJson(json, Student.class);
-		return domain;
-	}
+//	@Autowired
+//	StudentClient studentClient;
+//
+//	public Student updatePhoto(String identityNumber) {
+//		String json = studentClient.updatePhoto(identityNumber);
+//		Student domain = GsonUtil.getInstanceByJson(json, Student.class);
+//		return domain;
+//	}
 
 }

+ 3 - 3
exam-work-api/src/main/java/cn/com/qmth/examcloud/service/examwork/service/rpc/client/StudentClient.java

@@ -10,10 +10,10 @@ import org.springframework.web.bind.annotation.RequestParam;
  * @author ting.yin
  * @date 2017年1月14日
  */
-@FeignClient(value = "ExamCloud-service-core")
+//@FeignClient(value = "ExamCloud-service-core")
 public interface StudentClient {
 
-	@RequestMapping(method = RequestMethod.PUT, value = "${app.api.core}/student/update")
-	String updatePhoto(@RequestParam("identityNumber") String identityNumber);
+//	@RequestMapping(method = RequestMethod.GET, value = "${app.api.core}/student/update")
+//	String updatePhoto(@RequestParam("identityNumber") String identityNumber);
 
 }

+ 2 - 2
exam-work-main/src/main/java/cn/com/qmth/examcloud/service/examwork/Application.java

@@ -6,8 +6,8 @@ import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
 import org.springframework.cloud.netflix.feign.EnableFeignClients;
 
 @SpringBootApplication
-@EnableEurekaClient
-@EnableFeignClients
+//@EnableEurekaClient
+//@EnableFeignClients
 public class Application {
 
 	public static void main(String[] args) throws Exception {

+ 1 - 0
exam-work-main/src/main/resources/application.properties

@@ -26,6 +26,7 @@ spring.application.name=ExamCloud-service-exam-work
 server.port=8001
 eureka.client.serviceUrl.defaultZone=http://localhost:1111/eureka/
 app.api.root=/api/ecs_exam_work
+app.api.core=/api/ecs_core
 #\u5b66\u751f\u7167\u7247\u4e0a\u4f20\u5730\u5740
 app.em.photo.path=/Users/ting.yin/Downloads
 app.em.facepp.key=e94d4a6a1ea8749144328be96a40e388