package com.keao.edu.controller;

import com.keao.edu.common.controller.BaseController;
import com.keao.edu.common.entity.HttpResponseResult;
import com.keao.edu.common.page.PageInfo;
import com.keao.edu.user.entity.ExamSong;
import com.keao.edu.user.page.ExamSongQueryInfo;
import com.keao.edu.user.service.ExamSongService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
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;

/**
 * @Author Joburgess
 * @Date 2020.06.16
 */
@RestController
@RequestMapping("examSong")
@Api(tags = "曲库服务")
public class ExamSongController extends BaseController {

    @Autowired
    private ExamSongService examSongService;

    @ApiOperation("学生端分页查询考级曲库")
    @GetMapping(value = "/queryPage")
    public HttpResponseResult<PageInfo<ExamSong>> queryPage(ExamSongQueryInfo queryInfo) {
        return succeed(examSongService.querySongPage(queryInfo));
    }

}
