package cn.iocoder.yudao.module.jx.service.impl;

import cn.iocoder.yudao.framework.common.exception.ServiceException;
import cn.iocoder.yudao.framework.tenant.core.aop.TenantIgnore;
import cn.iocoder.yudao.module.jx.domain.DriveSchoolGuide;
import cn.iocoder.yudao.module.jx.mapper.DriveSchoolGuideMapper;
import cn.iocoder.yudao.module.jx.service.DriveSchoolGuideService;
import cn.iocoder.yudao.module.jx.vo.DlDriveSchoolGuidePageReqVO;
import cn.iocoder.yudao.util.StringUtils;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.Collections;
import java.util.List;

/**
 * 业务办理指南
 *
 * @author ruoyi
 * @date 2024-04-01
 */
@Service
public class DriveSchoolGuideServiceImpl extends ServiceImpl<DriveSchoolGuideMapper, DriveSchoolGuide> implements DriveSchoolGuideService {


    @Override
    @TenantIgnore
    public List<DriveSchoolGuide> listByTenantId(String tenantId) {
        LambdaQueryWrapper<DriveSchoolGuide> queryWrapper = new LambdaQueryWrapper<>();
        if (StringUtils.isNotBlank(tenantId)) {
            queryWrapper.eq(DriveSchoolGuide::getTenantId, tenantId).eq(DriveSchoolGuide::getDeleted, 0);
            return this.list(queryWrapper);
        }
        return null;
    }
}
