package cn.pluss.platform.device;

import cn.pluss.platform.dto.MercOrderNewDTO;
import cn.pluss.platform.entity.MercOrderNew;
import cn.pluss.platform.vo.MercOrderExpressVO;
import cn.pluss.platform.vo.MercOrderNewVO;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.Date;

/**
 * <p>
 * 新的订单表 服务类
 * </p>
 *
 * @author Djh
 * @since 2022-03-17
 */
public interface MercOrderNewService extends IService<MercOrderNew> {

    /**
     * 设备订单分页查询
     * @param page
     * @param condition
     * @return
     */
    Page<MercOrderNewVO> pageInfo(Page<MercOrderNewVO> page, MercOrderNewVO condition);

    /**
     * 确认收货
     * @param id
     */
    void receiving(Long id);

    /**
     * 获取订单物流信息
     * @param id
     * @return
     */
    MercOrderExpressVO getOrderExpressInfo(Long id);

    Object apiCreateOrder(MercOrderNewDTO orderNewDTO);

    Object createOrder(MercOrderNewDTO orderNewDTO);

    /**
     * 获取订单邮费信息
     * @param orderNewDTO
     * @return
     */
    Object getOrderPostageInfo(MercOrderNewDTO orderNewDTO);

    MercOrderNew getOrderByNo(String orderNumber);

    /**
     * 设备订单支付回调
     * @param newOrder
     */
    void proPayCallback(MercOrderNew newOrder, Date transDt,String transNo,String thirdTransNo);

    /**
     * 设备回调V2
     * @param orderNo
     * @param tradeNo
     * @param thridTradeNo
     * @param transDt
     */
    void devicePaySuccessNotifyV2(String orderNo, String tradeNo, String thridTradeNo, Date transDt,MercOrderNew newOrder);

    /**
     * 查询订单支付状态
     * @param orderNewDTO
     * @return
     */
    Object getOrderStatusInfo(MercOrderNewDTO orderNewDTO);
}
