zhanghua
2025-07-16 c4c1c6cf89781eb06dc02b677a8954fdb2666c43
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
package com.ycl.controller;
 
import com.alibaba.druid.util.StringUtils;
import com.ycl.api.CommonResult;
import com.ycl.remote.dto.EventAddParamDto;
import com.ycl.remote.dto.EventProcessParamDto;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;
 
import javax.servlet.http.HttpServletRequest;
import java.util.Map;
 
@Api(tags = "系统管理-测试")
@RestController
//@RequestMapping("/api/unauthorized/external/event")
@RequestMapping("/API/FMDeviceService")
public class TestController {
 
 
    @PostMapping("/Push")
    public String push(@RequestBody Map map) {
        System.out.println("FMDeviceService/Push");
        return "";
    }
 
    @PostMapping("/HeartBeat")
    public String heartBeat(@RequestBody Map map) {
        System.out.println("FMDeviceService/HeartBeat");
 
//        return "{\n" +
//                "\"req\": \"reqid\",\n" +
//                "\"cmd\": \"OpenDoor\"\n" +
//                "}\n";
        return "";
    }
 
 
    @ApiOperation("添加")
    @PostMapping("/add")
    public String add(@RequestBody EventAddParamDto book) {
        return "{\n" +
                "    \"code\": 0,\n" +
                "    \"msg\": \"OK\",\n" +
                "    \"result\": {\n" +
                "        \"taskcode\": \"202034150102280004\"\n" +
                "}\n" +
                "}\n";
    }
 
 
    @ApiOperation("详情")
    @PostMapping("/process")
    public String process(@RequestBody EventProcessParamDto book) {
 
 
        return "{\n" +
                "\t\"msg\": \"OK\",\n" +
                "\t\"code\": 0,\n" +
                "\t\"result\": {\n" +
                "\t\t\"taskcode\": \"202034150102280004\",\n" +
                "\t\t\"statusName\": \"已结案\",\n" +
                "\t\t\"dealTime\": \"2020-05-25 12:15:30\",\n" +
                "\t\t\"dealMsg\": \"已处理\",\n" +
                "\t\t\"hcczImages\": [\n" +
                "\t\t\t\" http:// 183.246.199.93:10000/upload/file/2020/05/20/20200520153430691576.jpg\",\n" +
                "\t\t\t\" http:// 183.246.199.93:10000//upload/file/2020/05/20/20200520153439170369.jpg\",\n" +
                "\t\t\t\" http:// 183.246.199.93:10000//upload/file/2020/05/20/20200520153454125143.jpg\"\n" +
                "\t\t]\n" +
                "\t}\n" +
                "}";
    }
}