import request from '@/utils/request'

// 查询dashboard抓取数据列表
export function listDashboarddata(query) {
  return request({
    url: '/aspen/dashboarddata/list',
    method: 'get',
    params: query
  })
}

// 查询最后一条dashboard抓取数据
export function selectLast(query) {
  return request({
    url: '/aspen/dashboarddata/selectLast',
    method: 'get',
    params: query
  })
}

// 查询月度dashboard抓取数据
export function selectMonth(query) {
  return request({
    url: '/aspen/dashboardday/month',
    method: 'get',
    params: query
  })
}

// 查询dashboard抓取数据详细
export function getDashboarddata(id) {
  return request({
    url: '/aspen/dashboarddata/' + id,
    method: 'get'
  })
}

// 新增dashboard抓取数据
export function addDashboarddata(data) {
  return request({
    url: '/aspen/dashboarddata',
    method: 'post',
    data: data
  })
}

// 修改dashboard抓取数据
export function updateDashboarddata(data) {
  return request({
    url: '/aspen/dashboarddata',
    method: 'put',
    data: data
  })
}

// 删除dashboard抓取数据
export function delDashboarddata(id) {
  return request({
    url: '/aspen/dashboarddata/' + id,
    method: 'delete'
  })
}

// 导出dashboard抓取数据
export function exportDashboarddata(query) {
  return request({
    url: '/aspen/dashboarddata/export',
    method: 'get',
    params: query
  })
}
