package com.diagbot.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.diagbot.dto.OrderDetialsDTO;
import com.diagbot.entity.OrderDetailStatus;
import com.diagbot.entity.OrderDetails;
import com.diagbot.entity.OrderDetailsIndex;
import com.diagbot.entity.wrapper.OrderDetailsWapper;

import java.util.List;

/**
 * <p>
 * 订单明细表 服务类
 * </p>
 *
 * @author gaodm
 * @since 2018-09-18
 */
public interface OrderDetailsService extends IService<OrderDetails> {
    /**
     * @Description: 查询所有待审核产品
     * @Author: wangyu
     * @Date: 15:06 2018/9/21
     */
    public List<OrderDetialsDTO> seleAllOrderDetials(OrderDetailsIndex orderDetailsIndex);

    /**
     * 根据订单编号查询所有订单明细审核状态
     * 
     * @param  orderNum
     * @return
     */
    public OrderDetailStatus selectAllOrderDetialsByOrderNum(String orderNum );

    /**
     * 添加订单明细
     * @param list
     * @return Boolean
     */
    public Boolean saveOrderDetails(List<OrderDetails> list);

    /**
     * 根据用户id查询是否有在认证中的产品
     * @param userId
     * @return
     */
    public List<Long> getOrderDetailsByUser(Long userId);
    
    public int  getOrderByUserToAudit(OrderDetailsWapper orderDetails);
}
