package com.neusoft.smart.pos.gateway.service.feignService;

import com.alibaba.fastjson.JSONObject;
import com.neusoft.smart.pos.dto.advertisement.response.MediaStrategyResponse;
import com.neusoft.smart.pos.framework.dto.ResponseData;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(value = "service-advertisement")
public interface RemoteAdvertisementService {
	
	@GetMapping("/mediaResourceStrategy/relation/{groupId}")
	ResponseData<List<MediaStrategyResponse>> getRelation(@PathVariable("groupId") Integer groupId);
	
	@PutMapping("/mediaResourceStrategy/cancel/{groupId}")
	ResponseData<?> cancel(@PathVariable("groupId") Integer groupId);
	
	@GetMapping("/OTA/Ad/query")
    JSONObject queryAd(@RequestParam("sn") String sn);
}
