package org.jeecg.modules.oroqen.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.modules.oroqen.entity.OroqenCultureContent;
import org.jeecg.modules.oroqen.mapper.OroqenCultureContentMapper;
import org.jeecg.modules.oroqen.service.IOroqenCultureContentService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Description: 文化内容
 * @Author: jeecg-boot
 * @Date: 2025-01-08
 * @Version: V1.0
 */
@Service
public class OroqenCultureContentServiceImpl extends ServiceImpl<OroqenCultureContentMapper, OroqenCultureContent> implements IOroqenCultureContentService {

    @Override
    public List<OroqenCultureContent> getByCategoryId(String categoryId) {
        return baseMapper.selectByCategoryId(categoryId);
    }

    @Override
    public List<OroqenCultureContent> getRecommended() {
        return baseMapper.selectRecommended();
    }

    @Override
    public void updateViewCount(String id) {
        baseMapper.updateViewCount(id);
    }

    @Override
    public void updateLikeCount(String id, Integer count) {
        baseMapper.updateLikeCount(id, count);
    }

    @Override
    public void updateFavoriteCount(String id, Integer count) {
        baseMapper.updateFavoriteCount(id, count);
    }
}