51 lines
1.2 KiB
Java
51 lines
1.2 KiB
Java
package io.as.modules.daycard.service;
|
|||
|
|
|
||
|
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||
|
|
import io.as.common.utils.PageUtils;
|
||
|
|
import io.as.modules.daycard.entity.DayCardProfitRuleEntity;
|
||
|
|
|
||
|
|
import java.util.List;
|
||
|
|
import java.util.Map;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 天卡分润规则 Service
|
||
|
|
*/
|
||
|
|
public interface DayCardProfitRuleService extends IService<DayCardProfitRuleEntity> {
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 分页查询分润规则
|
||
|
|
*/
|
||
|
|
PageUtils queryPage(Map<String, Object> params);
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 根据ID获取分润规则
|
||
|
|
*/
|
||
|
|
DayCardProfitRuleEntity getById(Long id);
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 新增分润规则(30%校验)
|
||
|
|
*/
|
||
|
|
void saveRule(DayCardProfitRuleEntity rule);
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 修改分润规则(30%校验)
|
||
|
|
*/
|
||
|
|
void updateRule(DayCardProfitRuleEntity rule);
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 批量删除分润规则(软删除)
|
||
|
|
*/
|
||
|
|
void delete(Long[] ids);
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 逐级匹配分润规则
|
||
|
|
* <p>优先门店级 -> 渠道级 -> 合作商级</p>
|
||
|
|
*
|
||
|
|
* @param partnerId 合作伙伴ID
|
||
|
|
* @param channelOrgId 渠道组织ID
|
||
|
|
* @param storeOrgId 门店组织ID(可空)
|
||
|
|
* @return 匹配的分润规则列表,按 priority DESC 排序
|
||
|
|
*/
|
||
|
|
List<DayCardProfitRuleEntity> matchRules(Long partnerId, Long channelOrgId, Long storeOrgId);
|
||
|
|
}
|