package com.yuchen.saas.parking.charge.api.feign;

import com.yuchen.saas.parking.charge.api.vo.charge.OccupyBlacklistLedVO;
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;

@FeignClient(
        value = AppNameConstant.SAAS_PARKING_CHARGE,
        fallback = SpcOccupyBlacklistFeignClientFallback.class
)
public interface SpcOccupyBlacklistFeignClient {

    String ROOT_PATH = "/occupy/blacklist";
    String GET_ONE_BY_PARKING_ID_AND_PLATE_NO = "/getOneByParkingIdAndPlateNo";


    /**
     * 根据停车场和车牌获取黑名单信息
     * @param parkingId 停车场id
     * @param plateNo  车牌号
     * @return
     */
    @GetMapping(ROOT_PATH + GET_ONE_BY_PARKING_ID_AND_PLATE_NO)
    R<OccupyBlacklistLedVO> getOneByParkingIdAndPlateNo(@RequestParam("parkingId")Long parkingId, @RequestParam("plateNo") String plateNo) ;

}
