src/main/java/com/zgn/hospital/controller/NoticeController.java
(完整代码) 1KBpackage com.zgn.hospital.controller;
import com.zgn.hospital.entity.notice;
import com.zgn.hospital.service.NoticeService;
import com.zgn.hospital.utils.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
/**
* @program: hospital_info
* @description:
* @author: ZGN
* @create: 2023-04-07 15:00
*/
@RestController
@RequestMapping("/notice")
public class NoticeController {
@Autowired
NoticeService noticeService;
@PostMapping("/select/{currentPage}/{size}")
R select(@PathVariable("currentPage") int currentPage, @PathVariable("size") int size, @RequestBody notice notice){
return noticeService.selectByPage(currentPage,size,notice);
}
@PostMapping("/lunch/{name}")
R lunch(@PathVariable("name")String name, @RequestBody notice notice){
return noticeService.insert(name,notice);
}
@PostMapping("/delete/{id}")
R delete(@PathVariable("id") Integer id){
return noticeService.delete(id);
}
}
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
