package com.jwipc.supplier.service.impl;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.jwipc.supplier.entity.CustomerInfo;
import com.jwipc.supplier.mapper.CustomerInfoMapper;
import com.jwipc.supplier.service.ICustomerInfoService;
import org.springframework.stereotype.Service;

import java.util.List;

import static com.jwipc.constant.DbTypeConst.SQLSERVER;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author zhangjie
 * @since 2024-03-15
 */
@Service
@DS(SQLSERVER)
public class CustomerInfoServiceImpl extends ServiceImpl<CustomerInfoMapper, CustomerInfo> implements ICustomerInfoService {

    @Override
    public Integer findCount(LambdaQueryWrapper<CustomerInfo> queryWrapper) {
        return this.baseMapper.findCount(queryWrapper);
    }

    @Override
    public List<CustomerInfo> findListForPage(Integer offset, Integer rows, LambdaQueryWrapper<CustomerInfo> queryWrapper) {
        return this.baseMapper.findListForPage(offset,rows,queryWrapper);
    }

    @Override
    public CustomerInfo getCustomerInfoByCode(String code) {
        return this.baseMapper.getCustomerInfoByCode(code);
    }
}
