From c2963c9ba128728788add2586f1fb5dc421ca6b5 Mon Sep 17 00:00:00 2001
From: 龚焕茏 <2842157468@qq.com>
Date: 星期三, 10 四月 2024 18:11:31 +0800
Subject: [PATCH] 新增运维平台、资产管理
---
ycl-server/src/main/java/com/ycl/platform/controller/YwUnitController.java | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/ycl-server/src/main/java/com/ycl/platform/controller/YwUnitController.java b/ycl-server/src/main/java/com/ycl/platform/controller/YwUnitController.java
index 8ca1397..7bda29c 100644
--- a/ycl-server/src/main/java/com/ycl/platform/controller/YwUnitController.java
+++ b/ycl-server/src/main/java/com/ycl/platform/controller/YwUnitController.java
@@ -1,11 +1,16 @@
package com.ycl.platform.controller;
+import com.ycl.platform.domain.query.ReportQuery;
+import com.ycl.platform.domain.vo.ReportVO;
+import com.ycl.platform.domain.vo.YwUnitVO;
import com.ycl.system.Result;
import com.ycl.platform.domain.form.YwUnitForm;
import com.ycl.system.domain.group.Update;
import com.ycl.system.domain.group.Add;
import com.ycl.platform.domain.query.YwUnitQuery;
import com.ycl.platform.service.YwUnitService;
+import com.ycl.utils.poi.ExcelUtil;
+import jakarta.servlet.http.HttpServletResponse;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.validation.annotation.Validated;
import lombok.RequiredArgsConstructor;
@@ -73,4 +78,12 @@
public Result list() {
return ywUnitService.all();
}
+
+ @PostMapping("/export")
+ public void export(HttpServletResponse response, YwUnitQuery query)
+ {
+ List<YwUnitVO> list = ywUnitService.export(query);
+ ExcelUtil<YwUnitVO> util = new ExcelUtil<>(YwUnitVO.class);
+ util.exportExcel(response, list, "鎶ュ");
+ }
}
--
Gitblit v1.8.0