Преглед изворни кода

[add rpc api] existExamRecordData

deason пре 3 година
родитељ
комит
764da9ffd2

+ 12 - 12
examcloud-core-oe-student-api-client/src/main/java/cn/com/qmth/examcloud/core/oe/student/client/ExamRecordDataCloudServiceClient.java

@@ -1,21 +1,20 @@
 package cn.com.qmth.examcloud.core.oe.student.client;
 
+import cn.com.qmth.examcloud.core.oe.student.api.ExamRecordDataCloudService;
 import cn.com.qmth.examcloud.core.oe.student.api.request.*;
 import cn.com.qmth.examcloud.core.oe.student.api.response.*;
 import org.springframework.stereotype.Service;
 
-import cn.com.qmth.examcloud.core.oe.student.api.ExamRecordDataCloudService;
-
 @Service("examRecordDataCloudService")
-public class ExamRecordDataCloudServiceClient extends AbstractCloudClientSupport
-		implements
-		ExamRecordDataCloudService {
+public class ExamRecordDataCloudServiceClient extends AbstractCloudClientSupport implements ExamRecordDataCloudService {
 
-    /**
-     *
-     */
     private static final long serialVersionUID = 3745318048361113898L;
 
+    @Override
+    public ExistExamRecordDataResp existExamRecordData(ExistExamRecordDataReq req) {
+        return post("examRecordData/existExamRecordData", req, ExistExamRecordDataResp.class);
+    }
+
     @Override
     public GetExamRecordDataIdsResp getExamRecordDataIds(GetExamRecordDataIdsReq req) {
         return post("examRecordData/getExamRecordDataIds", req, GetExamRecordDataIdsResp.class);
@@ -118,8 +117,9 @@ public class ExamRecordDataCloudServiceClient extends AbstractCloudClientSupport
         return post("examRecordData/updatePartialExamRecord", req, UpdatePartialExamRecordResp.class);
     }
 
-	@Override
-	public CheckPaperInExamResp checkPaperInExam(CheckPaperInExamReq req) {
-		return post("examRecordData/checkPaperInExam", req, CheckPaperInExamResp.class);
-	}
+    @Override
+    public CheckPaperInExamResp checkPaperInExam(CheckPaperInExamReq req) {
+        return post("examRecordData/checkPaperInExam", req, CheckPaperInExamResp.class);
+    }
+
 }

+ 13 - 27
examcloud-core-oe-student-api/src/main/java/cn/com/qmth/examcloud/core/oe/student/api/ExamRecordDataCloudService.java

@@ -1,35 +1,16 @@
 package cn.com.qmth.examcloud.core.oe.student.api;
 
 import cn.com.qmth.examcloud.api.commons.CloudService;
-import cn.com.qmth.examcloud.core.oe.student.api.request.CalcExamScoreReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.CalcFaceBiopsyResultReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.CheckPaperInExamReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.GetExamFaceLivenessVerifiesReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.GetExamRecordDataIdsReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.GetExamRecordNumReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.GetExamRecordPaperStructReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.GetExamRecordQuestionsReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.GetFaceBiopsyReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.HandInExamReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.UpdateExamRecordDataBatchNumReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.UpdateExamRecordStatusReq;
-import cn.com.qmth.examcloud.core.oe.student.api.request.UpdatePartialExamRecordReq;
-import cn.com.qmth.examcloud.core.oe.student.api.response.CalcExamScoreResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.CalcFaceBiopsyResultResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.CheckPaperInExamResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.GetExamFaceLivenessVerifiesResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.GetExamRecordDataIdsResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.GetExamRecordNumResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.GetExamRecordPaperStructResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.GetExamRecordQuestionsResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.GetFaceBiopsyResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.HandInExamResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.UpdateExamRecordDataBatchNumResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.UpdateExamRecordStatusResp;
-import cn.com.qmth.examcloud.core.oe.student.api.response.UpdatePartialExamRecordResp;
+import cn.com.qmth.examcloud.core.oe.student.api.request.*;
+import cn.com.qmth.examcloud.core.oe.student.api.response.*;
 
 public interface ExamRecordDataCloudService extends CloudService {
 
+    /**
+     * 查询是否存在考试记录
+     */
+    ExistExamRecordDataResp existExamRecordData(ExistExamRecordDataReq req);
+
     GetExamRecordDataIdsResp getExamRecordDataIds(GetExamRecordDataIdsReq req);
 
     UpdateExamRecordDataBatchNumResp updateExamRecordDataBatchNum(UpdateExamRecordDataBatchNumReq req);
@@ -52,6 +33,7 @@ public interface ExamRecordDataCloudService extends CloudService {
 
     /**
      * 获取旧活体检测结果
+     *
      * @param req
      * @return
      */
@@ -59,6 +41,7 @@ public interface ExamRecordDataCloudService extends CloudService {
 
     /**
      * 获取新活检
+     *
      * @param req
      * @return
      */
@@ -80,6 +63,7 @@ public interface ExamRecordDataCloudService extends CloudService {
 
     /**
      * 获取考试记录数量
+     *
      * @param req
      * @return
      */
@@ -87,10 +71,12 @@ public interface ExamRecordDataCloudService extends CloudService {
 
     /**
      * 更新部分考试数据
+     *
      * @param req
      * @return
      */
     UpdatePartialExamRecordResp updatePartialExamRecord(UpdatePartialExamRecordReq req);
-    
+
     CheckPaperInExamResp checkPaperInExam(CheckPaperInExamReq req);
+
 }

+ 48 - 0
examcloud-core-oe-student-api/src/main/java/cn/com/qmth/examcloud/core/oe/student/api/request/ExistExamRecordDataReq.java

@@ -0,0 +1,48 @@
+package cn.com.qmth.examcloud.core.oe.student.api.request;
+
+import cn.com.qmth.examcloud.api.commons.exchange.BaseRequest;
+
+public class ExistExamRecordDataReq extends BaseRequest {
+
+    private static final long serialVersionUID = -2218185239574140092L;
+
+    /**
+     * 考试ID
+     */
+    private Long examId;
+
+    /**
+     * 学生ID
+     */
+    private Long studentId;
+
+    /**
+     * 课程ID
+     */
+    private Long courseId;
+
+    public Long getExamId() {
+        return examId;
+    }
+
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
+
+    public Long getStudentId() {
+        return studentId;
+    }
+
+    public void setStudentId(Long studentId) {
+        this.studentId = studentId;
+    }
+
+    public Long getCourseId() {
+        return courseId;
+    }
+
+    public void setCourseId(Long courseId) {
+        this.courseId = courseId;
+    }
+
+}

+ 27 - 0
examcloud-core-oe-student-api/src/main/java/cn/com/qmth/examcloud/core/oe/student/api/response/ExistExamRecordDataResp.java

@@ -0,0 +1,27 @@
+package cn.com.qmth.examcloud.core.oe.student.api.response;
+
+import cn.com.qmth.examcloud.api.commons.exchange.BaseResponse;
+
+public class ExistExamRecordDataResp extends BaseResponse {
+
+    private static final long serialVersionUID = -256317254513358255L;
+
+    private Boolean existed;
+
+    public ExistExamRecordDataResp(Boolean existed) {
+        this.existed = existed;
+    }
+
+    public ExistExamRecordDataResp() {
+
+    }
+
+    public Boolean getExisted() {
+        return existed;
+    }
+
+    public void setExisted(Boolean existed) {
+        this.existed = existed;
+    }
+
+}