shiyj1101
2021-08-05 e57e32fc43da31917912eebb4e47d4e50df1a9e9
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
package com.java110.community.api;
 
import com.alibaba.fastjson.JSONObject;
import com.java110.community.bmo.car.IQueryCar;
import com.java110.utils.util.Assert;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
 
@RestController
@RequestMapping(value = "/car")
public class CarApi {
 
    @Autowired
    private IQueryCar queryCarImpl;
 
    @RequestMapping(value = "/carInfo", method = RequestMethod.POST)
    public ResponseEntity<String> carInfo(@RequestBody JSONObject reqJson) {
 
        Assert.hasKeyAndValue(reqJson, "code", "未包含小区ID");
        return queryCarImpl.queryCarInfo(reqJson);
    }
}