//房东端  民宿老板
import request from '@/utils/request'

/**
 * 民宿详情
 * @param {*} id 
 * @returns 
 */
 export const getHotelDetail = (id) => request(`/taHotel/${id}`)


 
/**
 * 查询指定名宿的账户
 * @param {*} params 
 * @returns 
 */
 export const getNowHotelManage = (id,params) => request(`/hotel/manage/${id}`, { params })


/**
 * 查询民宿老板的所有名宿列表
 * @param {*} params 
 * @returns 
 */
 export const getHotelManage = (params) => request('/hotel/manage/index', { params })

/**
 * 查询指定名宿的账户流水
 * @param {*} params 
 * @returns 
 */
 export const getAccountLogList = (id) => request(`/hotel/account/${id}/log`)



 /**
 * 删除房源
 * @param {*} data 
 * @returns 
 */
  export const deleteRoom = (id) => request(`/taRoom/${id}`, { method: 'delete'})


/**
 * 房源详情
 * @param {*} id 
 * @returns 
 */
export const getRoomDetail = (id) => request(`/taRoom/${id}`)
/**
 * 保存房源
 * @param {*} data 
 * @returns 
 */
 export const saveRoom = (data) => request('/taRoom', { method: 'post', data })