| | |
| | | package com.ruoyi.system.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.system.domain.TInformation; |
| | | import com.ruoyi.system.domain.TVideo; |
| | | import com.ruoyi.system.mapper.TVideoMapper; |
| | | import com.ruoyi.system.query.TInformationQuery; |
| | | import com.ruoyi.system.query.TVideoQuery; |
| | | import com.ruoyi.system.service.TVideoService; |
| | | import com.ruoyi.system.vo.TVideoVO; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | @Service |
| | | public class TVideoServiceImpl extends ServiceImpl<TVideoMapper, TVideo> implements TVideoService { |
| | | |
| | | @Override |
| | | public PageInfo<TVideoVO> pageList(TVideoQuery query) { |
| | | PageInfo<TVideoVO> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize()); |
| | | List<TVideoVO> list = this.baseMapper.pageList(query,pageInfo); |
| | | pageInfo.setRecords(list); |
| | | return pageInfo; |
| | | } |
| | | |
| | | @Override |
| | | public int upAndDown(Long id, Integer status) { |
| | | TVideo video = this.baseMapper.selectById(id); |
| | | video.setStatus(status); |
| | | return this.baseMapper.updateById(video); |
| | | } |
| | | |
| | | } |