package com.yuchen.saas.consumer.api.feign;

import org.nest.springwrap.core.launch.app.AppNameConstant;
import org.nest.springwrap.core.tool.api.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.time.LocalDateTime;


/**
 * @author: 李涛
 * @date 2021/12/20 16:42
 * @description: 开票订单接口
 */
@FeignClient(
        value = AppNameConstant.SAAS_CONSUMER,
        fallback = InvoiceOrderClientFallback.class
)
public interface InvoiceOrderClient {

    /**
     * 查询发票订单分页数据
     * @param current size customerName
     * @return
     */
    @GetMapping("/invoice/getInvoiceOrderPage")
    R getInvoiceOrderPage(@RequestParam Integer current,
                          @RequestParam Integer size,
                          @RequestParam(required = false) LocalDateTime startTime,
                          @RequestParam(required = false) LocalDateTime endTime,
                          @RequestParam(required = false) String customerName,
                          @RequestParam Long parkId);

    /**
     * 查询发票订单分页数据
     * @param orderNo
     * @return
     */
    @GetMapping("/invoice/getInvoiceOrderItemList")
    R getInvoiceOrderItemList(@RequestParam String orderNo);

}
