add gao user remind

This commit is contained in:
Timi
2026-09-07 12:06:38 +08:00
parent 01d33a1122
commit 3a4386261c
11 changed files with 356 additions and 0 deletions
@@ -0,0 +1,44 @@
<?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.imyeyu.api.modules.gao.mapper.GaoOrderReminderMapper">
<select id="selectOrderReceiveCustomers" resultType="com.imyeyu.api.modules.gao.vo.GaoOrderReminderCustomer">
SELECT
o.`store_id` AS `storeId`,
o.`customer_id` AS `customerId`,
c.`name` AS `customerName`
FROM `gao_sales_order` o
INNER JOIN `gao_customer` c ON c.`id` = o.`customer_id` AND c.`deleted_at` IS NULL
WHERE o.`deleted_at` IS NULL
AND o.`status` IN ('ACTIVE', 'FULFILLED')
AND o.`payment_status` IN ('UNPAID', 'PARTIALLY_PAID')
GROUP BY o.`store_id`, o.`customer_id`, c.`name`
ORDER BY o.`store_id`, c.`name`, o.`customer_id`
</select>
<select id="selectReceiveVerifyCustomers" resultType="com.imyeyu.api.modules.gao.vo.GaoOrderReminderCustomer">
SELECT
f.`store_id` AS `storeId`,
f.`customer_id` AS `customerId`,
c.`name` AS `customerName`
FROM `gao_fund_record` f
INNER JOIN `gao_customer` c ON c.`id` = f.`customer_id` AND c.`deleted_at` IS NULL
WHERE f.`deleted_at` IS NULL
AND f.`biz_type` = 'SALES_ORDER'
AND f.`operation_type` = 'RECEIVE'
AND f.`status` = 'PENDING'
GROUP BY f.`store_id`, f.`customer_id`, c.`name`
ORDER BY f.`store_id`, c.`name`, f.`customer_id`
</select>
<select id="selectFulfillmentVerifyCustomers" resultType="com.imyeyu.api.modules.gao.vo.GaoOrderReminderCustomer">
SELECT
f.`store_id` AS `storeId`,
f.`customer_id` AS `customerId`,
c.`name` AS `customerName`
FROM `gao_order_fulfillment` f
INNER JOIN `gao_customer` c ON c.`id` = f.`customer_id` AND c.`deleted_at` IS NULL
WHERE f.`status` = 'PENDING'
GROUP BY f.`store_id`, f.`customer_id`, c.`name`
ORDER BY f.`store_id`, c.`name`, f.`customer_id`
</select>
</mapper>