客商委托方数据同步

This commit is contained in:
秦鸿展
2026-06-08 15:05:34 +08:00
parent 734be2b825
commit c59fa363ee
23 changed files with 959 additions and 17 deletions
@@ -165,7 +165,8 @@
b.push_status,
b.push_time,
b.push_by,
b.push_by_name
b.push_by_name,
b.data_source
FROM "USER" a
LEFT JOIN user_shipper b ON a.user_id = b.user_id
left join (select user_id, LISTAGG(DISTINCT r.role_name, '&') WITHIN GROUP(ORDER BY r.role_name) AS roleName
@@ -435,5 +436,25 @@
WHERE shipper_id = #{shipperId}
</update>
<select id="findByCustomerNcCodeAndOrganizationId" resultType="com.mhd.user.domain.userAggregate.repository.po.UserShipperPo">
SELECT b.shipper_id,
b.user_id,
b.customer_nc_code,
b.data_source,
a.organization_id AS organizationId,
a.organization_name AS organizationName,
b.shipper_enterprise_name,
b.user_name_shipper,
b.emergency_contact_name,
b.emergency_contact_phone
FROM "USER" a
INNER JOIN user_shipper b ON a.user_id = b.user_id
WHERE a.del_flag = 1
AND b.del_flag = 1
AND b.customer_nc_code = #{customerNcCode}
AND a.organization_id = #{organizationId}
LIMIT 1
</select>
</mapper>