package cn.axzo.msg.center.service.group.client.fallback;

import cn.axzo.msg.center.service.group.client.MessageTemplateGroupRelationClient;
import cn.axzo.msg.center.service.group.request.MessageTemplateGroupRelationMoveRequest;
import cn.axzo.msg.center.service.group.request.MessageTemplateGroupRelationPageRequest;
import cn.axzo.msg.center.service.group.request.MessageTemplateGroupRelationRemoveRequest;
import cn.axzo.msg.center.service.group.response.MessageTemplateGroupRelationResponse;
import cn.azxo.framework.common.model.CommonResponse;
import cn.azxo.framework.common.model.Page;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @author cold_blade
 * @date 2023/10/12
 * @version 1.0
 */
@Slf4j
@Component
public class MessageTemplateGroupRelationClientFallback implements MessageTemplateGroupRelationClient {

    @Override
    public CommonResponse<Page<MessageTemplateGroupRelationResponse>> page(
            MessageTemplateGroupRelationPageRequest request) {
        log.error("fall back while page querying message template group relation. request:{}", request);
        return CommonResponse.error("fall back while page querying message template group relation");
    }

    @Override
    public CommonResponse<Void> move(MessageTemplateGroupRelationMoveRequest request) {
        log.error("fall back while moving message template group relation. request:{}", request);
        return CommonResponse.error("fall back while moving message template group relation");
    }

    @Override
    public CommonResponse<Void> remove(MessageTemplateGroupRelationRemoveRequest request) {
        log.error("fall back while removing message template group relation. request:{}", request);
        return CommonResponse.error("fall back while removing message template group relation");
    }
}
