<?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.picc.grab.mapper.PiccgrabaccountMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.picc.grab.domain.Piccgrabaccount">
        <id column="id" property="id"/>
        <result column="account" property="account"/>
        <result column="password" property="password"/>
        <result column="cookie" property="cookie"/>
        <result column="token" property="token"/>
        <result column="fgsId" property="fgsId"/>
        <result column="yzm" property="yzm"/>
        <result column="logIn" property="logIn"/>
        <result column="Isdel" property="Isdel"/>
        <result column="fgsmc" property="fgsmc"/>
        <result column="salesman" property="salesman"/>
        <result column="createName" property="createName"/>
        <result column="createtime" property="createtime"/>
        <result column="updatetime" property="updatetime"/>
    </resultMap>
    <select id="getGrabListPage" resultType="com.picc.grab.domain.Piccgrabaccount">
 select  a.*,f.fgs_mc fgsmc,u.trueName createName from nj_mdb.md_piccgrabaccount a  left  join  md_fgs_info f on f.id=a.fgsId
 left join md_user u on u.id= a.salesman
 where  a.Isdel=0 order by a.logIn asc,a.salesman asc
 </select>

    <select id="findTokenByLogIn" resultType="java.lang.String">
        select token from md_piccgrabaccount where logIn = 1
    </select>

    <select id="getZbwt" resultType="com.picc.grab.domain.Zbwt">
        select * FROM nj_mdb.md_carinfo where cph=#{carNo}
    </select>
</mapper>
