id
This commit is contained in:
@@ -18,11 +18,11 @@ public interface MkDistributionUserMapper extends BaseMapper<MkDistributionUser>
|
|||||||
/**
|
/**
|
||||||
* 查询我的分销店铺列表 已开通
|
* 查询我的分销店铺列表 已开通
|
||||||
*/
|
*/
|
||||||
List<DistributionCenterShopVO> selectMyDistributionShops(Long shopUserId);
|
List<DistributionCenterShopVO> selectMyDistributionShops(Long userId);
|
||||||
/**
|
/**
|
||||||
* 查询我的分销店铺列表 未开通
|
* 查询我的分销店铺列表 未开通
|
||||||
*/
|
*/
|
||||||
List<DistributionCenterShopVO> selectUnDistributionShops(Long shopUserId);
|
List<DistributionCenterShopVO> selectUnDistributionShops(Long userId);
|
||||||
|
|
||||||
boolean updateIncome(BigDecimal pendingIncome, BigDecimal receivedIncome, BigDecimal withdrawIncome, Long id);
|
boolean updateIncome(BigDecimal pendingIncome, BigDecimal receivedIncome, BigDecimal withdrawIncome, Long id);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
user.total_income as income
|
user.total_income as income
|
||||||
from mk_distribution_user user
|
from mk_distribution_user user
|
||||||
left join tb_shop_info shop on user.shop_id = shop.id
|
left join tb_shop_info shop on user.shop_id = shop.id
|
||||||
where user.shop_user_id = #{shopUserId}
|
where user.user_id = #{userId}
|
||||||
and user.status = 1
|
and user.status = 1
|
||||||
and user.is_del = 0
|
and user.is_del = 0
|
||||||
</select>
|
</select>
|
||||||
@@ -36,9 +36,9 @@
|
|||||||
CASE WHEN COUNT(shu.id) > 0 THEN 1 ELSE 0 END AS shopUser
|
CASE WHEN COUNT(shu.id) > 0 THEN 1 ELSE 0 END AS shopUser
|
||||||
FROM tb_shop_info shop
|
FROM tb_shop_info shop
|
||||||
inner JOIN mk_distribution_config config ON shop.id = config.shop_id
|
inner JOIN mk_distribution_config config ON shop.id = config.shop_id
|
||||||
LEFT JOIN mk_distribution_user du ON shop.id = du.shop_id AND du.user_id = #{user_id} AND du.is_del = 0
|
LEFT JOIN mk_distribution_user du ON shop.id = du.shop_id AND du.user_id = #{userId} AND du.is_del = 0
|
||||||
LEFT JOIN tb_shop_user shu ON shop.id IN (shu.main_shop_id, shu.source_shop_id) AND shu.user_id = #{user_id}
|
LEFT JOIN tb_shop_user shu ON shop.id IN (shu.main_shop_id, shu.source_shop_id) AND shu.user_id = #{userId}
|
||||||
LEFT JOIN tb_order_info ord ON shop.id = ord.shop_id AND ord.user_id = #{user_id}
|
LEFT JOIN tb_order_info ord ON shop.id = ord.shop_id AND ord.user_id = #{userId}
|
||||||
AND ord.STATUS = 'done'
|
AND ord.STATUS = 'done'
|
||||||
GROUP BY shop.id
|
GROUP BY shop.id
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user