Pu Zhibing
2025-01-17 c80c0184b6e560d41d5aa5691874e07b681fa18f
ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/factory/VipFallbackFactory.java
@@ -1,5 +1,6 @@
package com.ruoyi.other.api.factory;
import com.ruoyi.account.api.dto.GiveVipDto;
import com.ruoyi.common.core.domain.R;
import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.other.api.domain.TVip;
@@ -8,6 +9,8 @@
import org.slf4j.LoggerFactory;
import org.springframework.cloud.openfeign.FallbackFactory;
import org.springframework.stereotype.Component;
import java.util.List;
/**
 * 会员服务降级处理
@@ -35,6 +38,16 @@
            }
            @Override
            public R giveVip(GiveVipDto giveVipDto) {
                return R.fail("赠送会员:" + throwable.getMessage());
            }
            @Override
            public R<List<TVip>> getVipList() {
                return R.fail("查询会员集合失败:" + throwable.getMessage());
            }
            @Override
            public R<TVip> getInfo1(Integer id) {
                return R.fail("根据会员id 获取会员信息:" + throwable.getMessage());
            }