New file |
| | |
| | | package com.dsh.course.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.dsh.course.entity.TNotices; |
| | | import com.dsh.course.mapper.TNoticesMapper; |
| | | import com.dsh.course.model.dto.TNoticeWarpper; |
| | | import com.dsh.course.service.ITNoticesService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.List; |
| | | |
| | | @Service |
| | | public class TNoticesService1Impl extends ServiceImpl<TNoticesMapper, TNotices> implements ITNoticesService { |
| | | |
| | | @Resource |
| | | private TNoticesMapper tNoticesMapper; |
| | | |
| | | |
| | | |
| | | /** |
| | | * 获取滚动消息 |
| | | * @param type 1=滚动消息,2=公告 |
| | | * @return |
| | | * @throws Exception |
| | | */ |
| | | @Override |
| | | public List<TNoticeWarpper> queryNotices(Integer type) throws Exception { |
| | | List<TNotices> notices = tNoticesMapper.queryNotices(type); |
| | | return TNoticeWarpper.getTNoticeWarppers(notices); |
| | | } |
| | | } |