xhxu 5 лет назад
Родитель
Сommit
02827c559b
2 измененных файлов: 53 добавлений и 2 удалений
  1. +25
    -0
      mallinkService/src/main/resources/mapper/WxPropertyContractMapper.xml
  2. +28
    -2
      mallinkService/src/main/resources/mapper/WxRentContractMapper.xml

+ 25
- 0
mallinkService/src/main/resources/mapper/WxPropertyContractMapper.xml Просмотреть файл

@@ -98,6 +98,31 @@
<if test=" null != endDate ">and `end_date` = #{endDate}</if>
<if test=" null != rentShopType">and `rent_shop_type` = #{rentShopType}</if>
<if test=" null != operationType ">and `operation_type` = #{operationType}</if>

<if test=" null != businessForRule and '' != businessForRule ">
and business_id in (${businessForRule})
</if>
<if test=" null != floorForRule and '' != floorForRule ">
and `id` in
<foreach collection="tempShop" index="idx" separator=" union all " open="(" close=")">
select id from wx_property_contract where 1=1
<if test=" null != tenantId and '' != tenantId">
and `tenant_id` = #{tenantId}
</if>
<if test=" null != parentTenantId and '' != parentTenantId">
and `parent_tenant_id` = #{parentTenantId}
</if>
and json_unquote(json_extract(json_extract(rent_info,'$[*].shopId'),concat('$[',#{idx},']'))) in(select
id from wx_shop where 1=1
<if test=" null != tenantId and '' != tenantId">
and `tenant_id` = #{tenantId}
</if>
<if test=" null != parentTenantId and '' != parentTenantId">
and `parent_tenant_id` = #{parentTenantId}
</if>
and floor in (${floorForRule}))
</foreach>
</if>
<if test=" null != ids ">
and id in


+ 28
- 2
mallinkService/src/main/resources/mapper/WxRentContractMapper.xml Просмотреть файл

@@ -135,6 +135,32 @@
<if test=" null != shopNumber and shopNumber!=''">
and shop_name like concat('%',#{shopNumber},'%')
</if>

<if test=" null != businessForRule and '' != businessForRule ">
and business_id in (${businessForRule})
</if>
<if test="null != floorForRule and '' != floorForRule ">
and `id` in
<foreach collection="tempShop" index="idx" separator=" union all " open="(" close=")">
select id from wx_rent_contract where 1=1
<if test=" null != tenantId and '' != tenantId">
and `tenant_id` = #{tenantId}
</if>
<if test=" null != parentTenantId and '' != parentTenantId">
and `parent_tenant_id` = #{parentTenantId}
</if>
and json_unquote(json_extract(json_extract(rent_info,'$[*].shopId'),concat('$[',#{idx},']'))) in(select
id from wx_shop where 1=1
<if test=" null != tenantId and '' != tenantId">
and `tenant_id` = #{tenantId}
</if>
<if test=" null != parentTenantId and '' != parentTenantId">
and `parent_tenant_id` = #{parentTenantId}
</if>
and floor in (${floorForRule}))
</foreach>
</if>

<if test=" null != statuss ">
and status in
<foreach collection="statuss" index="index" item="statusItem" open="(" separator="," close=")">
@@ -588,7 +614,7 @@
and rc.business_id in (${businessForRule})
</if>
<!-- <if test="null != rentShopType and 1 == rentShopType and null != floorForRule and '' != floorForRule ">
<if test="null != floorForRule and '' != floorForRule ">
and rc.`id` in
<foreach collection="tempShop" index="idx" separator=" union all " open="(" close=")">
select id from wx_rent_contract where 1=1
@@ -608,7 +634,7 @@
</if>
and floor in (${floorForRule}))
</foreach>
</if> -->
</if>
<!-- <if test="null != rentShopType and 2 == rentShopType and null != floorForRule and '' != floorForRule ">
and rc.shop_id in (select id from wx_shop where 1=1
<if test=" null != tenantId and '' != tenantId">


Загрузка…
Отмена
Сохранить