package com.dgtly.order.mapper;

import com.dgtly.order.domain.CustomerAuthModel;
import com.dgtly.order.domain.CustomersStart;
import com.dgtly.order.domain.OrderCustomers;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 经销商启用Mapper接口
 * 
 * @author nsy
 * @date 2021-01-18
 */
public interface CustomersStartMapper 
{
    /**
     * 查询经销商启用
     * 
     * @param customersCode 经销商启用ID
     * @return 经销商启用
     */
    public CustomersStart selectCustomersStartByCustomersCode(String customersCode);

    /**
     * 查询经销商启用列表
     * 
     * @param customersStart 经销商启用
     * @return 经销商启用集合
     */
    public List<CustomersStart> selectCustomersStartList(CustomersStart customersStart);

    /**
     * 新增经销商启用
     * 
     * @param customersStart 经销商启用
     * @return 结果
     */
    public int insertCustomersStart(CustomersStart customersStart);

    /**
     * 修改经销商启用
     * 
     * @param customersStart 经销商启用
     * @return 结果
     */
    public int updateCustomersStart(CustomersStart customersStart);

    /**
     * 删除经销商启用
     * 
     * @param customersCode 经销商启用ID
     * @return 结果
     */
    public int deleteCustomersStartById(String customersCode);

    /**
     * 批量删除经销商启用
     * 
     * @param customersCodes 需要删除的数据ID
     * @return 结果
     */
    public int deleteCustomersStartByIds(String[] customersCodes);

    /**
     * 返回经销商列表，根据进销商编号去重
     * @param customers
     * @return
     */
    List<OrderCustomers> selectcustomersList(OrderCustomers customers);

    OrderCustomers selectCustomersById(Long id);

    List<CustomerAuthModel> selectCustomerAuthList(@Param("yearMonth") String yearMonth);

    List<CustomerAuthModel> selectCustomerExt();

    CustomerAuthModel selectCustomerExtByid(String id);

    String selectCustomerNameByCustomerId(String customerId);
}
