import request from '@/utils/request'

// 查询问诊订单列表
export function listinquiryOrder(query) {
  return request({
    url: '/his/inquiryOrder/list',
    method: 'get',
    params: query
  })
}
// 查询问诊订单详细
export function msglist(query) {
  return request({
    url: '/his/inquiryOrder/msgList',
    method: 'get',
    params: query
  })
}

export function getinquiryOrder(orderId) {
  return request({
    url: '/his/inquiryOrder/' + orderId,
    method: 'get'
  })
}
export function sendMsg(orderId) {
  return request({
    url: '/his/inquiryOrder/sendMsg/' + orderId,
    method: 'get'
  })
}

// 新增问诊订单
export function addinquiryOrder(data) {
  return request({
    url: '/his/inquiryOrder',
    method: 'post',
    data: data
  })
}
export function cancelOrder(data) {
  return request({
    url: '/his/inquiryOrder/cancelOrder',
    method: 'post',
    data: data
  })
}
export function refundOrder(data) {
  return request({
    url: '/his/inquiryOrder/refundOrder',
    method: 'post',
    data: data
  })
}


// 修改问诊订单
export function updateinquiryOrder(data) {
  return request({
    url: '/his/inquiryOrder',
    method: 'put',
    data: data
  })
}
// 修改问诊订单
export function editStatus(data) {
  return request({
    url: '/his/inquiryOrder/editStatus',
    method: 'put',
    data: data
  })
}
// 删除问诊订单
export function delinquiryOrder(orderId) {
  return request({
    url: '/his/inquiryOrder/' + orderId,
    method: 'delete'
  })
}
export function logList(orderId) {
  return request({
    url: '/his/inquiryOrder/logList/' + orderId,
    method: 'get'
  })
}
// 导出问诊订单
export function exportinquiryOrder(query) {
  return request({
    url: '/his/inquiryOrder/export',
    method: 'get',
    params: query
  })
}

export function exportMessageFeedback(query) {
  return request({
    url: '/his/inquiryOrder/messageFeedbackExport',
    method: 'get',
    params: query
  })
}
