package com.yida.data.user.controller.h5;

import com.yida.data.common.core.common.ResultBean;
import com.yida.data.user.service.EduTeacherDeptService;
import com.yida.data.user.vo.TeacherClassVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import java.util.List;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Api(tags = "教师-前台")
@RequiredArgsConstructor
@RestController
@RequestMapping("/h5/teacher")
public class H5EduTeacherController {

    private final EduTeacherDeptService eduTeacherDeptService;

    @ApiOperation("查询教师管辖的班级(查询班主任、任课老师)")
    @GetMapping("/listTeacherClass")
    public ResultBean<List<TeacherClassVO>> listTeacherClass(Long teacherId) {
        return ResultBean.buildSuccess(eduTeacherDeptService.listTeacherClass(teacherId));
    }
}
