wangwei 6 vuotta sitten
vanhempi
commit
8df851b51b

+ 2 - 0
examcloud-core-examwork-api-provider/src/main/java/cn/com/qmth/examcloud/core/examwork/api/provider/ExamStudentCloudServiceProvider.java

@@ -175,6 +175,8 @@ public class ExamStudentCloudServiceProvider extends ControllerSupport
 			if (null == finded) {
 				ExamStudentEntity one = new ExamStudentEntity();
 				one.setCourseId(es.getCourseId());
+				one.setCourseCode(es.getCourseCode());
+				one.setCourseLevel(es.getCourseLevel());
 				one.setEnable(es.getEnable());
 				one.setExamId(examId2);
 				one.setExamSite(es.getExamSite());

+ 14 - 0
examcloud-core-examwork-dao/src/main/java/cn/com/qmth/examcloud/core/examwork/dao/entity/ExamStudentEntity.java

@@ -70,6 +70,12 @@ public class ExamStudentEntity extends JpaEntity {
 	@Column(nullable = false)
 	private Long courseId;
 
+	/**
+	 * 课程ID
+	 */
+	@Column(nullable = false)
+	private String courseCode;
+
 	/**
 	 * 课程等级
 	 */
@@ -245,4 +251,12 @@ public class ExamStudentEntity extends JpaEntity {
 		this.courseLevel = courseLevel;
 	}
 
+	public String getCourseCode() {
+		return courseCode;
+	}
+
+	public void setCourseCode(String courseCode) {
+		this.courseCode = courseCode;
+	}
+
 }

+ 1 - 0
examcloud-core-examwork-service/src/main/java/cn/com/qmth/examcloud/core/examwork/service/impl/ExamStudentServiceImpl.java

@@ -177,6 +177,7 @@ public class ExamStudentServiceImpl implements ExamStudentService {
 		examStudent.setRootOrgId(rootOrgId);
 
 		examStudent.setCourseId(courseBean.getId());
+		examStudent.setCourseCode(courseBean.getCode());
 		examStudent.setCourseLevel(courseBean.getLevel());
 
 		examStudent.setExamId(exam.getId());