|
|
|
@ -1,5 +1,6 @@
|
|
|
|
|
package com.ruoyi.framework.web.service;
|
|
|
|
|
|
|
|
|
|
import com.ruoyi.system.mapper.SysUserMapper;
|
|
|
|
|
import org.slf4j.Logger;
|
|
|
|
|
import org.slf4j.LoggerFactory;
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
@ -30,10 +31,13 @@ public class UserDetailsServiceImpl implements UserDetailsService
|
|
|
|
|
@Autowired
|
|
|
|
|
private SysPermissionService permissionService;
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
private SysUserMapper sysUserMapper;
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public UserDetails loadUserByUsername(String username) throws UsernameNotFoundException
|
|
|
|
|
{
|
|
|
|
|
SysUser user = userService.selectUserByUserName(username);
|
|
|
|
|
SysUser user = sysUserMapper.selectUserByStudentNumber(username);
|
|
|
|
|
if (StringUtils.isNull(user))
|
|
|
|
|
{
|
|
|
|
|
log.info("登录用户:{} 不存在.", username);
|
|
|
|
|