<?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.om.mapper.AppsMapper">
    <select id="findApps" resultType="com.om.entity.vo.AppsVO">
        select a.*, c.name, c.number from apps as a, apps_clients as ac, client as c
        where a.id=ac.app_id and ac.client_num=c.number
        <if test="code != null and code != ''">
            and a.uploadBy like concat('%',#{code},'%')
        </if>
        ORDER BY a.createTime DESC
    </select>
</mapper>
