From 5dc04f3291c00d66f8733a49896612ea1e3b31c5 Mon Sep 17 00:00:00 2001 From: 罗元桥 <2376770955@qq.com> Date: 星期四, 16 九月 2021 13:19:14 +0800 Subject: [PATCH] Merge branch 'test' into 'zzj' --- springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComActMicroWishDAO.java | 22 ++++++++++++++-------- 1 files changed, 14 insertions(+), 8 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComActMicroWishDAO.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComActMicroWishDAO.java index bd1ec69..a193c72 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComActMicroWishDAO.java +++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComActMicroWishDAO.java @@ -43,7 +43,7 @@ "w.`detail`, " + "w.form, " + "w.reject_reason, " + - "su.`name` responsible_name, " + + "su1.`name` responsible_name, " + "w.score, " + "w.img_width, " + "w.finish_at, " + @@ -53,16 +53,16 @@ "FROM " + "com_act_micro_wish w " + "left join com_act_micro_wish_user wu on w.id=wu.micro_wish_id "+ - "JOIN sys_user u ON w.sponsor_id = u.user_id " + + "left JOIN sys_user u ON w.sponsor_id = u.user_id " + "<if test='comActMicroWishVO.sponsorName != null and comActMicroWishVO.sponsorName.trim() != ""'>" + "AND u.name like concat(#{comActMicroWishVO.sponsorName},'%') " + " </if> " + "<if test='comActMicroWishVO.responsibleName == null or comActMicroWishVO.responsibleName.trim() == ""'>" + - "LEFT JOIN com_pb_service_team su ON w.responsible_id = su.id " + + "LEFT JOIN sys_user su1 ON w.responsible_id = su1.user_id " + " </if> " + "<if test='comActMicroWishVO.responsibleName != null and comActMicroWishVO.responsibleName.trim() != ""'>" + - " JOIN com_pb_service_team su ON w.responsible_id = su.id " + - "AND su.`name` like concat(#{comActMicroWishVO.responsibleName},'%') " + + " JOIN sys_user su1 ON w.responsible_id = su1.user_id " + + "AND su1.`name` like concat(#{comActMicroWishVO.responsibleName},'%') " + " </if> " + " <where>" + "<if test='comActMicroWishVO.communityId != null and comActMicroWishVO.communityId != 0'>" + @@ -75,7 +75,7 @@ "AND w.`status` = #{comActMicroWishVO.status} " + " </if> " + "<if test='comActMicroWishVO.status == 3 and comActMicroWishVO.isPageMyWish==null'>" + - "AND w.`status` = 3 " + + "AND w.`status` in (2,3) " + " </if> " + "<if test='comActMicroWishVO.status != null and comActMicroWishVO.status!=0 and comActMicroWishVO.isPageMyWish!=null and comActMicroWishVO.status==1'>" + "AND w.`status` =1 " + @@ -104,6 +104,8 @@ "ORDER BY w.create_at desc "+ "</script>") IPage<ComActMicroWishVO> pageMicroWish(Page page, @Param("comActMicroWishVO") ComActMicroWishVO comActMicroWishVO); + + IPage<ComActMicroWishVO> pageMicroWishApplets(Page page, @Param("comActMicroWishVO") ComActMicroWishVO comActMicroWishVO); @Select("SELECT " + "w.id, " + "u.name sponsor_name, " + @@ -121,6 +123,7 @@ "su.`name` responsible_name, " + "w.form, " + "w.reject_reason, " + + "w.community_id, " + "w.examine_at, " + "w.finish, " + "w.finish_photo_path_list, " + @@ -136,7 +139,7 @@ "w.evaluate " + "FROM " + "com_act_micro_wish w " + - "JOIN sys_user u ON w.sponsor_id = u.user_id " + + "LEFT JOIN sys_user u ON w.sponsor_id = u.user_id " + "LEFT JOIN com_pb_service_team su ON w.responsible_id = su.id " + "LEFT JOIN com_act_micro_wish_user wu ON w.id = wu.micro_wish_id " + "WHERE " + @@ -168,9 +171,12 @@ " w.community_id ") List<TodoEventsVO> selectNeedToDo(@Param("communityId") Long communityId, @Param("userId") Long userId); - @Update("update com_act_micro_wish set `status`=6, evaluate_at=now() where `status`=5 and TIMESTAMPDIFF(HOUR, feedback_at, SYSDATE())>=72") + @Update("update com_act_micro_wish set `status`=6, evaluate_at=now() where `status`=5 and TIMESTAMPDIFF(HOUR, finish_at, SYSDATE())>=72") int updateStatusAutoConfirm(); + @Select("select id from com_act_micro_wish where `status`=5 and TIMESTAMPDIFF(HOUR, feedback_at, SYSDATE())>=72 ") + List<Long> getWishAutoConfirmIds(); + @Select("SELECT COUNT(id) AS completedNum," + "(SELECT COUNT(id) FROM com_act_micro_wish WHERE community_id = #{communityId} AND (status =1 OR status =2 OR status = 3 OR status = 5)) AS willNum ," + "(SELECT COUNT(id) FROM com_act_micro_wish WHERE community_id = #{communityId} AND (status =1 OR status =2 OR status = 3 OR status = 5 OR status = 6) AND create_at LIKE CONCAT(#{nowDate},'%')) AS currentNum " + -- Gitblit v1.7.1