import request from '@/utils/request';

export async function getTosUser(params) {
  return request('/tos/owner/getuser', {
    method: 'POST',
    data: params,
  });
}

export async function getOwner(params) {
  return request('/tos/tosOwner/getAll', {
    method: 'POST',
    data: params,
  });
}

export async function getOwnerDetail(params) {
  return request('/tos/tosOwner/getDetail', {
    method: 'POST',
    data: params,
  });
}
export async function saveOwner(params) {
  return request('/tos/tosOwner/save', {
    method: 'POST',
    data: params,
  });
}

export async function updateOwner(params) {
  return request('/tos/tosOwner/info/update', {
    method: 'POST',
    data: params,
  });
}

export async function getOwnerQr(params) {
  return request('/tos/life/community/qr/get', {
    method: 'POST',
    data: params,
  });
}

export async function deleteUnit(params) {
  return request('/tos/life/community/account/unit/del', {
    method: 'POST',
    data: params,
  });
}
export async function getDetailCommunityList(params) {
  return request('/tos/tosOwner/getDetail/community', {
    method: 'POST',
    data: params,
  });
}

export async function getDetailUnitList(params) {
  return request('/tos/tosOwner/getDetail/unit', {
    method: 'POST',
    data: params,
  });
}


export async function delAdvertisement(params) {
  return request('/api/ad/del', {
    method: 'POST',
    data: params,
  });
}

export async function saveAdvertisement(params) {
  return request('/api/ad/save', {
    method: 'POST',
    data: params,
  });
}

export async function quitAndUserAd(params) {
  return request('/api/ad/quitAndUserAd', {
    method: 'POST',
    data: params,
  });
}

export async function uploadApk(params) {
  return request('/api/uploadApk/apk', {
    method: 'POST',
    data: params,
  });
}

export async function checkVideo(params) {
  return request('/api/uploadApk/prview', {
    method: 'POST',
    data: params,
  });
}
