package cn.ezhizao.project.business.service.impl;

import cn.ezhizao.project.business.domain.BizDayworkItem;
import cn.ezhizao.project.business.domain.BizProductionResourceGroupDetail;
import cn.ezhizao.project.business.mapper.BizDayworkItemMapper;
import cn.ezhizao.project.business.service.IBizDayworkItemService;
import cn.ezhizao.project.system.domain.SysDept;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 报工记录Service业务层处理
 *
 * @author ezhizao
 * @date 2023-12-04
 */
@Service
public class BizDayworkItemServiceImpl extends ServiceImpl<BizDayworkItemMapper, BizDayworkItem> implements IBizDayworkItemService {
    @Resource
    private BizDayworkItemMapper bizDayworkItemMapper;

    /**
     * 查询报工记录列表
     *
     * @param bizDayworkItem 报工记录
     * @return 报工记录
     */
    @Override
    public List<BizDayworkItem> getList(BizDayworkItem bizDayworkItem) {
        return bizDayworkItemMapper.getList(bizDayworkItem);
    }

    @Override
    public List<SysDept> getDeptInfo(BizDayworkItem bizDayworkItem) {
        return bizDayworkItemMapper.getDeptInfo(bizDayworkItem);
    }

    /**
     * 查询设备信息
     *
     * @param bizProductionResourceGroupDetail
     * @return
     */
    @Override
    public BizProductionResourceGroupDetail getEquipmentInfo(BizProductionResourceGroupDetail bizProductionResourceGroupDetail) {
        return bizDayworkItemMapper.getEquipmentInfo(bizProductionResourceGroupDetail);
    }

    /**
     * 物理删除
     *
     * @param bizDayworkItem
     * @return 删除结果
     */
    @Override
    public int physicalDelete(BizDayworkItem bizDayworkItem) {
        return bizDayworkItemMapper.physicalDelete(bizDayworkItem);
    }
    @Override
    public void updateDayworkItem(BizDayworkItem bizDayworkItem) {
        bizDayworkItemMapper.updateDayworkItem(bizDayworkItem);
    }

    @Override
    public List<BizDayworkItem> getItemScreen(Long dayWorkId) {
        return bizDayworkItemMapper.getItemScreen(dayWorkId);
    }

    @Override
    public List<BizDayworkItem> selectList(BizDayworkItem item) {
        return bizDayworkItemMapper.selectList(item);
    }


}
