From e22d3ca089ad03cc33a7b5f440a67415283f75d1 Mon Sep 17 00:00:00 2001
From: zss <zss@example.com>
Date: 星期二, 31 十二月 2024 15:18:51 +0800
Subject: [PATCH] 无源器件的报告
---
performance-server/src/main/java/com/yuanchu/mom/controller/EvaluateController.java | 36 ++++++++++++++++++++++++++++++++++--
1 files changed, 34 insertions(+), 2 deletions(-)
diff --git a/performance-server/src/main/java/com/yuanchu/mom/controller/EvaluateController.java b/performance-server/src/main/java/com/yuanchu/mom/controller/EvaluateController.java
index 5815d15..e9834ee 100644
--- a/performance-server/src/main/java/com/yuanchu/mom/controller/EvaluateController.java
+++ b/performance-server/src/main/java/com/yuanchu/mom/controller/EvaluateController.java
@@ -1,8 +1,20 @@
package com.yuanchu.mom.controller;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.yuanchu.mom.annotation.ValueClassify;
+import com.yuanchu.mom.pojo.AuxiliaryWorkingHours;
+import com.yuanchu.mom.pojo.Evaluate;
+import com.yuanchu.mom.service.EvaluateService;
+import com.yuanchu.mom.utils.JackSonUtil;
+import com.yuanchu.mom.vo.Result;
import io.swagger.annotations.Api;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.web.bind.annotation.*;
+
+import javax.annotation.Resource;
+import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
+import java.util.Map;
/**
* <p>
@@ -17,4 +29,24 @@
@RequestMapping("/evaluate")
public class EvaluateController {
+
+ @Resource
+ private EvaluateService evaluateService;
+
+ @ValueClassify("浜哄憳鑰冭瘎")
+ @ApiOperation(value = "鏌ヨ鑰冭瘎")
+ @PostMapping("/page")
+ public Result page(@RequestBody Map<String, Object> data) throws Exception {
+ Page page = JackSonUtil.unmarshal(JackSonUtil.marshal(data.get("page")), Page.class);
+ Evaluate entity = JackSonUtil.unmarshal(JackSonUtil.marshal(data.get("entity")), Evaluate.class);
+ return Result.success(evaluateService.getPage(page, entity));
+ }
+
+ @ValueClassify("浜哄憳鑰冭瘎")
+ @ApiOperation(value = "瀵煎嚭鑰冭瘎")
+ @PostMapping("/exportEvaluate")
+ public void exportEvaluate(@RequestParam("month") String month, @RequestParam("name") String name, @RequestParam("departLims") String departLims, HttpServletResponse response) throws IOException {
+ evaluateService.export(month, name, departLims, response);
+ }
+
}
--
Gitblit v1.9.3