package com.cpxt.biz.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.cpxt.biz.domain.SysArea;
import com.cpxt.biz.service.SysAreaService;
import com.cpxt.biz.mapper.SysAreaMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author LuoJian
* @description 针对表【sys_area(从统计局上抓取的数据，导入到当前表)】的数据库操作Service实现
* @createDate 2025-01-16 14:22:17
*/
@Service
public class SysAreaServiceImpl extends ServiceImpl<SysAreaMapper, SysArea>
    implements SysAreaService{

    @Autowired
    private SysAreaMapper sysAreaMapper;

    @Override
    public List<SysArea> selectByParentId(String parentId) {
        LambdaQueryWrapper<SysArea> queryWrapper = new LambdaQueryWrapper<>();
        queryWrapper.eq(SysArea::getParentId,parentId);
        return sysAreaMapper.selectList(queryWrapper);
    }
}




