DirectiveController.java
2.08 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
package com.bsth.vehicle.directive.controller;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import com.bsth.vehicle.directive.service.DirectiveService;
/**
*
* @ClassName: DirectiveController
* @Description: TODO(页面下发调度指令) .0
* @author PanZhao
* @date 2016年6月8日 上午9:34:51
*
*/
@RestController
@RequestMapping("/directive")
public class DirectiveController {
@Autowired
DirectiveService directiveService;
/**
*
* @Title: send60
* @Description: TODO(60协议短语下发)
* @throws
*/
@RequestMapping(value = "/phrase", method = RequestMethod.POST)
public int send60Phrase(@RequestParam String nbbm, @RequestParam String text){
return directiveService.send60Phrase(nbbm, text);
}
/**
*
* @Title: send60Dispatch
* @Description: TODO(班次信息下发)
* @param @param id
* @throws
*/
@RequestMapping(value = "/dispatch", method = RequestMethod.POST)
public int send60Dispatch(@RequestParam Long id){
return directiveService.send60Dispatch(id);
}
/**
*
* @Title: lineChange
* @Description: TODO(切换线路)
* @param @param nbbm 车辆内部编码
* @param @param lineId 新线路编码
* @throws
*/
@RequestMapping(value = "/lineChnage", method = RequestMethod.POST)
public int lineChange(@RequestParam String nbbm, @RequestParam Integer lineId){
return directiveService.lineChange(nbbm, lineId);
}
/**
*
* @Title: upDownChange
* @Description: TODO(上下行切换)
* @param @param nbbm 车辆内部编码
* @param @param upDon
* @throws
*/
@RequestMapping(value = "/upDownChange", method = RequestMethod.POST)
public int upDownChange(@RequestParam String nbbm, @RequestParam Integer upDown){
return directiveService.upDownChange(nbbm, upDown);
}
}