mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Fix for showing deleted datasets in a history, also yet another fix for the new users report, users are now sorted descending by last login, as the report states.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
from datetime import datetime, timedelta
|
||||
from time import strftime
|
||||
import calendar
|
||||
import calendar, operator
|
||||
from galaxy.webapps.reports.base.controller import *
|
||||
import galaxy.model
|
||||
from galaxy.model.orm import *
|
||||
@@ -112,6 +112,7 @@ class Users( BaseController ):
|
||||
else:
|
||||
# The user has never logged in
|
||||
users.append( ( user.email, "never logged in" ) )
|
||||
users = sorted( users, key=operator.itemgetter( 1 ), reverse=True )
|
||||
return trans.fill_template( 'users_last_access_date.mako',
|
||||
users=users,
|
||||
not_logged_in_for_days=not_logged_in_for_days,
|
||||
|
||||
@@ -13,7 +13,12 @@
|
||||
<td>
|
||||
<form method="post" controller="users" action="last_access_date">
|
||||
<p>
|
||||
Users that have not logged in to Galaxy for
|
||||
%if users:
|
||||
${len( users ) }
|
||||
%else:
|
||||
0
|
||||
%endif
|
||||
users have not logged in to Galaxy for
|
||||
<input type="textfield" value="${not_logged_in_for_days}" size="3" name="not_logged_in_for_days"> days.
|
||||
<button name="action" value="not_logged_in_for_days">Go</button>
|
||||
</p>
|
||||
|
||||
@@ -11,15 +11,15 @@
|
||||
|
||||
<ul>
|
||||
%if user:
|
||||
<li><a href="${h.url_for( action='history_rename', id=history.id )}" target="galaxy_main">Rename</a> current history (stored as "${history.name}")</li>
|
||||
<li><a href="${h.url_for( action='history_available')}" target="galaxy_main">List</a> previously stored histories</li>
|
||||
<li><a href="${h.url_for( controller='root', action='history_rename', id=history.id )}" target="galaxy_main">Rename</a> current history (stored as "${history.name}")</li>
|
||||
<li><a href="${h.url_for( controller='root', action='history_available')}" target="galaxy_main">List</a> previously stored histories</li>
|
||||
%if len( history.active_datasets ) > 0:
|
||||
<li><a href="${h.url_for('/history_new')}">Create</a> a new empty history</li>
|
||||
<li><a href="${h.url_for( controller='root', action='history_new' )}">Create</a> a new empty history</li>
|
||||
%endif
|
||||
<li><a href="${h.url_for( controller='workflow', action='build_from_current_history' )}">Construct workflow</a> from the current history</li>
|
||||
<li><a href="${h.url_for( action='history_share' )}" target="galaxy_main">Share</a> current history</div>
|
||||
<li><a href="${h.url_for( controller='root', action='history_share' )}" target="galaxy_main">Share</a> current history</div>
|
||||
%endif
|
||||
<li><a href="${h.url_for( action='history', show_deleted=True)}" target="galaxy_history">Show deleted</a> datasets in history</li>
|
||||
<li><a href="${h.url_for( action='history_delete', id=history.id )}" confirm="Are you sure you want to delete the current history?">Delete</a> current history</div>
|
||||
<li><a href="${h.url_for( controller='root', action='history', show_deleted=True)}" target="galaxy_history">Show deleted</a> datasets in history</li>
|
||||
<li><a href="${h.url_for( controller='root', action='history_delete', id=history.id )}" confirm="Are you sure you want to delete the current history?">Delete</a> current history</div>
|
||||
</ul>
|
||||
|
||||
|
||||
@@ -248,7 +248,7 @@ div#footer {
|
||||
|
||||
<%namespace file="history_common.mako" import="render_dataset" />
|
||||
|
||||
%if ( show_deleted and len( history.datasets ) < 1 ) or len( history.active_datasets ) < 1:
|
||||
%if ( show_deleted and not history.activatable_datasets ) or ( not show_deleted and not history.active_datasets ):
|
||||
<div class="infomessagesmall" id="emptyHistoryMessage">
|
||||
%else:
|
||||
<%
|
||||
|
||||
Reference in New Issue
Block a user