package com.ruoyi.mall.service.impl;

import com.ruoyi.mall.domain.MallSchoolTag;
import com.ruoyi.mall.mapper.MallSchoolTagMapper;
import com.ruoyi.mall.service.IMallSchoolTagService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 学校标签分类idService业务层处理
 *
 * @author Lsm
 * @date 2023-10-18
 */
@Service
public class MallSchoolTagServiceImpl implements IMallSchoolTagService
{
    @Resource
    private MallSchoolTagMapper mallSchoolTagMapper;

    /**
     * 查询学校标签分类id
     *
     * @param schoolTagId 学校标签分类id主键
     * @return 学校标签分类id
     */
    @Override
    public MallSchoolTag selectMallSchoolTagBySchoolTagId(Long schoolTagId)
    {
        return mallSchoolTagMapper.selectMallSchoolTagBySchoolTagId(schoolTagId);
    }

    /**
     * 查询学校标签分类id列表
     *
     * @param mallSchoolTag 学校标签分类id
     * @return 学校标签分类id
     */
    @Override
    public List<MallSchoolTag> selectMallSchoolTagList(MallSchoolTag mallSchoolTag)
    {
        return mallSchoolTagMapper.selectMallSchoolTagList(mallSchoolTag);
    }

    /**
     * 新增学校标签分类id
     *
     * @param mallSchoolTag 学校标签分类id
     * @return 结果
     */
    @Override
    public int insertMallSchoolTag(MallSchoolTag mallSchoolTag)
    {
        return mallSchoolTagMapper.insertMallSchoolTag(mallSchoolTag);
    }

    /**
     * 修改学校标签分类id
     *
     * @param mallSchoolTag 学校标签分类id
     * @return 结果
     */
    @Override
    public int updateMallSchoolTag(MallSchoolTag mallSchoolTag)
    {
        return mallSchoolTagMapper.updateMallSchoolTag(mallSchoolTag);
    }

    /**
     * 批量删除学校标签分类id
     *
     * @param schoolTagIds 需要删除的学校标签分类id主键
     * @return 结果
     */
    @Override
    public int deleteMallSchoolTagBySchoolTagIds(Long[] schoolTagIds)
    {
        return mallSchoolTagMapper.deleteMallSchoolTagBySchoolTagIds(schoolTagIds);
    }

    /**
     * 删除学校标签分类id信息
     *
     * @param schoolTagId 学校标签分类id主键
     * @return 结果
     */
    @Override
    public int deleteMallSchoolTagBySchoolTagId(Long schoolTagId)
    {
        return mallSchoolTagMapper.deleteMallSchoolTagBySchoolTagId(schoolTagId);
    }

    /**
     * 学校标签列表
     * @return 结果
     */
    @Override
    public List<MallSchoolTag> selectTagList() {
        return mallSchoolTagMapper.selectTagList();
    }
}
