package com.community.huiju.controller;

import com.community.commom.mode.ResponseBean;
import com.community.huiju.service.IToSysMenuService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/")
@RefreshScope
@Api(value = "菜单 API", description = "菜单 API")
public class SysMenuController {

    @Autowired
    private IToSysMenuService iToSysMenuService;

    @RequestMapping(value = "/menu/list", method = RequestMethod.GET)
    @ApiOperation(value = "查询所有菜单", notes = "查询所有菜单")
    public ResponseBean getAll() {
        ResponseBean responseBean = iToSysMenuService.getMenuAll();
        return responseBean;
    }

}
