package com.zhentao.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.zhentao.vo.RecommendUserVO;
import com.zhentao.dto.UserSearchQuery;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface RecommendMapper {

    List<RecommendUserVO> selectRecommendedUsers(
            @Param("userId") Integer userId,
            @Param("oppoOnly") Integer oppoOnly,
            @Param("limit") Integer limit
    );

    List<RecommendUserVO> selectByRules(@Param("q") UserSearchQuery q,
                                        @Param("birthMin") String birthMin,
                                        @Param("birthMax") String birthMax,
                                        @Param("hobbyJson") String hobbyJson,
                                        @Param("excludeIds") List<Integer> excludeIds,
                                        @Param("limit") Integer limit,
                                        @Param("offset") Integer offset);

    // provinces
    List<com.zhentao.pojo.Province> selectAllProvinces();

    // cities
    List<com.zhentao.pojo.City> selectAllCities();

    // cities by provinceId
    List<com.zhentao.pojo.City> selectCitiesByProvince(@Param("provinceId") Integer provinceId);

    // areas by cityId
    List<com.zhentao.pojo.Area> selectAreasByCity(@Param("cityId") Integer cityId);
}


