| | |
| | | import org.springblade.jfpt.equipment.vo.EquipmentVO; |
| | | import org.springblade.jfpt.equipment.vo.EquipmentVOS; |
| | | import org.springblade.jfpt.equipment.wrapper.EqWrapper; |
| | | import org.springblade.system.user.entity.User; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import springfox.documentation.annotations.ApiIgnore; |
| | | |
| | |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 自定义分页(部门挂接) |
| | | */ |
| | | @GetMapping("/pageDept") |
| | | @ApiOperationSupport(order = 3) |
| | | @ApiOperation(value = "分页", notes = "传入equipment") |
| | | public R<IPage<EquipmentVO>> pageDept(EquipmentVO equipment, Query query, String pid, HttpServletResponse response) throws ParseException { |
| | | response.setHeader("Access-Control-Allow-Origin", "*"); |
| | | response.setHeader("Access-Control-Allow-Methods", "POST, GET, OPTIONS, DELETE"); |
| | | response.setHeader("Access-Control-Allow-Credentials", "true"); |
| | | |
| | | IPage<EquipmentVO> pages = equipmentService.selectDeptPages(Condition.getPage(query), equipment, pid); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | |
| | | //子节点 |
| | | private static List childMenu = new ArrayList(); |
| | | |
| | |
| | | equipment.setHeartbeat(null); |
| | | } |
| | | |
| | | String deviceName = equipment.getDeviceName(); |
| | | String deviceNumber = equipment.getDeviceNumber(); |
| | | String pId = equipment.getPid(); |
| | | if (equipment.getId() == null){ |
| | | catalogService.addCatalog(deviceName,deviceNumber,pId); |
| | | }else{ |
| | | catalogService.updateCatalog(deviceName,deviceNumber,pId); |
| | | } |
| | | // String deviceName = equipment.getDeviceName(); |
| | | // String deviceNumber = equipment.getDeviceNumber(); |
| | | // String pId = equipment.getPid(); |
| | | // if (equipment.getId() == null){ |
| | | // catalogService.addCatalog(deviceName,deviceNumber,pId); |
| | | // }else{ |
| | | // catalogService.updateCatalog(deviceName,deviceNumber,pId); |
| | | // } |
| | | |
| | | |
| | | return R.status(equipmentService.saveOrUpdate(equipment)); |