Authored by 张帅

fix

... ... @@ -15,10 +15,10 @@ public interface PublicUserAttentionRepository extends JpaRepository<PublicUserA
int countByTargetIdInAndUidInAndAttentionTypeIsAndSrcChannelIsAndCreateTimeBetween(List<Integer> targetIds,List<Integer> uids,Integer attentionType,Integer srcChannel, Long startTime,Long endTIme);
@Query(value = "select new com.yoho.datasync.fullsync.dal.repository.pcms.model.UidAndAttention(uid, count(id))" +
" from PublicUserAttention where createTime > :startTime and create_time <:endTime and attentionType=1 and status=1 group by uid")
" from PublicUserAttention where createTime > :startTime and create_time <=:endTime and attentionType=1 and status=1 group by uid")
List<UidAndAttention> selectUidAttenCount(@Param("startTime")Long startTime, @Param("endTime")Long endTime);
@Query(value = "select new com.yoho.datasync.fullsync.dal.repository.pcms.model.UidAndAttention(targetId, count(id),authorType)" +
" from PublicUserAttention where createTime > :startTime and create_time <:endTime and attentionType=1 and status=1 group by targetId,authorType")
" from PublicUserAttention where createTime > :startTime and create_time <=:endTime and attentionType=1 and status=1 group by targetId,authorType")
List<UidAndAttention> selectUidFansCount(@Param("startTime")Long startTime, @Param("endTime")Long endTime);
}
... ...
... ... @@ -17,6 +17,6 @@ public interface PublicUserFavoriteRepository extends JpaRepository<PublicUserFa
int countByTargetIdInAndFavoriteTypeIsAndSrcChannelIsAndCreateTimeBetween(List<Integer> ids, Integer favoriteType, Integer srcChannel, Long satrtTime, Long endTime);
@Query(value = "select new com.yoho.datasync.fullsync.dal.repository.pcms.model.ArticleIdAndCount(targetId, count(id))" +
" from PublicUserFavorite where createTime > :startTime and create_time <:endTime and favoriteType=1 and status=1 group by targetId")
" from PublicUserFavorite where createTime > :startTime and create_time <=:endTime and favoriteType=1 and status=1 group by targetId")
List<ArticleIdAndCount> selectArticleFavoriteCount(@Param("startTime")Long startTime, @Param("endTime")Long endTime);
}
... ...
... ... @@ -16,6 +16,6 @@ public interface PublicUserPraiseRepository extends JpaRepository<PublicUserPrai
int countByTargetIdInAndPraiseTypeIsAndSrcChannelIsAndCreateTimeBetween(List<Integer> ids, Integer type,Integer src_channel,Long startTime, Long endTime);
@Query(value = "select new com.yoho.datasync.fullsync.dal.repository.pcms.model.ArticleIdAndCount(targetId, count(id))" +
" from PublicUserPraise where createTime > :startTime and create_time <:endTime and praiseType=1 and status=1 group by targetId")
" from PublicUserPraise where createTime > :startTime and create_time <=:endTime and praiseType=1 and status=1 group by targetId")
List<ArticleIdAndCount> selectArticlePraiseCount(@Param("startTime")Long startTime, @Param("endTime")Long endTime);
}
... ...