<?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.izouma.awesomeadmin.dao.SysAppTokenMapper">
    <insert id="saveToken">
        insert into sys_app_token (user_id, token)
        values (#{userId}, #{token})
    </insert>
    <delete id="delToken">
        delete from sys_app_token where token = #{token}
    </delete>
    <delete id="delUserToken">
        delete from sys_app_token where user_id = #{userId}
    </delete>
    <select id="getToken" resultType="com.izouma.awesomeadmin.shiro.AppToken">
        select * from sys_app_token where token = #{token}
    </select>

</mapper>