package com.crm.manager.service.ucard;

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.ucard.CardPermissionDto;
import com.crm.rely.backend.core.entity.ucard.CardPermissionAddEntity;
import com.crm.rely.backend.core.entity.ucard.CardPermissionDeleteEntity;
import com.crm.rely.backend.core.entity.ucard.CardPermissionPageEntity;
import com.crm.rely.backend.core.entity.ucard.CardPermissionUpdateEntity;
import com.crm.rely.backend.exception.ServiceException;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;

@FeignClient(name = "UCARD-SERVICE", path = "/ucard/permission/manager")
public interface UcardPermissionFeignService {

    /**
     * 卡权限分页列表
     */
    @PostMapping("/page")
    ResultWithPagerDto<CardPermissionDto> queryPermissionPageList(CardPermissionPageEntity entity) throws ServiceException;

    /**
     * 新增卡权限
     */
    @PostMapping("/add")
    BaseResultDto permissionAdd(CardPermissionAddEntity entity) throws ServiceException;

    /**
     * 更新卡权限
     */
    @PostMapping("/update")
    BaseResultDto permissionUpdate(CardPermissionUpdateEntity entity) throws ServiceException;

    /**
     * 删除卡权限
     */
    @PostMapping("/delete")
    BaseResultDto permissionDelete(CardPermissionDeleteEntity entity) throws ServiceException;


}
