import { fetch, post, ApiResponse } from './index'

export function queryDataScopeTree(params = {}): Promise<ApiResponse<any[]>> {
  return fetch({ url: '/upms/data-scope/tree', params })
}

export function queryDataScopeTreeSelected(params = {}): Promise<ApiResponse<any[]>> {
  return fetch({ url: '/upms/data-scope/tree/selected', params })
}

export function createDataScopeAuth(params = {}): Promise<ApiResponse<any>> {
  return post({ url: '/upms/data-scope/auth/create', params })
}
