feat: oss
This commit is contained in:
32
sms-auth/sms-auth-domain/pom.xml
Normal file
32
sms-auth/sms-auth-domain/pom.xml
Normal file
@@ -0,0 +1,32 @@
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.landaiqing</groupId>
|
||||
<artifactId>sms-auth</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>sms-auth-domain</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>sms-auth-domain</name>
|
||||
<url>http://maven.apache.org</url>
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.landaiqing</groupId>
|
||||
<artifactId>sms-auth-infra</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.landaiqing</groupId>
|
||||
<artifactId>sms-auth-common</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
@@ -0,0 +1,43 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (AdminBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:28:30
|
||||
*/
|
||||
@Data
|
||||
public class AdminBO implements Serializable {
|
||||
|
||||
private Long id;
|
||||
|
||||
private String username;
|
||||
|
||||
private String password;
|
||||
/**
|
||||
* 角色id
|
||||
*/
|
||||
private Integer roleId;
|
||||
|
||||
private Integer isDeleted;
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private String createdBy;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createdTime;
|
||||
/**
|
||||
* 更新人
|
||||
*/
|
||||
private String updateBy;
|
||||
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,50 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* (ClazzBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:44:00
|
||||
*/
|
||||
public class ClazzBO implements Serializable {
|
||||
private static final long serialVersionUID = -14659318323663338L;
|
||||
|
||||
private Integer id;
|
||||
/**
|
||||
* 班级名称
|
||||
*/
|
||||
private String className;
|
||||
/**
|
||||
* 班级人数
|
||||
*/
|
||||
private Integer num;
|
||||
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getClassName() {
|
||||
return className;
|
||||
}
|
||||
|
||||
public void setClassName(String className) {
|
||||
this.className = className;
|
||||
}
|
||||
|
||||
public Integer getNum() {
|
||||
return num;
|
||||
}
|
||||
|
||||
public void setNum(Integer num) {
|
||||
this.num = num;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,43 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (CounselorBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:29:04
|
||||
*/
|
||||
@Data
|
||||
public class CounselorBO implements Serializable {
|
||||
|
||||
private Long id;
|
||||
|
||||
private String username;
|
||||
|
||||
private String password;
|
||||
/**
|
||||
* 角色id
|
||||
*/
|
||||
private Integer roleId;
|
||||
|
||||
private Integer isDeleted;
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private String createdBy;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createdTime;
|
||||
/**
|
||||
* 更新人
|
||||
*/
|
||||
private String updateBy;
|
||||
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,28 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* (GradeBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:29:20
|
||||
*/
|
||||
@Data
|
||||
public class GradeBO implements Serializable {
|
||||
|
||||
private Long id;
|
||||
/**
|
||||
* 年级
|
||||
*/
|
||||
private String gradeName;
|
||||
/**
|
||||
* 年级人数
|
||||
*/
|
||||
private Long num;
|
||||
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,54 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (PermissionBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:29:35
|
||||
*/
|
||||
@Data
|
||||
public class PermissionBO implements Serializable {
|
||||
|
||||
private Long id;
|
||||
|
||||
private String name;
|
||||
|
||||
private Long parentId;
|
||||
|
||||
private Integer type;
|
||||
|
||||
private String menuUrl;
|
||||
|
||||
private Integer status;
|
||||
|
||||
private Integer show;
|
||||
|
||||
private String icon;
|
||||
|
||||
private String permissionKey;
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private String createdBy;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createdTime;
|
||||
/**
|
||||
* 更新人
|
||||
*/
|
||||
private String updateBy;
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
private Integer isDeleted;
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,43 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (RoleBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:29:56
|
||||
*/
|
||||
@Data
|
||||
public class RoleBO implements Serializable {
|
||||
|
||||
private Long id;
|
||||
|
||||
private String roleName;
|
||||
|
||||
private String roleKey;
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private String createdBy;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createdTime;
|
||||
/**
|
||||
* 更新人
|
||||
*/
|
||||
private String updateBy;
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
private Integer isDeleted;
|
||||
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,43 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (RolePermissionBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:30:14
|
||||
*/
|
||||
@Data
|
||||
public class RolePermissionBO implements Serializable {
|
||||
|
||||
private Long id;
|
||||
|
||||
private Long roleId;
|
||||
|
||||
private Long permissionId;
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private String createdBy;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createdTime;
|
||||
/**
|
||||
* 更新人
|
||||
*/
|
||||
private String updateBy;
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
private Integer isDeleted;
|
||||
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,85 @@
|
||||
package com.landaiqing.domain.bo;
|
||||
|
||||
import com.landaiqing.auth.common.entity.PageInfo;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (StudentBO)实体类
|
||||
*
|
||||
* @author makejava
|
||||
* @since 2024-03-04 22:25:32
|
||||
*/
|
||||
@Data
|
||||
public class StudentBO extends PageInfo implements Serializable {
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
private Long id;
|
||||
/**
|
||||
* 学号
|
||||
*/
|
||||
private String sno;
|
||||
/**
|
||||
* 密码
|
||||
*/
|
||||
private String password;
|
||||
/**
|
||||
* 姓名
|
||||
*/
|
||||
private String username;
|
||||
/**
|
||||
* 班级
|
||||
*/
|
||||
private Integer className;
|
||||
/**
|
||||
* 年级
|
||||
*/
|
||||
private Integer grade;
|
||||
/**
|
||||
* 年龄
|
||||
*/
|
||||
private Integer age;
|
||||
/**
|
||||
* 性别
|
||||
*/
|
||||
private Integer sex;
|
||||
/**
|
||||
* 头像链接
|
||||
*/
|
||||
private String avatar;
|
||||
/**
|
||||
* 出生日期
|
||||
*/
|
||||
private Date dateOfBirth;
|
||||
/**
|
||||
* email
|
||||
*/
|
||||
private String email;
|
||||
/**
|
||||
* 电话
|
||||
*/
|
||||
private String phoneNumber;
|
||||
/**
|
||||
* 班级id
|
||||
*/
|
||||
private Long classId;
|
||||
/**
|
||||
* 年级id
|
||||
*/
|
||||
private Long gradeId;
|
||||
/**
|
||||
* 角色id
|
||||
*/
|
||||
private Integer roleId;
|
||||
|
||||
private Integer isDeleted;
|
||||
|
||||
private String url;
|
||||
|
||||
|
||||
}
|
||||
|
@@ -0,0 +1,15 @@
|
||||
package com.landaiqing.domain.constants;
|
||||
|
||||
/**
|
||||
* auth服务常量
|
||||
*
|
||||
* @author: landaiqing
|
||||
* @date: 2024/2/19
|
||||
*/
|
||||
public class AuthConstant {
|
||||
|
||||
public static final String STUDENT = "student";
|
||||
public static final String ADMIN = "admin";
|
||||
public static final String COUNSELOR = "counselor";
|
||||
|
||||
}
|
@@ -0,0 +1,17 @@
|
||||
package com.landaiqing.domain.convert;
|
||||
|
||||
import com.landaiqing.domain.bo.PermissionBO;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.infra.basic.entity.Permission;
|
||||
import com.landaiqing.infra.basic.entity.Student;
|
||||
import org.mapstruct.Mapper;
|
||||
import org.mapstruct.factory.Mappers;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Mapper
|
||||
public interface PermissionBOConvert {
|
||||
PermissionBOConvert INSTANCE= Mappers.getMapper(PermissionBOConvert.class);
|
||||
|
||||
List<PermissionBO> convertToboList(List<Permission> permissions);
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package com.landaiqing.domain.convert;
|
||||
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.infra.basic.entity.Student;
|
||||
import org.mapstruct.Mapper;
|
||||
import org.mapstruct.factory.Mappers;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Mapper
|
||||
public interface StudentBOConvert {
|
||||
StudentBOConvert INSTANCE= Mappers.getMapper(StudentBOConvert.class);
|
||||
Student convertBOToEntity(StudentBO studentBO);
|
||||
List<StudentBO> convertBOToDTOList(List<Student> students);
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
package com.landaiqing.domain.service;
|
||||
|
||||
import com.landaiqing.domain.bo.PermissionBO;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface PermissionDomainService {
|
||||
|
||||
List<PermissionBO> queryPermission(List<Integer> permissionList);
|
||||
}
|
@@ -0,0 +1,10 @@
|
||||
package com.landaiqing.domain.service;
|
||||
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface RolePermissionDomainService {
|
||||
|
||||
List<Integer> queryPermissionByRoleId(Integer roleId);
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package com.landaiqing.domain.service;
|
||||
|
||||
import com.landaiqing.auth.common.entity.PageResult;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface StudentDomainService {
|
||||
|
||||
Boolean uploadAvatar(StudentBO studentBO);
|
||||
|
||||
PageResult<StudentBO> queryAllStudentByPage(StudentBO studentBO);
|
||||
|
||||
Boolean login(StudentBO studentBO);
|
||||
}
|
@@ -0,0 +1,10 @@
|
||||
package com.landaiqing.domain.service;
|
||||
|
||||
import com.landaiqing.domain.bo.PermissionBO;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface StudentPermissionDomainService {
|
||||
List<PermissionBO> queryStudentPermission(StudentBO studentBO);
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
package com.landaiqing.domain.service;
|
||||
|
||||
import com.landaiqing.domain.bo.PermissionBO;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.infra.basic.entity.Student;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface StudentRoleDomainService {
|
||||
Integer queryStudentRole(StudentBO studentBO);
|
||||
}
|
@@ -0,0 +1,34 @@
|
||||
package com.landaiqing.domain.service.impl;
|
||||
|
||||
import com.landaiqing.domain.bo.PermissionBO;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.domain.convert.PermissionBOConvert;
|
||||
import com.landaiqing.domain.service.*;
|
||||
import com.landaiqing.infra.basic.entity.Permission;
|
||||
import com.landaiqing.infra.basic.service.PermissionService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Classname StudentPermissionDomainServiceImpl
|
||||
* @BelongsProject: student-Management-system
|
||||
* @BelongsPackage: com.landaiqing.domain.service.impl
|
||||
* @Author: landaiqing
|
||||
* @CreateTime: 2024-03-05 11:59
|
||||
* @Description: TODO
|
||||
* @Version: 1.0
|
||||
*/
|
||||
@Service
|
||||
public class PermissionDomainServiceImpl implements PermissionDomainService {
|
||||
@Resource
|
||||
private PermissionService permissionService;
|
||||
|
||||
@Override
|
||||
public List<PermissionBO> queryPermission(List<Integer> permissionList) {
|
||||
List<Permission> permission= permissionService.queryPermission(permissionList);
|
||||
List<PermissionBO> permissionBOList = PermissionBOConvert.INSTANCE.convertToboList(permission);
|
||||
return permissionBOList;
|
||||
}
|
||||
}
|
@@ -0,0 +1,33 @@
|
||||
package com.landaiqing.domain.service.impl;
|
||||
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.domain.convert.StudentBOConvert;
|
||||
import com.landaiqing.domain.service.RolePermissionDomainService;
|
||||
import com.landaiqing.domain.service.StudentRoleDomainService;
|
||||
import com.landaiqing.infra.basic.entity.Student;
|
||||
import com.landaiqing.infra.basic.service.RolePermissionService;
|
||||
import com.landaiqing.infra.basic.service.StudentRoleService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Classname StudentPermissionDomainServiceImpl
|
||||
* @BelongsProject: student-Management-system
|
||||
* @BelongsPackage: com.landaiqing.domain.service.impl
|
||||
* @Author: landaiqing
|
||||
* @CreateTime: 2024-03-05 11:59
|
||||
* @Description: TODO
|
||||
* @Version: 1.0
|
||||
*/
|
||||
@Service
|
||||
public class RolePermissionDomainServiceImpl implements RolePermissionDomainService {
|
||||
@Resource
|
||||
private RolePermissionService rolePermissionService;
|
||||
@Override
|
||||
public List<Integer> queryPermissionByRoleId(Integer roleId) {
|
||||
List<Integer> permissionList = rolePermissionService.queryPermissionById(roleId);
|
||||
return permissionList;
|
||||
}
|
||||
}
|
@@ -0,0 +1,68 @@
|
||||
package com.landaiqing.domain.service.impl;
|
||||
|
||||
import com.landaiqing.auth.common.entity.PageResult;
|
||||
import com.landaiqing.auth.common.enums.IsDeletedFlagEnum;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.domain.convert.StudentBOConvert;
|
||||
import com.landaiqing.domain.service.StudentDomainService;
|
||||
import com.landaiqing.infra.basic.entity.Student;
|
||||
import com.landaiqing.infra.basic.service.StudentService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* @Classname StudentDomainServiceImpl
|
||||
* @BelongsProject: student-Management-system
|
||||
* @BelongsPackage: com.landaiqing.domain.service.impl
|
||||
* @Author: landaiqing
|
||||
* @CreateTime: 2024-03-04 23:14
|
||||
* @Description: TODO
|
||||
* @Version: 1.0
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class StudentDomainServiceImpl implements StudentDomainService {
|
||||
@Resource
|
||||
private StudentService studentService;
|
||||
|
||||
@Override
|
||||
public Boolean uploadAvatar(StudentBO studentBO) {
|
||||
Student student = new Student();
|
||||
student.setId(studentBO.getId());
|
||||
student.setAvatar(studentBO.getUrl());
|
||||
student.setIsDeleted(IsDeletedFlagEnum.UN_DELETED.getCode());
|
||||
Integer count = studentService.update(student);
|
||||
return count > 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageResult<StudentBO> queryAllStudentByPage(StudentBO studentBO) {
|
||||
PageResult<StudentBO> pageResult = new PageResult<>();
|
||||
pageResult.setPageNo(studentBO.getPageNo());
|
||||
pageResult.setPageSize(studentBO.getPageSize());
|
||||
int start = (studentBO.getPageNo() - 1) * studentBO.getPageSize();
|
||||
Student student = StudentBOConvert.INSTANCE.convertBOToEntity(studentBO);
|
||||
Integer total = studentService.selectCount();
|
||||
if (total == 0) {
|
||||
return pageResult;
|
||||
}
|
||||
List<Student> studentList = studentService.queryPage(student, start, studentBO.getPageSize());
|
||||
List<StudentBO> studentBOS = StudentBOConvert.INSTANCE.convertBOToDTOList(studentList);
|
||||
pageResult.setRecords(studentBOS);
|
||||
pageResult.setTotal(total);
|
||||
return pageResult;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Boolean login(StudentBO studentBO) {
|
||||
Student student = StudentBOConvert.INSTANCE.convertBOToEntity(studentBO);
|
||||
Integer count= studentService.login(student);
|
||||
return count>0;
|
||||
}
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,43 @@
|
||||
package com.landaiqing.domain.service.impl;
|
||||
|
||||
import com.landaiqing.domain.bo.PermissionBO;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.domain.service.*;
|
||||
import com.landaiqing.infra.basic.entity.Student;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Classname StudentPermissionDomainServiceImpl
|
||||
* @BelongsProject: student-Management-system
|
||||
* @BelongsPackage: com.landaiqing.domain.service.impl
|
||||
* @Author: landaiqing
|
||||
* @CreateTime: 2024-03-05 11:59
|
||||
* @Description: TODO
|
||||
* @Version: 1.0
|
||||
*/
|
||||
@Service
|
||||
public class StudentPermissionDomainServiceImpl implements StudentPermissionDomainService {
|
||||
@Resource
|
||||
private StudentPermissionDomainService studentPermissionDomainService;
|
||||
|
||||
@Resource
|
||||
private StudentRoleDomainService studentRoleDomainService;
|
||||
|
||||
@Resource
|
||||
private StudentDomainService studentDomainService;
|
||||
|
||||
@Resource
|
||||
private RolePermissionDomainService rolePermissionDomainService;
|
||||
@Resource
|
||||
private PermissionDomainService permissionDomainService;
|
||||
@Override
|
||||
public List<PermissionBO> queryStudentPermission(StudentBO studentBO) {
|
||||
Integer roleId = studentRoleDomainService.queryStudentRole(studentBO);
|
||||
List<Integer> permissionList= rolePermissionDomainService.queryPermissionByRoleId(roleId);
|
||||
List<PermissionBO> permissionBOList= permissionDomainService.queryPermission(permissionList);
|
||||
return permissionBOList;
|
||||
}
|
||||
}
|
@@ -0,0 +1,38 @@
|
||||
package com.landaiqing.domain.service.impl;
|
||||
|
||||
import com.landaiqing.domain.bo.PermissionBO;
|
||||
import com.landaiqing.domain.bo.StudentBO;
|
||||
import com.landaiqing.domain.convert.StudentBOConvert;
|
||||
import com.landaiqing.domain.service.StudentDomainService;
|
||||
import com.landaiqing.domain.service.StudentPermissionDomainService;
|
||||
import com.landaiqing.domain.service.StudentRoleDomainService;
|
||||
import com.landaiqing.infra.basic.entity.Student;
|
||||
import com.landaiqing.infra.basic.service.StudentRoleService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Classname StudentPermissionDomainServiceImpl
|
||||
* @BelongsProject: student-Management-system
|
||||
* @BelongsPackage: com.landaiqing.domain.service.impl
|
||||
* @Author: landaiqing
|
||||
* @CreateTime: 2024-03-05 11:59
|
||||
* @Description: TODO
|
||||
* @Version: 1.0
|
||||
*/
|
||||
@Service
|
||||
public class StudentRoleDomainServiceImpl implements StudentRoleDomainService {
|
||||
@Resource
|
||||
private StudentRoleService studentRoleService;
|
||||
|
||||
|
||||
@Override
|
||||
public Integer queryStudentRole(StudentBO studentBO) {
|
||||
|
||||
Student student = StudentBOConvert.INSTANCE.convertBOToEntity(studentBO);
|
||||
Integer roleId = studentRoleService.queryRoleById(student);
|
||||
return roleId;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user