| | |
| | | import com.ruoyi.device.dto.DeviceDefectRecordDto; |
| | | import com.ruoyi.device.pojo.DeviceDefectRecord; |
| | | import com.ruoyi.device.service.DeviceDefectRecordService; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | |
| | | return AjaxResult.success(deviceDefectRecordService.listPage(new Page<>(1,-1),deviceDefectRecordDto)); |
| | | } |
| | | |
| | | @Log(title = "新增设备缺陷记录", businessType = BusinessType.INSERT) |
| | | @PostMapping("/add") |
| | | @Operation(summary = "添加设备缺陷记录") |
| | | public AjaxResult add(@RequestBody DeviceDefectRecord deviceDefectRecord) { |
| | | return AjaxResult.success(deviceDefectRecordService.add(deviceDefectRecord)); |
| | | } |
| | | @Log(title = "修改设备缺陷记录", businessType = BusinessType.UPDATE) |
| | | @PostMapping("/update") |
| | | @Operation(summary = "修改设备缺陷记录") |
| | | public AjaxResult update(@RequestBody DeviceDefectRecord deviceDefectRecord) { |
| | | return AjaxResult.success(deviceDefectRecordService.updateByDDR(deviceDefectRecord)); |
| | | } |
| | | @Log(title = "删除设备缺陷记录", businessType = BusinessType.DELETE) |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "删除设备缺陷记录") |
| | | public AjaxResult delete(@PathVariable Long id) { |