<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.lframework.xingyun.template.inner.mappers.UserDetailsMapper">

    <resultMap id="result" type="com.lframework.starter.web.common.security.DefaultUserDetails">
        <id property="id" column="id"/>
        <result property="username" column="username"/>
        <result property="password" column="password"/>
        <result property="name" column="name"/>
        <result property="email" column="email"/>
        <result property="telephone" column="telephone"/>
        <result property="available" column="available"/>
        <result property="lockStatus" column="lock_status"/>
    </resultMap>

    <select id="findByUsername" resultType="com.lframework.starter.web.common.security.DefaultUserDetails">
        SELECT id, username, password, name, email, telephone, available, lock_status FROM sys_user
        WHERE username = #{username}
    </select>
</mapper>
