27 changed files with 422 additions and 38 deletions
@ -0,0 +1,46 @@ |
|||||
|
/** |
||||
|
* Copyright 2018 人人开源 https://www.renren.io
|
||||
|
* <p> |
||||
|
* This program is free software: you can redistribute it and/or modify |
||||
|
* it under the terms of the GNU General Public License as published by |
||||
|
* the Free Software Foundation, either version 3 of the License, or |
||||
|
* (at your option) any later version. |
||||
|
* <p> |
||||
|
* This program is distributed in the hope that it will be useful, |
||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
|
* GNU General Public License for more details. |
||||
|
* <p> |
||||
|
* You should have received a copy of the GNU General Public License |
||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
*/ |
||||
|
|
||||
|
package com.elink.esua.epdc.dto; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 修改过时积分日志 |
||||
|
* |
||||
|
* @author elink elink@elink-cn.com |
||||
|
* @since v1.0.0 2020-04-29 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class PointsLogsBindUnIdDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 用户ID |
||||
|
*/ |
||||
|
private String userId; |
||||
|
|
||||
|
/** |
||||
|
* 新用户 |
||||
|
*/ |
||||
|
private UserDTO user; |
||||
|
|
||||
|
} |
@ -0,0 +1,32 @@ |
|||||
|
package com.elink.esua.epdc.feign; |
||||
|
|
||||
|
import com.elink.esua.epdc.commons.tools.constant.ServiceConstant; |
||||
|
import com.elink.esua.epdc.commons.tools.utils.Result; |
||||
|
import com.elink.esua.epdc.dto.PointsLogsBindUnIdDTO; |
||||
|
import com.elink.esua.epdc.feign.fallback.NewsFeignClientFallback; |
||||
|
import org.springframework.cloud.openfeign.FeignClient; |
||||
|
import org.springframework.http.MediaType; |
||||
|
import org.springframework.web.bind.annotation.PostMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestBody; |
||||
|
|
||||
|
/** |
||||
|
* 积分管理模块 |
||||
|
* |
||||
|
* @author work@yujt.net.cn |
||||
|
* @date 2019/9/18 15:37 |
||||
|
*/ |
||||
|
@FeignClient(name = ServiceConstant.EPDC_POINTS_SERVER, fallback = NewsFeignClientFallback.class) |
||||
|
public interface PointsFeignClient { |
||||
|
|
||||
|
/** |
||||
|
* 更新积分日志 |
||||
|
* |
||||
|
* @param formDto |
||||
|
* @return com.elink.esua.epdc.commons.tools.utils.Result |
||||
|
* @author zhy |
||||
|
* @date 2020/8/12 15:55 |
||||
|
*/ |
||||
|
@PostMapping(value = "points/pointslogs/maBindUnIdLogs", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE) |
||||
|
Result maBindUnIdLogs(@RequestBody PointsLogsBindUnIdDTO formDto); |
||||
|
|
||||
|
} |
@ -0,0 +1,21 @@ |
|||||
|
package com.elink.esua.epdc.feign.fallback; |
||||
|
|
||||
|
import com.elink.esua.epdc.commons.tools.constant.ServiceConstant; |
||||
|
import com.elink.esua.epdc.commons.tools.utils.ModuleUtils; |
||||
|
import com.elink.esua.epdc.commons.tools.utils.Result; |
||||
|
import com.elink.esua.epdc.dto.PointsLogsBindUnIdDTO; |
||||
|
import com.elink.esua.epdc.feign.PointsFeignClient; |
||||
|
import org.springframework.stereotype.Component; |
||||
|
|
||||
|
/** |
||||
|
* @author work@yujt.net.cn |
||||
|
* @date 2019/9/18 15:38 |
||||
|
*/ |
||||
|
@Component |
||||
|
public class PointsFeignClientFallback implements PointsFeignClient { |
||||
|
|
||||
|
@Override |
||||
|
public Result maBindUnIdLogs(PointsLogsBindUnIdDTO formDto) { |
||||
|
return ModuleUtils.feignConError(ServiceConstant.EPDC_POINTS_SERVER, "maBindUnIdLogs", formDto); |
||||
|
} |
||||
|
} |
Loading…
Reference in new issue