package com.ym.mec.education.controller;

import com.ym.mec.education.base.PageResponse;
import com.ym.mec.education.req.TeacherLeaveRecordReq;
import com.ym.mec.education.service.ITeacherLeaveRecordService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @program: mec
 * @description: 老师考勤
 * @author: xw
 * @create: 2019-09-29 17:10
 */
@RestController
@RequestMapping("api/teacherLeaveRecord")
@Api(tags = "老师请假记录")
public class TeacherLeaveRecordController {

    @Autowired
    private ITeacherLeaveRecordService teacherLeaveRecordService;

    @PostMapping("/list")
    @ApiOperation("老师请假记录列表")
    public PageResponse list(@RequestBody TeacherLeaveRecordReq teacherLeaveRecordReq) {
        return teacherLeaveRecordService.getPage(teacherLeaveRecordReq);
    }
}
