package com.crm.manager.service.activity;

import com.crm.rely.backend.core.dto.base.BaseResultDto;
import com.crm.rely.backend.core.dto.base.ResultWithPagerDto;
import com.crm.rely.backend.core.dto.custom.activity.hundred.CustomActivityHundredDto;
import com.crm.rely.backend.core.entity.base.SingleLongEntity;
import com.crm.rely.backend.core.entity.custom.activity.hundred.CustomActivityHundredApproveEntity;
import com.crm.rely.backend.core.entity.custom.activity.hundred.CustomActivityHundredDeleteEntity;
import com.crm.rely.backend.core.entity.custom.activity.hundred.CustomActivityHundredSearchEntity;
import com.crm.rely.backend.core.entity.custom.activity.hundred.comment.CustomActivityHundredCommentAddEntity;
import com.crm.rely.backend.core.entity.custom.activity.hundred.comment.CustomActivityHundredCommentSearchEntity;
import com.crm.rely.backend.exception.ServiceException;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;

import java.util.List;

/**
 * @author: houn
 */
@FeignClient(name = "ACTIVITY-SERVICE", path = "/custom/activity/hundred/manager")
public interface CustomActivityHundredFeignService {

    /**
     * 销售审核
     *
     * @param entity
     * @return
     * @throws Exception
     */
    @PostMapping("/sales/approve")
    BaseResultDto salesApprove(CustomActivityHundredApproveEntity entity) throws
            Exception;

    @PostMapping("/transform/approve")
    BaseResultDto transformApprove(CustomActivityHundredApproveEntity entity) throws
            Exception;

    @PostMapping("/delete")
    BaseResultDto delete(CustomActivityHundredDeleteEntity entity) throws Exception;


    @PostMapping("/search/list")
    ResultWithPagerDto<CustomActivityHundredDto> searcherList(
            CustomActivityHundredSearchEntity entity) throws Exception;

    @PostMapping("/search/single")
    BaseResultDto searcherSingle(SingleLongEntity entity) throws Exception;

    /**
     * 添加备注
     *
     * @param entity
     * @return
     * @throws ServiceException
     */
    @PostMapping("/comment")
    BaseResultDto addComment(CustomActivityHundredCommentAddEntity entity) throws
            ServiceException;

    /**
     * 查看备注
     *
     * @param entity
     * @return
     * @throws ServiceException
     */
    @PostMapping("/search/list/comment")
    BaseResultDto searchComment(CustomActivityHundredCommentSearchEntity entity)
            throws ServiceException;

    @PostMapping("/export")
    BaseResultDto<List<CustomActivityHundredDto>> export(CustomActivityHundredSearchEntity entity) throws Exception;
}
