import request from '@/utils/request'
import { parseStrEmpty } from "@/utils/ruoyi"


/**
 * 角色列表查询
 * @param {*} query 
 * @returns 
 */
export function queryAll(query) {
  return request({
    url: '/console/role/queryAll',
    method: 'get',
    params: query
  })
}

/*
  * 角色列表查询 
  * @param {*} query
  * @returns
  */
export function query(data) {
  return request({
    url: '/console/role/query',
    method: 'post',
    data: data
  })
}


export function initEdit(data) {
  return request({
    url: '/console/role/initEdit',
    method: 'post',
    data: data
  })
}

export function add(data) {
  return request({
    url: '/console/role/add',
    method: 'post',
    data: data
  })
}


export function modify(data) {
  return request({
    url: '/console/role/modify',
    method: 'post',
    data: data
  })
}


export function del(data) {
  return request({
    url: '/console/role/del',
    method: 'post',
    data: data
  })
}


export function checkNameExit(data) {
  return request({
    url: '/console/role/checkNameExit',
    method: 'post',
    data: data
  })
}