diff --git a/client/galaxy/scripts/mvc/groups/group-detail-view.js b/client/toolshed/scripts/mvc/groups/group-detail-view.js similarity index 99% rename from client/galaxy/scripts/mvc/groups/group-detail-view.js rename to client/toolshed/scripts/mvc/groups/group-detail-view.js index 062ae79274e..aa42e4bcaa5 100644 --- a/client/galaxy/scripts/mvc/groups/group-detail-view.js +++ b/client/toolshed/scripts/mvc/groups/group-detail-view.js @@ -1,6 +1,6 @@ define([ "libs/toastr", - "mvc/groups/group-model" + "toolshed/scripts/mvc/groups/group-model" ], function( mod_toastr, diff --git a/client/galaxy/scripts/mvc/groups/group-list-view.js b/client/toolshed/scripts/mvc/groups/group-list-view.js similarity index 96% rename from client/galaxy/scripts/mvc/groups/group-list-view.js rename to client/toolshed/scripts/mvc/groups/group-list-view.js index 3adeb0feefb..a34f332f78a 100644 --- a/client/galaxy/scripts/mvc/groups/group-list-view.js +++ b/client/toolshed/scripts/mvc/groups/group-list-view.js @@ -1,12 +1,12 @@ define([ "libs/toastr", - "mvc/groups/group-model", - "mvc/groups/group-listrow-view" + "toolshed/scripts/mvc/groups/group-model", + "toolshed/scripts/mvc/groups/group-listrow-view" ], function( mod_toastr, mod_group_model, - mod_group_listrow_view + mod_group_row ){ var GroupListView = Backbone.View.extend({ @@ -71,7 +71,7 @@ var GroupListView = Backbone.View.extend({ * @param {Group} model of the view that will be rendered */ renderOne: function( options ){ - var rowView = new mod_group_listrow_view.GroupListRowView( options ); + var rowView = new mod_group_row.GroupListRowView( options ); this.$el.find( '#group_list_body' ).append( rowView.el ); }, diff --git a/client/galaxy/scripts/mvc/groups/group-listrow-view.js b/client/toolshed/scripts/mvc/groups/group-listrow-view.js similarity index 100% rename from client/galaxy/scripts/mvc/groups/group-listrow-view.js rename to client/toolshed/scripts/mvc/groups/group-listrow-view.js diff --git a/client/galaxy/scripts/mvc/groups/group-model.js b/client/toolshed/scripts/mvc/groups/group-model.js similarity index 100% rename from client/galaxy/scripts/mvc/groups/group-model.js rename to client/toolshed/scripts/mvc/groups/group-model.js diff --git a/client/toolshed/scripts/test-file.js b/client/toolshed/scripts/test-file.js deleted file mode 100644 index 093dfad294e..00000000000 --- a/client/toolshed/scripts/test-file.js +++ /dev/null @@ -1,3 +0,0 @@ -define( [], function() { - return 'Remove this file'; -}); \ No newline at end of file diff --git a/client/galaxy/scripts/toolshed.groups.js b/client/toolshed/scripts/toolshed.groups.js similarity index 88% rename from client/galaxy/scripts/toolshed.groups.js rename to client/toolshed/scripts/toolshed.groups.js index 1785878ed51..d4843e4979a 100644 --- a/client/galaxy/scripts/toolshed.groups.js +++ b/client/toolshed/scripts/toolshed.groups.js @@ -3,9 +3,9 @@ // MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM define([ - "mvc/groups/group-list-view", - "mvc/groups/group-detail-view", - "mvc/groups/group-model" + 'toolshed/scripts/mvc/groups/group-list-view', + 'toolshed/scripts/mvc/groups/group-detail-view', + 'toolshed/scripts/mvc/groups/group-model' ], function( mod_group_list, diff --git a/lib/galaxy/webapps/tool_shed/controllers/groups.py b/lib/galaxy/webapps/tool_shed/controllers/groups.py index 1e1e80f1351..3fac05dee17 100644 --- a/lib/galaxy/webapps/tool_shed/controllers/groups.py +++ b/lib/galaxy/webapps/tool_shed/controllers/groups.py @@ -14,7 +14,7 @@ class Group( BaseUIController ): def index( self, trans, **kwd ): # define app configuration for generic mako template app = { - 'jscript' : "toolshed.groups" + 'jscript' : "../toolshed/scripts/toolshed.groups" } return trans.fill_template( '/webapps/tool_shed/group/index.mako', config = { diff --git a/static/scripts/mvc/groups/group-detail-view.js b/static/scripts/mvc/groups/group-detail-view.js deleted file mode 100644 index fcee488d131..00000000000 --- a/static/scripts/mvc/groups/group-detail-view.js +++ /dev/null @@ -1,2 +0,0 @@ -define(["libs/toastr","mvc/groups/group-model"],function(a,b){var c=Backbone.View.extend({el:"#groups_element",options:{},app:null,initialize:function(a){this.options=_.extend(this.options,a),this.app=window.globalTS.groups,null!==this.app.collection?(this.model=this.app.collection.get(this.options.group_id),this.render()):this.fetchGroup()},fetchGroup:function(c){var d=this;this.options=_.extend(this.options,c),this.model=new b.Group({id:this.options.group_id}),this.model.fetch({success:function(a){console.log("received data: "),console.log(a),d.render()},error:function(b,c){a.error("undefined"!=typeof c.responseJSON?c.responseJSON.err_msg:"An error ocurred.")}})},render:function(){var a=this.templateRow();this.$el.html(a({group:this.model})),$("#center [data-toggle]").tooltip()},templateRow:function(){return _.template(["
",'

<%= group.get("name") %>

','

','A group of <%= group.get("members").length %> members with <%= group.get("repositories").length %> repositories and a total of <%= group.get("total_downloads") %> combined tool downloads.

',"

Members

",'',"","","","","","",'<% _.each(group.get("members"), function(member) { %>',"","","","","","<% }); %>","","
NameRepositoriesRegistered
","<%= member.username %>","",'<%= member.user_repos_count %>',"","<%= member.time_created %>","
","

Repositories

",'',"","","","","","","","","","",'<% _.each(group.get("repositories"), function(repo) { %>',"","","","","","","","","","<% }); %>","","
NameDescriptionDownloadsOwnerCreatedRatingVerified
",'<%= repo.name %>',"","<%= repo.description %>","","<%= repo.times_downloaded %>","","<%= repo.owner %>","","<%= repo.time_created %>","","<%= repo.ratings_mean %>","","<%= repo.approved %>","
","
"].join(""))}});return{GroupDetailView:c}}); -//# sourceMappingURL=../../../maps/mvc/groups/group-detail-view.js.map \ No newline at end of file diff --git a/static/scripts/mvc/groups/group-groupdetail-view.js b/static/scripts/mvc/groups/group-groupdetail-view.js deleted file mode 100644 index ac9d5f5c776..00000000000 --- a/static/scripts/mvc/groups/group-groupdetail-view.js +++ /dev/null @@ -1,2 +0,0 @@ -define([],function(){var a=Backbone.View.extend({events:{},initialize:function(a){this.render(a)},render:function(a){var b=this.templateRow();return this.setElement(b({group:a})),this.$el.show(),this},templateRow:function(){return _.template(["
TEST GROUP PAGE
"].join(""))}});return{GroupDetailView:a}}); -//# sourceMappingURL=../../../maps/mvc/groups/group-groupdetail-view.js.map \ No newline at end of file diff --git a/static/scripts/mvc/groups/group-grouprow-view.js b/static/scripts/mvc/groups/group-grouprow-view.js deleted file mode 100644 index 49178b680f1..00000000000 --- a/static/scripts/mvc/groups/group-grouprow-view.js +++ /dev/null @@ -1,2 +0,0 @@ -define([],function(){var a=Backbone.View.extend({events:{},initialize:function(a){this.render(a)},render:function(a){var b=this.templateRow();return this.setElement(b({group:a})),this.$el.show(),this},templateRow:function(){return _.template(['">','"><%= group.get("name") %>',"description",'<%= group.get("total_members") %>','<%= group.get("total_repos") %>',""].join(""))}});return{GroupRowView:a}}); -//# sourceMappingURL=../../../maps/mvc/groups/group-grouprow-view.js.map \ No newline at end of file diff --git a/static/scripts/mvc/groups/group-list-view.js b/static/scripts/mvc/groups/group-list-view.js deleted file mode 100644 index d14a196bd3f..00000000000 --- a/static/scripts/mvc/groups/group-list-view.js +++ /dev/null @@ -1,2 +0,0 @@ -define(["libs/toastr","mvc/groups/group-model","mvc/groups/group-listrow-view"],function(a,b,c){var d=Backbone.View.extend({el:"#groups_element",defaults:{},initialize:function(c){this.options=_.defaults(this.options||{},this.defaults,c);var d=this;window.globalTS.groups.collection=new b.Groups,window.globalTS.groups.collection.fetch({success:function(a){console.log("received data: "),console.log(a),d.render()},error:function(b,c){a.error("undefined"!=typeof c.responseJSON?c.responseJSON.err_msg:"An error ocurred.")}})},fetch:function(){},render:function(a){this.options=_.extend(this.options,a),$(".tooltip").hide();var b=this.templateGroupsList();this.$el.html(b({length:10,order:"asc"})),this.renderRows(window.globalTS.groups.collection.models),$("#center [data-toggle]").tooltip(),$("#center").css("overflow","auto")},renderRows:function(a){for(var b=0;b'),tmpl_array.push(""),tmpl_array.push('
'),tmpl_array.push("<% if(length === 0) { %>"),tmpl_array.push("
There are no groups yet.
"),tmpl_array.push("<% } else{ %>"),tmpl_array.push(''),tmpl_array.push(" "),tmpl_array.push(' '),tmpl_array.push(' '),tmpl_array.push(' '),tmpl_array.push(' '),tmpl_array.push(" "),tmpl_array.push(' '),tmpl_array.push(" "),tmpl_array.push("
name descriptionmembersrepositories
"),tmpl_array.push("<% }%>"),tmpl_array.push("
"),_.template(tmpl_array.join(""))}});return{GroupListView:d}}); -//# sourceMappingURL=../../../maps/mvc/groups/group-list-view.js.map \ No newline at end of file diff --git a/static/scripts/mvc/groups/group.model.js b/static/scripts/mvc/groups/group.model.js deleted file mode 100644 index b050bdad096..00000000000 --- a/static/scripts/mvc/groups/group.model.js +++ /dev/null @@ -1,2 +0,0 @@ -define([],function(){var a=Backbone.Model.extend({urlRoot:"/api/groups/"}),b=Backbone.Collection.extend({url:"/api/groups",model:a});return{Group:a,Groups:b}}); -//# sourceMappingURL=../../../maps/mvc/groups/group.model.js.map \ No newline at end of file diff --git a/static/scripts/toolshed.groups.js b/static/scripts/toolshed.groups.js deleted file mode 100644 index 4c0663b9afb..00000000000 --- a/static/scripts/toolshed.groups.js +++ /dev/null @@ -1,2 +0,0 @@ -define(["mvc/groups/group-list-view","mvc/groups/group-detail-view","mvc/groups/group-model"],function(a,b){var c=Backbone.Router.extend({routes:{"":"groups",":group_id":"group_page"}}),d=Backbone.View.extend({groupListView:null,groupDetailView:null,collection:null,initialize:function(){window.globalTS.groups=this,this.ts_router=new c,this.ts_router.on("route:groups",function(){window.globalTS.groups.groupListView=new a.GroupListView}),this.ts_router.on("route:group_page",function(a){window.globalTS.groups.groupDetailView=new b.GroupDetailView({group_id:a})}),Backbone.history.start({pushState:!1})}});return{ToolshedGroups:d}}); -//# sourceMappingURL=../maps/toolshed.groups.js.map \ No newline at end of file diff --git a/static/toolshed/maps/mvc/groups/group-detail-view.js.map b/static/toolshed/maps/mvc/groups/group-detail-view.js.map new file mode 100644 index 00000000000..516498bde80 --- /dev/null +++ b/static/toolshed/maps/mvc/groups/group-detail-view.js.map @@ -0,0 +1 @@ +{"version":3,"file":"group-detail-view.js","sources":["../../../src/mvc/groups/group-detail-view.js"],"names":["define","mod_toastr","mod_group_model","GroupDetailView","Backbone","View","extend","el","options","app","initialize","this","_","window","globalTS","groups","collection","model","get","group_id","render","fetchGroup","that","Group","id","fetch","success","console","log","error","response","responseJSON","err_msg","template","templateRow","$el","html","group","$","tooltip","join"],"mappings":"AAAAA,QACI,cACA,2CAEJ,SACIC,EACAC,GAIJ,GAAIC,GAAkBC,SAASC,KAAKC,QAChCC,GAAI,kBACJC,WACAC,IAAK,KAELC,WAAa,SAAUF,GACnBG,KAAKH,QAAUI,EAAEN,OAAQK,KAAKH,QAASA,GACvCG,KAAKF,IAAMI,OAAOC,SAASC,OAEE,OAAxBJ,KAAKF,IAAIO,YACVL,KAAKM,MAAQN,KAAKF,IAAIO,WAAWE,IAAKP,KAAKH,QAAQW,UACnDR,KAAKS,UAELT,KAAKU,cAKbA,WAAY,SAAUb,GAClB,GAAIc,GAAOX,IACXA,MAAKH,QAAUI,EAAEN,OAAQK,KAAKH,QAASA,GACvCG,KAAKM,MAAQ,GAAIf,GAAgBqB,OAASC,GAAIb,KAAKH,QAAQW,WAC3DR,KAAKM,MAAMQ,OACTC,QAAS,SAAUT,GACjBU,QAAQC,IAAK,mBACbD,QAAQC,IAAKX,GACbK,EAAKF,UAEPS,MAAO,SAAUZ,EAAOa,GAElB7B,EAAW4B,MADyB,mBAA1BC,GAASC,aACDD,EAASC,aAAaC,QAEtB,yBAM9BZ,OAAQ,WACJ,GAAIa,GAAWtB,KAAKuB,aACpBvB,MAAKwB,IAAIC,KAAMH,GAAYI,MAAO1B,KAAKM,SACvCqB,EAAE,yBAAyBC,WAG/BL,YAAa,WACT,MAAOtB,GAAEqB,UACD,QACI,oCACA,mCACA,kMAEA,mBACA,6CACI,UACI,gBACA,wBACA,sBACJ,WACA,UACI,wDACA,OACI,OACI,yBACJ,QACA,OACI,gPACJ,QACA,OACI,6BACJ,QACJ,QACA,YACJ,WACJ,WAEA,wBACA,6CACI,UACI,gBACA,uBACA,qBACA,iBACA,mBACA,kBACA,oBACJ,WACA,UACI,2DACA,OACI,OACI,6KACJ,QACA,OACI,0BACJ,QACA,OACI,+BACJ,QACA,OACI,oBACJ,QACA,OACI,2BACJ,QACA,OACI,2BACJ,QACA,OACI,uBACJ,QACJ,QACA,YACJ,WACJ,WACJ,UACNO,KAAK,OAGf,QACIrC,gBAAiBA"} \ No newline at end of file diff --git a/static/toolshed/maps/mvc/groups/group-list-view.js.map b/static/toolshed/maps/mvc/groups/group-list-view.js.map new file mode 100644 index 00000000000..2214b0b5952 --- /dev/null +++ b/static/toolshed/maps/mvc/groups/group-list-view.js.map @@ -0,0 +1 @@ +{"version":3,"file":"group-list-view.js","sources":["../../../src/mvc/groups/group-list-view.js"],"names":["define","mod_toastr","mod_group_model","mod_group_row","GroupListView","Backbone","View","extend","el","defaults","initialize","options","this","_","that","window","globalTS","groups","collection","Groups","fetch","success","model","console","log","render","error","response","responseJSON","err_msg","$","hide","template","templateGroupsList","$el","html","length","order","renderRows","models","tooltip","css","groups_to_render","i","group","renderOne","rowView","GroupListRowView","find","append","tmpl_array","push","join"],"mappings":"AAAAA,QACI,cACA,0CACA,kDAED,SACCC,EACAC,EACAC,GAGJ,GAAIC,GAAgBC,SAASC,KAAKC,QAC9BC,GAAI,kBACJC,YAOAC,WAAa,SAAUC,GACnBC,KAAKD,QAAUE,EAAEJ,SAAUG,KAAKD,YAAeC,KAAKH,SAAUE,EAC9D,IAAIG,GAAOF,IACXG,QAAOC,SAASC,OAAOC,WAAa,GAAIhB,GAAgBiB,OACxDJ,OAAOC,SAASC,OAAOC,WAAWE,OAChCC,QAAS,SAAUC,GACjBC,QAAQC,IAAK,mBACbD,QAAQC,IAAKF,GACbR,EAAKW,UAEPC,MAAO,SAAUJ,EAAOK,GAElB1B,EAAWyB,MADyB,mBAA1BC,GAASC,aACDD,EAASC,aAAaC,QAEtB,yBAO9BT,MAAO,aAMPK,OAAQ,SAAWd,GACfC,KAAKD,QAAUE,EAAEN,OAAQK,KAAKD,QAASA,GACvCmB,EAAG,YAAaC,MAChB,IAAIC,GAAWpB,KAAKqB,oBACpBrB,MAAKsB,IAAIC,KAAMH,GAAYI,OAAQ,GAAIC,MAAO,SAC9CzB,KAAK0B,WAAYvB,OAAOC,SAASC,OAAOC,WAAWqB,QACnDT,EAAG,yBAA0BU,UAC7BV,EAAG,WAAYW,IAAK,WAAW,SAOnCH,WAAY,SAAUI,GAClB,IAAM,GAAIC,GAAI,EAAGA,EAAID,EAAiBN,OAAQO,IAAM,CAChD,GAAIC,GAAQF,EAAiBC,EAC7B/B,MAAKiC,WAAaD,MAAOA,MAQjCC,UAAW,SAAUlC,GACjB,GAAImC,GAAU,GAAI3C,GAAc4C,iBAAkBpC,EAClDC,MAAKsB,IAAIc,KAAM,oBAAqBC,OAAQH,EAAQtC,KAyCxDyB,mBAAoB,WAuBhB,MAtBAiB,eAEAA,WAAWC,KAAK,qBAChBD,WAAWC,KAAK,UAChBD,WAAWC,KAAK,mDAChBD,WAAWC,KAAK,4BAChBD,WAAWC,KAAK,uCAChBD,WAAWC,KAAK,iBAChBD,WAAWC,KAAK,8CAChBD,WAAWC,KAAK,cAChBD,WAAWC,KAAK,mMAChBD,WAAWC,KAAK,gDAChBD,WAAWC,KAAK,6CAChBD,WAAWC,KAAK,iDAChBD,WAAWC,KAAK,eAChBD,WAAWC,KAAK,mCAEhBD,WAAWC,KAAK,eAChBD,WAAWC,KAAK,YAChBD,WAAWC,KAAK,UAChBD,WAAWC,KAAK,UAETtC,EAAEmB,SAASkB,WAAWE,KAAK,OAK1C,QACIhD,cAAeA"} \ No newline at end of file diff --git a/static/toolshed/maps/mvc/groups/group-listrow-view.js.map b/static/toolshed/maps/mvc/groups/group-listrow-view.js.map new file mode 100644 index 00000000000..a3a50073eab --- /dev/null +++ b/static/toolshed/maps/mvc/groups/group-listrow-view.js.map @@ -0,0 +1 @@ +{"version":3,"file":"group-listrow-view.js","sources":["../../../src/mvc/groups/group-listrow-view.js"],"names":["define","GroupListRowView","Backbone","View","extend","events","initialize","options","this","render","group","tmpl","templateRow","setElement","$el","show","_","template","join"],"mappings":"AAAAA,UACA,WAGA,GAAIC,GAAmBC,SAASC,KAAKC,QACjCC,UAEAC,WAAa,SAAUC,GACnBC,KAAKC,OAAQF,EAAQG,QAGzBD,OAAQ,SAAUC,GACd,GAAIC,GAAOH,KAAKI,aAGhB,OAFAJ,MAAKK,WAAWF,GAAQD,MAAMA,KAC9BF,KAAKM,IAAIC,OACFP,MAGXI,YAAa,WACT,MAAOI,GAAEC,UACD,iDACA,iFACA,uBACA,6CACA,2CACA,SACNC,KAAK,OAKf,QACIjB,iBAAkBA"} \ No newline at end of file diff --git a/static/toolshed/maps/mvc/groups/group-model.js.map b/static/toolshed/maps/mvc/groups/group-model.js.map new file mode 100644 index 00000000000..7cf16222049 --- /dev/null +++ b/static/toolshed/maps/mvc/groups/group-model.js.map @@ -0,0 +1 @@ +{"version":3,"file":"group-model.js","sources":["../../../src/mvc/groups/group-model.js"],"names":["define","Group","Backbone","Model","extend","urlRoot","Groups","Collection","url","model"],"mappings":"AAAAA,UAAW,WAKP,GAAIC,GAAQC,SAASC,MAAMC,QACzBC,QAAS,gBAGPC,EAASJ,SAASK,WAAWH,QAC/BI,IAAK,cAELC,MAAOR,GAIb,QACIA,MAAOA,EACPK,OAAQA"} \ No newline at end of file diff --git a/static/toolshed/maps/test-file.js.map b/static/toolshed/maps/test-file.js.map new file mode 100644 index 00000000000..60e635db925 --- /dev/null +++ b/static/toolshed/maps/test-file.js.map @@ -0,0 +1 @@ +{"version":3,"file":"test-file.js","sources":["../src/test-file.js"],"names":["define"],"mappings":"AAAAA,UAAY,WACX,MAAO"} \ No newline at end of file diff --git a/static/toolshed/maps/toolshed.groups.js.map b/static/toolshed/maps/toolshed.groups.js.map new file mode 100644 index 00000000000..654c967d2c1 --- /dev/null +++ b/static/toolshed/maps/toolshed.groups.js.map @@ -0,0 +1 @@ +{"version":3,"file":"toolshed.groups.js","sources":["../src/toolshed.groups.js"],"names":["define","mod_group_list","mod_group_detail","ToolshedRouter","Backbone","Router","extend","routes",":group_id","ToolshedGroups","View","groupListView","groupDetailView","collection","initialize","window","globalTS","groups","this","ts_router","on","GroupListView","group_id","GroupDetailView","history","start","pushState"],"mappings":"AAIAA,QACQ,8CACA,gDACA,2CAEJ,SACIC,EACAC,GAMR,GAAIC,GAAiBC,SAASC,OAAOC,QACjCC,QACI,GAA4B,SAC5BC,YAA4B,gBAKhCC,EAAiBL,SAASM,KAAKJ,QAC/BK,cAAe,KACfC,gBAAiB,KACjBC,WAAY,KAEZC,WAAa,WACTC,OAAOC,SAASC,OAASC,KAEzBA,KAAKC,UAAY,GAAIhB,GACrBe,KAAKC,UAAUC,GAAI,eAAgB,WAC/BL,OAAOC,SAASC,OAAON,cAAgB,GAAIV,GAAeoB,gBAG9DH,KAAKC,UAAUC,GAAI,mBAAoB,SAAUE,GAC7CP,OAAOC,SAASC,OAAOL,gBAAkB,GAAIV,GAAiBqB,iBAAmBD,SAAUA,MAG/FlB,SAASoB,QAAQC,OAAOC,WAAW,MAI3C,QACIjB,eAAgBA"} \ No newline at end of file diff --git a/static/toolshed/scripts/mvc/groups/group-detail-view.js b/static/toolshed/scripts/mvc/groups/group-detail-view.js new file mode 100644 index 00000000000..92a188269c3 --- /dev/null +++ b/static/toolshed/scripts/mvc/groups/group-detail-view.js @@ -0,0 +1,2 @@ +define(["libs/toastr","toolshed/scripts/mvc/groups/group-model"],function(a,b){var c=Backbone.View.extend({el:"#groups_element",options:{},app:null,initialize:function(a){this.options=_.extend(this.options,a),this.app=window.globalTS.groups,null!==this.app.collection?(this.model=this.app.collection.get(this.options.group_id),this.render()):this.fetchGroup()},fetchGroup:function(c){var d=this;this.options=_.extend(this.options,c),this.model=new b.Group({id:this.options.group_id}),this.model.fetch({success:function(a){console.log("received data: "),console.log(a),d.render()},error:function(b,c){a.error("undefined"!=typeof c.responseJSON?c.responseJSON.err_msg:"An error ocurred.")}})},render:function(){var a=this.templateRow();this.$el.html(a({group:this.model})),$("#center [data-toggle]").tooltip()},templateRow:function(){return _.template(["
",'

<%= group.get("name") %>

','

','A group of <%= group.get("members").length %> members with <%= group.get("repositories").length %> repositories and a total of <%= group.get("total_downloads") %> combined tool downloads.

',"

Members

",'',"","","","","","",'<% _.each(group.get("members"), function(member) { %>',"","","","","","<% }); %>","","
NameRepositoriesRegistered
","<%= member.username %>","",'<%= member.user_repos_count %>',"","<%= member.time_created %>","
","

Repositories

",'',"","","","","","","","","","",'<% _.each(group.get("repositories"), function(repo) { %>',"","","","","","","","","","<% }); %>","","
NameDescriptionDownloadsOwnerCreatedRatingVerified
",'<%= repo.name %>',"","<%= repo.description %>","","<%= repo.times_downloaded %>","","<%= repo.owner %>","","<%= repo.time_created %>","","<%= repo.ratings_mean %>","","<%= repo.approved %>","
","
"].join(""))}});return{GroupDetailView:c}}); +//# sourceMappingURL=../../../maps/mvc/groups/group-detail-view.js.map \ No newline at end of file diff --git a/static/toolshed/scripts/mvc/groups/group-list-view.js b/static/toolshed/scripts/mvc/groups/group-list-view.js new file mode 100644 index 00000000000..f956c996d92 --- /dev/null +++ b/static/toolshed/scripts/mvc/groups/group-list-view.js @@ -0,0 +1,2 @@ +define(["libs/toastr","toolshed/scripts/mvc/groups/group-model","toolshed/scripts/mvc/groups/group-listrow-view"],function(a,b,c){var d=Backbone.View.extend({el:"#groups_element",defaults:{},initialize:function(c){this.options=_.defaults(this.options||{},this.defaults,c);var d=this;window.globalTS.groups.collection=new b.Groups,window.globalTS.groups.collection.fetch({success:function(a){console.log("received data: "),console.log(a),d.render()},error:function(b,c){a.error("undefined"!=typeof c.responseJSON?c.responseJSON.err_msg:"An error ocurred.")}})},fetch:function(){},render:function(a){this.options=_.extend(this.options,a),$(".tooltip").hide();var b=this.templateGroupsList();this.$el.html(b({length:10,order:"asc"})),this.renderRows(window.globalTS.groups.collection.models),$("#center [data-toggle]").tooltip(),$("#center").css("overflow","auto")},renderRows:function(a){for(var b=0;b'),tmpl_array.push(""),tmpl_array.push('
'),tmpl_array.push("<% if(length === 0) { %>"),tmpl_array.push("
There are no groups yet.
"),tmpl_array.push("<% } else{ %>"),tmpl_array.push(''),tmpl_array.push(" "),tmpl_array.push(' '),tmpl_array.push(' '),tmpl_array.push(' '),tmpl_array.push(' '),tmpl_array.push(" "),tmpl_array.push(' '),tmpl_array.push(" "),tmpl_array.push("
name descriptionmembersrepositories
"),tmpl_array.push("<% }%>"),tmpl_array.push("
"),_.template(tmpl_array.join(""))}});return{GroupListView:d}}); +//# sourceMappingURL=../../../maps/mvc/groups/group-list-view.js.map \ No newline at end of file diff --git a/static/scripts/mvc/groups/group-listrow-view.js b/static/toolshed/scripts/mvc/groups/group-listrow-view.js similarity index 100% rename from static/scripts/mvc/groups/group-listrow-view.js rename to static/toolshed/scripts/mvc/groups/group-listrow-view.js diff --git a/static/scripts/mvc/groups/group-model.js b/static/toolshed/scripts/mvc/groups/group-model.js similarity index 100% rename from static/scripts/mvc/groups/group-model.js rename to static/toolshed/scripts/mvc/groups/group-model.js diff --git a/static/toolshed/scripts/toolshed.groups.js b/static/toolshed/scripts/toolshed.groups.js new file mode 100644 index 00000000000..87de050425f --- /dev/null +++ b/static/toolshed/scripts/toolshed.groups.js @@ -0,0 +1,2 @@ +define(["toolshed/scripts/mvc/groups/group-list-view","toolshed/scripts/mvc/groups/group-detail-view","toolshed/scripts/mvc/groups/group-model"],function(a,b){var c=Backbone.Router.extend({routes:{"":"groups",":group_id":"group_page"}}),d=Backbone.View.extend({groupListView:null,groupDetailView:null,collection:null,initialize:function(){window.globalTS.groups=this,this.ts_router=new c,this.ts_router.on("route:groups",function(){window.globalTS.groups.groupListView=new a.GroupListView}),this.ts_router.on("route:group_page",function(a){window.globalTS.groups.groupDetailView=new b.GroupDetailView({group_id:a})}),Backbone.history.start({pushState:!1})}});return{ToolshedGroups:d}}); +//# sourceMappingURL=../maps/toolshed.groups.js.map \ No newline at end of file diff --git a/templates/webapps/tool_shed/group/index.mako b/templates/webapps/tool_shed/group/index.mako index e070faec5ee..297c16fda8d 100644 --- a/templates/webapps/tool_shed/group/index.mako +++ b/templates/webapps/tool_shed/group/index.mako @@ -41,6 +41,11 @@