import { BaseDefine, MultipleQuery, MultipleResult } from './base'

/** 角色管理 */
export namespace Role {
  /** role api  */
  interface RawRole {
    code: ROLE
    roleName: string
    updateTime: string
    updaterName: string
  }

  type GetRoleList = BaseDefine<{ role?: ROLE }, RawRole[]>
  type GetAllRoleList = BaseDefine<{ role?: ROLE }, RawRole[]>
  type GetRolePrivilege = BaseDefine<{ role: ROLE }, any>

  type SetRolePrivilege = BaseDefine<{ role: ROLE; privilegeCodes: string[] }>

  /** role api end */

  export interface ApiMap {
    getRoleList: GetRoleList
    getAllRoleList: GetAllRoleList
    getRolePrivilege: GetRolePrivilege
    setRolePrivilege: SetRolePrivilege
    nomakerRoleList: any
  }
}
