Commit b5d36fb2c96235020fe0e38ad09dc24c2b09afaa

Authored by xiejp
2 parents 50a320b3 611cf547

pda

src/main/java/com/zteits/irain/portal/web/parkinglotcloudplatform/devicemanagement/PdaController.java
... ... @@ -15,6 +15,7 @@ import org.springframework.beans.factory.annotation.Value;
15 15 import org.springframework.web.bind.annotation.GetMapping;
16 16 import org.springframework.web.bind.annotation.PostMapping;
17 17 import org.springframework.web.bind.annotation.RequestBody;
  18 +import org.springframework.web.bind.annotation.RequestMapping;
18 19 import org.springframework.web.bind.annotation.RequestParam;
19 20 import org.springframework.web.bind.annotation.RestController;
20 21 import org.springframework.web.multipart.MultipartFile;
... ... @@ -35,6 +36,7 @@ import com.zteits.clouds.api.apibase.constants.ErrorType;
35 36 import com.zteits.clouds.api.apibase.exception.BizException;
36 37 import com.zteits.clouds.api.dto.park.dto.TpPPdaDTO;
37 38 import com.zteits.clouds.api.dto.park.dto.TpPTgsPassedcarDTO;
  39 +import com.zteits.clouds.api.dto.park.param.TpPPdaPageQueryRequest;
38 40 import com.zteits.clouds.api.dto.park.param.TpPPdaRequest;
39 41 import com.zteits.clouds.api.dto.park.param.TpPPdaSRequest;
40 42 import com.zteits.clouds.api.dto.park.param.TpPTgsPassedcarRequest;
... ... @@ -60,6 +62,7 @@ import io.swagger.annotations.ApiOperation;
60 62 * 2017年8月31日 wangbiao v1.0.0 创建
61 63 */
62 64 @RestController
  65 +@RequestMapping("/padinfo")
63 66 public class PdaController extends BizController {
64 67  
65 68 private static final Logger logger = LoggerFactory.getLogger(InOutParkStatisticController.class);
... ... @@ -74,7 +77,7 @@ public class PdaController extends BizController {
74 77  
75 78  
76 79  
77   - @ApiOperation("PDA信息信息")
  80 + @ApiOperation("过车查询")
78 81 @PostMapping("/queryPassedca4pabe")
79 82 public BizResultVO<EasyUIDataGridVO<TpPTgsPassedcarDTO>> queryPassedca4pabe(@RequestBody TpPTgsPassedcarRequest tpPTgsPassedcarRequest, HttpServletRequest request,
80 83 HttpServletResponse response){
... ... @@ -91,9 +94,9 @@ public class PdaController extends BizController {
91 94 return new BizResultVO<EasyUIDataGridVO<TpPTgsPassedcarDTO>>();
92 95 }
93 96  
94   - @ApiOperation("PDA信息信息")
  97 + @ApiOperation("PDA分页查询信息")
95 98 @PostMapping("/queryPdaInfo4pabe")
96   - public BizResultVO<EasyUIDataGridVO<TpPPdaDTO>> queryPdaInfo4pabe(@RequestBody TpPPdaRequest tpPPdaRequest, HttpServletRequest request,
  99 + public BizResultVO<EasyUIDataGridVO<TpPPdaDTO>> queryPdaInfo4pabe(@RequestBody TpPPdaPageQueryRequest tpPPdaRequest, HttpServletRequest request,
97 100 HttpServletResponse response){
98 101 BizResult<PageBean<TpPPdaDTO>> bizResult = new BizResult<PageBean<TpPPdaDTO>>();
99 102 try {
... ... @@ -178,41 +181,40 @@ public class PdaController extends BizController {
178 181 return new BizResultVO<Integer>();
179 182 }
180 183  
181   - @ApiOperation("pda信息导出excel")
182   - @GetMapping("exportBerthInfoExcel")
183   - public void exportBerthInfoExcel(@RequestBody TpPPdaRequest tpPPdaRequest, HttpServletRequest requests, HttpServletResponse response) {
184   - tpPPdaRequest.setSysCode(sysCode);
185   - BizResult<List<TpPPdaDTO>> list = tpPPdaService.queryPdaInfo(tpPPdaRequest);
186   - String[] title = new String[] { "序号","设备编号", "设备名称", "设备类型", "状态","持有人","资源描述" };
187   - String sheetName = "PDA信息";
188   - String fileName = sheetName+DateUtil.getDate();
189   - // 1.创建excel信息
190   - XSSFSheet workSheet = ExcelUtil.createExcel(fileName);
191   - // 2.设置excel表头和表体
192   - Layouter.buildReport(workSheet, title, 0, 0);
193   - // 3.填充数据
194   - List<Object[]> contentList = new ArrayList<Object[]>();
195   - int number = 1;
196   - if(list.isSuccess() && CollectionUtil.isNotEmpty(list.getData())){
197   - for (TpPPdaDTO b : list.getData()) {
198   - Object[] obj = new Object[title.length];
199   - int index = 0;
200   - obj[index++] = number++;
201   - obj[index++] = b.getId();
202   - obj[index++] = b.getPdaNo();
203   - obj[index++] = b.getPdaName();
204   - obj[index++] = b.getPdaType();
205   - obj[index++] = b.getPdaStatus();
206   - obj[index++] = b.getOwnerName();
207   - obj[index++] = b.getRemark();
208   - contentList.add(obj);
209   - }
210   - }
211   - ExcleFillDateManager fillUserManager = new ExcleFillDateManager();
212   - fillUserManager.fillSalesOrga(workSheet, title, contentList, 2);
213   - // 4.excel输出配置
214   - ExcelUtil.write(response, workSheet, fileName);
215   - }
  184 +// @ApiOperation("pda信息导出excel")
  185 +// @GetMapping("exportBerthInfoExcel")
  186 +// public void exportBerthInfoExcel(@RequestBody TpPPdaRequest tpPPdaRequest, HttpServletRequest requests, HttpServletResponse response) {
  187 +// tpPPdaRequest.setSysCode(sysCode);
  188 +// BizResult<PageBean<TpPPdaDTO>> list = tpPPdaService.queryPdaInfo4pabe(tpPPdaRequest);
  189 +// String[] title = new String[] { "序号","设备编号", "设备名称", "设备类型", "状态","资源描述" };
  190 +// String sheetName = "PDA信息";
  191 +// String fileName = sheetName+DateUtil.getDate();
  192 +// // 1.创建excel信息
  193 +// XSSFSheet workSheet = ExcelUtil.createExcel(fileName);
  194 +// // 2.设置excel表头和表体
  195 +// Layouter.buildReport(workSheet, title, 0, 0);
  196 +// // 3.填充数据
  197 +// List<Object[]> contentList = new ArrayList<Object[]>();
  198 +// int number = 1;
  199 +// if(list.isSuccess() && CollectionUtil.isNotEmpty(list.getData())){
  200 +// for (TpPPdaDTO b : list.getData()) {
  201 +// Object[] obj = new Object[title.length];
  202 +// int index = 0;
  203 +// obj[index++] = number++;
  204 +// obj[index++] = b.getId();
  205 +// obj[index++] = b.getPdaNo();
  206 +// obj[index++] = b.getPdaName();
  207 +// obj[index++] = b.getPdaType();
  208 +// obj[index++] = b.getPdaStatus();
  209 +// obj[index++] = b.getRemark();
  210 +// contentList.add(obj);
  211 +// }
  212 +// }
  213 +// ExcleFillDateManager fillUserManager = new ExcleFillDateManager();
  214 +// fillUserManager.fillSalesOrga(workSheet, title, contentList, 2);
  215 +// // 4.excel输出配置
  216 +// ExcelUtil.write(response, workSheet, fileName);
  217 +// }
216 218  
217 219  
218 220 @ApiOperation("pda信息 导入模板下载")
... ...