add sales order

This commit is contained in:
Timi
2026-09-06 12:09:58 +08:00
parent 41f692aad9
commit f3166f0413
43 changed files with 560 additions and 73 deletions
@@ -31,6 +31,16 @@
ORDER BY `sort`, `name`, `code`, `created_at` DESC
LIMIT #{offset}, #{limit}
</select>
<select id="selectByIdList" resultType="com.imyeyu.api.modules.gao.entity.GaoProduct">
SELECT * FROM `gao_product`
WHERE `deleted_at` IS NULL
<choose>
<when test="idList != null and !idList.isEmpty()">
AND `id` IN <foreach collection="idList" item="id" open="(" separator="," close=")">#{id}</foreach>
</when>
<otherwise>AND FALSE</otherwise>
</choose>
</select>
<select id="selectByStoreIdAndCode" resultType="com.imyeyu.api.modules.gao.entity.GaoProduct">
SELECT * FROM `gao_product`
WHERE `store_id` = #{storeId} AND `code` = #{code} AND `deleted_at` IS NULL