package com.yijia.customer.service.impl;


import com.yijia.customer.domain.CustomerManage;
import com.yijia.customer.mapper.CustomerManageMapper;
import com.yijia.customer.service.ICustomerManageService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 客户管理Service业务层处理
 * 
 * @author yijia
 * @date 2020-12-21
 */
@Service
public class CustomerManageServiceImpl implements ICustomerManageService
{
    @Autowired
    private CustomerManageMapper customerManageMapper;

    /**
     * 查询客户管理
     * 
     * @param id 客户管理ID
     * @return 客户管理
     */
    @Override
    public CustomerManage selectCustomerManageById(Long id)
    {
        return customerManageMapper.selectCustomerManageById(id);
    }

    /**
     * 查询客户管理列表
     * 
     * @param customerManage 客户管理
     * @return 客户管理
     */
    @Override
    public List<CustomerManage> selectCustomerManageList(CustomerManage customerManage)
    {
        return customerManageMapper.selectCustomerManageList(customerManage);
    }

    /**
     * 新增客户管理
     * 
     * @param customerManage 客户管理
     * @return 结果
     */
    @Override
    public int insertCustomerManage(CustomerManage customerManage)
    {
        return customerManageMapper.insertCustomerManage(customerManage);
    }

    /**
     * 修改客户管理
     * 
     * @param customerManage 客户管理
     * @return 结果
     */
    @Override
    public int updateCustomerManage(CustomerManage customerManage)
    {
        return customerManageMapper.updateCustomerManage(customerManage);
    }

    /**
     * 批量删除客户管理
     * 
     * @param ids 需要删除的客户管理ID
     * @return 结果
     */
    @Override
    public int deleteCustomerManageByIds(Long[] ids)
    {
        return customerManageMapper.deleteCustomerManageByIds(ids);
    }

    /**
     * 删除客户管理信息
     * 
     * @param id 客户管理ID
     * @return 结果
     */
    @Override
    public int deleteCustomerManageById(Long id)
    {
        return customerManageMapper.deleteCustomerManageById(id);
    }

    /**
     * 客户信息查询
     * @param customerManage
     * @return
     */
    @Override
    public List<CustomerManage> selectCustomerManage(CustomerManage customerManage) {
        return customerManageMapper.selectCustomerManage(customerManage);
    }
}
