##// END OF EJS Templates
adjusted the padding of path and summary box between files and file details screens
adjusted the padding of path and summary box between files and file details screens

File last commit:

r3638:c1c37b0b merge new-ui
r3720:0c0b5c69 new-ui
Show More
repos.mako
105 lines | 3.2 KiB | application/x-mako | MakoHtmlLexer
templating: use .mako as extensions for template files.
r1282 ## -*- coding: utf-8 -*-
<%inherit file="/base/base.mako"/>
<%def name="title()">
${_('Repositories administration')}
%if c.rhodecode_name:
&middot; ${h.branding(c.rhodecode_name)}
%endif
</%def>
nav: bring back quick filter and cleanup titles
r3589 <%def name="breadcrumbs_links()"></%def>
templating: use .mako as extensions for template files.
r1282
<%def name="menu_bar_nav()">
${self.menu_items(active='admin')}
</%def>
ui: navigation, fixed wrapping of new admin navigation items
r3566 <%def name="menu_bar_subnav()">
${self.admin_menu(active='repositories')}
</%def>
templating: use .mako as extensions for template files.
r1282 <%def name="main()">
<div class="box">
nav: bring back quick filter and cleanup titles
r3589
templating: use .mako as extensions for template files.
r1282 <div class="title">
nav: bring back quick filter and cleanup titles
r3589 <input class="q_filter_box" id="q_filter" size="15" type="text" name="filter" placeholder="${_('quick filter...')}" value=""/>
<span id="repo_count">0</span> ${_('repositories')}
templating: use .mako as extensions for template files.
r1282 <ul class="links">
nav: bring back quick filter and cleanup titles
r3589 %if c.can_create_repo:
<li>
<a href="${h.route_path('repo_new')}" class="btn btn-small btn-success">${_(u'Add Repository')}</a>
</li>
%endif
templating: use .mako as extensions for template files.
r1282 </ul>
</div>
<div id="repos_list_wrap">
<table id="repo_list_table" class="display"></table>
</div>
</div>
<script>
$(document).ready(function() {
var get_datatable_count = function(){
var api = $('#repo_list_table').dataTable().api();
$('#repo_count').text(api.page.info().recordsDisplay);
};
// repo list
$('#repo_list_table').DataTable({
data: ${c.data|n},
dom: 'rtp',
pageLength: ${c.visual.admin_grid_items},
order: [[ 0, "asc" ]],
columns: [
{ data: {"_": "name",
"sort": "name_raw"}, title: "${_('Name')}", className: "td-componentname" },
{ data: 'menu', "bSortable": false, className: "quick_repo_menu" },
{ data: {"_": "desc",
"sort": "desc"}, title: "${_('Description')}", className: "td-description" },
{ data: {"_": "last_change",
"sort": "last_change_raw",
"type": Number}, title: "${_('Last Change')}", className: "td-time" },
{ data: {"_": "last_changeset",
"sort": "last_changeset_raw",
"type": Number}, title: "${_('Commit')}", className: "td-commit" },
{ data: {"_": "owner",
"sort": "owner"}, title: "${_('Owner')}", className: "td-user" },
{ data: {"_": "state",
"sort": "state"}, title: "${_('State')}", className: "td-tags td-state" },
{ data: {"_": "action",
repository-groups: use lazy loaded admin dashboard
r3623 "sort": "action"}, title: "${_('Action')}", className: "td-action", orderable: false }
templating: use .mako as extensions for template files.
r1282 ],
language: {
paginate: DEFAULT_GRID_PAGINATION,
emptyTable:_gettext("No repositories available yet.")
},
"initComplete": function( settings, json ) {
get_datatable_count();
quick_repo_menu();
}
});
// update the counter when doing search
$('#repo_list_table').on( 'search.dt', function (e,settings) {
get_datatable_count();
});
// filter, filter both grids
$('#q_filter').on( 'keyup', function () {
var repo_api = $('#repo_list_table').dataTable().api();
repo_api
.columns(0)
.search(this.value)
.draw();
});
// refilter table if page load via back button
$("#q_filter").trigger('keyup');
});
</script>
</%def>