| | |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.waterrecord.pojo.WaterRecord; |
| | | import com.ruoyi.waterrecord.service.WaterRecordService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.util.CollectionUtils; |
| | |
| | | * @date : 2025/8/11 10:08 |
| | | */ |
| | | @RestController |
| | | @Api(tags = "用水管理") |
| | | @Tag(name = "用水管理") |
| | | @RequestMapping("/waterRecord") |
| | | @AllArgsConstructor |
| | | public class WaterRecordController extends BaseController { |
| | | |
| | | @Autowired |
| | | private WaterRecordService waterRecordService; |
| | | |
| | | @GetMapping("/listPage") |
| | |
| | | */ |
| | | @Log(title = "导入用水管理", businessType = BusinessType.IMPORT) |
| | | @PostMapping("/importData") |
| | | @ApiOperation("导入用水管理") |
| | | @Operation(summary = "导入用水管理") |
| | | public AjaxResult importData(MultipartFile file) throws Exception { |
| | | return waterRecordService.importData(file); |
| | | } |
| | |
| | | */ |
| | | @Log(title = "导出用水管理", businessType = BusinessType.EXPORT) |
| | | @PostMapping("/export") |
| | | @ApiOperation("导出用水管理") |
| | | @Operation(summary = "导出用水管理") |
| | | public void export(HttpServletResponse response) { |
| | | Page page = new Page(-1,-1); |
| | | WaterRecord waterRecord = new WaterRecord(); |