mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-21 13:50:20 +08:00
1 line
3.1 KiB
JavaScript
1 line
3.1 KiB
JavaScript
define("admin.toolshed",["exports","mvc/toolshed/shed-list-view","mvc/toolshed/categories-view","mvc/toolshed/repositories-view","mvc/toolshed/repository-view","mvc/toolshed/repository-queue-view","mvc/toolshed/repo-status-view","mvc/toolshed/workflows-view"],function(e,o,t,a,i,s,d,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(e,"__esModule",{value:!0});var l=n(o),p=n(t),h=n(a),u=n(i),w=n(s),m=n(d),y=n(r),c=Backbone.Router.extend({initialize:function(){this.routesHit=0,Backbone.history.on("route",function(){this.routesHit++},this),this.bind("route",this.trackPageview)},routes:{"":"toolsheds",sheds:"toolsheds",queue:"queue",workflows:"workflows","status/r/:repositories":"status",status:"status","categories/s/:tool_shed":"categories","category/s/:tool_shed/c/:cateory_id":"repositories","repository/s/:tool_shed/r/:repository_id":"repository"},back:function(){this.routesHit>1?window.history.back():this.navigate("#",{trigger:!0,replace:!0})}}),f=Backbone.View.extend({app_config:{known_views:["toolsheds","queue","status","categories","repositories","repoository"]},initialize:function(){Galaxy.admintoolshedapp=this,this.admin_toolshed_router=new c,this.admin_toolshed_router.on("route:queue",function(){Galaxy.admintoolshedapp.adminRepoQueueView?Galaxy.admintoolshedapp.adminRepoQueueView.reDraw():Galaxy.admintoolshedapp.adminRepoQueueView=new w.default.RepoQueueView}),this.admin_toolshed_router.on("route:toolsheds",function(){Galaxy.admintoolshedapp.adminShedListView?Galaxy.admintoolshedapp.adminShedListView.reDraw():Galaxy.admintoolshedapp.adminShedListView=new l.default.ShedListView}),this.admin_toolshed_router.on("route:categories",function(e){Galaxy.admintoolshedapp.adminShedCategoriesView?Galaxy.admintoolshedapp.adminShedCategoriesView.reDraw({tool_shed:e.replace(/\//g,"%2f")}):Galaxy.admintoolshedapp.adminShedCategoriesView=new p.default.CategoryView({tool_shed:e.replace(/\//g,"%2f")})}),this.admin_toolshed_router.on("route:repositories",function(e,o){Galaxy.admintoolshedapp.adminShedCategoryView?Galaxy.admintoolshedapp.adminShedCategoryView.reDraw({tool_shed:e.replace(/\//g,"%2f"),category_id:o}):Galaxy.admintoolshedapp.adminShedCategoryView=new h.default.Category({tool_shed:e.replace(/\//g,"%2f"),category_id:o})}),this.admin_toolshed_router.on("route:repository",function(e,o){Galaxy.admintoolshedapp.adminRepositoryView?Galaxy.admintoolshedapp.adminRepositoryView.reDraw({tool_shed:e.replace(/\//g,"%2f"),repository_id:o}):Galaxy.admintoolshedapp.adminRepositoryView=new u.default.RepoDetails({tool_shed:e.replace(/\//g,"%2f"),repository_id:o})}),this.admin_toolshed_router.on("route:status",function(e){Galaxy.admintoolshedapp.adminRepoStatusView?Galaxy.admintoolshedapp.adminRepoStatusView.reDraw({repositories:e.split("|")}):Galaxy.admintoolshedapp.adminRepoStatusView=new m.default.RepoStatus({repositories:e.split("|")})}),this.admin_toolshed_router.on("route:workflows",function(){Galaxy.admintoolshedapp.adminWorkflowsView?Galaxy.admintoolshedapp.adminWorkflowsView.reDraw():Galaxy.admintoolshedapp.adminWorkflowsView=new y.default.Workflows}),Backbone.history.start({pushState:!1})}});e.default={GalaxyApp:f}}); |