| | |
| | | import com.fgkj.services.User_logService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | |
| | | @Resource |
| | | private User_logService uservice; |
| | | |
| | | |
| | | |
| | | //9.1录入机房信息 |
| | | @PostMapping("/") |
| | | @ApiOperation(notes = "",value="录入机房信息") |
| | | @ApiOperation(notes = "{ \"stationId\": \"1\", \"stationName\": \"s\", \"stationName3\": \"61850机房-2G\", \"address\": \" \", \"longitude\": 0.0, \"latitude\": 0.0, \"information\": \"f\", \"fBSDeviceId\": 0, \"stationName1\": \"湖北省\", \"stationName2\": \"武汉市\", \"stationName5\": \"东西湖区\" }",value="录入机房信息") |
| | | public ServiceModel add(@RequestBody BattMap_information binfo){ |
| | | // BattMap_information binfo = getGson().fromJson(json, BattMap_information.class); |
| | | ServiceModel model = service.add(binfo); |
| | |
| | | |
| | | return model; |
| | | } |
| | | |
| | | |
| | | //9.1录入机房信息 |
| | | @PostMapping("dev") |
| | | @ApiOperation(notes = "",value="录入机房信息") |
| | | @ApiOperation(notes = "{ \"stationId\": \"1\", \"stationName\": \"s\", \"stationName3\": \"61850机房-2G\", \"address\": \" \", \"longitude\": 0.0, \"latitude\": 0.0, \"information\": \"f\", \"fBSDeviceId\": 0, \"stationName1\": \"湖北省\", \"stationName2\": \"武汉市\", \"stationName5\": \"东西湖区\" }",value="录入机房信息") |
| | | public ServiceModel addDev(@RequestBody BattMap_information binfo){ |
| | | // BattMap_information binfo = getGson().fromJson(json, BattMap_information.class); |
| | | ServiceModel model = service.addDev(binfo); |
| | | |
| | | return model; |
| | | } |
| | | |
| | | @PutMapping("/") |
| | | @ApiOperation(notes = "",value="修改") |
| | | @ApiOperation(notes = "{ \"num\": \"38\", \"stationId\": \"111\", \"stationName\": \"s\", \"stationName3\": \"61850机房-2G\", \"address\": \" \", \"longitude\": 0.0, \"latitude\": 0.0, \"information\": \"f\", \"fBSDeviceId\": 0, \"stationName1\": \"湖北省\", \"stationName2\": \"武汉市\", \"stationName5\": \"东西湖区\" }",value="修改") |
| | | public ServiceModel update(@RequestBody BattMap_information binfo){ |
| | | // BattMap_information binfo = getGson().fromJson(json, BattMap_information.class); |
| | | ServiceModel model = service.update(binfo); |
| | |
| | | //删除机房的位置信息 |
| | | @DeleteMapping("/") |
| | | @ApiOperation(notes = "",value="删除机房的位置信息") |
| | | public ServiceModel del(@RequestBody BattMap_information binfo){ |
| | | // BattMap_information binfo = getGson().fromJson(json, BattMap_information.class); |
| | | public ServiceModel del(@RequestParam String stationName3,@RequestParam Double longitude,@RequestParam Double latitude){ |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationName(stationName3); |
| | | binfo.setLongitude(longitude); |
| | | binfo.setLatitude(latitude); |
| | | ServiceModel model = service.del(binfo); |
| | | { |
| | | String msg="删除"+binfo.getStationName()+"的位置"; |
| | |
| | | return list; |
| | | } |
| | | //9.1地图上根据维护区查询机房经纬度 |
| | | @GetMapping("byInfo") |
| | | @PostMapping("byInfo") |
| | | @ApiOperation(notes = "",value="地图上根据维护区查询机房经纬度") |
| | | public ServiceModel serchByInfo(@RequestBody BattMap_information binfo){ |
| | | // BattMap_information binfo = getGson().fromJson(json, BattMap_information.class); |
| | | public ServiceModel serchByInfo(@RequestParam String stationId) { |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationId(stationId); |
| | | ServiceModel model = service.serchByInfo(binfo); |
| | | |
| | | return model; |
| | |
| | | //9.1百度地图定位根据省份查询所有该区域的机房 |
| | | @GetMapping("byCondition") |
| | | @ApiOperation(notes = "",value="百度地图定位根据省份查询所有该区域的机房") |
| | | public List serchByCondition(@RequestBody BattMap_information binfo){ |
| | | // BattMap_information binfo = getGson().fromJson(json, BattMap_information.class); |
| | | public List serchByCondition(@RequestParam String address) { |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationId(address); |
| | | List list = service.serchByCondition(binfo); |
| | | return list; |
| | | } |
| | | |
| | | //9.1机房详情显示机房具体落后和告警的信息(机房信息内容画图) |
| | | @GetMapping("monNum") |
| | | @PostMapping("monNum") |
| | | @ApiOperation(notes = "",value="机房详情显示机房具体落后和告警的信息(机房信息内容画图)") |
| | | public List serchMonNum(@RequestBody BattMap_information binfo){ |
| | | // BattMap_information binfo = getGson().fromJson(json, BattMap_information.class); |
| | | public List serchMonNum(@RequestParam String stationId) { |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationId(stationId); |
| | | List list = service.serchMonNum(binfo); |
| | | return list; |
| | | } |
| | |
| | | } |
| | | |
| | | //9.1电池寿命管理 |
| | | @GetMapping("byStationId") |
| | | @PostMapping("byStationId") |
| | | @ApiOperation(notes = "",value="电池寿命管理") |
| | | public ServiceModel serchByStationid(@RequestBody BattMap_information bmap){ |
| | | // BattMap_information bmap = getGson().fromJson(json, BattMap_information.class); |
| | | ServiceModel model = service.serchByStationid(bmap); |
| | | public ServiceModel serchByStationid(@RequestParam String stationId) { |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationId(stationId); |
| | | ServiceModel model = service.serchByStationid(binfo); |
| | | |
| | | return model; |
| | | } |
| | |
| | | } |
| | | |
| | | //9.1根据省份查询机房所在的所有城市 |
| | | @GetMapping("stationName2") |
| | | @ApiOperation(notes = "",value="根据省份查询机房所在的所有城市") |
| | | public ServiceModel serchStationName2(@RequestBody BattMap_information bmap){ |
| | | // BattMap_information bmap = getGson().fromJson(json, BattMap_information.class); |
| | | ServiceModel model = service.serchStationName2(bmap); |
| | | @PostMapping("stationName2") |
| | | @ApiOperation(notes = "模糊查询",value="根据省份查询机房所在的所有城市") |
| | | public ServiceModel serchStationName2(@RequestParam String address) { |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationId(address); |
| | | ServiceModel model = service.serchStationName2(binfo); |
| | | |
| | | return model; |
| | | } |
| | | return model; |
| | | } |
| | | //根据省/市/区县查询所有的站点 |
| | | @GetMapping("stationName3") |
| | | @ApiOperation(notes = "",value="根据省/市/区县查询所有的站点") |
| | | public ServiceModel serchStationName3(@RequestBody BattInf binf){ |
| | | // BattInf binf = getGson().fromJson(json, BattInf.class); |
| | | ServiceModel model = service.serchStationName3(binf); |
| | | @PostMapping("stationName3") |
| | | @ApiOperation(notes = "模糊查询 s1,s2,s5",value="根据省/市/区县查询所有的站点") |
| | | public ServiceModel serchStationName3(@ApiParam(value = "省",required = true) @RequestParam String stationName1, @ApiParam(value = "市",required = true) @RequestParam String stationName2, @ApiParam(value = "区",required = true) @RequestParam String stationName5) { |
| | | BattInf binf = new BattInf(); |
| | | binf.setStationName1(stationName1); |
| | | binf.setStationName2(stationName2); |
| | | binf.setStationName5(stationName5); |
| | | ServiceModel model = service.serchStationName3(binf); |
| | | |
| | | return model; |
| | | } |
| | | return model; |
| | | } |
| | | //9.1根据省份和城市查询机房所在的所有机房 |
| | | @GetMapping("stationName") |
| | | @ApiOperation(notes = "",value="根据省份和城市查询机房所在的所有机房") |
| | | public ServiceModel serchStationName(@RequestBody BattMap_information bmap){ |
| | | // BattMap_information bmap = getGson().fromJson(json, BattMap_information.class); |
| | | ServiceModel model = service.serchStationName(bmap); |
| | | @ApiOperation(notes = "模糊查询",value="根据省份和城市查询机房所在的所有机房") |
| | | public ServiceModel serchStationName(@RequestParam String address) { |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationId(address); |
| | | ServiceModel model = service.serchStationName(binfo); |
| | | |
| | | return model; |
| | | } |
| | | //查询站点的经纬度 |
| | | @GetMapping("addressByStationName3") |
| | | @ApiOperation(notes = "",value="查询站点的经纬度") |
| | | public ServiceModel serchAddressByStationName3(@RequestBody BattMap_information bmap){ |
| | | // BattMap_information bmap = getGson().fromJson(json, BattMap_information.class); |
| | | ServiceModel model = service.serchAddressByStationName3(bmap); |
| | | @ApiOperation(notes = "模糊查询",value="查询站点的经纬度") |
| | | public ServiceModel serchAddressByStationName3(@RequestParam String stationName) { |
| | | BattMap_information binfo = new BattMap_information(); |
| | | binfo.setStationName(stationName); |
| | | ServiceModel model = service.serchAddressByStationName3(binfo); |
| | | |
| | | return model; |
| | | } |
| | | |
| | | return model; |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |