package cn.iocoder.yudao.module.museum.dal.mysql.museumpicture;

import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.museum.dal.database.museumpicture.PictureGroupDO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

@Mapper
public interface PictureGroupMapper extends BaseMapperX<PictureGroupDO> {

    @Update("UPDATE museum_picture_table SET picture_set_introduce=#{picture_set_introduce} WHERE id =#{id}")
    void updatePictureGroup(PictureGroupDO pictureGroupDO);

    @Update("UPDATE museum_picture_table SET deleted=1  WHERE id =#{id}")
    void deletePictureGroup(Integer id);

    @Select("SELECT * FROM museum_picture_table WHERE id = #{id} AND deleted =0 ")
    PictureGroupDO selectPictureGroupById(@Param("id") Integer id);

}
