import http from '@/utils/request'
export const apiCreateTravelAgency = (params) => {
  return http.post('/travelAgency/createTravelAgency', params)
}
export const apiDeleteTravelAgency = (params) => {
  return http.post('/travelAgency/deleteTravelAgency', params)
}
export const apiGetTravelAgencyList = (params) => {
  return http.post('/admin/otaSource', params)
}
export const apiUpdateTravelAgency = (params) => {
  return http.post('/travelAgency/updateTravelAgency', params)
}
export const apiAgencyStatistic = (params) => {
  return http.post('/travelAgency/getTravelAgencyStatistics', params)
}
export const getTravelAgencyCashStatistics = (params) => {
  return http.post('/travelAgency/getTravelAgencyCashStatistics', params)
}
export const apiAddGuide = (params) => {
  return http.post('/guide/addGuide', params)
}
export const apiDeleteGuide = (params) => {
  return http.post('/guide/deleteGuide', params)
}
export const apiGetGuideList = (params) => {
  return http.post('/guide/getGuideList', params)
}
export const apiUpdateGuide = (params) => {
  return http.post('/guide/updateGuide', params)
}
export const getSingleGuide = (id) => {
  return http.post(`guide/${id}`)
}
export const apiGuideStatistics = (params) => {
  return http.post('/guide/getGuideStatistics', params)
}
export const addGuideFee = (params) => {
  return http.post('/guide/addGuideFee', params)
}

// 旅行社预订
export function agencyPreOrder (params) {
  return http.post('/travelAgency/travelAgencyPreorder', params)
}

// 旅行社预订编辑
export function editAgencyPreOrder (params) {
  return http.post('/travelAgency/editTravelAgencyPreorder', params)
}
// 导出旅行社售票统计
export function exportTravelAgencyStatistics (params) {
  return http.post('exportMission/exportTravelAgencyStatistics', params)
}
// 导出导游售票统计
export function exportGuideStatistics (params) {
  return http.post('exportMission/exportGuideStatistics', params)
}

// 旅行社预订订单查询
export function getAgencyPreOrderList (params) {
  return http.post('/travelAgency/getTravelAgencyPreorderList', params)
}

// 旅行社预订订单查询
export function getTravelAgencyPreorder (id) {
  return http.post(`/exportMission/travelAgencyPreorder/${id}`)
}

// 旅行社预订订单编辑记录
export function getTravelAgencyPreorderUpdateLog (num) {
  return http.post(`/travelAgency/getTravelAgencyPreorderUpdateLog`, {
    keyWords1: num
  })
}

// 订单审核
export function preOrderAudit (params) {
  return http.post('/travelAgency/travelAgencyPreorderAudit', params)
}

// 旅行社预付款充值
export function addTravelAgencyPrepayment (params) {
  return http.post('/travelAgency/addTravelAgencyPrepayment', params)
}

// 旅行社交易记录
export function getTravelAgencyPrepaymentLog (params) {
  return http.post('/travelAgency/getTravelAgencyPrepaymentLog', params)
}

// 旅行社预付款统计-查询
export function getAgencyAmountFlow (params) {
  return http.post('/travelAgency/getAgencyAmountFlow', params)
}

// 旅行社预付款统计-导出
export function exportAgencyAmount (params) {
  return http.post('/exportMission/exportAgencyAmount', params)
}

// 已审核预订单作废
export function travelAgencyPreorderCancel (params) {
  return http.post('/travelAgency/travelAgencyPreorderCancel', params)
}
