| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990 |
- <?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.ydtech.modules.fnc.dao.ImportAsyncMapper">
- <!-- 通用查询映射结果 -->
- <resultMap id="BaseResultMap" type="com.ydtech.modules.fnc.entity.ImportResult">
- <id column="id" property="id"/>
- <result column="create_time" property="createTime"/>
- <result column="created_at" property="createdAt"/>
- <result column="completed_at" property="completedAt"/>
- <result column="status" property="status"/>
- <result column="total_amount" property="totalAmount"/>
- <result column="upload_url" property="uploadUrl"/>
- <result column="company_id" property="companyId"/>
- <result column="partner_companies_id" property="partnerCompaniesId"/>
- <result column="agreement_id" property="agreementId"/>
- <result column="ids" property="ids"/>
- <result column="hand_status" property="handStatus"/>
- <result column="income_id" property="incomeId"/>
- </resultMap>
- <select id="queryNew" resultType="com.ydtech.modules.fnc.entity.ImportResult">
- select
- a.id as "id",
- a.create_time as "createTime",
- a.created_at as "createdAt",
- a.completed_at as "completedAt",
- a.status as "status",
- a.total_amount as "totalAmount",
- a.upload_url as "uploadUrl",
- a.company_id as "companyId",
- a.partner_companies_id as "partnerCompaniesId",
- a.agreement_id as "agreementId",
- a.ids as "ids",
- a.hand_status as "handStatus",
- a.hand_status as "handStatus",
- a.income_id as "incomeId",
- eic.namesimple as "partnerCompaniesName"
- from
- import_task a
- LEFT JOIN esm_ins_company eic on eic.id = a.partner_companies_id
- <where>
- <if test="handStatus !=null and handStatus !=''">
- a.hand_status =#{handStatus}
- </if>
- <if test="createTime !=null and createTime !=''">
- AND DATE(a.create_time) =#{createTime}
- </if>
- <if test="incomeId !=null and incomeId !=''">
- AND a.income_id =#{incomeId}
- </if>
- </where>
- order by a.create_time desc
- </select>
- <select id="selectByIncomeId" resultType="com.ydtech.modules.fnc.entity.ImportResult">
- select
- a.id as "id",
- a.create_time as "createTime",
- a.created_at as "createdAt",
- a.completed_at as "completedAt",
- a.status as "status",
- a.total_amount as "totalAmount",
- a.upload_url as "uploadUrl",
- a.company_id as "companyId",
- a.partner_companies_id as "partnerCompaniesId",
- a.agreement_id as "agreementId",
- a.ids as "ids",
- a.hand_status as "handStatus",
- a.hand_status as "handStatus",
- a.income_id as "incomeId",
- eic.namesimple as "partnerCompaniesName"
- from
- import_task a
- LEFT JOIN esm_ins_company eic on eic.id = a.partner_companies_id
- <where>
- <if test="handStatus !=null and handStatus !=''">
- a.hand_status =#{handStatus}
- </if>
- <if test="createTime !=null and createTime !=''">
- AND DATE(a.create_time) =#{createTime}
- </if>
- <if test="incomeId !=null and incomeId !=''">
- AND a.income_id =#{incomeId}
- </if>
- </where>
- order by a.create_time desc
- </select>
- </mapper>
|