| | |
| | | import com.xinquan.common.core.constant.ServiceNameConstants; |
| | | import com.xinquan.common.core.domain.R; |
| | | import com.xinquan.system.api.model.AppCaptchaBody; |
| | | import com.xinquan.system.api.model.AppLoginUser; |
| | | import com.xinquan.system.api.model.AppVerifyCellPhoneBody; |
| | | import com.xinquan.system.api.model.AppWXLoginBody; |
| | | import com.xinquan.system.api.model.AppleLoginUser; |
| | | import com.xinquan.system.api.model.LoginUser; |
| | | import com.xinquan.system.api.model.WXLoginUser; |
| | | import com.xinquan.user.api.domain.AppUser; |
| | | import com.xinquan.user.api.domain.dto.AppUserDTO; |
| | | import com.xinquan.user.api.factory.RemoteAppUserFallbackFactory; |
| | | import java.util.Collection; |
| | | import java.util.List; |
| | | import org.springframework.cloud.openfeign.FeignClient; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestHeader; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | /** |
| | | * @author mitao |
| | |
| | | */ |
| | | @FeignClient(contextId = "remoteAppUserService", value = ServiceNameConstants.APP_USER_SERVICE, fallbackFactory = RemoteAppUserFallbackFactory.class) |
| | | public interface RemoteAppUserService { |
| | | |
| | | @GetMapping("/client/app-user-course/getUserByCourseId/{courseId}") |
| | | R<List<String>> getUserByCourseId(@PathVariable("courseId") Long courseId); |
| | | |
| | | /** |
| | | * 获取未注销的用户信息 |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/inner/app-user/registerAppUser") |
| | | R<Boolean> registerAppUser(@RequestBody AppUserDTO appUserDTO, |
| | | R<AppUser> registerAppUser(@RequestBody AppUserDTO appUserDTO, |
| | | @RequestHeader(SecurityConstants.FROM_SOURCE) String source); |
| | | |
| | | /** |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/inner/app-user/wxLogin") |
| | | R<WXLoginUser> wxLogin(@RequestBody AppWXLoginBody body, |
| | | R<AppLoginUser> wxLogin(@RequestBody AppWXLoginBody body, |
| | | @RequestHeader(SecurityConstants.FROM_SOURCE) String source); |
| | | |
| | | /** |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/inner/app-user/appleLogin") |
| | | R<AppleLoginUser> appleLogin(@RequestParam("appleId") String appleId, |
| | | R<AppLoginUser> appleLogin(@RequestParam("appleId") String appleId, |
| | | @RequestHeader(SecurityConstants.FROM_SOURCE) String source); |
| | | |
| | | /** |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/inner/app-user/captchaLogin") |
| | | R<LoginUser> appCaptchaLogin(@RequestBody AppCaptchaBody body, |
| | | R<AppLoginUser> appCaptchaLogin(@RequestBody AppCaptchaBody body, |
| | | @RequestHeader(SecurityConstants.FROM_SOURCE) String source); |
| | | |
| | | /** |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/inner/app-user/verifyCellPhone") |
| | | R<WXLoginUser> verifyCellPhone(@RequestBody AppVerifyCellPhoneBody body, |
| | | R<AppLoginUser> verifyCellPhone(@RequestBody AppVerifyCellPhoneBody body, |
| | | @RequestHeader(SecurityConstants.FROM_SOURCE) String source); |
| | | |
| | | /** |
| | | * 更新用户信息 |
| | | * |
| | | * @param dto |
| | | * @param source |
| | | * @return |
| | | */ |
| | | @PostMapping("/inner/app-user/updateAppUser") |
| | | R<?> updateAppUser(@RequestBody AppUserDTO dto, |
| | | @RequestHeader(SecurityConstants.FROM_SOURCE) String source); |
| | | |
| | | /** |
| | | * 获取用户列表 |
| | | * |
| | | * @param appUserIdSet 用户id列表 |
| | | * @param source 请求来源 |
| | | * @return |
| | | */ |
| | | @PostMapping("/inner/app-user/getAppUserList") |
| | | R<List<AppUser>> getAppUserList(@RequestBody Collection<Long> appUserIdSet, |
| | | @RequestHeader(SecurityConstants.FROM_SOURCE) String source); |
| | | } |