| | |
| | | if (StringUtil.isNullOrEmpty(type)) { |
| | | return getVideoInfoData(videoInfoDao.sqlList( |
| | | "select v.id,v.`name`,v.`tag`,v.`picture`,v.`hpicture`,v.`latest_hpicture`,v.watchcount,v.commentcount from wk_video_video v INNER JOIN (SELECT DISTINCT(v.id) FROM wk_category_video ca LEFT JOIN wk_video_video v ON v.id= ca.videoid LEFT JOIN wk_resource_video rv ON rv.`videoid`= v.`id` AND( ? ) WHERE v.show= 1 and ca.id is not null AND rv.`resourceid` IS NOT NULL ? ) a using(id)", |
| | | (page - 1) * pageCount, pageCount, new Serializable[]{resourceWhere, orderby,}),resourceList); |
| | | (page - 1) * pageCount, pageCount, new Serializable[]{resourceWhere, orderby,}), resourceList); |
| | | } |
| | | |
| | | List<VideoInfo> list = new ArrayList<VideoInfo>(); |
| | |
| | | }); |
| | | |
| | | System.out.println("查询SQL费时:" + (System.currentTimeMillis() - startTime)); |
| | | return getVideoInfoData(list,resourceList); |
| | | return getVideoInfoData(list, resourceList); |
| | | } |
| | | |
| | | public List<VideoInfo> getVideoInfoData(List list, List<Long> resourceIdList) { |
| | |
| | | */ |
| | | |
| | | @SuppressWarnings("unchecked") |
| | | public List<com.yeshi.buwan.domain.web.VideoTypeAdmin> getVideoTypeAdmin(final int detailSystem, final int pid, |
| | | public List<com.yeshi.buwan.domain.web.VideoTypeAdmin> getVideoTypeAdmin(final String systemId, final int detailSystem, final int pid, |
| | | final int page) { |
| | | return (List<com.yeshi.buwan.domain.web.VideoTypeAdmin>) videoTypeDao |
| | | .excute(new HibernateCallback<List<com.yeshi.buwan.domain.web.VideoTypeAdmin>>() { |
| | |
| | | throws HibernateException { |
| | | List<com.yeshi.buwan.domain.web.VideoTypeAdmin> hotTypeList = new ArrayList<com.yeshi.buwan.domain.web.VideoTypeAdmin>(); |
| | | try { |
| | | List<DetailSystem> detailSystemList = session.createQuery("from DetailSystem").list(); |
| | | List<DetailSystem> detailSystemList = session.createQuery("from DetailSystem ds where ds.system.id=" + systemId).list(); |
| | | String where = ""; |
| | | |
| | | List<VideoType> list = null; |