package org.springblade.file.feign;

import jakarta.validation.Valid;
import org.springblade.core.tool.api.R;
import org.springblade.file.pojo.dto.*;
import org.springblade.file.pojo.entity.Attachment;
import org.springblade.file.pojo.vo.*;
import org.springblade.thirdparty.ocr.pojo.vo.TransportCertificateVO;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.stereotype.Component;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
 * @author bfhuange
 * @date 2024/10/21
 */
@Component
public class IFileClientFallback implements IFileClient, IFileUploadClient {

    @Override
    public R<List<Attachment>> getAttachment(String id) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<AttachmentDetailVO> getAttachmentDetail(Long id) {
        return R.fail("获取数据失败");
    }

    @Override
    public R saveAndRemoveBusinessAttachment(BusinessAttachmentBatchAddDTO param) {
        return R.fail("获取数据失败");
    }

    @Override
    public R batchSaveAndRemoveBusinessAttachment(List<BusinessAttachmentAddDTO> params, Long bizId) {
        return R.fail("获取数据失败");
    }

    @Override
    public R batchSaveAndRemoveByParamBusinessAttachment(List<@Valid BusinessAttachmentAddDTO> params, @Valid @SpringQueryMap BusinessAttachmentDeleteDTO deleteParam) {
        return R.fail("获取数据失败");
    }

    @Override
    public R batchSaveAndRemoveBusinessAttachment(List<@Valid BusinessAttachmentAddDTO> params) {
        return R.fail("获取数据失败");
    }

    @Override
    public R removeBusinessAttachment(Long bizId) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<List<BusinessAttachmentVO>> getBusinessAttachments(BusinessAttachmentQueryDTO param) {
        return R.fail("获取数据失败");
    }

    @Override
    public R saveBusinessUnzipTask(BusinessUnzipTaskAddDTO param) {
        return R.fail("获取数据失败");
    }

    @Override
    public R updateBusinessUnzipTask(BusinessUnzipTaskUpdateDTO param) {
        return R.fail("获取数据失败");
    }

    @Override
    public R cancelBusinessUnzipTask(Long bizId) {
        return R.fail("获取数据失败");
    }

    @Override
    public R removeBusinessUnzipTask(Long bizId) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<List<BusinessUnzipTaskListVO>> getBusinessUnzipTasksByBizIds(List<Long> bizIds) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<List<BusinessUnzipDetailListVO>> queryBusinessUnzipDetail(Long bizId) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<TransportCertificateVO> recognitionTransportCertificates(@Validated @RequestBody FileCertificateBatchRecognitionDTO param) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<List<FileUrlVO>> getFileUrls(IdsDTO param) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<List<Attachment>> ossUpload(MultipartFile[] files) {
        return R.fail("获取数据失败");
    }

    @Override
    public R<TempFileUrlVO> ossUploadTemp(MultipartFile file, Integer expires) {
        return R.fail("获取数据失败");
    }
}
