查表的数据

package com.atguigu.eduservice.controller;import com.atguigu.eduservice.entity.EduTeacher;import com.atguigu.eduservice.service.EduTeacherService;import org.springframework.beans.factory.annotation.Autowired;import org.springframework.web.bind.annotation.GetMapping;import org.springframework.web.bind.annotation.RequestMapping;import org.springframework.web.bind.annotation.RestController;import java.util.List;/** *

* 讲师 前端控制器 *

* * @author testjava * @since 2022-06-23 */@RestController@RequestMapping(“/eduservice/teacher”)public class EduTeacherController { //把service注入 @Autowired private EduTeacherService teacherService;// 1 查询讲师表所有数据 //rest风格 @GetMapping(“findAll”) public List findAllTeacher(){ //调用service方法实现查询所有的讲师 List list = teacherService.list(null); return list; }}

郑重声明:本文内容及图片均整理自互联网,不代表本站立场,版权归原作者所有,如有侵权请联系管理员(admin#wlmqw.com)删除。
(0)
用户投稿
上一篇 2022年6月27日
下一篇 2022年6月27日

相关推荐

联系我们

联系邮箱:admin#wlmqw.com
工作时间:周一至周五,10:30-18:30,节假日休息