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

import com.yida.data.attendance.dto.ListStudentResultDTO;
import com.yida.data.attendance.service.EduAttendanceResultService;
import com.yida.data.attendance.vo.ResultDetailVO;
import com.yida.data.common.core.common.ResultBean;
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/result")
public class H5EduAttendanceResultController {

    private final EduAttendanceResultService eduAttendanceResultService;

    @ApiOperation("查询考勤记录")
    @GetMapping("/listStudentResult")
    public ResultBean<List<ResultDetailVO>> listStudentResult(ListStudentResultDTO dto) {
        return ResultBean.buildSuccess(eduAttendanceResultService.listStudentResultDetail(dto));
    }
}
