package com.microservices.pms.common.controller;

import com.microservices.common.core.web.controller.BaseController;
import com.microservices.common.core.web.domain.AjaxResult;
import com.microservices.common.security.utils.SecurityUtils;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author otto
 */
@RestController
@Api(tags = "项目管理-公共接口", hidden = true)
@RequestMapping("/common")
public class CommonController extends BaseController {
    /**
     * 查询项目管理企业列表
     */
    @GetMapping("/permissions")
    @ApiOperation(value = "获取接口权限列表")
    public AjaxResult list() {
        return success(SecurityUtils.getAllPermissions("com.microservices.pms.*.controller"));
    }
}
