|
@@ -21,18 +21,8 @@ public interface AdminUserMapper extends BaseMapperX<AdminUserDO> {
|
|
|
|
|
|
List<AdminUserDO> getStudentSelectExternalSupervisorsList(@Param("projectId")Long projectId) ;
|
|
|
|
|
|
- @Update("<script>" +
|
|
|
- "UPDATE system_users " +
|
|
|
- "SET supervisor_id = CASE id " +
|
|
|
- "<foreach collection='updateVO' item='entry' separator=' '>" +
|
|
|
- "WHEN #{entry.studentId} THEN #{entry.supervisorId} " +
|
|
|
- "</foreach>" +
|
|
|
- "WHERE id IN " +
|
|
|
- "<foreach collection='updateVO' item='entry' open='(' separator=',' close=')'>" +
|
|
|
- "#{entry.studentId}" +
|
|
|
- "</foreach>" +
|
|
|
- "</script>")
|
|
|
- void updateInnerSupervisors(@Param("updateVO") List<Map<String, Long>> updateVO);
|
|
|
+ @Update("UPDATE system_users SET supervisor_id = #{supervisorId} WHERE id = #{studentId}")
|
|
|
+ void updateInnerSupervisor(@Param("studentId") Long studentId, @Param("supervisorId") Long supervisorId);
|
|
|
|
|
|
default AdminUserDO selectByUsername(String username) {
|
|
|
return selectOne(AdminUserDO::getUsername, username);
|