jobs.hbs 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  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. <div id="jobs">
  19. <div class="jobs_head">
  20. <div>{{t menu.item.jobs}}</div>
  21. {{#if controller.hasNewJobs}}
  22. <div class="new-jobs-link">
  23. <a href="javascript:void(null);" {{action updateJobsByClick target="controller"}}>{{t jobs.new_jobs.info}}</a>
  24. </div>
  25. {{/if}}
  26. <div class="jobs-type">
  27. {{t jobs.type}} : <span class="label label-info">{{t jobs.type.hive}}</span>
  28. </div>
  29. </div>
  30. <table id="jobs-table" class="table table-bordered table-striped">
  31. <thead>
  32. {{#view view.sortView classNames="label-row" contentBinding="view.content"}}
  33. <th></th>
  34. {{view view.parentView.idSort}}
  35. {{view view.parentView.userSort}}
  36. {{view view.parentView.startTimeSort}}
  37. {{view view.parentView.endTimeSort}}
  38. {{view view.parentView.durationSort}}
  39. {{/view}}
  40. <tr id="filter-row" class="first">
  41. <th></th>
  42. <th>{{view view.jobsIdFilterView}}</th>
  43. <th>{{view view.userFilterView}}</th>
  44. <th class="start-time">{{view view.startTimeFilterView}}</th>
  45. <th></th>
  46. <th></th>
  47. </tr>
  48. </thead>
  49. <tbody>
  50. {{#if view.noDataToShow}}
  51. <tr>
  52. {{#if controller.loaded}}
  53. <td class="no-data" {{bindAttr colspan="controller.columnsName.content.length"}}>{{t jobs.nothingToShow}}</td>
  54. {{else}}
  55. <td class="no-data" {{bindAttr colspan="controller.columnsName.content.length"}}>{{t jobs.loadingTasks}}</td>
  56. {{/if}}
  57. </tr>
  58. {{else}}
  59. {{#each job in controller.sortedContent}}
  60. <tr>
  61. <td>
  62. {{#if job.failed}}
  63. <i class="icon-remove-sign job-link" {{bindAttr title="view.jobFailMessage"}}></i>
  64. {{/if}}
  65. </td>
  66. <td>
  67. <div class="id">
  68. {{view view.jobNameView jobBinding="job"}}
  69. </div>
  70. </td>
  71. <td>
  72. {{job.user}}
  73. </td>
  74. <td>
  75. {{job.startTimeDisplay}}
  76. </td>
  77. <td>
  78. {{job.endTimeDisplay}}
  79. </td>
  80. <td>
  81. {{job.durationDisplay}}
  82. </td>
  83. </tr>
  84. {{/each}}
  85. {{/if}}
  86. </tbody>
  87. </table>
  88. <div class="page-bar">
  89. <div id="filtered-jobs">
  90. {{view.filteredJobs}} - <a href="javascript:void(null);" {{action clearFilters target="view"}}>{{t jobs.filtered.clear}}</a>
  91. </div>
  92. <div class="items-on-page">
  93. <label>{{t jobs.show.up.to}}: {{view view.rowsPerPageSelectView selectionBinding="view.displayLength"}}</label>
  94. </div>
  95. <div class="paging_two_button">
  96. {{view view.jobsPaginationLeft}}
  97. {{view view.jobsPaginationRight}}
  98. </div>
  99. </div>
  100. </div>