|
@@ -41,17 +41,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
c.chains_name AS chainsName
|
|
|
FROM
|
|
|
ssb_order_file AS of
|
|
|
- LEFT JOIN customers AS c ON of.chains_code = c.chains_code
|
|
|
- <where>
|
|
|
+ LEFT JOIN (select chains_name,chains_code from customers GROUP BY chains_code ) AS c ON c.chains_code = of.chains_code
|
|
|
+ where of.file_url is not NULL
|
|
|
<if test="orderId != null and orderId != ''"> and c.chains_name = #{orderId}</if>
|
|
|
<if test="chainsName != null and chainsName != ''"> and c.chains_name like concat('%', #{chainsName}, '%')</if>
|
|
|
<if test="signerName != null and signerName != ''"> and of.signer_name like concat('%', #{signerName}, '%')</if>
|
|
|
<if test="flowId != null and flowId != ''"> and flow_id = #{flowId}</if>
|
|
|
<if test="fileUrl != null and fileUrl != ''"> and file_url = #{fileUrl}</if>
|
|
|
<if test="isDelete != null and isDelete != ''"> and is_delete = #{isDelete}</if>
|
|
|
- </where>
|
|
|
- GROUP BY
|
|
|
- of.chains_code
|
|
|
</select>
|
|
|
|
|
|
<select id="selectOrderFileById" parameterType="String" resultMap="OrderFileResult">
|