|
|
@ -1,5 +1,6 @@ |
|
|
|
package com.cloud.kicc.system.controller; |
|
|
|
package com.cloud.kicc.system.controller; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.util.StrUtil; |
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
|
|
|
import com.cloud.kicc.common.core.api.R; |
|
|
|
import com.cloud.kicc.common.core.api.R; |
|
|
|
import com.cloud.kicc.common.core.constant.AppConstants; |
|
|
|
import com.cloud.kicc.common.core.constant.AppConstants; |
|
|
@ -9,12 +10,10 @@ import com.cloud.kicc.system.service.AppService; |
|
|
|
import com.cloud.kicc.system.service.ISsoUserService; |
|
|
|
import com.cloud.kicc.system.service.ISsoUserService; |
|
|
|
import io.swagger.annotations.Api; |
|
|
|
import io.swagger.annotations.Api; |
|
|
|
import lombok.AllArgsConstructor; |
|
|
|
import lombok.AllArgsConstructor; |
|
|
|
import org.springframework.web.bind.annotation.GetMapping; |
|
|
|
import org.springframework.web.bind.annotation.*; |
|
|
|
import org.springframework.web.bind.annotation.PathVariable; |
|
|
|
|
|
|
|
import org.springframework.web.bind.annotation.RequestMapping; |
|
|
|
|
|
|
|
import org.springframework.web.bind.annotation.RestController; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import java.util.List; |
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
import java.util.Map; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
*<p> |
|
|
|
*<p> |
|
|
@ -42,15 +41,16 @@ public class AppController { |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 获取指定用户全部信息 |
|
|
|
* 获取指定用户全部信息 |
|
|
|
* @param ssoUser SSO用户 |
|
|
|
* @param param 参数 |
|
|
|
* @return 用户信息 |
|
|
|
* @return 用户信息 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Inner |
|
|
|
@Inner |
|
|
|
@GetMapping("/selectByPhoneAndSsoUser") |
|
|
|
@GetMapping("/selectByPhoneAndSsoUser") |
|
|
|
public R<SsoUser> selectByPhoneAndSsoUser(SsoUser ssoUser) { |
|
|
|
public R<SsoUser> selectByPhoneAndSsoUser(@RequestParam Map<String, String> param) { |
|
|
|
List<SsoUser> user = iSsoUserService.list(Wrappers.<SsoUser>lambdaQuery() |
|
|
|
List<SsoUser> user = iSsoUserService.list(Wrappers.<SsoUser>lambdaQuery() |
|
|
|
.eq(SsoUser::getPhone, ssoUser.getPhone()) |
|
|
|
.eq(SsoUser::getPhone, param.get("phone")) |
|
|
|
.eq(SsoUser::getIdentityProvider, ssoUser.getIdentityProvider())); |
|
|
|
.eq(SsoUser::getTenantId, param.get("tenantId")) |
|
|
|
|
|
|
|
.eq(StrUtil.isNotBlank(param.get("identityProvider")) ,SsoUser::getIdentityProvider, param.get("identityProvider"))); |
|
|
|
if (user.isEmpty()) { |
|
|
|
if (user.isEmpty()) { |
|
|
|
return R.error("该手机号不存在,请先注册!"); |
|
|
|
return R.error("该手机号不存在,请先注册!"); |
|
|
|
} |
|
|
|
} |
|
|
|