| | |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.yeshi.buwan.dao.AttentionDao; |
| | | import com.yeshi.buwan.dao.LoginUserDao; |
| | | import com.yeshi.buwan.dao.user.LoginUserDao; |
| | | import com.yeshi.buwan.domain.Attention; |
| | | import com.yeshi.buwan.domain.LoginUser; |
| | | import com.yeshi.buwan.domain.user.LoginUser; |
| | | import com.yeshi.buwan.domain.VideoDetailInfo; |
| | | import com.yeshi.buwan.domain.VideoResource; |
| | | import com.yeshi.buwan.util.Constant; |
| | |
| | | private VideoDetailUtil videoDetailUtil; |
| | | @Resource |
| | | private LoginUserDao loginUserDao; |
| | | |
| | | public VideoDetailUtil getVideoDetailUtil() { |
| | | return videoDetailUtil; |
| | | } |
| | | |
| | | public void setVideoDetailUtil(VideoDetailUtil videoDetailUtil) { |
| | | this.videoDetailUtil = videoDetailUtil; |
| | | } |
| | | |
| | | public AttentionDao getAttentionDao() { |
| | | return attentionDao; |
| | | } |
| | | |
| | | public void setAttentionDao(AttentionDao attentionDao) { |
| | | this.attentionDao = attentionDao; |
| | | } |
| | | |
| | | @SuppressWarnings("unchecked") |
| | | @Caching(evict = { |
| | |
| | | } catch (Exception e) { |
| | | isS = false; |
| | | e.printStackTrace(); |
| | | if (session.getTransaction().isActive()) |
| | | session.getTransaction().rollback(); |
| | | } |
| | | return isS; |
| | |
| | | if (map.get(at.getId()) != null) { |
| | | VideoResource vr = (VideoResource) map.get(at.getId()); |
| | | VideoDetailInfo detail = videoDetailUtil.getLatestVideoDetail(at.getVideoInfo().getId(), vr); |
| | | List<VideoDetailInfo> detailInfos = new ArrayList<VideoDetailInfo>(); |
| | | List<VideoDetailInfo> detailInfos = new ArrayList<>(); |
| | | detailInfos.add(detail); |
| | | at.getVideoInfo().setVideoDetailList(detailInfos); |
| | | } |