index1.html 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. {extend name="common/common2" /}
  2. {block name="main"}
  3. <div class="row">
  4. <div class="col-sm-12">
  5. <div class="ibox float-e-margins">
  6. <div class="ibox-content">
  7. <ul class="nav nav-tabs" id="myTab">
  8. <li class="{$is_spot==0?'active':''}">
  9. <a href="{:url('index1')}?is_spot=0">
  10. 预定餐
  11. </a>
  12. </li>
  13. <li class="{$is_spot==1?'active':''}">
  14. <a href="{:url('index1')}?is_spot=1">
  15. 当日餐
  16. </a>
  17. </li>
  18. <li class="{$is_spot==2?'active':''}">
  19. <a href="{:url('index1')}?is_spot=2">
  20. 特殊套餐
  21. </a>
  22. </li>
  23. </ul>
  24. </div>
  25. <div class="ibox-content">
  26. <div class="tab-content">
  27. <form action="{:url('index1')}" method="GET" class="form-inline">
  28. <input type="hidden" name="is_spot" value="{$is_spot}">
  29. <div class="input-group">
  30. {:widget_view('common/laydate',['name'=>'start','title' => '下单日期','type' => 'date','val'=>$start])}
  31. </div>
  32. <div class="input-group">
  33. <span class="input-group-btn">
  34. <button class="btn-sm btn-primary" type="submit" ><i class="fa fa-search"></i></button>
  35. </span> &nbsp;
  36. <span class="input-group-btn">
  37. <button class="btn-sm btn-info" type="button" onclick="printer()"><i class="glyphicon glyphicon-print"></i>打印</button>
  38. </span>
  39. </div>
  40. </form>
  41. </div>
  42. </div>
  43. <div class="ibox-content" style="overflow-y: auto">
  44. <div id="visaReport">
  45. <table class="table table-bordered" >
  46. <caption>
  47. <h3 class="text-center">厨房配菜表</h3>
  48. <span class="text-right">日期:{$start}</span>
  49. </caption>
  50. <thead>
  51. <tr>
  52. {foreach $type as $k=>$v}
  53. <th nowrap="nowrap" class="text-center">{$v.dinner_type_name}</th>
  54. <th nowrap="nowrap" class="text-center">数量</th>
  55. {/foreach}
  56. </tr>
  57. </thead>
  58. <tbody>
  59. {foreach $data as $k=>$v}
  60. <tr>
  61. {foreach $type as $k1=>$v1}
  62. <th nowrap="nowrap" class="text-center">{$v['name'.$v1['id']]}</th>
  63. <th nowrap="nowrap" class="text-center">{$v['nums'.$v1['id']]}</th>
  64. {/foreach}
  65. </tr>
  66. {/foreach}
  67. </tbody>
  68. </table>
  69. </div>
  70. </div>
  71. </div>
  72. </div>
  73. </div>
  74. {/block}
  75. {block name="script"}
  76. <script src="/static/browser.js"></script>
  77. <script src="/static/jquery.jqprint-0.3.js"></script>
  78. <script>
  79. function printer() {
  80. $("#visaReport").jqprint({});
  81. }
  82. </script>
  83. {/block}