TaskFeignClient.java
1.32 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
package com.viontech.fanxing.commons.feign;
import com.alibaba.fastjson.JSONObject;
import com.viontech.fanxing.commons.model.Task;
import com.viontech.fanxing.commons.model.main.VaServerInfo;
import com.viontech.fanxing.commons.vo.TaskVo;
import com.viontech.keliu.util.JsonMessageUtil;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
* .
*
* @author 谢明辉
* @date 2021/7/16
*/
@FeignClient(value = "fanxing-task")
@Service
public interface TaskFeignClient {
/**
* 获取所有任务
*/
@GetMapping("/tasks")
JsonMessageUtil.JsonMessage<List<Task>> getAllTask();
/**
* 通过通道号获取任务
*/
@GetMapping("/tasks")
JsonMessageUtil.JsonMessage<List<Task>> getTaskByChannelUnid(@RequestParam("channelUnid") String channelUnid);
/**
* 更新任务
*/
@PostMapping("/tasks/{id}")
JsonMessageUtil.JsonMessage updateById(@PathVariable("id") Long id, @RequestBody TaskVo taskVo);
/**
* 获取全部的VaServer信息
*/
@GetMapping("/vaServerInfo")
JsonMessageUtil.JsonMessage<List<VaServerInfo>> vaServerInfo();
@GetMapping("/status")
JSONObject getVaServerStatusByDevId(@RequestParam String devId);
}