import { request } from 'umi';

export async function getTopGoods(data) {
  return request(`/kitchen/api​/member-analysis​/top-goods`, {
    method: 'Post',
    data: data,
  });
}

//新增会员
export async function getnewMember(data) {
  return request(`/kitchen/api/member-analysis/newm-member`, {
    method: 'Post',
    data: data,
  });
}

//销售额
export async function getSalesVolume() {
  return request(`​/kitchen/api​/member-analysis​/sales-volume`, {
    method: 'Get',
  });
}

///销售时间点
export async function getSalesTimePoint(data) {
  return request(`​/kitchen/api/member-analysis/sales-time-point`, {
    method: 'POST',
    data: data,
  });
}

///会员回购率
export async function GetRepurchasing(data) {
  return request(`/kitchen​​/api​/member-analysis​/repurchasing`, {
    method: 'POST',
    data: data,
  });
}
///会员回购率
export async function GetSaleSamountAnalysis(data) {
  return request(`/kitchen/api​/member-analysis​/sale-samount-analysis`, {
    method: 'GET',
  });
}

///订单分析
export async function GetOrderAnalysis(data) {
  return request(`​/kitchen/api​/member-analysis​/order-analysis`, {
    method: 'POST',
    data: data,
  });
}
