| | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | import com.ard.tianyu.domain.UavBox; |
| | | import com.ard.tianyu.domain.entity.UavBoxEntity; |
| | | import com.ard.tianyu.service.IUavBoxService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | |
| | | @ApiOperation("查询无人机盒子列表") |
| | | @PreAuthorize("@ss.hasPermi('uav:box:list')") |
| | | @GetMapping("/list") |
| | | public TableDataInfo list(UavBox uavBox) |
| | | public TableDataInfo list(UavBoxEntity uavBoxEntity) |
| | | { |
| | | startPage(); |
| | | List<UavBox> list = uavBoxService.selectUavBoxList(uavBox); |
| | | List<UavBoxEntity> list = uavBoxService.selectUavBoxList(uavBoxEntity); |
| | | return getDataTable(list); |
| | | } |
| | | |
| | |
| | | @PreAuthorize("@ss.hasPermi('uav:box:export')") |
| | | @Log(title = "无人机盒子", businessType = BusinessType.EXPORT) |
| | | @PostMapping("/export") |
| | | public void export(HttpServletResponse response, UavBox uavBox) |
| | | public void export(HttpServletResponse response, UavBoxEntity uavBoxEntity) |
| | | { |
| | | List<UavBox> list = uavBoxService.selectUavBoxList(uavBox); |
| | | ExcelUtil<UavBox> util = new ExcelUtil<UavBox>(UavBox.class); |
| | | List<UavBoxEntity> list = uavBoxService.selectUavBoxList(uavBoxEntity); |
| | | ExcelUtil<UavBoxEntity> util = new ExcelUtil<UavBoxEntity>(UavBoxEntity.class); |
| | | util.exportExcel(response, list, "无人机盒子数据"); |
| | | } |
| | | |
| | |
| | | @PreAuthorize("@ss.hasPermi('uav:box:add')") |
| | | @Log(title = "无人机盒子", businessType = BusinessType.INSERT) |
| | | @PostMapping |
| | | public AjaxResult add(@RequestBody UavBox uavBox) |
| | | public AjaxResult add(@RequestBody UavBoxEntity uavBoxEntity) |
| | | { |
| | | return toAjax(uavBoxService.insertUavBox(uavBox)); |
| | | return toAjax(uavBoxService.insertUavBox(uavBoxEntity)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @PreAuthorize("@ss.hasPermi('uav:box:edit')") |
| | | @Log(title = "无人机盒子", businessType = BusinessType.UPDATE) |
| | | @PutMapping |
| | | public AjaxResult edit(@RequestBody UavBox uavBox) |
| | | public AjaxResult edit(@RequestBody UavBoxEntity uavBoxEntity) |
| | | { |
| | | return toAjax(uavBoxService.updateUavBox(uavBox)); |
| | | return toAjax(uavBoxService.updateUavBox(uavBoxEntity)); |
| | | } |
| | | |
| | | /** |