You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

375 lines
15 KiB

  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta HTTP-EQUIV="pragma" CONTENT="no-cache">
  6. <meta HTTP-EQUIV="expires" CONTENT="0">
  7. <title>自我游酒店订单列表</title>
  8. <link rel="stylesheet" type="text/css" href="./css/ace.min.css"/>
  9. <link rel="stylesheet" type="text/css" href="./css/bootstrap/bootstrap.min.css"/>
  10. <link rel="stylesheet" type="text/css" href="./css/bootstrap-timepicker.css"/>
  11. <link rel="stylesheet" type="text/css" href="./css/font-awesome.min.css"/>
  12. <link rel="stylesheet" type="text/css" href="./css/daterangepicker.css"/>
  13. <link rel="stylesheet" type="text/css" href="./css/datepicker.css"/>
  14. <link rel="stylesheet" type="text/css" href="./css/master.css">
  15. <link rel="stylesheet" href="css/new_page.css"/>
  16. <link rel="stylesheet" type="text/css" href="./css/combo.select.css"/>
  17. <style>
  18. .main_style {
  19. width: 500px;
  20. height: 500px;
  21. border: solid 1px #CCCCCC;
  22. }
  23. .frist_style {
  24. width: 497px;
  25. height: 50px;
  26. background-color: #F2F2F2;
  27. }
  28. .frist_style_chinese {
  29. vertical-align: top;
  30. display: inline-block;
  31. height: 50px;
  32. width: 435px;
  33. line-height: 50px;
  34. font-family: "微软雅黑";
  35. margin-left: 15px;
  36. }
  37. .frist_style_cha {
  38. display: inline-block;
  39. height: 50px;
  40. width: 46px;
  41. }
  42. .frist_style_cha img {
  43. width: 20px;
  44. height: 20px;
  45. margin-top: 15px;
  46. margin-left: 15px;
  47. }
  48. .second_style {
  49. width: 500px;
  50. height: 450px;
  51. }
  52. .second_style_frist {
  53. width: 500px;
  54. height: 30px;
  55. margin-top: 10px;
  56. }
  57. .second_style_main {
  58. width: 100px;
  59. height: 30px;
  60. margin-left: -15px;
  61. text-align: right;
  62. display: inline-block;
  63. line-height: 30px;
  64. vertical-align: top;
  65. }
  66. .second_style_next {
  67. display: inline-block;
  68. width: 280px;
  69. height: 30px;
  70. margin-left: 5px;
  71. line-height: 30px;
  72. }
  73. .combo-select {
  74. border: none;
  75. }
  76. .table {
  77. max-width: none !important;
  78. }
  79. </style>
  80. </head>
  81. <body style="font-size: 12px;">
  82. <!--<div class="navbar navbar-default" style="margin-bottom: 0px;width: 1920px;">
  83. <div class="navbar-header ">
  84. <a href="#" class="navbar-brand">
  85. <i class="icon-leaf"></i> CS System<sub style="font-size:12px;position: initial;">&nbsp;<span
  86. id="version_txt"></span></sub>
  87. </a>
  88. </div>
  89. </div>
  90. <div class="warp clearfix" id="show_html" style="display: none;width: 1920px;">
  91. <div class="control-show" style="float: left;width: 100%">-->
  92. <div style="margin-top: 20px;margin-left: 20px">
  93. <!--最上一栏-->
  94. <div>
  95. <span style="display: inline-block;">日期选择:</span>
  96. <select style="width: 100px; height: 30px; margin-top: 5px;margin-left: 5px;display: inline-block;cursor: pointer"
  97. id="date_type">
  98. <!--<option value="0" selected="selected" style="font-size: 12px;">所有日期</option>-->
  99. <option value="1" selected="selected" style="font-size: 12px;">预订日期</option>
  100. <option value="2" style="font-size: 12px;">入住日期</option>
  101. <option value="3" style="font-size: 12px;">离店日期</option>
  102. </select>
  103. <input type="text" id="start_date" class="Wdate"
  104. style="height: 30px; width: 100px;display: inline-block"
  105. name="begin"
  106. onClick="WdatePicker({doubleCalendar:true,errDealMode:0,alwaysUseStartDate:true})"/>
  107. <span>-</span>
  108. <input type="text" id="end_date" class="Wdate" style="height: 30px; width: 100px;display: inline-block"
  109. name="end"
  110. onClick="WdatePicker({doubleCalendar:true,errDealMode:0,alwaysUseStartDate:true})"/>
  111. <!--<span id="yesterday" class="btn"
  112. style="font-size: 12px;width: 50px; padding: 3px;display: inline-block;margin-left: 5px;"
  113. onclick="">昨日</span>
  114. <span id="today" class="btn"
  115. style="font-size: 12px;width: 50px; padding: 3px;display: inline-block;margin-left: 5px;">今日</span>
  116. <span id="thisweek" class="btn"
  117. style="font-size: 12px;width: 50px; padding: 3px;display: inline-block;margin-left: 5px;">本周</span>
  118. <span id="thismonth" class="btn"
  119. style="font-size: 12px;width: 50px; padding: 3px;display: inline-block;margin-left: 5px;">本月</span>-->
  120. <span style="display: inline-block; margin-top: 5px;;margin-left: 30px">酒店名称:</span>
  121. <input type="text" id="hotel_name" placeholder="酒店名称"
  122. style="width: 100px; height: 30px;font-size: 12px"/>
  123. </div>
  124. <!--状态栏-->
  125. <div style="margin-top: 20px">
  126. <span style="display: inline-block;">订单渠道:</span>
  127. <input id="org_name" type="text"
  128. style="height: 30px; width: 200px;display: inline-block;font-size: 12px;margin-left: 5px"
  129. placeholder="订单渠道"/>
  130. <span style="display: inline-block;">订单号:</span>
  131. <input id="order_id" type="text"
  132. style="height: 30px; width: 200px;display: inline-block;font-size: 12px;margin-left: 5px"
  133. placeholder="订单号"/>
  134. <span id="search" class="btn"
  135. style="font-size: 12px;width: 50px; padding: 3px;display: inline-block;margin-left: 5px;"
  136. onclick="search();">查询
  137. </span>
  138. <span class="btn"
  139. style="font-size: 12px;width: 100px; padding: 3px;display: inline-block;margin-left: 5px;"
  140. onclick="excel();">导出订单信息</span>
  141. </div>
  142. <!--表单-->
  143. <div style="margin-top: 20px;margin-right: 20px;">
  144. <div>
  145. </div>
  146. <div class="pageDiv"></div>
  147. <table id="table" class="table table-striped table-bordered table-hover" style="width: 100%;">
  148. <thead>
  149. <tr style="color: rgba(0, 0, 3, 0.7)">
  150. <th>订单编号</th>
  151. <th>母订单编号</th>
  152. <th>预订日期</th>
  153. <th>入住日期</th>
  154. <th>离店日期</th>
  155. <th>客人姓名</th>
  156. <th>客人手机号</th>
  157. <th>预订产品</th>
  158. <th>间夜数</th>
  159. <th>订单金额</th>
  160. <th>采购成本</th>
  161. <th>支付方式</th>
  162. <th>支付日期</th>
  163. <th>毛利</th>
  164. <th>产品编号</th>
  165. <th>产品名称</th>
  166. <!--</tr>-->
  167. <!--<tr style="color: rgba(0, 0, 3, 0.37)">-->
  168. <th>订单项目</th>
  169. <th>产品数量</th>
  170. <th>销售单价</th>
  171. <th>采购单价</th>
  172. <th>状态</th>
  173. <th>地区</th>
  174. <th>跟单客服</th>
  175. <th>订单渠道</th>
  176. <th>渠道订单号</th>
  177. <th>供应商</th>
  178. <th>采购人</th>
  179. <th>供应商订单ID</th>
  180. <th>票号确认号</th>
  181. <th>内部备注</th>
  182. <th>备注</th>
  183. </tr>
  184. </thead>
  185. <tbody id="order_list" style="display: none">
  186. <tr id="tr_order_1" style="color: rgba(0, 0, 3, 0.7)">
  187. <td rowspan="[rowM]">[order_id]</td>
  188. <td rowspan="[rowM]">[parent_order_id]</td>
  189. <td rowspan="[rowM]">[book_time]</td>
  190. <td rowspan="[rowM]">[start_time]</td>
  191. <td rowspan="[rowM]">[end_time]</td>
  192. <td rowspan="[rowM]">[contact_name]</td>
  193. <td rowspan="[rowM]">[contact_phone]</td>
  194. <td rowspan="[rowM]" style="width: 150px;">[order_content]</td>
  195. <td rowspan="[rowM]">[amount]</td>
  196. <td rowspan="[rowM]">[total_price]</td>
  197. <td rowspan="[rowM]">[cg_total_price]</td>
  198. <td rowspan="[rowM]">[receipt_type]</td>
  199. <td rowspan="[rowM]">[receipt_time]</td>
  200. <td rowspan="[rowM]">[gy_profit]</td>
  201. <td>[prod_id]</td>
  202. <td>[prod_name]</td>
  203. <td>[order_project]</td>
  204. <td>[prod_num]</td>
  205. <td>[fx_price]</td>
  206. <td>[cg_price]</td>
  207. <td rowspan="[rowM]">[status]</td>
  208. <td rowspan="[rowM]">[area]</td>
  209. <td rowspan="[rowM]">[write_user]</td>
  210. <td rowspan="[rowM]">[fx_code]</td>
  211. <td rowspan="[rowM]">[fx_order_id]</td>
  212. <td rowspan="[rowM]">[gy_code]</td>
  213. <td rowspan="[rowM]">[gy_man]</td>
  214. <td rowspan="[rowM]">[gy_order_id]</td>
  215. <td rowspan="[rowM]">[ticket_verify_id]</td>
  216. <td rowspan="[rowM]">[inside_comment]</td>
  217. <td rowspan="[rowM]">[comment]</td>
  218. </tr>
  219. <tr id="tr_order_2" style="color: rgba(0, 0, 3, 0.7)">
  220. <td>[prod_id]</td>
  221. <td>[prod_name]</td>
  222. <td>[order_project]</td>
  223. <td>[prod_num]</td>
  224. <td>[fx_price]</td>
  225. <td>[cg_price]</td>
  226. </tr>
  227. </tbody>
  228. </table>
  229. <div class="pageDiv"></div>
  230. </div>
  231. </div>
  232. <!--</div>
  233. </div>-->
  234. </body>
  235. <script language="javascript" type="text/javascript" src="My97DatePicker/WdatePicker.js"></script>
  236. <script type="text/javascript" src="js/htCommon.js"></script>
  237. <script type="text/javascript" src="js/jquery.cookie.js"></script>
  238. <!--<script type="text/javascript" src="js/xm.js"></script>-->
  239. <!--<script src="js/master.js" type="text/javascript" charset="utf-8"></script>-->
  240. <script src="js/jquery.combo.select.js" type="text/javascript" charset="utf-8"></script>
  241. <!--<script>
  242. login();
  243. </script>-->
  244. <script type="text/javascript">
  245. var current = 1;
  246. var page_size = 15;
  247. var tr_order_str_1 = $('#tr_order_1').prop('outerHTML');//获取tr1中所有的字符串
  248. var tr_order_str_2 = $('#tr_order_2').prop('outerHTML');//获取tr2中所有的字符串
  249. $(document).ready(function () {
  250. //昨日日期
  251. $('#yesterday').bind('click', function () {
  252. $("#start_date").val(getDateTime(10));
  253. $("#end_date").val(getDateTime(10));
  254. search(1);
  255. });
  256. //今日日期
  257. $('#today').bind('click', function () {
  258. $("#start_date").val(getDateTime(0));
  259. $("#end_date").val(getDateTime(0));
  260. search(1);
  261. });
  262. //本周日期
  263. $('#thisweek').bind('click', function () {
  264. $("#start_date").val(after(getDateTime(12)));
  265. $("#end_date").val(after(getDateTime(13)));
  266. search(1);
  267. });
  268. //本月日期
  269. $('#thismonth').bind('click', function () {
  270. $("#start_date").val(getDateTime(14));
  271. $("#end_date").val(getDateTime(15));
  272. search(1);
  273. });
  274. });
  275. $("#start_date").val(getDateByDay(-3, getDateTime(0)));
  276. start_date = getDateByDay(-3, getDateTime(0));
  277. $("#end_date").val(getDateTime(0));
  278. end_date = getDateTime(0);
  279. function search(page) {
  280. var param = {
  281. op: 'getOrderList',
  282. date_type: $('#date_type').val(),
  283. start_date: $('#start_date').val(),
  284. end_date: $('#end_date').val(),
  285. hotel_name: $('#hotel_name').val(),
  286. org_name: $('#org_name').val(),
  287. order_id: $('#order_id').val(),
  288. current: page,
  289. };
  290. var url = base_api + "?type=order_ZwyOrderList";
  291. $.getJSON(url, param, function (data) {
  292. if (data['code']) {
  293. alert(data['info']);
  294. } else {
  295. current = data['current'];
  296. $(".pageDiv").createPage({
  297. pageCount: data['total_page'],//总页数
  298. current: current,//当前页
  299. turndown: 'true',//是否显示跳转框,显示为true,不现实为false,一定记得加上引号...
  300. backFn: function (p) {
  301. current = p;
  302. search(p);
  303. }
  304. });
  305. $('.pageDiv').show();
  306. setDataBody(data);
  307. }
  308. });
  309. }
  310. function setDataBody(data) {
  311. var order_list = data['order_list'];
  312. var comHTML = '';
  313. var rowM = '';
  314. for (var i = 0; i < order_list.length; i++) {
  315. var dict = order_list[i];
  316. if (dict['order_id'] != rowM) {
  317. var HTML = tr_order_str_1;
  318. rowM = dict['order_id'];
  319. HTML = HTML.replace(/\[rowM\]/g, dict['cnt'] === null ? 1 : dict['cnt']);
  320. } else {
  321. var HTML = tr_order_str_2;
  322. }
  323. for (var key in dict) {
  324. HTML = HTML.replace('[' + key + ']', dict[key] === null ? '-' : dict[key]);
  325. }
  326. comHTML += HTML;
  327. }
  328. $('#order_list').html(comHTML);
  329. $('#order_list').show();
  330. }
  331. //导出数据导excel
  332. function excel() {
  333. var param = {
  334. date_type: $('#date_type').val(),
  335. start_date: $('#start_date').val(),
  336. end_date: $('#end_date').val(),
  337. hotel_name: $('#hotel_name').val(),
  338. org_name: $('#org_name').val(),
  339. order_id: $('#order_id').val(),
  340. };
  341. var toUrl = "/zz-jd/st-ht/HTcontrol.php?type=order_ZwyOrderList&op=excel&date_type=" +
  342. param['date_type'] + "&start_date=" + param['start_date'] + "&end_date=" + param['end_date'] + "&hotel_name=" + param['hotel_name']
  343. + "&org_name=" + param['org_name'] + "&order_id=" + param['order_id'];
  344. var name = 'add'; //网页名称,可为空;
  345. var iWidth = 400; //弹出窗口的宽度;
  346. var iHeight = 200; //弹出窗口的高度;
  347. //获得窗口的垂直位置
  348. var iTop = (window.screen.availHeight - 30 - iHeight) / 3;
  349. //获得窗口的水平位置
  350. var iLeft = (window.screen.availWidth - 10 - iWidth) / 2;
  351. win = window.open(toUrl, name, 'height=' + iHeight + ',,innerHeight=' + iHeight + ',width=' + iWidth + ',innerWidth=' + iWidth + ',top=' + iTop + ',left=' + iLeft + ',status=no,toolbar=no,menubar=no,location=no,resizable=no,scrollbars=0,titlebar=no');
  352. win.document.title = "导出excel中,导出较慢,请耐心等候。。。";
  353. }
  354. search(1);
  355. </script>
  356. </html>