import request from '@/utils/request'

// 获取模板列表
export function getThemeList() {
  return request({
    url: '/platform/theme',
    method: 'get'
  })
}

// 切换模板
export function switchTheme(data) {
  return request({
    url: '/platform/theme/switch',
    method: 'post',
    data
  })
}

// 获取模板数据
export function getThemeData(params) {
  return request({
    url: '/platform/theme/data',
    method: 'get',
    params
  })
}

// 保存模板数据
export function saveThemeData(data) {
  return request({
    url: '/platform/theme/data',
    method: 'post',
    data
  })
}
