package com.yuchen.saas.payment.api.feign;


import com.yuchen.saas.payment.api.util.PayFeignFallbackUtils;
import com.yuchen.saas.payment.api.vo.invoice.SaasInvoiceTaxCategoryVO;
import feign.hystrix.FallbackFactory;
import org.nest.springwrap.core.tool.api.R;
import org.springframework.stereotype.Component;



@Component
public class ISaasInvoiceTaxCategoryFeignFallback implements FallbackFactory<ISaasInvoiceTaxCategoryFeign> {

    @Override
    public ISaasInvoiceTaxCategoryFeign create(Throwable throwable) {

        return new ISaasInvoiceTaxCategoryFeign() {

            @Override
            public R<SaasInvoiceTaxCategoryVO> getTaxCategoryById(Long id) {
                return PayFeignFallbackUtils.printLogAndReturn(throwable);
            }
        };
    }
}