package com.yonge.cooleshow.bbs.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.yonge.cooleshow.bbs.entity.BbsConfigLabel;
import com.yonge.cooleshow.bbs.vo.BbsConfigLabelVo;
import com.yonge.cooleshow.bbs.dto.search.BbsConfigLabelSearch;
import com.yonge.cooleshow.bbs.dao.BbsConfigLabelDao;
import com.yonge.cooleshow.bbs.service.BbsConfigLabelService;

import java.util.List;

@Service
public class BbsConfigLabelServiceImpl extends ServiceImpl<BbsConfigLabelDao, BbsConfigLabel> implements BbsConfigLabelService {
    private final static Logger log = LoggerFactory.getLogger(BbsConfigLabelServiceImpl.class);

    @Override
    public BbsConfigLabelVo detail(Long id) {
        return baseMapper.detail(id);
    }

    @Override
    public IPage<BbsConfigLabelVo> selectPage(IPage<BbsConfigLabelVo> page, BbsConfigLabelSearch query) {
        return page.setRecords(baseMapper.selectPage(page, query));
    }

    @Override
    public List<BbsConfigLabel> selectAll(Integer delFlag) {
        return baseMapper.selectAll(delFlag);
    }

    @Override
    public void updateFlagByIds(BbsConfigLabelSearch query, Long userId) {
        baseMapper.updateFlagByIds(query, userId);
    }
}