package com.crm.manager.service;

import com.crm.rely.backend.core.dto.base.BaseResultDto;
import com.crm.rely.backend.core.dto.base.ResultWithPagerDto;
import com.crm.rely.backend.core.entity.base.SingleLongEntity;
import com.crm.rely.backend.model.dto.finance.withdraw.FinanceWithdrawDto;
import com.crm.rely.backend.model.entity.finance.withdraw.*;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

@FeignClient(name = "GOLDEN-PAY-SERVICE", path = "/withdraw/manager")
public interface FinanceWithdrawFeignService {


    @PostMapping("/approve")
    BaseResultDto approve(@RequestBody @Validated FinanceWithdrawApproveEntity entity) throws Exception;

    @PostMapping("/sales/approve")
    BaseResultDto approveBySales(@RequestBody @Validated FinanceWithdrawApproveSalesEntity entity) throws Exception;

    @PostMapping("/approve/manager")
    BaseResultDto approveByManager(@RequestBody @Validated FinanceWithdrawApproveManagerEntity entity) throws Exception;

    @PostMapping("/approve/backstage")
    BaseResultDto approveByBackstage(@RequestBody @Validated FinanceWithdrawApproveBackstageEntity entity) throws Exception;

    @PostMapping("/approve/info")
    BaseResultDto approveByInfo(@RequestBody @Validated FinanceWithdrawApproveInfoEntity entity) throws Exception;

    @PostMapping("/approve/infos")
    BaseResultDto approveByInfos(@RequestBody @Validated FinanceWithdrawApproveInfosEntity entity) throws Exception;

    @PostMapping("/approve/submit/channel")
    BaseResultDto approveBySubmit(@RequestBody @Validated FinanceWithdrawApproveChannelSubmitEntity entity) throws Exception;

    @PostMapping("/approve/channel")
    BaseResultDto approveByChannel(@RequestBody @Validated FinanceWithdrawApproveChannelEntity entity) throws Exception;


    @PostMapping("/approve/submits/channel")
    BaseResultDto approveBySubmits(@RequestBody @Validated FinanceWithdrawApproveChannelSubmitsEntity entity) throws Exception;

    @PostMapping("/approve/channels")
    BaseResultDto approveByChannels(@RequestBody @Validated FinanceWithdrawApproveChannelsEntity entity) throws Exception;

    @PostMapping("/delete")
    BaseResultDto delete(@RequestBody @Validated FinanceWithdrawDeleteEntity entity) throws Exception;

    @PostMapping("/searcher/list")
    ResultWithPagerDto<FinanceWithdrawDto> searcherList(@RequestBody @Validated FinanceWithdrawSearchListEntity entity) throws Exception;

    @PostMapping("/searcher/list/export")
    BaseResultDto<List<FinanceWithdrawDto>> searcherListExport(FinanceWithdrawSearchListEntity entity) throws Exception;

    @PostMapping("/export/ids")
    BaseResultDto<List<FinanceWithdrawDto>> searcherByIdsExport(FinanceWithdrawSearchByIdsEntity entity) throws Exception;

    @PostMapping("/searcher/single")
    BaseResultDto<FinanceWithdrawDto> searcherSingle(@RequestBody @Validated SingleLongEntity entity) throws Exception;

    @PostMapping(value = "/remit/channel")
    BaseResultDto remitChannel();

}
