import request from '@/utils/request'

// 创建报价单跟进日志
export function createOfferLog(data) {
  return request({
    url: '/ecw/offer-log/create',
    method: 'post',
    data: data
  })
}

// 更新报价单跟进日志
export function updateOfferLog(data) {
  return request({
    url: '/ecw/offer-log/update',
    method: 'put',
    data: data
  })
}

// 删除报价单跟进日志
export function deleteOfferLog(id) {
  return request({
    url: '/ecw/offer-log/delete?id=' + id,
    method: 'delete'
  })
}

// 获得报价单跟进日志
export function getOfferLog(id) {
  return request({
    url: '/ecw/offer-log/get?id=' + id,
    method: 'get'
  })
}

// 获得报价单跟进日志分页
export function getOfferLogPage(query) {
  return request({
    url: '/ecw/offer-log/page',
    method: 'get',
    params: query
  })
}

// 导出报价单跟进日志 Excel
export function exportOfferLogExcel(query) {
  return request({
    url: '/ecw/offer-log/export-excel',
    method: 'get',
    params: query,
    responseType: 'blob'
  })
}
