/****************************** 功能资源管理 ************************************ */
import request from "@/utils/request"

const baseUrl = "/authsvr/v2/appfuninfo"
export const tableUrl = baseUrl + "/search"
export function save(data) {
    return request({
        url: `${baseUrl}/save`,
        method: "POST",
        data
    })
}
export function update(data) {
    return request({
        url: `${baseUrl}/update`,
        method: "PUT",
        data
    })
}
export function detail(id) {
    return request({
        url: `${baseUrl}/` + id,
        method: "GET"
    })
}
export function del(id) {
    return request({
        url: `${baseUrl}/` + id,
        method: "DELETE"
    })
}

export function getRoleMenu(roleId) {
    return request({
        url: `${baseUrl}/menuTree?roleId=` + roleId,
        method: "GET"
    })
}
