| | |
| | | </if> |
| | | </select> |
| | | |
| | | <select id="getDailyAdd" resultType="java.util.Map"> |
| | | SELECT DATE_FORMAT( su.create_at, '%Y-%m-%d' ) as createAt ,count(su.user_id) as addUser FROM |
| | | sys_user AS su |
| | | LEFT JOIN com_act AS ac ON su.community_id = ac.community_id |
| | | LEFT JOIN com_street AS cs ON ac.street_id = cs.street_id |
| | | where su.community_id<>'' |
| | | and cs.area_code<>'' |
| | | and su.type = 1 |
| | | <if test="appId != null and appId != """> |
| | | and su.app_id = #{appId} |
| | | </if> |
| | | <if test="id != null"> |
| | | and cs.street_id=#{id} |
| | | </if> |
| | | <if test="areaCode != null"> |
| | | and cs.area_code=#{areaCode} |
| | | </if> |
| | | AND su.create_at > #{createAt} GROUP BY createAt |
| | | </select> |
| | | <select id="getActive" resultType="java.util.Map"> |
| | | SELECT DATE_FORMAT( su.last_login_time, '%Y-%m-%d' ) as createAt ,count(su.user_id) as activeUser FROM |
| | | sys_user AS su |
| | | LEFT JOIN com_act AS ac ON su.community_id = ac.community_id |
| | | LEFT JOIN com_street AS cs ON ac.street_id = cs.street_id |
| | | where su.community_id<>'' |
| | | and cs.area_code<>'' |
| | | and su.type = 1 |
| | | <if test="appId != null and appId != """> |
| | | and su.app_id = #{appId} |
| | | </if> |
| | | <if test="id != null"> |
| | | and cs.street_id=#{id} |
| | | </if> |
| | | <if test="areaCode != null"> |
| | | and cs.area_code=#{areaCode} |
| | | </if> |
| | | AND su.last_login_time > #{lastLoginTime} GROUP BY createAt |
| | | </select> |
| | | |
| | | <select id="selectStreetByAreaCode" resultType="com.panzhihua.common.model.vos.user.StreetVOS"> |
| | | select street_id as id,name as name from com_street where area_code=#{code} and app_id ='wx118de8a734d269f0' |
| | | </select> |