const require_runtime = require("../../../../_virtual/_rolldown/runtime.js");
let dayjs = require("dayjs");
dayjs = require_runtime.__toESM(dayjs);
require("@pisell/utils");
//#region src/plus/pisellReservation/components/bookingDetailModal/bookingDetailFromRaw.ts
/**
* 将平面图点击得到的宿主 booking 原始行解析为详情弹窗视图模型（防御性读取，缺字段则省略对应区块）。
* 人数、起止时刻、迟到/超时、倒计时、进度等与 {@link rawToBooking} / RoomCard 一致。
*/
/** 预约 raw 是否已为 fully paid（优先 `order.payment_status`，否则顶层 `payment_status`） */
function isBookingRawOrderPaid(raw) {
	const order = raw.order;
	const fromOrder = order === null || order === void 0 ? void 0 : order.payment_status;
	const fromTop = raw.payment_status;
	const v = fromOrder != null && String(fromOrder).trim() !== "" ? fromOrder : fromTop;
	return String(v !== null && v !== void 0 ? v : "").trim().toLowerCase() === "paid";
}
//#endregion
exports.isBookingRawOrderPaid = isBookingRawOrderPaid;
