{"photos":null,"status":1,"msg":"","html":"\u003cdiv class=\"hotel-tit\"\u003e客房预订\u003c/div\u003e\r\n\u003clink rel=\"stylesheet\" href=\"/templates/hys_cn/css/sj12.2/public.css\" /\u003e\r\n\u003clink rel=\"stylesheet\" href=\"/templates/hys_cn/css/sj12.2/main.css\" /\u003e\r\n\u003clink rel=\"stylesheet\" href=\"/static/css/mobiscroll.css\"\u003e\r\n\u003c!--start 客房列表--\u003e\r\n\u003cdiv class=\"roomList\"\u003e\r\n \u003ch3 class=\"listTitle\"\u003e\u003ca href=\"javascript:void(0);\" class=\"tabTitle on\"\u003e房型列表\u003c/a\u003e\u003c/h3\u003e\r\n \u003cdiv class=\"listBox\"\u003e\r\n \u003cp class=\"dateSelect\"\u003e\r\n \r\n \r\n \u003clabel\u003e入住\u003c/label\u003e\u003cinput type=\"text\" data-time=\u00272021-06-17\u0027 id=\"startDate\" /\u003e\r\n \u003clabel\u003e退房\u003c/label\u003e\u003cinput type=\"text\" data-time=\u00272021-06-18\u0027 id=\"endDate\" /\u003e\r\n \u003c/p\u003e\r\n \u003ctable id=\"roomTable\" class=\"table\"\u003e\r\n \u003cthead\u003e\r\n \u003ctr\u003e\r\n \u003cth class=\"col1\"\u003e房型\u003c/th\u003e\r\n \u003cth class=\"col2\"\u003e配套设施\u003c/th\u003e\r\n \u003cth class=\"col3\"\u003e房价\u003c/th\u003e\r\n \u003cth class=\"col4\"\u003e\u003c/th\u003e\r\n \u003c/tr\u003e\r\n \u003c/thead\u003e\r\n \u003ctbody\u003e\r\n \r\n \u003ctr\u003e\r\n \u003cth\u003e\r\n \r\n \u003cimg src=\"/upload/201511/05/201511051356078792.jpg\"/\u003e\r\n \u003cdiv class=\"conBox\"\u003e\r\n \u003cp class=\"title\"\u003e标准间\u003c/p\u003e\r\n \u003cp class=\"p1 showMes\"\u003e查看详情\u003c/p\u003e\r\n \u003c/div\u003e\r\n \r\n \u003c/th\u003e\r\n \u003ctd\u003e\u003cspan class=\"ss\"\u003e1.5M单人床\u003c/span\u003e\u003cspan class=\"ss\"\u003e双人早餐\u003c/span\u003e\u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"price\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e880.00\u003c/em\u003e\u003c/span\u003e\r\n \u003cdel class=\"priceOld\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e880.00\u003c/em\u003e\u003c/del\u003e\r\n \u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"book\" data-id=\"188\"\u003e预订\u003c/span\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \u003ctr class=\"clicked\"\u003e\r\n \u003ctd colspan=\"4\"\u003e\r\n \u003cdiv\u003e\r\n \r\n \u003cp class=\"jianjie\"\u003e\u003c/p\u003e\r\n \u003cp class=\"hideMes\"\u003e\u003cspan\u003e收起\u003c/span\u003e\u003c/p\u003e\r\n \u003c/div\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \r\n \u003ctr\u003e\r\n \u003cth\u003e\r\n \r\n \u003cimg src=\"/upload/201511/05/201511051354094160.jpg\"/\u003e\r\n \u003cdiv class=\"conBox\"\u003e\r\n \u003cp class=\"title\"\u003e单人间\u003c/p\u003e\r\n \u003cp class=\"p1 showMes\"\u003e查看详情\u003c/p\u003e\r\n \u003c/div\u003e\r\n \r\n \u003c/th\u003e\r\n \u003ctd\u003e\u003cspan class=\"ss\"\u003e1.5M单人床\u003c/span\u003e\u003cspan class=\"ss\"\u003e双人早餐\u003c/span\u003e\u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"price\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e928.00\u003c/em\u003e\u003c/span\u003e\r\n \u003cdel class=\"priceOld\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e928.00\u003c/em\u003e\u003c/del\u003e\r\n \u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"book\" data-id=\"187\"\u003e预订\u003c/span\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \u003ctr class=\"clicked\"\u003e\r\n \u003ctd colspan=\"4\"\u003e\r\n \u003cdiv\u003e\r\n \r\n \u003cp class=\"jianjie\"\u003e\u003c/p\u003e\r\n \u003cp class=\"hideMes\"\u003e\u003cspan\u003e收起\u003c/span\u003e\u003c/p\u003e\r\n \u003c/div\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \r\n \u003ctr\u003e\r\n \u003cth\u003e\r\n \r\n \u003cimg src=\"/upload/201511/05/201511051358511262.jpg\"/\u003e\r\n \u003cdiv class=\"conBox\"\u003e\r\n \u003cp class=\"title\"\u003e豪华套房\u003c/p\u003e\r\n \u003cp class=\"p1 showMes\"\u003e查看详情\u003c/p\u003e\r\n \u003c/div\u003e\r\n \r\n \u003c/th\u003e\r\n \u003ctd\u003e\u003cspan class=\"ss\"\u003e1.5M单人床\u003c/span\u003e\u003cspan class=\"ss\"\u003e双人早餐\u003c/span\u003e\u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"price\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e1980.00\u003c/em\u003e\u003c/span\u003e\r\n \u003cdel class=\"priceOld\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e1980.00\u003c/em\u003e\u003c/del\u003e\r\n \u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"book\" data-id=\"189\"\u003e预订\u003c/span\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \u003ctr class=\"clicked\"\u003e\r\n \u003ctd colspan=\"4\"\u003e\r\n \u003cdiv\u003e\r\n \r\n \u003cp class=\"jianjie\"\u003e\u003c/p\u003e\r\n \u003cp class=\"hideMes\"\u003e\u003cspan\u003e收起\u003c/span\u003e\u003c/p\u003e\r\n \u003c/div\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \r\n \u003ctr\u003e\r\n \u003cth\u003e\r\n \r\n \u003cimg src=\"/upload/201511/05/201511051359365886.jpg\"/\u003e\r\n \u003cdiv class=\"conBox\"\u003e\r\n \u003cp class=\"title\"\u003e总统套房\u003c/p\u003e\r\n \u003cp class=\"p1 showMes\"\u003e查看详情\u003c/p\u003e\r\n \u003c/div\u003e\r\n \r\n \u003c/th\u003e\r\n \u003ctd\u003e\u003cspan class=\"ss\"\u003e1.5M单人床\u003c/span\u003e\u003cspan class=\"ss\"\u003e双人早餐\u003c/span\u003e\u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"price\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e18888.00\u003c/em\u003e\u003c/span\u003e\r\n \u003cdel class=\"priceOld\"\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e18888.00\u003c/em\u003e\u003c/del\u003e\r\n \u003c/td\u003e\r\n \u003ctd\u003e\r\n \u003cspan class=\"book\" data-id=\"190\"\u003e预订\u003c/span\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \u003ctr class=\"clicked\"\u003e\r\n \u003ctd colspan=\"4\"\u003e\r\n \u003cdiv\u003e\r\n \r\n \u003cp class=\"jianjie\"\u003e\u003c/p\u003e\r\n \u003cp class=\"hideMes\"\u003e\u003cspan\u003e收起\u003c/span\u003e\u003c/p\u003e\r\n \u003c/div\u003e\r\n \u003c/td\u003e\r\n \u003c/tr\u003e\r\n \r\n\u003c/tbody\u003e \r\n \u003c/table\u003e\r\n \u003c/div\u003e\r\n\u003c/div\u003e\r\n\u003c!--end 客房列表--\u003e\r\n\u003cscript src=\"/static/js/mobiscroll_1.js\"\u003e\u003c/script\u003e\r\n\u003cscript src=\"/static/js/mobiscroll_2.js\"\u003e\u003c/script\u003e\r\n\u003cscript\u003e\r\n var currYear = (new Date()).getFullYear();\r\n var opt = {};\r\n opt.date = { preset: \u0027date\u0027 };\r\n opt.datetime = { preset: \u0027datetime\u0027 };\r\n opt.time = { preset: \u0027time\u0027 };\r\n opt.default = {\r\n theme: \u0027android-ics light\u0027, //皮肤样式\r\n display: \u0027modal\u0027, //显示方式 \r\n mode: \u0027scroller\u0027, //日期选择模式\r\n dateFormat: \u0027yyyy-mm-dd\u0027,\r\n lang: \u0027zh\u0027,\r\n showNow: true,\r\n nowText: \"今天\",\r\n startYear: currYear - 0, //开始年份\r\n startMonth: (new Date()).getMonth(), //开始月份\r\n startDay: (new Date()).getDate() + 1, //开始日期\r\n endYear: currYear + 1 //结束年份\r\n\r\n };\r\n $(\"#startDate\").mobiscroll($.extend(opt[\u0027date\u0027], opt[\u0027default\u0027]));\r\n $(\"#endDate\").mobiscroll($.extend(opt[\u0027date\u0027], opt[\u0027default\u0027]));\r\n $(\"#startDate\").val($(\"#startDate\").data(\"time\"));\r\n $(\"#endDate\").val($(\"#endDate\").data(\"time\"));\r\n $(\"#endDate\").mobiscroll(\u0027option\u0027, {\r\n \u0027onSelect\u0027: function (value) {\r\n var startDate = new Date((new Date($(\"#startDate\").val())).valueOf() + 1 * 24 * 60 * 60 * 1000);\r\n var endDate = new Date($(\"#endDate\").val());\r\n console.log(startDate);\r\n $(\"#endDate\").mobiscroll(\u0027option\u0027, { \u0027startYear\u0027: (new Date(startDate)).getFullYear(), \u0027startMonth\u0027: (new Date(startDate)).getMonth(), \u0027startDay\u0027: (new Date(startDate)).getDate() });\r\n if (startDate \u003e endDate) {\r\n console.log(\"startDate\u003eendDate\");\r\n $(\"#endDate\").val(startDate.getFullYear() + \"-\" + (startDate.getMonth() + 1) + \"-\" + startDate.getDate());\r\n }\r\n }\r\n });\r\n\r\n\r\n\r\n\r\n //省钱显示 \r\n $(\".priceOld\").each(function () {\r\n var _pNow = parseFloat($(this).prev(\".price\").find(\"em\").html()),//现价\r\n _pOld = parseFloat($(this).find(\"em\").html()),//原价\r\n _pHui = _pOld - _pNow;//优惠价\r\n if(_pHui\u003e0){\r\n var _str = \u0027\u003cspan class=\"priceHui\"\u003e\u003ci\u003e省\u003c/i\u003e\u003cdfn\u003e¥\u003c/dfn\u003e\u003cem\u003e\u0027 + _pHui + \u0027\u003c/em\u003e\u003c/span\u003e\u0027;\r\n $(this).after(_str);\r\n }\r\n \r\n });\r\n //查看详情和收起\r\n $(\".showMes,.hideMes span\").on(\"click\", function () {\r\n var $obj_click;\r\n if ($(this).hasClass(\"showMes\")) {\r\n $obj_click = $(this).closest(\"tr\").next(\".clicked\");\r\n } else {\r\n $obj_click = $(this).closest(\".clicked\");\r\n }\r\n //效果实现\r\n var _ind = $(\".clicked\").index($obj_click);\r\n $(\".clicked\").eq(_ind).find(\"td\").slideToggle(\"fast\");\r\n $(\".clicked\").eq(_ind).find(\"td div\").slideToggle(\"fast\");\r\n $(\".clicked\").eq(_ind).siblings(\".clicked\").find(\"td\").slideUp(\"fast\");\r\n $(\".clicked\").eq(_ind).siblings(\".clicked\").find(\"td div\").slideUp(\"fast\");\r\n })\r\n\r\n $(\"span.book\").click(function () {\r\n console.log(\"ssdf\");\r\n var id = $(this).data(\"id\");\r\n var start_time = $(\"#startDate\").val();\r\n var end_time = $(\"#endDate\").val();\r\n $.get(\"/tools/query_ajax.ashx?action=hotel_room\u0026id=\" + id + \"\u0026start_time=\" + start_time + \"\u0026end_time=\" + end_time, function (data) {\r\n if (data.status == 1) {\r\n $(\"#hotel_col_r\").html(data.html);\r\n } else {\r\n\r\n }\r\n \r\n },\"JSON\");\r\n });\r\n\u003c/script\u003e"}