package com.liquidnet.service.kylin.service.admin;

import com.github.pagehelper.PageInfo;
import com.liquidnet.service.kylin.dto.param.OrderRefundReasonParam;
import com.liquidnet.service.kylin.dto.param.OrderRefundReasonSearchParam;
import com.liquidnet.service.kylin.dto.vo.OrderRefundReasonVo;
import com.liquidnet.service.kylin.entity.KylinOrderRefundReasons;

import java.util.List;

/**
 * 退款原因配置管理
 */
public interface IOrderRefundReasonAdminService {

    Boolean create(OrderRefundReasonParam param);

    Boolean update(OrderRefundReasonParam param);

    OrderRefundReasonVo detail(String reasonId);

    Boolean delete(List<String> reasonIds);

    PageInfo<KylinOrderRefundReasons> reasonList(OrderRefundReasonSearchParam param);

    /**
     * 应用 / 取消应用
     *
     * @param reasonId  原因ID
     * @param isApplied 1应用 0取消应用
     */
    Boolean apply(String reasonId, Integer isApplied);

    /**
     * 已应用列表（读缓存）
     */
    List<OrderRefundReasonVo> listApplied();
}
