springcloud_k8s_panzhihuazhihuishequ/service_user/src/main/java/com/panzhihua/service_user/dao/UserDao.java
@@ -317,16 +317,16 @@ "FROM\n" + "\t com_pb_member_role a \n" + "WHERE\n" + "\t a.phone = #{phone}") Integer selectCountMemberRole(@Param("phone")String phone); "\t a.phone = #{phone} and community_id=#{userCommunityId} ") Integer selectCountMemberRole(@Param("phone")String phone, @Param("userCommunityId")Long userCommunityId); @Select("SELECT\n" + "\t COUNT(a.id)\n" + "FROM\n" + "\t com_pb_service_team a \n" + "WHERE\n" + "\t a.phone = #{phone}") Integer selectCountTeam(@Param("phone")String phone); "\t a.phone = #{phone} and community_id=#{userCommunityId} ") Integer selectCountTeam(@Param("phone")String phone, @Param("userCommunityId")Long userCommunityId); @Update("update com_pb_member_role u set u.phone=#{newphone},is_reg=1 where u.phone=#{oldphone}") springcloud_k8s_panzhihuazhihuishequ/service_user/src/main/java/com/panzhihua/service_user/service/impl/UserServiceImpl.java
@@ -230,6 +230,7 @@ loginUserInfoVO.setIsmemberrole(2); // 志愿者状态 String phone = sysUserDO.getPhone(); Long userCommunityId = sysUserDO.getCommunityId(); if (!ObjectUtils.isEmpty(phone)) { ComMngVolunteerMngVO comMngVolunteerMngVO = userDao.selectVolunteerMngByPhone(phone); if (ObjectUtils.isEmpty(comMngVolunteerMngVO)) { @@ -238,8 +239,9 @@ int state = comMngVolunteerMngVO.getState().intValue(); loginUserInfoVO.setVolunteerStatus(state); } Integer countTeam = userDao.selectCountTeam(phone); Integer selectCountMemberRole = userDao.selectCountMemberRole(phone); //是否是"管理员"或者 本社区 "社区团队"、"党委成员" Integer countTeam = userDao.selectCountTeam(phone, userCommunityId); Integer selectCountMemberRole = userDao.selectCountMemberRole(phone, userCommunityId); Integer isSysUser = userDao.selectCountSysUser(phone); if (countTeam != null && countTeam > 0) { loginUserInfoVO.setIsmemberrole(1);