xyh
2021-06-18 42239f79490e7130a63d51a67efd1f2c8d23be37
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComActNeighborCircleDAO.java
@@ -152,8 +152,8 @@
    List<PieElementVO> countAllNoneCompletedWorkByCommunityId(@Param("communityId")Long communityId);
    @Select(" SELECT AVG(b.t)AS avgTime " +
            "  FROM (SELECT  TIMESTAMPDIFF(HOUR,create_at,feedback_at) AS t  FROM com_act_easy_photo WHERE community_id = #{communityId} and STATUS = 4 " +
            "  UNION ALL SELECT  TIMESTAMPDIFF(HOUR,create_at,finish_at) AS t  FROM com_act_micro_wish WHERE community_id = #{communityId} and STATUS = 6 " +
            "  FROM (SELECT  TIMESTAMPDIFF(MINUTE,create_at,feedback_at) AS t  FROM com_act_easy_photo WHERE community_id = #{communityId} and STATUS = 4 " +
            "  UNION ALL SELECT  TIMESTAMPDIFF(MINUTE,create_at,finish_at) AS t  FROM com_act_micro_wish WHERE community_id = #{communityId} and STATUS = 6 " +
            "  )AS b ")
    Map<String, Object> countAvgByCommunityId(@Param("communityId")Long communityId);
}