ComExpertGroupDAO.xml 717 Bytes
<?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.yiboshi.science.dao.ComExpertGroupDAO">
    <sql id="allColumns">
        t.id as id, t.expert_id as expertId, t.spec_id as specId, t.created as created, t.updated as updated
    </sql>
    <select id="getListByPage" resultType="com.yiboshi.science.param.dto.ComExpertGroupDTO">
        select a.*,b.name batchName,b.year,b.batch
        from com_expert_group a
        left join com_expert_batch b on a.batch_id=b.id
        <where>
            ${ew.sqlSegment}
        </where>
        ORDER BY b.year ASC,b.batch desc
    </select>
</mapper>