import request from '@/utils/request';

const baseUrl = '/platform/cursor/equipment';

export function getCursorEquipmentList(params) {
  return request({
    url: `${baseUrl}/list`,
    method: 'get',
    params,
  });
}

export function getCursorEquipmentDetail(id) {
  return request({
    url: `${baseUrl}/detail/${id}`,
    method: 'get',
  });
}

export function addCursorEquipment(data) {
  return request({
    url: `${baseUrl}/add`,
    method: 'post',
    data,
  });
}

export function updateCursorEquipment(data) {
  return request({
    url: `${baseUrl}/update`,
    method: 'post',
    data,
  });
}

export function deleteCursorEquipment(id) {
  return request({
    url: `${baseUrl}/delete/${id}`,
    method: 'post',
  });
}

export function activateCursorEquipment(data) {
  return request({
    url: `${baseUrl}/activate`,
    method: 'post',
    data,
  });
}

export function getCursorEquipmentActivationRecords(params) {
  return request({
    url: `${baseUrl}/activationRecords`,
    method: 'get',
    params,
  });
}

export function getCursorEquipmentExtractRecords(params) {
  return request({
    url: `${baseUrl}/extractRecords`,
    method: 'get',
    params,
  });
}
