package com.fs.hospital.service.impl;

import java.util.List;

import com.fs.hospital.vo.HospitalProductCheckOrderItemListHVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.fs.hospital.mapper.HospitalProductCheckOrderItemMapper;
import com.fs.hospital.domain.HospitalProductCheckOrderItem;
import com.fs.hospital.service.IHospitalProductCheckOrderItemService;

/**
 * 采购单明细Service业务层处理
 *
 * @author fs
 * @date 2024-03-14
 */
@Service
public class HospitalProductCheckOrderItemServiceImpl implements IHospitalProductCheckOrderItemService
{
    @Autowired
    private HospitalProductCheckOrderItemMapper hospitalProductCheckOrderItemMapper;

    /**
     * 查询采购单明细
     *
     * @param itemId 采购单明细主键
     * @return 采购单明细
     */
    @Override
    public HospitalProductCheckOrderItem selectHospitalProductCheckOrderItemByItemId(Long itemId)
    {
        return hospitalProductCheckOrderItemMapper.selectHospitalProductCheckOrderItemByItemId(itemId);
    }

    /**
     * 查询采购单明细列表
     *
     * @param hospitalProductCheckOrderItem 采购单明细
     * @return 采购单明细
     */
    @Override
    public List<HospitalProductCheckOrderItem> selectHospitalProductCheckOrderItemList(HospitalProductCheckOrderItem hospitalProductCheckOrderItem)
    {
        return hospitalProductCheckOrderItemMapper.selectHospitalProductCheckOrderItemList(hospitalProductCheckOrderItem);
    }

    /**
     * 新增采购单明细
     *
     * @param hospitalProductCheckOrderItem 采购单明细
     * @return 结果
     */
    @Override
    public int insertHospitalProductCheckOrderItem(HospitalProductCheckOrderItem hospitalProductCheckOrderItem)
    {
        return hospitalProductCheckOrderItemMapper.insertHospitalProductCheckOrderItem(hospitalProductCheckOrderItem);
    }

    /**
     * 修改采购单明细
     *
     * @param hospitalProductCheckOrderItem 采购单明细
     * @return 结果
     */
    @Override
    public int updateHospitalProductCheckOrderItem(HospitalProductCheckOrderItem hospitalProductCheckOrderItem)
    {
        return hospitalProductCheckOrderItemMapper.updateHospitalProductCheckOrderItem(hospitalProductCheckOrderItem);
    }

    /**
     * 批量删除采购单明细
     *
     * @param itemIds 需要删除的采购单明细主键
     * @return 结果
     */
    @Override
    public int deleteHospitalProductCheckOrderItemByItemIds(Long[] itemIds)
    {
        return hospitalProductCheckOrderItemMapper.deleteHospitalProductCheckOrderItemByItemIds(itemIds);
    }

    /**
     * 删除采购单明细信息
     *
     * @param itemId 采购单明细主键
     * @return 结果
     */
    @Override
    public int deleteHospitalProductCheckOrderItemByItemId(Long itemId)
    {
        return hospitalProductCheckOrderItemMapper.deleteHospitalProductCheckOrderItemByItemId(itemId);
    }

    @Override
    public List<HospitalProductCheckOrderItemListHVO> selectHospitalProductCheckOrderItemListPVO(HospitalProductCheckOrderItem hospitalProductCheckOrderItem) {
        return hospitalProductCheckOrderItemMapper.selectHospitalProductCheckOrderItemListPVO(hospitalProductCheckOrderItem);
    }
}
