const { request } = require('../../../api/request')
/**
 * 订单统计
 * @returns {Promise<*>}
 */
export const fetchOrderCount = () => request({
  url: '/api/user/order/count',
  method: 'POST',
  showLoading: false
}, false)

/**
 * 根据起始终点获取行程信息
 * @returns {Promise<*>}
 */
export const fetchDistanceInfo = (formData) => request({
  url: '/api/user/order/distance/info',
  method: 'POST',
  data: {
    ...formData
  },
  showLoading: true
}, true)
