提交 b9bb3db2 authored 作者: 000516's avatar 000516

Merge branch 'master' into lql

package com.sfa.system.api; package com.sfa.system.api;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;
import com.sfa.common.core.constant.SecurityConstants; import com.sfa.common.core.constant.SecurityConstants;
import com.sfa.common.core.constant.ServiceNameConstants; import com.sfa.common.core.constant.ServiceNameConstants;
import com.sfa.common.core.domain.R; import com.sfa.common.core.domain.R;
import com.sfa.system.api.domain.SysUser; import com.sfa.system.api.domain.SysUser;
import com.sfa.system.api.factory.RemoteUserFallbackFactory; import com.sfa.system.api.factory.RemoteUserFallbackFactory;
import com.sfa.system.api.model.LoginUser; import com.sfa.system.api.model.LoginUser;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;
/** /**
* 用户服务 * 用户服务
...@@ -32,6 +27,9 @@ public interface RemoteUserService ...@@ -32,6 +27,9 @@ public interface RemoteUserService
@GetMapping("/system/user/info/{username}") @GetMapping("/system/user/info/{username}")
public R<LoginUser> getUserInfo(@PathVariable("username") String username, @RequestHeader(SecurityConstants.FROM_SOURCE) String source); public R<LoginUser> getUserInfo(@PathVariable("username") String username, @RequestHeader(SecurityConstants.FROM_SOURCE) String source);
@GetMapping("/system/user/userInfoById")
public R<SysUser> getUserInfoById(@RequestParam("userId")Long userId, @RequestHeader(SecurityConstants.FROM_SOURCE) String source);
/** /**
* 注册用户信息 * 注册用户信息
* *
......
...@@ -31,6 +31,12 @@ public class RemoteUserFallbackFactory implements FallbackFactory<RemoteUserServ ...@@ -31,6 +31,12 @@ public class RemoteUserFallbackFactory implements FallbackFactory<RemoteUserServ
return R.fail("获取用户失败:" + throwable.getMessage()); return R.fail("获取用户失败:" + throwable.getMessage());
} }
@Override
public R<SysUser> getUserInfoById(Long userId, String source) {
return R.fail("获取用户失败:" + throwable.getMessage());
}
@Override @Override
public R<Boolean> registerUserInfo(SysUser sysUser, String source) public R<Boolean> registerUserInfo(SysUser sysUser, String source)
{ {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论