package com.ym.mec.education.controller;

import com.alibaba.fastjson.JSONObject;
import com.ym.mec.education.base.BaseResponse;
import com.ym.mec.education.service.ISubjectService;
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-10-01 11:25
 */
@RestController
@RequestMapping("api/subject")
@Api(tags = "声部")
public class SubjectController {

    @Autowired
    private ISubjectService subjectService;

    @PostMapping("/list")
    @ApiOperation("声部列表")
    public BaseResponse list(@RequestBody JSONObject jsonObject) {
        return BaseResponse.success(subjectService.list());
    }
}
