feiyu02
2022-01-12 1564af04dacafcc08a9682a4ef1e651120c8cc46
src/main/kotlin/cn/flightfeather/supervision/lightshare/web/UserinfoController.kt
@@ -6,6 +6,7 @@
import cn.flightfeather.supervision.lightshare.vo.UserSearchCondition
import io.swagger.annotations.Api
import io.swagger.annotations.ApiOperation
import io.swagger.annotations.ApiParam
import org.springframework.web.bind.annotation.*
import org.springframework.web.multipart.MultipartFile
import javax.servlet.http.HttpServletResponse
@@ -71,4 +72,14 @@
    fun getBaseInfo(
            @RequestParam("userId") userId: String
    ) = userinfoService.getBaseInfo(userId)
    @ApiOperation(value = "根据给定条件,搜索用户")
    @GetMapping("/search")
    fun search(
        @ApiParam("区县", example = "徐汇区") @RequestParam("district", required = false) district: String,
        @ApiParam("场景类型", example = "1", allowableValues = "0,1,2,3,4,5,6,7") @RequestParam("sceneType", required = false) sceneType: Int,
        @ApiParam("用户类型", example = "0", allowableValues = "0,1,2,3") @RequestParam("userType", required = false) userType: Int,
        @RequestParam(value = "page") page: Int,
        @RequestParam(value = "per_page") perPage: Int,
    ) = userinfoService.search(district, sceneType, userType, page, perPage)
}