package com.bonus.zlpt.equip.service.impl;

import java.util.List;

import com.bonus.zlpt.equip.api.domain.LeaseInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.bonus.zlpt.equip.mapper.LeaseInfoMapper;
import com.bonus.zlpt.equip.service.ILeaseInfoService;

/**
 * 租赁信息Service业务层处理
 * 
 * @author xsheng
 * @date 2023-12-02
 */
@Service
public class LeaseInfoServiceImpl implements ILeaseInfoService 
{
    @Autowired
    private LeaseInfoMapper leaseInfoMapper;

    /**
     * 查询租赁信息
     * 
     * @param id 租赁信息主键
     * @return 租赁信息
     */
    @Override
    public LeaseInfo selectLeaseInfoById(Long id)
    {
        return leaseInfoMapper.selectLeaseInfoById(id);
    }

    /**
     * 查询租赁信息列表
     * 
     * @param leaseInfo 租赁信息
     * @return 租赁信息
     */
    @Override
    public List<LeaseInfo> selectLeaseInfoList(LeaseInfo leaseInfo)
    {
        return leaseInfoMapper.selectLeaseInfoList(leaseInfo);
    }

    /**
     * 新增租赁信息
     * 
     * @param leaseInfo 租赁信息
     * @return 结果
     */
    @Override
    public int insertLeaseInfo(LeaseInfo leaseInfo)
    {
        return leaseInfoMapper.insertLeaseInfo(leaseInfo);
    }

    /**
     * 修改租赁信息
     * 
     * @param leaseInfo 租赁信息
     * @return 结果
     */
    @Override
    public int updateLeaseInfo(LeaseInfo leaseInfo)
    {
        return leaseInfoMapper.updateLeaseInfo(leaseInfo);
    }

    /**
     * 批量删除租赁信息
     * 
     * @param ids 需要删除的租赁信息主键
     * @return 结果
     */
    @Override
    public int deleteLeaseInfoByIds(Long[] ids)
    {
        return leaseInfoMapper.deleteLeaseInfoByIds(ids);
    }

    /**
     * 删除租赁信息信息
     * 
     * @param id 租赁信息主键
     * @return 结果
     */
    @Override
    public int deleteLeaseInfoById(Long id)
    {
        return leaseInfoMapper.deleteLeaseInfoById(id);
    }
}
