| 对比新文件 |
| | |
| | | package com.ruoyi.technology.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.R; |
| | | import com.ruoyi.technology.bean.dto.TechnologyParamDto; |
| | | import com.ruoyi.technology.bean.vo.TechnologyParamVo; |
| | | import com.ruoyi.technology.service.TechnologyParamService; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import lombok.RequiredArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | @RestController |
| | | @RequestMapping("/technologyParam") |
| | | @RequiredArgsConstructor |
| | | @Tag(name = "鍩虹鍙傛暟") |
| | | public class TechnologyParamController { |
| | | |
| | | private final TechnologyParamService technologyParamService; |
| | | |
| | | @GetMapping("list") |
| | | @Log(title = "鍩虹鍙傛暟鏁版嵁闆嗗悎", businessType = BusinessType.OTHER) |
| | | @Operation(summary = "鍩虹鍙傛暟鍒嗛〉鏌ヨ") |
| | | public R<IPage<TechnologyParamVo>> TechnologyParamDtoList(Page<TechnologyParamDto> page, TechnologyParamDto technologyParamDto) { |
| | | IPage<TechnologyParamVo> paramList = technologyParamService.baseParamList(page, technologyParamDto); |
| | | return R.ok(paramList); |
| | | } |
| | | |
| | | @PostMapping("/add") |
| | | @Log(title = "鏂板鍩虹鍙傛暟", businessType = BusinessType.INSERT) |
| | | @Operation(summary = "鏂板鍩虹鍙傛暟") |
| | | public R TechnologyParamDtoAdd(@RequestBody TechnologyParamDto TechnologyParamDto) { |
| | | return R.ok(technologyParamService.addBaseParam(TechnologyParamDto)); |
| | | } |
| | | |
| | | @PutMapping("/edit") |
| | | @Log(title = "淇敼鍩虹鍙傛暟", businessType = BusinessType.UPDATE) |
| | | @Operation(summary = "淇敼鍩虹鍙傛暟") |
| | | public R TechnologyParamDtoEdit(@RequestBody TechnologyParamDto TechnologyParamDto) { |
| | | return R.ok(technologyParamService.updateBaseParam(TechnologyParamDto)); |
| | | } |
| | | |
| | | @DeleteMapping("/remove/{ids}") |
| | | @Log(title = "鍒犻櫎鍩虹鍙傛暟", businessType = BusinessType.DELETE) |
| | | @Operation(summary = "鍒犻櫎鍩虹鍙傛暟") |
| | | public R TechnologyParamDtoRemove(@PathVariable Long[] ids) { |
| | | return R.ok(technologyParamService.deleteBaseParamByIds(ids)); |
| | | } |
| | | } |