jobs.hbs 3.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. {{!
  2. * Licensed to the Apache Software Foundation (ASF) under one
  3. * or more contributor license agreements. See the NOTICE file
  4. * distributed with this work for additional information
  5. * regarding copyright ownership. The ASF licenses this file
  6. * to you under the Apache License, Version 2.0 (the
  7. * "License"); you may not use this file except in compliance
  8. * with the License. You may obtain a copy of the License at
  9. *
  10. * http://www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing, software
  13. * distributed under the License is distributed on an "AS IS" BASIS,
  14. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. * See the License for the specific language governing permissions and
  16. * limitations under the License.
  17. }}
  18. {{#if controller.loaded}}
  19. <div id="jobs">
  20. <div class="jobs_head">
  21. <div>{{t menu.item.jobs}}</div>
  22. <div class="jobs-type">
  23. {{t jobs.type}} : <span class="label label-info">{{t jobs.type.hive}}</span>
  24. </div>
  25. </div>
  26. <table id="jobs-table" class="table table-bordered table-striped">
  27. <thead>
  28. {{#view view.sortView classNames="label-row" contentBinding="view.filteredContent"}}
  29. {{view view.parentView.idSort}}
  30. {{view view.parentView.userSort}}
  31. {{view view.parentView.startTimeSort}}
  32. {{view view.parentView.endTimeSort}}
  33. {{view view.parentView.durationSort}}
  34. {{/view}}
  35. <tr id="filter-row" class="first">
  36. <th></th>
  37. <th>{{view view.jobsIdFilterView}}</th>
  38. <th>{{view view.userFilterView}}</th>
  39. <th class="start-time">{{view view.startTimeFilterView}}</th>
  40. <th></th>
  41. <th></th>
  42. </tr>
  43. </thead>
  44. <tbody>
  45. {{#if view.noDataToShow}}
  46. <tr>
  47. <td class="no-data" {{bindAttr colspan="controller.columnsName.content.length"}}>{{t jobs.nothingToShow}}</td>
  48. </tr>
  49. {{else}}
  50. {{#each job in view.pageContent}}
  51. <tr>
  52. <td>
  53. {{#if job.failed}}
  54. <i class="icon-remove-sign job-link" {{bindAttr title="view.jobFailMessage"}}></i>
  55. {{/if}}
  56. </td>
  57. <td>
  58. <div class="id">
  59. {{#if job.hasTezDag}}
  60. <a rel="tooltip" class="job-link" title="{{unbound job.queryText}}" href="#" {{action "showJobDetails" job}}>{{unbound job.name}}</a>
  61. {{else}}
  62. <span rel="tooltip" class="job-link" title="{{unbound job.queryText}}">{{unbound job.name}}</span>
  63. {{/if}}
  64. </div>
  65. </td>
  66. <td>
  67. {{job.user}}
  68. </td>
  69. <td>
  70. {{job.startTimeDisplay}}
  71. </td>
  72. <td>
  73. {{job.endTimeDisplay}}
  74. </td>
  75. <td>
  76. {{job.durationDisplay}}
  77. </td>
  78. </tr>
  79. {{/each}}
  80. {{/if}}
  81. </tbody>
  82. </table>
  83. <div class="page-bar">
  84. <div id="filtered-jobs">
  85. {{view.filteredJobs}} - <a href="javascript:void(null);" {{action clearFilters target="view"}}>{{t jobs.filtered.clear}}</a>
  86. </div>
  87. <div class="items-on-page">
  88. <label>{{t jobs.show.up.to}}: {{view view.rowsPerPageSelectView selectionBinding="view.displayLength"}}</label>
  89. </div>
  90. </div>
  91. </div>
  92. {{/if}}