exception-tracker: add show-more link.
This commit is contained in:
parent
eb911610bd
commit
c1c8c93ea6
2 changed files with 5 additions and 3 deletions
|
|
@ -28,7 +28,7 @@ from rhodecode.apps.admin.navigation import navigation_list
|
|||
from rhodecode.lib import helpers as h
|
||||
from rhodecode.lib.auth import (
|
||||
LoginRequired, HasPermissionAllDecorator, CSRFRequired)
|
||||
from rhodecode.lib.utils2 import time_to_utcdatetime
|
||||
from rhodecode.lib.utils2 import time_to_utcdatetime, safe_int
|
||||
from rhodecode.lib import exc_tracking
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
|
@ -96,7 +96,8 @@ class ExceptionsTrackerView(BaseAppView):
|
|||
_ = self.request.translate
|
||||
c = self.load_default_context()
|
||||
c.active = 'exceptions_browse'
|
||||
c.limit = self.request.GET.get('limit', 50)
|
||||
c.limit = safe_int(self.request.GET.get('limit')) or 50
|
||||
c.next_limit = c.limit + 50
|
||||
c.exception_list = self.get_all_exceptions(read_metadata=True, limit=c.limit)
|
||||
c.exception_list_count = self.count_all_exceptions()
|
||||
c.exception_store_dir = exc_tracking.get_exc_store()
|
||||
|
|
|
|||
|
|
@ -29,7 +29,8 @@
|
|||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">${_('Exceptions Tracker - Showing the last {} Exceptions').format(c.limit)}</h3>
|
||||
<h3 class="panel-title">${_('Exceptions Tracker - Showing the last {} Exceptions').format(c.limit)}.</h3>
|
||||
<a class="panel-edit" href="${h.current_route_path(request, limit=c.next_limit)}">${_('Show more')}</a>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<table class="rctable">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue