| | |
| | | public class StarService { |
| | | @Resource |
| | | private HotStarDao hotStarDao; |
| | | @Resource |
| | | private VideoInfoDao videoInfoDao; |
| | | |
| | | @Resource |
| | | private SuperHotStarDao superHotStarDao; |
| | | |
| | |
| | | |
| | | return hotStarDao.getCount("select count(*) from SuperHotStar s where s.detailSystem.id=?", |
| | | new String[]{detailSystem}); |
| | | } |
| | | |
| | | public List<VideoInfo> getHotStarVideo(String starId, int page) { |
| | | |
| | | List<VideoInfo> list = videoInfoDao.list( |
| | | "select h.video from HotStarVideo as h LEFT JOIN h.video as v where h.video.show='1' and v.id=h.video.id and h.star.id=? order by h.video.updatetime desc", |
| | | (page - 1) * Constant.pageCount, Constant.pageCount, new String[]{starId}); |
| | | return list; |
| | | } |
| | | |
| | | public long getHotStarVideoCount(String starId) { |
| | | |
| | | long count = hotStarDao.getCount( |
| | | "select count(*) from HotStarVideo as h where h.video.show='1' and h.star.id=?", |
| | | new String[]{starId}); |
| | | return count; |
| | | } |
| | | |
| | | public List<HotStar> getStarList() { |