import request from '@/utils/request'


export function searchTemplateCategory(data) {
  return request({
    url: '/template/category/search',
    method: 'post',
    data,
    timeout:0
  })
}
/* 获取全部分类接口 /template/category/selcetList*/
export function selcetList(data) {
  return request({
    url: '/template/category/selcetList',
    method: 'post',
    data
  })
}



export function getAllCategory(data) {
  return request({
    url: '/template/category/all',
    method: 'post',
    data
  })
}



export function createTemplateCategory(data) {
  return request({
    url: '/template/category/create',
    method: 'post',
    data
  })
}



export function updateTemplateCategory(data) {
  return request({
    url: '/template/category/update',
    method: 'post',
    data
  })
}


export function getTemplateCategoryInfo(data) {
  return request({
    url: '/template/category/info',
    method: 'post',
    data
  })
}



export function deleteTemplateCategory(data) {
  return request({
    url: '/template/category/delete',
    method: 'post',
    data
  })
}


/* 模块列表 /template/pageTemplate*/
export function pageTemplate(data) {
  return request({
    url: '/template/pageTemplate',
    method: 'post',
    data
  })
}

export function searchTemplate(data) {
  return request({
    url: '/template/search',
    method: 'post',
    data
  })
}



export function getTemplateInfo(data) {
  return request({
    url: '/template/info',
    method: 'post',
    data
  })
}




export function deleteTemplate(data) {
  return request({
    url: '/template/delete',
    method: 'post',
    data
  })
}




export function createTemplate(data) {
  return request({
    url: '/template/create',
    method: 'post',
    data
  })
}




export function updateTemplate(data) {
  return request({
    url: '/template/update',
    method: 'post',
    data
  })
}


/*template/category/allList  */


export function getAllList(data) {
  return request({
    url: '/template/category/allList',
    method: 'post',
    data
  })
}

/* 获取树状分类  /template/category/treeCategory */

export function treeCategory(data) {
  return request({
    url: '/template/category/treeCategory',
    method: 'post',
    data
  })
}

/* 获取模块点位 */

export function extract_locations(data) {
  return request({
    url: '/template/extract_and_save_locations',
    method: 'post',
    data
  })
}