package com.jwipc.sys.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.jwipc.sys.entity.MoldForm;
import com.jwipc.sys.entity.ProductGroup;
import com.jwipc.sys.mapper.ProductGroupMapper;
import com.jwipc.sys.model.po.MoldFormPO;
import com.jwipc.sys.model.po.ProductGroupPO;
import com.jwipc.sys.model.query.MoldFormQuery;
import com.jwipc.sys.model.query.ProductGroupQuery;
import com.jwipc.sys.service.IProductGroupService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 物料组描述(只需同步MATKL、WGBEZ60) 服务实现类
 * </p>
 *
 * @author AL
 * @since 2024-02-18
 */
@Service
public class ProductGroupServiceImpl extends ServiceImpl<ProductGroupMapper, ProductGroup> implements IProductGroupService {
    @Override
    public List<ProductGroupPO> findPageByQuery(Page<ProductGroup> dbPage, ProductGroupQuery query) {
        if (dbPage==null){
            return baseMapper.findPageByQuery(query);
        }
        return baseMapper.findPageByQuery(dbPage,query);
    }
    @Override
    public ProductGroupPO getDataById(Long id) {
        return baseMapper.getDataById(id);
    }
}
