在自定义UserDetailsService时我继承了JdbcDaoImpl,并重写了loadUserByUsername()方法在方法体中:[code="java"]@Overridepublic UserDetails loadUserByUsername(String username) throws UsernameNotFoundException, DataAccessException {UserDetails ud = super.loadUserByUsername(username);AuthUserDetails authUser = new AuthUserDetails(ud.getUsername(),ud.getPassword(),ud.isEnabled(),ud.isAccountNonExpired(),ud.isCredentialsNonExpired(),ud.isAccountNonLocked(),ud.getAuthorities());}[/code]调用了父类的loadUserByUsername()方法,是不是就是走了父类中的sql:[code="java"]public static final String DEF_USERS_BY_USERNAME_QUERY ="SELECT username,password,enabled " +"FROM users " +"WHERE username = ?";[/code]这样我是不是就得建users表?我感觉这个我能通过自己自定义应该可以重写一下吧?求ss大牛...
添加回答
举报
0/150
提交
取消