Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Insert admin app, redirect controller
- Loading branch information
Showing
14 changed files
with
186 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
var jQuery = require( 'jquery' ), | ||
$ = jQuery, | ||
GalaxyApp = require( 'galaxy' ).GalaxyApp, | ||
AdminPanel = require( './panels/admin-panel' ), | ||
Page = require( 'layout/page' ); | ||
|
||
window.app = function app( options, bootstrapped ){ | ||
window.Galaxy = new GalaxyApp( options, bootstrapped ); | ||
Galaxy.debug( 'admin app' ); | ||
Galaxy.params = Galaxy.config.params; | ||
|
||
// render and start the router | ||
$(function(){ | ||
|
||
Galaxy.page = new Page.View( _.extend( options, { | ||
Left : AdminPanel | ||
} ) ); | ||
|
||
// start the router - which will call any of the routes above | ||
Backbone.history.start({ | ||
root : Galaxy.root, | ||
pushState : true, | ||
}); | ||
}); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
var _l = require( 'utils/localization' ); | ||
|
||
var AdminPanel = Backbone.View.extend({ | ||
initialize: function( page, options ) { | ||
// access configuration options | ||
var config = options.config; | ||
this.root = options.root; | ||
|
||
// components for panel definition | ||
this.model = new Backbone.Model({ | ||
title : _l( 'Administration' ) | ||
}); | ||
|
||
// build body template | ||
this.setElement( this._template() ); | ||
}, | ||
|
||
render : function(){ | ||
}, | ||
|
||
/** override to include inital menu dom and workflow section */ | ||
_template : function() { | ||
return [ | ||
'<div class="toolMenuContainer">', | ||
'<div class="toolMenu">', | ||
'<div class="toolSectionList">', | ||
'<div class="toolSectionTitle">Server</div>', | ||
'<div class="toolSectionBody">', | ||
'<div class="toolSectionBg">', | ||
'<div class="toolTitle"><a href="${h.url_for( controller="admin", action="view_datatypes_registry" )}" target="galaxy_main">Data types registry</a></div>', | ||
'<div class="toolTitle"><a href="${h.url_for( controller="admin", action="view_tool_data_tables" )}" target="galaxy_main">Data tables registry</a></div>', | ||
'<div class="toolTitle"><a href="${h.url_for( controller="admin", action="display_applications" )}" target="galaxy_main">Display applications</a></div>', | ||
'<div class="toolTitle"><a href="${h.url_for( controller="admin", action="jobs" )}" target="galaxy_main">Manage jobs</a></div>', | ||
'</div>', | ||
'</div>', | ||
'</div>', | ||
'</div>', | ||
'</div>' | ||
|
||
|
||
/*<div class="toolSectionPad"></div> | ||
<div class="toolSectionTitle">Tools and Tool Shed</div> | ||
<div class="toolSectionBody"> | ||
<div class="toolSectionBg"> | ||
%if trans.app.tool_shed_registry and trans.app.tool_shed_registry.tool_sheds: | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin_toolshed', action='browse_tool_sheds' )}" target="galaxy_main">Search Tool Shed</a></div> | ||
%if trans.app.config.enable_beta_ts_api_install: | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin_toolshed', action='browse_toolsheds' )}" target="galaxy_main">Search Tool Shed (Beta)</a></div> | ||
%endif | ||
%endif | ||
%if installing_repository_ids: | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin_toolshed', action='monitor_repository_installation', tool_shed_repository_ids=installing_repository_ids )}" target="galaxy_main">Monitor installing repositories</a></div> | ||
%endif | ||
%if is_repo_installed: | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin_toolshed', action='browse_repositories' )}" target="galaxy_main">Manage installed tools</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin_toolshed', action='reset_metadata_on_selected_installed_repositories' )}" target="galaxy_main">Reset metadata</a></div> | ||
%endif | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='package_tool' )}" target="galaxy_main">Download local tool</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='tool_versions' )}" target="galaxy_main">Tool lineage</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='reload_tool' )}" target="galaxy_main">Reload a tool's configuration</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='review_tool_migration_stages' )}" target="galaxy_main">Review tool migration stages</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='tool_errors' )}" target="galaxy_main">View Tool Error Logs</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='sanitize_whitelist' )}" target="galaxy_main">Manage Display Whitelist</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='manage_tool_dependencies' )}" target="galaxy_main">Manage Tool Dependencies</a></div> | ||
</div> | ||
</div> | ||
<div class="toolSectionPad"></div> | ||
<div class="toolSectionTitle">User Management</div> | ||
<div class="toolSectionBody"> | ||
<div class="toolSectionBg"> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='users' )}" target="galaxy_main">Users</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='groups' )}" target="galaxy_main">Groups</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='roles' )}" target="galaxy_main">Roles</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='userskeys', action='all_users' )}" target="galaxy_main">API keys</a></div> | ||
%if trans.app.config.allow_user_impersonation: | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='impersonate' )}" target="galaxy_main">Impersonate a user</a></div> | ||
%endif | ||
</div> | ||
</div> | ||
<div class="toolSectionPad"></div> | ||
<div class="toolSectionTitle">Data</div> | ||
<div class="toolSectionBody"> | ||
<div class="toolSectionBg"> | ||
%if trans.app.config.enable_quotas: | ||
<div class="toolTitle"><a href="${h.url_for( controller='admin', action='quotas' )}" target="galaxy_main">Quotas</a></div> | ||
%endif | ||
<div class="toolTitle"><a href="${h.url_for( controller='library_admin', action='browse_libraries' )}" target="galaxy_main">Data libraries</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='data_manager' )}" target="galaxy_main">Local data</a></div> | ||
</div> | ||
</div> | ||
<div class="toolSectionPad"></div> | ||
<div class="toolSectionTitle">Form Definitions</div> | ||
<div class="toolSectionBody"> | ||
<div class="toolSectionBg"> | ||
<div class="toolTitle"><a href="${h.url_for( controller='forms', action='browse_form_definitions' )}" target="galaxy_main">Form definitions</a></div> | ||
</div> | ||
</div> | ||
<div class="toolSectionPad"></div> | ||
<div class="toolSectionTitle">Sample Tracking</div> | ||
<div class="toolSectionBody"> | ||
<div class="toolSectionBg"> | ||
<div class="toolTitle"><a href="${h.url_for( controller='external_service', action='browse_external_services' )}" target="galaxy_main">Sequencers and external services</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='request_type', action='browse_request_types' )}" target="galaxy_main">Request types</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='requests_admin', action='browse_requests' )}" target="galaxy_main">Sequencing requests</a></div> | ||
<div class="toolTitle"><a href="${h.url_for( controller='requests_common', action='find_samples', cntrller='requests_admin' )}" target="galaxy_main">Find samples</a></div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div>*/ | ||
|
||
].join(''); | ||
}, | ||
|
||
toString : function() { return 'adminPanel' } | ||
}); | ||
|
||
module.exports = AdminPanel; |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.