Commit 38f2f27427d9c7725f477457dc7e9d792be51844
1 parent
053aa9f1
泊位管理接口
Showing
3 changed files
with
114 additions
and
2 deletions
src/main/java/com/zteits/irain/portal/vo/parkinglotcloudplatform/datastatistic/ParkLotEqpTypeCountVO.java
| @@ -20,7 +20,8 @@ public class ParkLotEqpTypeCountVO { | @@ -20,7 +20,8 @@ public class ParkLotEqpTypeCountVO { | ||
| 20 | 20 | ||
| 21 | /**设备类型:1-地磁*/ | 21 | /**设备类型:1-地磁*/ |
| 22 | private Integer eqpType; | 22 | private Integer eqpType; |
| 23 | - /**设备状态:1-未安装,2-使用中,3-损坏*/ | 23 | + ///**设备状态:1-未安装,2-使用中,3-损坏*/ |
| 24 | + /**设备状态:1-在线,0-离线*/ | ||
| 24 | private Integer eqpState; | 25 | private Integer eqpState; |
| 25 | /**个数*/ | 26 | /**个数*/ |
| 26 | private Integer eqpNum; | 27 | private Integer eqpNum; |
src/main/java/com/zteits/irain/portal/web/parkinglotcloudplatform/datastatistic/BerthManageController.java
0 → 100644
| 1 | +package com.zteits.irain.portal.web.parkinglotcloudplatform.datastatistic; | ||
| 2 | + | ||
| 3 | +import org.slf4j.Logger; | ||
| 4 | +import org.slf4j.LoggerFactory; | ||
| 5 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 6 | +import org.springframework.beans.factory.annotation.Value; | ||
| 7 | +import org.springframework.stereotype.Controller; | ||
| 8 | +import org.springframework.web.bind.annotation.PostMapping; | ||
| 9 | +import org.springframework.web.bind.annotation.RequestBody; | ||
| 10 | +import org.springframework.web.bind.annotation.RequestMapping; | ||
| 11 | +import org.springframework.web.bind.annotation.ResponseBody; | ||
| 12 | + | ||
| 13 | +import com.clouds.common.web.BizController; | ||
| 14 | +import com.clouds.common.web.vo.BizResultVO; | ||
| 15 | +import com.clouds.common.web.vo.EasyUIDataGridVO; | ||
| 16 | +import com.zteits.clouds.api.apibase.bean.BizResult; | ||
| 17 | +import com.zteits.clouds.api.apibase.bean.PageBean; | ||
| 18 | +import com.zteits.clouds.api.dto.park.dto.BerthsDTO; | ||
| 19 | +import com.zteits.clouds.api.dto.park.param.BerthManageRequest; | ||
| 20 | +import com.zteits.clouds.api.service.park.BerthManageService; | ||
| 21 | + | ||
| 22 | +import io.swagger.annotations.Api; | ||
| 23 | +import io.swagger.annotations.ApiOperation; | ||
| 24 | + | ||
| 25 | +/** | ||
| 26 | + * | ||
| 27 | + * | ||
| 28 | + * Copyright: Copyright (c) 2017 zteits | ||
| 29 | + * | ||
| 30 | + * @ClassName: BerthManageController.java | ||
| 31 | + * @Description: | ||
| 32 | + * @version: v1.0.0 | ||
| 33 | + * @author: wangfei | ||
| 34 | + * @date: 2017年8月28日 下午5:45:21 | ||
| 35 | + * Modification History: | ||
| 36 | + * Date Author Version Description | ||
| 37 | + *---------------------------------------------------------* | ||
| 38 | + * 2017年8月28日 wangfei v1.0.0 创建 | ||
| 39 | + */ | ||
| 40 | +@Api("停车场云平台 基础信息 泊位管理") | ||
| 41 | +@Controller | ||
| 42 | +@RequestMapping("/berth") | ||
| 43 | +public class BerthManageController extends BizController { | ||
| 44 | + private static final Logger logger = LoggerFactory.getLogger(BerthManageController.class); | ||
| 45 | + @Value("${project.syscode}") | ||
| 46 | + private String sysCode; | ||
| 47 | + @Autowired | ||
| 48 | + private BerthManageService berthManageService; | ||
| 49 | + | ||
| 50 | + | ||
| 51 | + /** | ||
| 52 | + * @param requestObject | ||
| 53 | + * @return | ||
| 54 | + * @throws IllegalAccessException | ||
| 55 | + * @throws InstantiationException | ||
| 56 | + */ | ||
| 57 | + @ApiOperation("泊位信息分页查询") | ||
| 58 | + @PostMapping("berthList") | ||
| 59 | + @ResponseBody | ||
| 60 | + public BizResultVO<EasyUIDataGridVO<BerthsDTO>> berthList(@RequestBody BerthManageRequest requestObject) | ||
| 61 | + throws InstantiationException, IllegalAccessException { | ||
| 62 | + | ||
| 63 | + requestObject.setSysCode(sysCode); | ||
| 64 | + BizResult<PageBean<BerthsDTO>> respondObject = | ||
| 65 | + berthManageService.queryBerthByCondition(requestObject); | ||
| 66 | + return returnJqGridData(respondObject,BerthsDTO.class); | ||
| 67 | + } | ||
| 68 | + /** | ||
| 69 | + * @param requestObject | ||
| 70 | + * @return | ||
| 71 | + */ | ||
| 72 | + @ApiOperation("修改泊位信息") | ||
| 73 | + @PostMapping("updateBerthInfo") | ||
| 74 | + @ResponseBody | ||
| 75 | + public BizResultVO<Boolean> updateBerthInfo(@RequestBody BerthManageRequest requestObject) { | ||
| 76 | + requestObject.setSysCode(sysCode); | ||
| 77 | + BizResult<Boolean> respondObject = berthManageService.updateBerthById(requestObject); | ||
| 78 | + return new BizResultVO<Boolean>(respondObject); | ||
| 79 | + } | ||
| 80 | + | ||
| 81 | + /** | ||
| 82 | + * @param requestObject | ||
| 83 | + * @return | ||
| 84 | + */ | ||
| 85 | + @ApiOperation("批量删除泊位信息") | ||
| 86 | + @PostMapping("deleteBerths") | ||
| 87 | + @ResponseBody | ||
| 88 | + public BizResultVO<Boolean> deleteBerths(@RequestBody BerthManageRequest requestObject) { | ||
| 89 | + requestObject.setSysCode(sysCode); | ||
| 90 | + BizResult<Boolean> respondObject = berthManageService.deleteBerthByIds(requestObject); | ||
| 91 | + return new BizResultVO<Boolean>(respondObject); | ||
| 92 | + } | ||
| 93 | + | ||
| 94 | + /** | ||
| 95 | + * 保存泊位信息 | ||
| 96 | + * @param requestObject | ||
| 97 | + * @return | ||
| 98 | + */ | ||
| 99 | + @ApiOperation("保存泊位信息") | ||
| 100 | + @PostMapping("saveBerthInfo") | ||
| 101 | + @ResponseBody | ||
| 102 | + public BizResultVO<Boolean> saveBerthInfo(@RequestBody BerthManageRequest requestObject) { | ||
| 103 | + requestObject.setSysCode(sysCode); | ||
| 104 | + BizResult<Boolean> respondObject = berthManageService.saveBerthInfo(requestObject); | ||
| 105 | + return new BizResultVO<Boolean>(respondObject); | ||
| 106 | + } | ||
| 107 | + | ||
| 108 | +} |
src/main/resources/dubbo/dubbo-park-consumer.xml
| @@ -153,5 +153,8 @@ | @@ -153,5 +153,8 @@ | ||
| 153 | version="${spring.dubbo.provider.version}" | 153 | version="${spring.dubbo.provider.version}" |
| 154 | timeout="30000"/> | 154 | timeout="30000"/> |
| 155 | 155 | ||
| 156 | - | 156 | + <!--企业云平台-基础信息-泊位管理 --> |
| 157 | + <dubbo:reference id="berthManageService" interface="com.zteits.clouds.api.service.park.BerthManageService" | ||
| 158 | + version="${spring.dubbo.provider.version}" | ||
| 159 | + timeout="30000"/> | ||
| 157 | </beans> | 160 | </beans> |
| 158 | \ No newline at end of file | 161 | \ No newline at end of file |