POST
/hotelApi/getHotelOrderDetail开放/回调获取订单详情 */
酒店 / 对外酒店接口
基本信息
- 接口状态前端在用 免鉴权
- 接口URLPOST
https://dscp-dev.hn12301.net/open-api/hotelApi/getHotelOrderDetail - 请求方式
POST - Content-Type
application/json - 暴露渠道开放/回调 前缀
/open-api - 名称来源源码注释
- 调用方已确认在用 · 湘工惠商城(1 个前端)
- 需求上下文
- 维护人 / 最后改动liuxu 2025-01-09
- 读写数据表
hotel_order_room、hotel_member_traveler、hotel_order、hotel_info、hotel_room_type、hotel_room_type_plan反查该表全部接口 → - 控制器
com.jxxx.dscp.api.controller.hotel.HotelApiController#getHotelOrderDetail - 源码位置
jxxx-dscp/dscp-service-business/src/main/java/com/jxxx/dscp/api/controller/hotel/HotelApiController.java:732 - 判定依据
请求参数
Header 请求参数
| 参数名 | 参数值 | 是否必填 | 参数类型 | 描述说明 |
|---|---|---|---|---|
| 无(渠道统一鉴权头见《认证方式》) | ||||
Query 请求参数
| 参数名 | 参数值 | 是否必填 | 参数类型 | 描述说明 |
|---|---|---|---|---|
| 无 | ||||
路径参数及说明
| 参数名 | 参数值 | 是否必填 | 参数类型 | 描述说明 |
|---|---|---|---|---|
| 无 | ||||
Body 请求参数
| 参数名 | 参数值 | 是否必填 | 参数类型 | 描述说明 |
|---|---|---|---|---|
| id | … | 是 | Long | id → hotel_room_type.id |
认证方式
响应参数
| 参数名 | 参数值 | 是否必填 | 参数类型 | 描述说明 |
|---|---|---|---|---|
| order | … | 否 | HotelOrder | |
| id | … | 否 | Long | 订单ID → hotel_room_type.id |
| orderNo | … | 否 | String | 订单编号 → hotel_order.order_no |
| channel | … | 否 | HotelChannel | 渠道 → hotel_order.channel 1=质慧游小程序 |
| merchantId | … | 否 | Long | 商户ID → hotel_room_type.merchant_id |
| shopId | … | 否 | Long | 商铺ID → hotel_room_type.shop_id |
| hotelId | … | 否 | Long | 酒店ID → hotel_room_type.hotel_id |
| roomTypeId | … | 否 | Long | 房型ID → hotel_order_room.room_type_id |
| planId | … | 否 | Long | 价格方案ID → hotel_order_room.plan_id |
| purchaseDate | … | 否 | Date | 购买日期 → hotel_order.purchase_date |
| checkInDate | … | 否 | Date | 入住日期 → hotel_order.check_in_date |
| checkOutDate | … | 否 | Date | 离店日期 → hotel_order.check_out_date |
| expectedArrivalTime | … | 否 | Date | 预计到店时间 → hotel_order.expected_arrival_time |
| actualCheckinTime | … | 否 | Date | 实际入住时间 → hotel_order.actual_checkin_time |
| actualCheckoutTime | … | 否 | Date | 实际离店时间 → hotel_order.actual_checkout_time |
| stayNights | … | 否 | Integer | 入住天数 → hotel_order.stay_nights |
| roomNum | … | 否 | Integer | 房间数量 → hotel_order_room.room_num |
| originalAmount | … | 否 | Integer | 订单原价(分) → hotel_order.original_amount |
| discountAmount | … | 否 | Integer | 优惠金额(分) → hotel_order.discount_amount |
| totalAmount | … | 否 | Integer | 订单应付金额(分) → hotel_order.total_amount |
| paidAmount | … | 否 | Integer | 已付金额(分) → hotel_order.paid_amount |
| couponId | … | 否 | String | 优惠券ID → hotel_order.coupon_id |
| couponAmount | … | 否 | Integer | 优惠券抵扣金额(分) → hotel_order.coupon_amount |
| guestId | … | 否 | String | 入住人姓名(关联traveId,多个用逗号分隔) → hotel_order.guest_id |
| guestNum | … | 否 | Integer | 入住人数 → hotel_order.guest_num |
| breakfastNum | … | 否 | Integer | 早餐份数 → hotel_order.breakfast_num |
| cancelType | … | 否 | Integer | 取消政策类型 → hotel_order.cancel_type |
| cancelTime | … | 否 | Date | 最晚取消时间 → hotel_order.cancel_time |
| memberId | … | 否 | Long | 下单用户ID → hotel_order.member_id |
| contactName | … | 否 | String | 联系人姓名 → hotel_order.contact_name |
| contactPhone | … | 否 | String | 联系人手机号 → hotel_order.contact_phone |
| remark | … | 否 | String | 备注 → hotel_order.remark |
| reviewStatus | … | 否 | Integer | 评价状态(0-未评价,1-已评价) → hotel_order.review_status |
| paymentStatus | … | 否 | HotelOrderPaymentStatus | 支付状态(0-未支付,1-部分支付,2-已支付,3-已退款,4-部分退款) → hotel_order.payment_status 0=未支付 1=部分支付 2=已支付 3=已退款 4=部分退款 5=退款中 6=退款失败 |
| status | … | 否 | HotelOrderStatus | 订单状态 → hotel_room_type.status 0=待支付 1=待确认 2=待入住 3=已入住 4=已退房 5=已取消 6=部分退房 |
| isDeleted | … | 否 | Boolean | 是否删除(0否 1是) → hotel_room_type.is_deleted |
| createdBy | … | 否 | Long | 创建人 → hotel_room_type.created_by |
| createdTime | … | 否 | Date | → hotel_room_type.created_time |
| updatedBy | … | 否 | Long | 修改人 → hotel_room_type.updated_by |
| updatedTime | … | 否 | Date | → hotel_room_type.updated_time |
| orderExpressTime | … | 否 | Date | 失效时间 → hotel_order.order_express_time |
| hotelInfo | … | 否 | HotelInfo | |
| id | … | 否 | Long | 酒店ID → hotel_room_type.id |
| merchantId | … | 否 | Long | 商户ID → hotel_room_type.merchant_id |
| shopId | … | 否 | Long | 店铺ID → hotel_room_type.shop_id |
| name | … | 否 | String | 酒店名称 → hotel_room_type.name |
| grade | … | 否 | HotelGrade | 酒店等级,1二星及以下/经济,2三星/舒适,3四星/高档,4五星/豪华,5奢华 → hotel_info.grade 1=二星及以下/经济 2=三星/舒适 3=四星/高档 4=五星/豪华 5=奢华 |
| type | … | 否 | HotelType | 酒店类型 → hotel_info.type 1=酒店 2=民宿 3=公寓 4=青年旅社 5=别墅 6=度假村 7=客栈 8=农家乐 9=汽车旅馆 10=露营地 99=其他 |
| status | … | 否 | Integer | 状态,0正常,1停用 → hotel_room_type.status |
| openingYear | … | 否 | Integer | 开业年份 → hotel_info.opening_year |
| roomCount | … | 否 | Integer | 房间数量 → hotel_info.room_count |
| phone | … | 否 | String | 联系电话 → hotel_info.phone |
| address | … | 否 | String | 详细地址 → hotel_info.address |
| landmark | … | 否 | String | 地标 → hotel_info.landmark |
| provinceId | … | 否 | Long | 省id → hotel_info.province_id |
| cityId | … | 否 | Long | 市id → hotel_info.city_id |
| districtId | … | 否 | Long | 区县id → hotel_info.district_id |
| longitude | … | 否 | BigDecimal | 经度 → hotel_info.longitude |
| latitude | … | 否 | BigDecimal | 纬度 → hotel_info.latitude |
| coverImage | … | 否 | String | 主图URL → hotel_room_type.cover_image |
| images | … | 否 | String | 轮播图URL,多个用逗号分隔 → hotel_room_type.images |
| tags | … | 否 | String | 酒店标签,多个用逗号分隔 → hotel_info.tags |
| locationTags | … | 否 | String | 位置描述标签,多个用逗号分隔 → hotel_info.location_tags |
| highlights | … | 否 | String | 酒店亮点(富文本) → hotel_info.highlights |
| isDeleted | … | 否 | Boolean | 是否删除(0否 1是) → hotel_room_type.is_deleted |
| createdBy | … | 否 | Long | 创建人ID → hotel_room_type.created_by |
| createdTime | … | 否 | Date | 创建时间 → hotel_room_type.created_time |
| updatedBy | … | 否 | Long | 更新人ID → hotel_room_type.updated_by |
| updatedTime | … | 否 | Date | 更新时间 → hotel_room_type.updated_time |
| roomType | … | 否 | HotelRoomType | |
| id | … | 否 | Long | 房型ID → hotel_room_type.id |
| merchantId | … | 否 | Long | 所属商户id,关联merchant表id → hotel_room_type.merchant_id |
| shopId | … | 否 | Long | 所属商铺id → hotel_room_type.shop_id |
| hotelId | … | 否 | Long | 所属酒店ID → hotel_room_type.hotel_id |
| name | … | 否 | String | 房型名称 → hotel_room_type.name |
| basePrice | … | 否 | Integer | 基本价格 → hotel_room_type.base_price |
| coverImage | … | 否 | String | 主图URL → hotel_room_type.cover_image |
| images | … | 否 | String | 房型图片,JSON格式存储多张图片URL → hotel_room_type.images |
| status | … | 否 | Integer | 状态 → hotel_room_type.status |
| sort | … | 否 | Integer | 显示顺序 → hotel_room_type.sort |
| roomTypeArea | … | 否 | BigDecimal | 面积 → hotel_room_type.room_type_area |
| floorInfo | … | 否 | String | 楼层信息 → hotel_room_type.floor_info |
| windowType | … | 否 | WindowType | 窗户类型 → hotel_room_type.window_type 1=无窗 2=部分有窗 3=全部有窗 |
| bedInfo | … | 否 | String | 床型 → hotel_room_type.bed_info |
| guests | … | 否 | Integer | 可住人数 → hotel_room_type.guests |
| smoking | … | 否 | Integer | 是否禁烟(0否 1是) → hotel_room_type.smoking |
| networkType | … | 否 | NetworkType | 网络类型 → hotel_room_type.network_type 1=免费WiFi 2=收费WiFi 3=无网络 |
| extraBedAllowed | … | 否 | Integer | 是否可加床(0否 1是) → hotel_room_type.extra_bed_allowed |
| extraBedDesc | … | 否 | String | 加床说明 → hotel_room_type.extra_bed_desc |
| isDeleted | … | 否 | Boolean | 是否删除(0否 1是) → hotel_room_type.is_deleted |
| createdBy | … | 否 | Long | 创建人ID → hotel_room_type.created_by |
| createdTime | … | 否 | Date | 创建时间 → hotel_room_type.created_time |
| updatedBy | … | 否 | Long | 更新人ID → hotel_room_type.updated_by |
| updatedTime | … | 否 | Date | 更新时间 → hotel_room_type.updated_time |
| roomList | … | 否 | List<HotelOrderRoom> | |
| id | … | 否 | Long | 主键ID → hotel_room_type.id |
| orderId | … | 否 | Long | 订单ID → hotel_order_room.order_id |
| roomTypeId | … | 否 | Long | 房型ID → hotel_order_room.room_type_id |
| planId | … | 否 | Long | 价格方案ID → hotel_order_room.plan_id |
| priceCalendarId | … | 否 | Long | 价格日历ID → hotel_order_room.price_calendar_id |
| roomName | … | 否 | String | 房型名称 → hotel_order_room.room_name |
| roomDate | … | 否 | Date | 房间日期 → hotel_order_room.room_date |
| roomNum | … | 否 | Integer | 房间数量 → hotel_order_room.room_num |
| roomPrice | … | 否 | Integer | 每天单房间实际支付价(分).去掉了每天每间房的优惠券 → hotel_order_room.room_price |
| totalPrice | … | 否 | Integer | 每天所有房间实际支付总价(分).去掉了每天的优惠券 → hotel_order_room.total_price |
| status | … | 否 | Integer | 状态(0-正常,1-已退房) → hotel_room_type.status |
| checkedOutNum | … | 否 | Integer | 已退房数量 → hotel_order_room.checked_out_num |
| isDeleted | … | 否 | Boolean | 是否删除(0否 1是) → hotel_room_type.is_deleted |
| createdBy | … | 否 | Long | 创建人 → hotel_room_type.created_by |
| createdTime | … | 否 | Date | → hotel_room_type.created_time |
| updatedBy | … | 否 | Long | 修改人 → hotel_room_type.updated_by |
| updatedTime | … | 否 | Date | → hotel_room_type.updated_time |
| plan | … | 否 | HotelRoomTypePlan | |
| id | … | 否 | Long | → hotel_room_type.id |
| hotelId | … | 否 | Long | 酒店ID → hotel_room_type.hotel_id |
| roomTypeId | … | 否 | Long | 房型ID → hotel_order_room.room_type_id |
| name | … | 否 | String | 方案名称 → hotel_room_type.name |
| autoConfirm | … | 否 | Integer | 是否自动确认 → hotel_room_type_plan.auto_confirm |
| breakfast | … | 否 | Integer | 是否含早 → hotel_room_type_plan.breakfast |
| basePrice | … | 否 | Integer | 底价(分) → hotel_room_type.base_price |
| salePrice | … | 否 | Integer | 卖价(分) → hotel_room_type_plan.sale_price |
| stockType | … | 否 | StockType | 库存类型 → hotel_room_type_plan.stock_type 0=无限 1=共享 2=独立 |
| stockNum | … | 否 | Integer | 数量 → hotel_room_type_plan.stock_num |
| cancelType | … | 否 | CancelType | 取消类型 → hotel_order.cancel_type 1=免费取消 2=不可取消 3=有条件取消 |
| cancelDays | … | 否 | Integer | 提前取消天数,0表示入住当天 → hotel_room_type_plan.cancel_days |
| cancelHours | … | 否 | String | 取消截止时间点,如18:00 → hotel_room_type_plan.cancel_hours |
| sort | … | 否 | Integer | 排序号 → hotel_room_type.sort |
| status | … | 否 | Integer | 状态 → hotel_room_type.status |
| isDeleted | … | 否 | Boolean | 是否删除(0否 1是) → hotel_room_type.is_deleted |
| createdBy | … | 否 | Long | 创建人ID → hotel_room_type.created_by |
| createdTime | … | 否 | Date | 创建时间 → hotel_room_type.created_time |
| updatedBy | … | 否 | Long | 更新人ID → hotel_room_type.updated_by |
| updatedTime | … | 否 | Date | 更新时间 → hotel_room_type.updated_time |
| guestName | … | 否 | String |
响应示例
成功响应示例
{
"errcode": 0,
"errmsg": "",
"data": {
"order": "…",
"id": "1",
"orderNo": "\"string\"",
"channel": "1",
"merchantId": "1",
"shopId": "1",
"hotelId": "1",
"roomTypeId": "1",
"planId": "1",
"purchaseDate": "\"2026-01-01 00:00:00\"",
"checkInDate": "\"2026-01-01 00:00:00\"",
"checkOutDate": "\"2026-01-01 00:00:00\""
}
}附录 · 实现细节
调用链 / 数据表 / 调用点证据 / 源码注释 / 逻辑摘要
涉及数据表:hotel_order_room、hotel_member_traveler、hotel_order、hotel_info、hotel_room_type、hotel_room_type_plan 反查全部引用接口 →
- HotelApiController#getHotelOrderDetail
- HotelApiService#getHotelOrderDetail(HotelApiServiceImpl)
- HotelOrderRoomService#queryList(HotelOrderRoomServiceImpl)
- HotelOrderRoomMapper#queryList
- HotelMemberTravelerService#queryList(HotelMemberTravelerServiceImpl)
- HotelMemberTravelerMapper#queryList
逻辑摘要:查询详情(hotelApiService.getHotelOrderDetail)
旧站环境备注:pro:(仓库 .env.pro 指向 uat;生产域名未确认,此处沿用 uat 主机示意)
调用点证据
xghmall/common/http.api.js:71湘工惠商城 · getHotelOrderDetailUrl