From 7d2ae4c2fd8d45f0896b9accf84ff4177638fbcd Mon Sep 17 00:00:00 2001 From: Lius <Lius2225@163.com> Date: 星期四, 17 七月 2025 20:38:01 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/EamTechnicalStatusDeactivateDetailController.java | 149 +++++++------------------------------------------ 1 files changed, 22 insertions(+), 127 deletions(-) diff --git a/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/EamTechnicalStatusDeactivateDetailController.java b/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/EamTechnicalStatusDeactivateDetailController.java index 13dd569..91ae811 100644 --- a/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/EamTechnicalStatusDeactivateDetailController.java +++ b/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/EamTechnicalStatusDeactivateDetailController.java @@ -1,151 +1,46 @@ package org.jeecg.modules.eam.controller; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import com.baomidou.mybatisplus.core.metadata.IPage; -import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import lombok.extern.slf4j.Slf4j; import org.jeecg.common.api.vo.Result; -import org.jeecg.common.aspect.annotation.AutoLog; import org.jeecg.common.system.base.controller.JeecgController; -import org.jeecg.common.system.query.QueryGenerator; import org.jeecg.modules.eam.entity.EamTechnicalStatusDeactivateDetail; import org.jeecg.modules.eam.service.IEamTechnicalStatusDeactivateDetailService; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.web.bind.annotation.*; -import org.springframework.web.servlet.ModelAndView; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestParam; +import org.springframework.web.bind.annotation.RestController; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; -import java.util.Arrays; +import java.util.List; - /** +/** * @Description: 鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁� * @Author: jeecg-boot - * @Date: 2025-07-09 + * @Date: 2025-07-09 * @Version: V1.0 */ @Slf4j -@Api(tags="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�") +@Api(tags = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�") @RestController @RequestMapping("/eam/eamTechnicalStatusDeactivateDetail") public class EamTechnicalStatusDeactivateDetailController extends JeecgController<EamTechnicalStatusDeactivateDetail, IEamTechnicalStatusDeactivateDetailService> { - @Autowired - private IEamTechnicalStatusDeactivateDetailService eamTechnicalStatusDeactivateDetailService; - - /** - * 鍒嗛〉鍒楄〃鏌ヨ - * - * @param eamTechnicalStatusDeactivateDetail - * @param pageNo - * @param pageSize - * @param req - * @return - */ - @ApiOperation(value="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-鍒嗛〉鍒楄〃鏌ヨ", notes="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-鍒嗛〉鍒楄〃鏌ヨ") - @GetMapping(value = "/list") - public Result<?> queryPageList(EamTechnicalStatusDeactivateDetail eamTechnicalStatusDeactivateDetail, - @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, - @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, - HttpServletRequest req) { - QueryWrapper<EamTechnicalStatusDeactivateDetail> queryWrapper = QueryGenerator.initQueryWrapper(eamTechnicalStatusDeactivateDetail, req.getParameterMap()); - Page<EamTechnicalStatusDeactivateDetail> page = new Page<EamTechnicalStatusDeactivateDetail>(pageNo, pageSize); - IPage<EamTechnicalStatusDeactivateDetail> pageList = eamTechnicalStatusDeactivateDetailService.page(page, queryWrapper); - return Result.OK(pageList); - } - - /** - * 娣诲姞 - * - * @param eamTechnicalStatusDeactivateDetail - * @return - */ - @AutoLog(value = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-娣诲姞") - @ApiOperation(value="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-娣诲姞", notes="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-娣诲姞") - @PostMapping(value = "/add") - public Result<?> add(@RequestBody EamTechnicalStatusDeactivateDetail eamTechnicalStatusDeactivateDetail) { - eamTechnicalStatusDeactivateDetailService.save(eamTechnicalStatusDeactivateDetail); - return Result.OK("娣诲姞鎴愬姛锛�"); - } - - /** - * 缂栬緫 - * - * @param eamTechnicalStatusDeactivateDetail - * @return - */ - @AutoLog(value = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-缂栬緫") - @ApiOperation(value="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-缂栬緫", notes="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-缂栬緫") - @RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST}) - public Result<?> edit(@RequestBody EamTechnicalStatusDeactivateDetail eamTechnicalStatusDeactivateDetail) { - eamTechnicalStatusDeactivateDetailService.updateById(eamTechnicalStatusDeactivateDetail); - return Result.OK("缂栬緫鎴愬姛!"); - } - - /** - * 閫氳繃id鍒犻櫎 - * - * @param id - * @return - */ - @AutoLog(value = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-閫氳繃id鍒犻櫎") - @ApiOperation(value="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-閫氳繃id鍒犻櫎", notes="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-閫氳繃id鍒犻櫎") - @DeleteMapping(value = "/delete") - public Result<?> delete(@RequestParam(name="id",required=true) String id) { - eamTechnicalStatusDeactivateDetailService.removeById(id); - return Result.OK("鍒犻櫎鎴愬姛!"); - } - - /** - * 鎵归噺鍒犻櫎 - * - * @param ids - * @return - */ - @AutoLog(value = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-鎵归噺鍒犻櫎") - @ApiOperation(value="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-鎵归噺鍒犻櫎", notes="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-鎵归噺鍒犻櫎") - @DeleteMapping(value = "/deleteBatch") - public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) { - this.eamTechnicalStatusDeactivateDetailService.removeByIds(Arrays.asList(ids.split(","))); - return Result.OK("鎵归噺鍒犻櫎鎴愬姛锛�"); - } - - /** - * 閫氳繃id鏌ヨ - * - * @param id - * @return - */ - @AutoLog(value = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-閫氳繃id鏌ヨ") - @ApiOperation(value="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-閫氳繃id鏌ヨ", notes="鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-閫氳繃id鏌ヨ") - @GetMapping(value = "/queryById") - public Result<?> queryById(@RequestParam(name="id",required=true) String id) { - EamTechnicalStatusDeactivateDetail eamTechnicalStatusDeactivateDetail = eamTechnicalStatusDeactivateDetailService.getById(id); - return Result.OK(eamTechnicalStatusDeactivateDetail); - } + @Autowired + private IEamTechnicalStatusDeactivateDetailService deactivateDetailService; - /** - * 瀵煎嚭excel - * - * @param request - * @param eamTechnicalStatusDeactivateDetail - */ - @RequestMapping(value = "/exportXls") - public ModelAndView exportXls(HttpServletRequest request, EamTechnicalStatusDeactivateDetail eamTechnicalStatusDeactivateDetail) { - return super.exportXls(request, eamTechnicalStatusDeactivateDetail, EamTechnicalStatusDeactivateDetail.class, "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�"); - } + /** + * 鍒楄〃鏌ヨ + * + * @param applicationId + * @return + */ + @ApiOperation(value = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-鍒楄〃鏌ヨ", notes = "鍋滅敤鍔犲伐璁惧鐢宠鍗曟槑缁�-鍒楄〃鏌ヨ") + @GetMapping(value = "/queryList") + public Result<?> queryList(@RequestParam("applicationId") String applicationId) { + List<EamTechnicalStatusDeactivateDetail> list = deactivateDetailService.queryList(applicationId); + return Result.OK(list); + } - /** - * 閫氳繃excel瀵煎叆鏁版嵁 - * - * @param request - * @param response - * @return - */ - @RequestMapping(value = "/importExcel", method = RequestMethod.POST) - public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) { - return super.importExcel(request, response, EamTechnicalStatusDeactivateDetail.class); - } } -- Gitblit v1.9.3