简要描述:
请求URL:
GET/plugin.hotel.frontend.hotel.goods.get-hotel-goods-by-title
参数:
参数名 |
是否必须 |
类型 |
说明 |
lng |
是 |
float |
经度 |
lat |
是 |
float |
纬度 |
city_name |
是 |
string |
城市名称 |
kwd |
否 |
string |
酒店名称/品牌/位置 搜索 |
entrance_time |
否 |
string |
入住时间 |
price |
否 |
int |
价格 |
star_rated |
否 |
int |
星级 |
category_id |
否 |
int |
酒店分类id |
page |
否 |
int |
酒店分页 |
返回示例:
正确时返回:
{
"result": 1,
"msg": "成功",
"data": {
"total": 2,
"per_page": 15,
"current_page": 1,
"last_page": 1,
"next_page_url": null,
"prev_page_url": null,
"from": 1,
"to": 2,
"data": [
{
"id": 1,
"mobile": "123",
"category_id": 1,
"hotel_name": "1123123",
"thumb": "http://www.web7.com/attachment/images/5/2019/01/WyCG5QCvXI7QQ7C7CxUCu6QXbu65q6.jpg",
"latitude": "39.915177",
"longitude": "116.403851",
"distance": 1885.3,
"unit": "km",
"average_score": "9.0",
"order_total": 0,
"address": {
"city": "广州市",
"detailed_address": "五道口"
},
"order_time": 1535466672,
"room_amount": 750,
"goods": [
{
"id": 2930,
"uniacid": 5,
"brand_id": 10,
"type": 1,
"status": 1,
"display_order": 0,
"title": "我讨厌",
"thumb": "images/5/2019/01/WyCG5QCvXI7QQ7C7CxUCu6QXbu65q6.jpg",
"thumb_url": "a:2:{i:0;s:51:\"images/5/2019/01/x3qYvUfvvUFIy4Uo63Z4HPvvudVpoY.jpg\";i:1;s:51:\"images/5/2019/01/ts4KKHnMeM3MKZ87EWhTupEHnwTs8P.jpg\";}",
"sku": "123",
"description": "",
"content": "",
"goods_sn": "123",
"product_sn": "123",
"market_price": "123.00",
"price": "123.00",
"cost_price": "123.00",
"stock": 123,
"reduce_stock_method": 0,
"show_sales": 0,
"real_sales": 0,
"weight": "123.00",
"has_option": 0,
"is_new": 1,
"is_hot": 0,
"is_discount": 0,
"is_recommand": 1,
"is_comment": 0,
"is_deleted": 0,
"created_at": "2019-01-23 10:45:13",
"deleted_at": null,
"updated_at": "2019-01-23 10:45:14",
"comment_num": 0,
"is_plugin": 0,
"plugin_id": 33,
"virtual_sales": 0,
"no_refund": 0,
"buyNum": 0,
"hotel_name": "1123123",
"hotel_id": 2,
"has_one_hotel_goods": {
"id": 3,
"goods_id": 2930,
"hotel_id": 2,
"created_at": "2019-01-23 10:45:13",
"updated_at": "2019-01-23 10:45:13",
"deleted_at": null,
"has_one_hotel": {
"id": 2,
"uniacid": 5,
"uid": 826,
"hotel_name": "1123123",
"thumb": "http://www.web7.com/attachment/images/5/2019/01/WyCG5QCvXI7QQ7C7CxUCu6QXbu65q6.jpg",
"banner_thumb": "http://www.web7.com/attachment/images/5/2019/01/cSHLlc1MnrhrYlA8usl8asnzMs1nni.jpg",
"category_id": 1,
"province_id": 440000,
"city_id": 440100,
"district_id": 440103,
"street_id": 440103002,
"address": "五道口",
"star_rated": 3,
"entrance_time": "23:45",
"departure_time": "11:40",
"user_uid": 1572,
"longitude": "116.403851",
"latitude": "39.915177",
"mobile": "123",
"username": "我喜欢你",
"password": "123",
"template_id": null,
"salers": "N;",
"hotel_introduce": "123",
"instructions": "123123123123",
"is_black": 0,
"created_at": "2019-01-16 19:21:45",
"updated_at": "2019-01-23 10:43:01",
"deleted_at": null,
"full_address": "广东省 广州市 荔湾区 五道口"
}
}
}
],
"full_address": "",
"has_one_category": {
"id": 1,
"name": "我讨厌",
"is_open": 1
}
}
]
}
}
错误时返回:
{
"result": 0,
"msg": "坐标错误",
"data": ""
}
or
{
"result": 0,
"msg": "城市不能为空",
"data": ""
}
or
{
"result": 0,
"msg": "没找到城市",
"data": ""
}
or
{
"result": 0,
"msg": "未找到酒店房间",
"data": ""
}
or
{
"result": 0,
"msg": "该酒店不在定位市",
"data": ""
}
返回参数说明:
参数名 |
类型 |
说明 |
id |
int |
酒店 id |
thumb |
string |
酒店图片 |
hotel_name |
string |
酒店名称 |
average_score |
string |
评分 |
distance |
float |
距离 |
unit |
string |
距离单位m/km |
order_time |
int |
最近预订时间 |
order_total |
int |
消费数 |
room_amount |
int |
房间金额 |
参数名 |
类型 |
说明 |
address |
obj |
酒店地址 |
city |
string |
城市 |
detailed_address |
string |
详细地址 |
参数名 |
类型 |
说明 |
has_one_category |
obj |
酒店所属分类 |
id |
int |
分类id |
name |
string |
分类名称 |
备注: