| | |
| | | package com.mes.downstorage.controller; |
| | | |
| | | import com.mes.downstorage.entity.DownStorageCage; |
| | | import com.mes.downstorage.entity.DownStorageCageDetails; |
| | | import com.mes.downstorage.service.DownStorageCageDetailsService; |
| | | import com.mes.downstorage.service.DownStorageCageService; |
| | | import com.mes.utils.Result; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | /** |
| | | * <p> |
| | | * 前端控制器 |
| | | * </p> |
| | | * |
| | | * @author zhoush |
| | | * @since 2024-03-27 |
| | | */ |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | @Api(tags = "缓存") |
| | | @RestController |
| | | @RequestMapping("/downStorageCageDetails") |
| | | @RequestMapping("/downStorage") |
| | | public class DownStorageCageDetailsController { |
| | | |
| | | } |
| | | @Autowired |
| | | private DownStorageCageDetailsService downStorageCageDetailsService; |
| | | @Autowired |
| | | private DownStorageCageService downStorageCageService; |
| | | |
| | | @PostMapping("/add") |
| | | public String addDownStorageCageDetails(@RequestBody DownStorageCageDetails details) { |
| | | downStorageCageDetailsService.addDownStorageCageDetails(details); |
| | | return "Details added successfully"; |
| | | } |
| | | |
| | | |
| | | |
| | | //查询磨边缓存理片笼内详情 |
| | | @ApiOperation("查询缓存理片笼内详情") |
| | | @GetMapping("/selectStorageCage") |
| | | @ResponseBody |
| | | public Result selectDownStorageCage () { |
| | | List<Map<String, Object>> list=downStorageCageDetailsService.getCacheInfo(); |
| | | return Result.build(200,"成功",list); |
| | | } |
| | | |
| | | |
| | | // |
| | | // @ApiOperation("添加缓存理片笼信息 功能:笼内绑定玻璃 参数(DownStorageCageDetails downStorageCageDetails)") |
| | | // @PostMapping("/insertEdgStorageCage") |
| | | // @ResponseBody |
| | | // public Result insertEdgStorageCage(@RequestBody DownStorageCageDetails downStorageCageDetails) { |
| | | // boolean isSucess=downStorageCageService.updatedownStorageCageDetails(downStorageCageDetails); |
| | | // return Result.build(200,"添加成功",1); |
| | | // } |
| | | |
| | | |
| | | |
| | | @ApiOperation("修改缓存理片笼信息 功能:对笼内栅格进行【启用/禁用】/ 【更换】笼内栅格玻璃信息") |
| | | @PostMapping("/updateDownStorageCage") |
| | | @ResponseBody |
| | | public Result updateDownStorageCage(@RequestBody DownStorageCage downStorageCage) { |
| | | boolean isSucess=downStorageCageService.updateDownStorageCage(downStorageCage); |
| | | return Result.build(200,"更换成功",1); |
| | | } |
| | | @ApiOperation("删除缓存理片笼信息 功能:对笼内栅格玻璃进行【清除】") |
| | | @PostMapping("/deleteDownStorageCage") |
| | | @ResponseBody |
| | | public Result deleteDownStorageCage(@RequestBody DownStorageCageDetails downStorageCageDetails,int downStorageCageId) { |
| | | boolean isSucess=downStorageCageService.updateDownStorageCageDetails(downStorageCageId,downStorageCageDetails); |
| | | return Result.build(200,"删除成功",1); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | // |
| | | |
| | | |
| | | // Other CRUD operations can be defined here |
| | | } |