hsy
2026-08-28 a8e4132c3e2e9c3b3fcb0360901b35571b6464ea
src/main/resources/mapper/sales/SalesQuotationMapper.xml
@@ -4,18 +4,22 @@
        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.sales.mapper.SalesQuotationMapper">
    <select id="listPage" resultType="com.ruoyi.sales.dto.SalesQuotationDto">
        SELECT t1.*
        SELECT t1.*, p.title as projectName
        FROM sales_quotation t1
        LEFT JOIN project_management_info p ON t1.project_id = p.id
        <where>
            <if test="salesQuotationDto.quotationNo != null and salesQuotationDto.quotationNo != '' ">
                AND t1.quotation_no LIKE CONCAT('%',#{salesQuotationDto.quotationNo},'%')
            </if>
            <if test="salesQuotationDto.customer != null and salesQuotationDto.customer != '' ">
                AND t1.customer = #{salesQuotationDto.customer}
                AND t1.customer LIKE CONCAT('%',#{salesQuotationDto.customer},'%')
            </if>
            <if test="salesQuotationDto.status != null and salesQuotationDto.status != '' ">
                AND t1.status = #{salesQuotationDto.status}
            </if>
            <if test="salesQuotationDto.projectId != null">
                AND t1.project_id = #{salesQuotationDto.projectId}
            </if>
        </where>
        order by t1.id desc
    </select>