package com.buy507.mall.service;

import java.util.List;

import org.springframework.transaction.annotation.Transactional;

import com.buy507.mall.common.api.CommonResult;
import com.buy507.mall.dto.OmsMoneyInfoParam;
import com.buy507.mall.dto.OmsOrderDeliveryParam;
import com.buy507.mall.dto.OmsOrderDetail;
import com.buy507.mall.dto.OmsOrderQueryParam;
import com.buy507.mall.dto.OmsOrderResult;
import com.buy507.mall.dto.OmsReceiverInfoParam;

/**
 * 订单管理Service
 */
public interface OmsOrderService {
    /**
     * 订单查询
     */
    List<OmsOrderResult> list(OmsOrderQueryParam queryParam, Integer pageSize, Integer pageNum);

    /**
     * 批量发货
     */
    @Transactional
    int delivery(List<OmsOrderDeliveryParam> deliveryParamList);

    /**
     * 批量关闭订单
     */
    int close(List<Long> ids, String note);

    /**
     * 批量删除订单
     */
    int delete(List<Long> ids);

    /**
     * 获取指定订单详情
     */
    OmsOrderDetail detail(Long id);

    /**
     * 修改订单收货人信息
     */
    @Transactional
    int updateReceiverInfo(OmsReceiverInfoParam receiverInfoParam);

    /**
     * 修改订单费用信息
     */
    @Transactional
    int updateMoneyInfo(OmsMoneyInfoParam moneyInfoParam);

    /**
     * 修改订单备注
     */
    @Transactional
    int updateNote(Long id, String note, Integer status);
    
    /**
     * 线下支付确认
     */
    @Transactional
    CommonResult paymentConfirm(Long id);
    
    CommonResult getLogistics(Long id);
    
    @Transactional
    CommonResult confirmReceiving(Long id, boolean confirmFlag);
    
    /*
    @Transactional
    CommonResult returnGoods(Long id);
    */
    
}
