48 changed files with 418 additions and 149 deletions
@ -1,9 +1,9 @@ |
|||
package com.epmet.dto.feign; |
|||
package com.epmet.feign; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.dto.feign.fallback.GovAccessFeignClientFallBack; |
|||
import com.epmet.dto.form.InitDefaultOperationsFormDTO; |
|||
import com.epmet.feign.fallback.GovAccessFeignClientFallBack; |
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
import org.springframework.web.bind.annotation.PostMapping; |
|||
import org.springframework.web.bind.annotation.RequestBody; |
@ -1,10 +1,10 @@ |
|||
package com.epmet.dto.feign.fallback; |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.ModuleUtils; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.dto.feign.GovAccessFeignClient; |
|||
import com.epmet.dto.form.InitDefaultOperationsFormDTO; |
|||
import com.epmet.feign.GovAccessFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
@ -0,0 +1,16 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.feign.fallback.GovIssueOpenFeignClientFallBack; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:37 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.GOV_ISSUE_SERVER, fallback = GovIssueOpenFeignClientFallBack.class) |
|||
public interface GovIssueOpenFeignClient { |
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.feign.GovIssueOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:43 |
|||
*/ |
|||
@Component |
|||
public class GovIssueOpenFeignClientFallBack implements GovIssueOpenFeignClient { |
|||
} |
@ -1,34 +0,0 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.dto.CustomerAgencyDTO; |
|||
import com.epmet.dto.form.LatestGridFormDTO; |
|||
import com.epmet.dto.form.StaffInfoFromDTO; |
|||
import com.epmet.dto.result.CustomerGridByUserIdResultDTO; |
|||
import com.epmet.dto.result.LatestCustomerResultDTO; |
|||
import com.epmet.dto.result.MineResultDTO; |
|||
import com.epmet.feign.fallback.GovOrgFeignClientFallBack; |
|||
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.RequestBody; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @Description url = "localhost:8092" |
|||
* @Author sun |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallback = GovOrgFeignClientFallBack.class) |
|||
public interface GovOrgFeignClient { |
|||
|
|||
/** |
|||
* 根据staffId查询所属的组织机构 |
|||
* @param staffId |
|||
* @return |
|||
*/ |
|||
@PostMapping("/gov/org/agency/agencybystaff/{staffId}") |
|||
Result<CustomerAgencyDTO> getAgencyByStaff(@PathVariable("staffId") String staffId); |
|||
} |
@ -1,23 +1,40 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.dto.CustomerAgencyDTO; |
|||
import com.epmet.feign.callback.GovOrgOpenFeignClientFallback; |
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
import org.springframework.web.bind.annotation.PathVariable; |
|||
import org.springframework.web.bind.annotation.PostMapping; |
|||
|
|||
//@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallback = GovOrgOpenFeignClientFallback.class, url = "localhost:8092")
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.dto.CustomerAgencyDTO; |
|||
import com.epmet.feign.fallback.GovOrgOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:37 |
|||
*/ |
|||
// @FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallback = GovOrgOpenFeignClientFallback.class, url =
|
|||
// "localhost:8092")
|
|||
@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallback = GovOrgOpenFeignClientFallback.class) |
|||
public interface GovOrgOpenFeignClient { |
|||
|
|||
/** |
|||
* 根据Id查询agency |
|||
* |
|||
* @param agencyId |
|||
* @return |
|||
*/ |
|||
@PostMapping("/gov/org/agency/agencybyid/{agencyId}") |
|||
Result<CustomerAgencyDTO> getAgencyById(@PathVariable("agencyId") String agencyId); |
|||
|
|||
/** |
|||
* 根据staffId查询所属的组织机构 |
|||
* |
|||
* @param staffId |
|||
* @return |
|||
*/ |
|||
@PostMapping("/gov/org/agency/agencybystaff/{staffId}") |
|||
Result<CustomerAgencyDTO> getAgencyByStaff(@PathVariable("staffId") String staffId); |
|||
} |
|||
|
@ -1,27 +0,0 @@ |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.ModuleUtils; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.dto.CustomerAgencyDTO; |
|||
import com.epmet.dto.form.LatestGridFormDTO; |
|||
import com.epmet.dto.form.StaffInfoFromDTO; |
|||
import com.epmet.dto.result.CustomerGridByUserIdResultDTO; |
|||
import com.epmet.dto.result.LatestCustomerResultDTO; |
|||
import com.epmet.dto.result.MineResultDTO; |
|||
import com.epmet.feign.GovOrgFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @Description |
|||
* @Author sun |
|||
*/ |
|||
@Component |
|||
public class GovOrgFeignClientFallBack implements GovOrgFeignClient { |
|||
@Override |
|||
public Result<CustomerAgencyDTO> getAgencyByStaff(String staffId) { |
|||
return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "getAgencyByStaff", staffId); |
|||
} |
|||
} |
@ -0,0 +1,16 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.feign.fallback.GovProjectOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:32 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.GOV_PROJECT_SERVER, fallback = GovProjectOpenFeignClientFallback.class) |
|||
public interface GovProjectOpenFeignClient { |
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.feign.GovProjectOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:33 |
|||
*/ |
|||
@Component |
|||
public class GovProjectOpenFeignClientFallback implements GovProjectOpenFeignClient { |
|||
} |
@ -0,0 +1,18 @@ |
|||
package com.epmet.feign; |
|||
|
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.dto.feign.fallback.GovVoiceFeignClientFallBack; |
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 16:01 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.GOV_VOICE_SERVER, fallback = GovVoiceFeignClientFallBack.class) |
|||
public interface GovVoiceOpenFeignClient { |
|||
|
|||
|
|||
} |
@ -0,0 +1,13 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 16:01 |
|||
*/ |
|||
@Component |
|||
public class GovVoiceOpenFeignClientFallback implements GovVoiceOpenFeignClient{ |
|||
} |
@ -1,19 +1,20 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.feign.fallback.OperAccessFeignClientFallback; |
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
import org.springframework.web.bind.annotation.GetMapping; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.feign.fallback.OperAccessOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* @Description 运营端权限模块 |
|||
* @Author yinzuomei |
|||
* @Date 2020/5/21 15:17 |
|||
* @Date 2020/5/21 15:17 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
*/ |
|||
//, url = "http://localhost:8093"
|
|||
@FeignClient(name = ServiceConstant.OPER_ACCESS_SERVER, fallback = OperAccessFeignClientFallback.class) |
|||
public interface OperAccessFeignClient { |
|||
// , url = "http://localhost:8093"
|
|||
@FeignClient(name = ServiceConstant.OPER_ACCESS_SERVER, fallback = OperAccessOpenFeignClientFallback.class) |
|||
public interface OperAccessOpenFeignClient { |
|||
/** |
|||
* @param |
|||
* @return com.epmet.commons.tools.utils.Result |
@ -0,0 +1,16 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.feign.fallback.OperCrmOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:25 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.OPER_CRM_SERVER, fallback = OperCrmOpenFeignClientFallback.class) |
|||
public interface OperCrmOpenFeignClient { |
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.feign.OperCrmOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:26 |
|||
*/ |
|||
@Component |
|||
public class OperCrmOpenFeignClientFallback implements OperCrmOpenFeignClient { |
|||
} |
@ -0,0 +1,17 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.feign.fallback.OperCustomizeOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:16 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.OPER_CUSTOMIZE_SERVER, fallback = OperCustomizeOpenFeignClientFallback.class) |
|||
public interface OperCustomizeOpenFeignClient { |
|||
|
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.feign.OperCustomizeOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:23 |
|||
*/ |
|||
@Component |
|||
public class OperCustomizeOpenFeignClientFallback implements OperCustomizeOpenFeignClient { |
|||
} |
@ -0,0 +1,16 @@ |
|||
package com.epmet.resi.group.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.resi.group.feign.fallback.ResiGroupOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:16 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.RESI_GROUP_SERVER, fallback = ResiGroupOpenFeignClientFallback.class) |
|||
public interface ResiGroupOpenFeignClient { |
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.resi.group.feign.fallback; |
|||
|
|||
import com.epmet.resi.group.feign.ResiGroupOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:17 |
|||
*/ |
|||
@Component |
|||
public class ResiGroupOpenFeignClientFallback implements ResiGroupOpenFeignClient { |
|||
} |
@ -0,0 +1,16 @@ |
|||
package com.epmet.resi.partymember.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.resi.partymember.feign.fallback.ResiPartyMemberOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:12 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.RESI_PARTYMEMBER_SERVER, fallback = ResiPartyMemberOpenFeignClientFallback.class) |
|||
public interface ResiPartyMemberOpenFeignClient { |
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.resi.partymember.feign.fallback; |
|||
|
|||
import com.epmet.resi.partymember.feign.ResiPartyMemberOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:14 |
|||
*/ |
|||
@Component |
|||
public class ResiPartyMemberOpenFeignClientFallback implements ResiPartyMemberOpenFeignClient { |
|||
} |
@ -0,0 +1,16 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.feign.fallback.ResiVoiceOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:01 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.RESI_VOICE_SERVER, fallback = ResiVoiceOpenFeignClientFallback.class) |
|||
public interface ResiVoiceOpenFeignClient { |
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.feign.ResiVoiceOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:05 |
|||
*/ |
|||
@Component |
|||
public class ResiVoiceOpenFeignClientFallback implements ResiVoiceOpenFeignClient { |
|||
} |
@ -0,0 +1,16 @@ |
|||
package com.epmet.feign; |
|||
|
|||
import org.springframework.cloud.openfeign.FeignClient; |
|||
|
|||
import com.epmet.commons.tools.constant.ServiceConstant; |
|||
import com.epmet.feign.fallback.EpmetUserOpenFeignClientFallback; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:09 |
|||
*/ |
|||
@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallback = EpmetUserOpenFeignClientFallback.class) |
|||
public interface EpmetUserOpenFeignClient { |
|||
} |
@ -0,0 +1,14 @@ |
|||
package com.epmet.feign.fallback; |
|||
|
|||
import com.epmet.feign.EpmetUserOpenFeignClient; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 本服务对外开放的API,其他服务通过引用此client调用该服务 |
|||
* |
|||
* @author yinzuomei@elink-cn.com |
|||
* @date 2020/6/4 13:10 |
|||
*/ |
|||
@Component |
|||
public class EpmetUserOpenFeignClientFallback implements EpmetUserOpenFeignClient { |
|||
} |
Loading…
Reference in new issue