wangwei 7 лет назад
Родитель
Сommit
5bff372a5e

+ 13 - 0
examcloud-core-basic-service/src/main/java/cn/com/qmth/examcloud/core/basic/service/bean/StudentInfo.java

@@ -28,6 +28,11 @@ public class StudentInfo implements JsonSerializable {
 	 */
 	private Long rootOrgId;
 
+	/**
+	 * 顶级机构名称
+	 */
+	private String rootOrgName;
+
 	/**
 	 * 机构ID
 	 */
@@ -102,6 +107,14 @@ public class StudentInfo implements JsonSerializable {
 		this.rootOrgId = rootOrgId;
 	}
 
+	public String getRootOrgName() {
+		return rootOrgName;
+	}
+
+	public void setRootOrgName(String rootOrgName) {
+		this.rootOrgName = rootOrgName;
+	}
+
 	public Long getOrgId() {
 		return orgId;
 	}

+ 2 - 0
examcloud-core-basic-service/src/main/java/cn/com/qmth/examcloud/core/basic/service/impl/StudentServiceImpl.java

@@ -311,6 +311,8 @@ public class StudentServiceImpl implements StudentService {
 		info.setPhotoPath(s.getPhotoPath());
 		info.setRemark(s.getRemark());
 		info.setRootOrgId(s.getRootOrgId());
+		Org rootOrg = orgRepo.findOne(s.getRootOrgId());
+		info.setRootOrgName(rootOrg.getName());
 		info.setSecurityPhone(s.getSecurityPhone());
 		info.setStudentCode(s.getStudentCode());