package cn.iocoder.yudao.module.crm.api.customer; import cn.iocoder.yudao.module.crm.api.customer.dto.CrmCustomerRespDTO; import java.util.Collection; import java.util.List; import java.util.Map; /** * CRM 客户 API 接口 * * 提供给其它模块(如 ERP)调用 * * @author 芋道源码 */ public interface CrmCustomerApi { /** * 获得客户信息 * * @param id 客户编号 * @return 客户信息 */ CrmCustomerRespDTO getCustomer(Long id); /** * 获得客户信息列表 * * @param ids 客户编号列表 * @return 客户信息列表 */ List getCustomerList(Collection ids); /** * 获得客户信息 Map * * @param ids 客户编号列表 * @return 客户信息 Map */ Map getCustomerMap(Collection ids); /** * 校验客户是否存在 * * @param id 客户编号 * @return 客户信息(校验通过) */ CrmCustomerRespDTO validateCustomer(Long id); /** * 获取当前用户有权限的客户 ID 列表 * * 包括:用户自己在团队中、用户的下级在团队中、公海数据 * * @return 有权限的客户 ID 列表(null 表示不限制,即超管) */ List getPermittedCustomerIds(); }