mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Sort tags for display (note, this is stupid to have in 3 places -- refactor)
This commit is contained in:
@@ -307,7 +307,7 @@ var DatasetListItemView = _super.extend(
|
||||
|
||||
_renderNametags : function(){
|
||||
var tpl = _.template([
|
||||
'<% _.each(_.uniq(tags), function(tag){ %>',
|
||||
'<% _.each(_.sortBy(_.uniq(tags), function(x) { return x }), function(tag){ %>',
|
||||
'<% if (tag.indexOf("name:") == 0){ %>',
|
||||
'<span class="label label-info"><%- tag.slice(5) %></span>',
|
||||
'<% } %>',
|
||||
|
||||
@@ -16,7 +16,7 @@ var _super = DATASET_LI.DatasetListItemView;
|
||||
var HDAListItemView = _super.extend(
|
||||
/** @lends HDAListItemView.prototype */{
|
||||
|
||||
className : _super.prototype.className + " history-content",
|
||||
className : _super.prototype.className + " history-content",
|
||||
|
||||
initialize : function( attributes, options ){
|
||||
_super.prototype.initialize.call( this, attributes, options );
|
||||
@@ -45,7 +45,7 @@ HDAListItemView.prototype.templates = (function(){
|
||||
'</div>',
|
||||
'</br>',
|
||||
'<span class="nametags">',
|
||||
'<% _.each(dataset.tags, function(tag){ %>',
|
||||
'<% _.each(_.sortBy(_.uniq(dataset.tags), function(x) { return x }), function(tag){ %>',
|
||||
'<% if (tag.indexOf("name:") == 0){ %>',
|
||||
'<span class="label label-info"><%- tag.slice(5) %></span>',
|
||||
'<% } %>',
|
||||
|
||||
@@ -85,7 +85,7 @@ HDCAListItemView.prototype.templates = (function(){
|
||||
'</div>',
|
||||
'<div class="subtitle"></div>',
|
||||
'<span class="nametags">',
|
||||
'<% _.each(_.uniq(collection.tags), function(tag){ %>',
|
||||
'<% _.each(_.sortBy(_.uniq(collection.tags), function(x) { return x }), function(tag){ %>',
|
||||
'<% if (tag.indexOf("name:") == 0){ %>',
|
||||
'<span class="label label-info"><%- tag.slice(5) %></span>',
|
||||
'<% } %>',
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
|
||||
{"version":3,"file":"hda-li.js","sources":["../../../src/mvc/history/hda-li.js"],"names":["define","DATASET_LI","BASE_MVC","_l","_super","DatasetListItemView","HDAListItemView","extend","className","prototype","initialize","attributes","options","call","this","toString","modelString","model","templates","titleBarTemplate","wrapTemplate","warnings","_","hidden","titleBar"],"mappings":"AAAAA,QACI,yBACA,eACA,sBACD,SAAUC,EAAYC,EAAUC,GAEnC,YAGA,IAAIC,GAASH,EAAWI,oBAMpBC,EAAkBF,EAAOG,QAGzBC,UAAcJ,EAAOK,UAAUD,UAAY,mBAE3CE,WAAa,SAAUC,EAAYC,GAC/BR,EAAOK,UAAUC,WAAWG,KAAMC,KAAMH,EAAYC,IAKxDG,SAAW,WACP,GAAIC,GAAgBF,KAAW,MAAIA,KAAKG,MAAQ,GAAK,YACrD,OAAO,mBAAqBD,EAAc,MAgD9C,OA1CJV,GAAgBG,UAAUS,UAAa,WAEnC,GAAIC,GAAmBjB,EAASkB,cAE5B,6CACI,mCACA,sBAEI,+CACA,gDACJ,SACA,QACA,0BACI,4CACI,wCACI,4DACJ,UACJ,YACJ,UACJ,UACD,WAECC,EAAWC,EAAEf,UAAYH,EAAOK,UAAUS,UAAUG,UACpDE,OAASrB,EAASkB,cAEd,gCACI,+CACIjB,EAAI,gCACR,SACJ,WACD,YAGP,OAAOmB,GAAEf,UAAYH,EAAOK,UAAUS,WAClCM,SAAWL,EACXE,SAAWA,QAQXf,gBAAmBA"}
|
||||
{"version":3,"file":"hda-li.js","sources":["../../../src/mvc/history/hda-li.js"],"names":["define","DATASET_LI","BASE_MVC","_l","_super","DatasetListItemView","HDAListItemView","extend","className","prototype","initialize","attributes","options","call","this","toString","modelString","model","templates","titleBarTemplate","wrapTemplate","warnings","_","hidden","titleBar"],"mappings":"AAAAA,QACI,yBACA,eACA,sBACD,SAAUC,EAAYC,EAAUC,GAEnC,YAGA,IAAIC,GAASH,EAAWI,oBAMpBC,EAAkBF,EAAOG,QAGzBC,UAAYJ,EAAOK,UAAUD,UAAY,mBAEzCE,WAAa,SAAUC,EAAYC,GAC/BR,EAAOK,UAAUC,WAAWG,KAAMC,KAAMH,EAAYC,IAKxDG,SAAW,WACP,GAAIC,GAAgBF,KAAW,MAAIA,KAAKG,MAAQ,GAAK,YACrD,OAAO,mBAAqBD,EAAc,MAgD9C,OA1CJV,GAAgBG,UAAUS,UAAa,WAEnC,GAAIC,GAAmBjB,EAASkB,cAE5B,6CACI,mCACA,sBAEI,+CACA,gDACJ,SACA,QACA,0BACI,wFACI,wCACI,4DACJ,UACJ,YACJ,UACJ,UACD,WAECC,EAAWC,EAAEf,UAAYH,EAAOK,UAAUS,UAAUG,UACpDE,OAASrB,EAASkB,cAEd,gCACI,+CACIjB,EAAI,gCACR,SACJ,WACD,YAGP,OAAOmB,GAAEf,UAAYH,EAAOK,UAAUS,WAClCM,SAAWL,EACXE,SAAWA,QAQXf,gBAAmBA"}
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"file":"hdca-li.js","sources":["../../../src/mvc/history/hdca-li.js"],"names":["define","STATES","DC_LI","DC_VIEW","BASE_MVC","_l","_super","DCListItemView","HDCAListItemView","extend","className","prototype","_setUpListeners","call","this","listenTo","model","change:tags change:populated change:visible","render","_getFoldoutPanelClass","get","ListCollectionView","PairCollectionView","ListOfPairsCollectionView","ListOfListsCollectionView","TypeError","_swapNewRender","$newRender","state","OK","RUNNING","$el","addClass","toString","modelString","templates","warnings","_","hidden","wrapTemplate","titleBarTemplate","titleBar"],"mappings":"AAAAA,QACI,qBACA,+BACA,iCACA,eACA,sBACD,SAAUC,EAAQC,EAAOC,EAASC,EAAUC,GAE/C,YAGA,IAAIC,GAASJ,EAAMK,eAGfC,EAAmBF,EAAOG,QAG1BC,UAAcJ,EAAOK,UAAUD,UAAY,mBAG3CE,gBAAkB,WACdN,EAAOK,UAAUC,gBAAgBC,KAAMC,MACvCA,KAAKC,SAAUD,KAAKE,OAChBC,8CAAgD,WAA4BH,KAAKI,aAKzFC,sBAAwB,WACpB,OAAQL,KAAKE,MAAMI,IAAK,oBACpB,IAAK,OACD,MAAOjB,GAAQkB,kBACnB,KAAK,SACD,MAAOlB,GAAQmB,kBACnB,KAAK,cACD,MAAOnB,GAAQoB,yBACnB,KAAK,YACD,MAAOpB,GAAQqB,0BAEvB,KAAM,IAAIC,WAAW,2BAA6BX,KAAKE,MAAMI,IAAK,qBAItEM,eAAiB,SAAUC,GACvBrB,EAAOK,UAAUe,eAAeb,KAAMC,KAAMa,EAE5C,IAAIC,GAASd,KAAKE,MAAMI,IAAK,aAAiCnB,EAAO4B,GAAxB5B,EAAO6B,OAIpD,OAFAhB,MAAKiB,IAAIC,SAAU,SAAWJ,GAEvBd,KAAKiB,KAKhBE,SAAW,WACP,GAAIC,GAAgBpB,KAAW,MAAIA,KAAKE,MAAQ,GAAK,YACrD,OAAO,oBAAsBkB,EAAc,MA+C/C,OA1CJ1B,GAAiBG,UAAUwB,UAAa,WAEpC,GAAIC,GAAWC,EAAE5B,UAAYH,EAAOK,UAAUwB,UAAUC,UACpDE,OAASlC,EAASmC,cAEd,mCACI,+CACIlC,EAAI,mCACR,SACJ,WACD,gBAIHmC,EAAmBpC,EAASmC,cAE5B,6CACI,mCACA,sBAEI,kDACA,mDACJ,SACA,+BACA,0BACI,uDACI,wCACI,4DACJ,UACJ,YACJ,UACJ,UACD,aAEH,OAAOF,GAAE5B,UAAYH,EAAOK,UAAUwB,WAClCC,SAAWA,EACXK,SAAWD,QAOXhC,iBAAmBA"}
|
||||
{"version":3,"file":"hdca-li.js","sources":["../../../src/mvc/history/hdca-li.js"],"names":["define","STATES","DC_LI","DC_VIEW","BASE_MVC","_l","_super","DCListItemView","HDCAListItemView","extend","className","prototype","_setUpListeners","call","this","listenTo","model","change:tags change:populated change:visible","render","_getFoldoutPanelClass","get","ListCollectionView","PairCollectionView","ListOfPairsCollectionView","ListOfListsCollectionView","TypeError","_swapNewRender","$newRender","state","OK","RUNNING","$el","addClass","toString","modelString","templates","warnings","_","hidden","wrapTemplate","tit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XhC,iBAAmBA"}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1,4 +1,4 @@
|
||||
!function(t){function e(i){if(n[i])return n[i].exports;var s=n[i]={exports:{},id:i,loaded:!1};return t[i].call(s.exports,s,s.exports,e),s.loaded=!0,s.exports}var i=window.webpackJsonp;window.webpackJsonp=function(o,r){for(var a,l,u=0,c=[];u<o.length;u++)l=o[u],s[l]&&c.push.apply(c,s[l]),s[l]=0;for(a in r)t[a]=r[a];for(i&&i(o,r);c.length;)c.shift().call(null,e);if(r[0])return n[0]=0,e(0)};var n={},s={2:0};return e.e=function(t,i){if(0===s[t])return i.call(null,e);if(void 0!==s[t])s[t].push(i);else{s[t]=[i];var n=document.getElementsByTagName("head")[0],o=document.createElement("script");o.type="text/javascript",o.charset="utf-8",o.async=!0,o.src=e.p+""+t+"."+({3:"analysis",4:"login"}[t]||t)+".bundled.js",n.appendChild(o)}},e.m=t,e.c=n,e.p="",e(0)}([function(t,e,i){i(133),i(1),i(107),i(69),i(66),i(67),i(68),i(105),i(65),i(102),i(64),i(104),i(2),i(3),i(86),i(62),i(10),t.exports=i(132)},function(t,e,i){var n,s;/*!
|
||||
!function(t){function e(i){if(n[i])return n[i].exports;var s=n[i]={exports:{},id:i,loaded:!1};return t[i].call(s.exports,s,s.exports,e),s.loaded=!0,s.exports}var i=window.webpackJsonp;window.webpackJsonp=function(o,r){for(var a,l,u=0,c=[];u<o.length;u++)l=o[u],s[l]&&c.push.apply(c,s[l]),s[l]=0;for(a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a]);for(i&&i(o,r);c.length;)c.shift().call(null,e);if(r[0])return n[0]=0,e(0)};var n={},s={2:0};return e.e=function(t,i){if(0===s[t])return i.call(null,e);if(void 0!==s[t])s[t].push(i);else{s[t]=[i];var n=document.getElementsByTagName("head")[0],o=document.createElement("script");o.type="text/javascript",o.charset="utf-8",o.async=!0,o.src=e.p+""+t+"."+({3:"analysis",4:"login"}[t]||t)+".bundled.js",n.appendChild(o)}},e.m=t,e.c=n,e.p="",e(0)}([function(t,e,i){i(133),i(1),i(107),i(69),i(66),i(67),i(68),i(105),i(65),i(102),i(64),i(104),i(2),i(3),i(86),i(62),i(10),t.exports=i(132)},function(t,e,i){var n,s;/*!
|
||||
* jQuery JavaScript Library v1.12.4
|
||||
* http://jquery.com/
|
||||
*
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1,2 +1,2 @@
|
||||
define(["mvc/dataset/dataset-li","mvc/base-mvc","utils/localization"],function(a,b,c){"use strict";var d=a.DatasetListItemView,e=d.extend({className:d.prototype.className+" history-content",initialize:function(a,b){d.prototype.initialize.call(this,a,b)},toString:function(){var a=this.model?this.model+"":"(no model)";return"HDAListItemView("+a+")"}});return e.prototype.templates=function(){var a=b.wrapTemplate(['<div class="title-bar clear" tabindex="0">','<span class="state-icon"></span>','<div class="title">','<span class="hid"><%- dataset.hid %></span> ','<span class="name"><%- dataset.name %></span>',"</div>","</br>",'<span class="nametags">',"<% _.each(dataset.tags, function(tag){ %>",'<% if (tag.indexOf("name:") == 0){ %>','<span class="label label-info"><%- tag.slice(5) %></span>',"<% } %>","<% }); %>","</span>","</div>"],"dataset"),e=_.extend({},d.prototype.templates.warnings,{hidden:b.wrapTemplate(["<% if( !dataset.visible ){ %>",'<div class="hidden-msg warningmessagesmall">',c("This dataset has been hidden"),"</div>","<% } %>"],"dataset")});return _.extend({},d.prototype.templates,{titleBar:a,warnings:e})}(),{HDAListItemView:e}});
|
||||
define(["mvc/dataset/dataset-li","mvc/base-mvc","utils/localization"],function(a,b,c){"use strict";var d=a.DatasetListItemView,e=d.extend({className:d.prototype.className+" history-content",initialize:function(a,b){d.prototype.initialize.call(this,a,b)},toString:function(){var a=this.model?this.model+"":"(no model)";return"HDAListItemView("+a+")"}});return e.prototype.templates=function(){var a=b.wrapTemplate(['<div class="title-bar clear" tabindex="0">','<span class="state-icon"></span>','<div class="title">','<span class="hid"><%- dataset.hid %></span> ','<span class="name"><%- dataset.name %></span>',"</div>","</br>",'<span class="nametags">',"<% _.each(_.sortBy(_.uniq(dataset.tags), function(x) { return x }), function(tag){ %>",'<% if (tag.indexOf("name:") == 0){ %>','<span class="label label-info"><%- tag.slice(5) %></span>',"<% } %>","<% }); %>","</span>","</div>"],"dataset"),e=_.extend({},d.prototype.templates.warnings,{hidden:b.wrapTemplate(["<% if( !dataset.visible ){ %>",'<div class="hidden-msg warningmessagesmall">',c("This dataset has been hidden"),"</div>","<% } %>"],"dataset")});return _.extend({},d.prototype.templates,{titleBar:a,warnings:e})}(),{HDAListItemView:e}});
|
||||
//# sourceMappingURL=../../../maps/mvc/history/hda-li.js.map
|
||||
@@ -1,2 +1,2 @@
|
||||
define(["mvc/dataset/states","mvc/collection/collection-li","mvc/collection/collection-view","mvc/base-mvc","utils/localization"],function(a,b,c,d,e){"use strict";var f=b.DCListItemView,g=f.extend({className:f.prototype.className+" history-content",_setUpListeners:function(){f.prototype._setUpListeners.call(this),this.listenTo(this.model,{"change:tags change:populated change:visible":function(){this.render()}})},_getFoldoutPanelClass:function(){switch(this.model.get("collection_type")){case"list":return c.ListCollectionView;case"paired":return c.PairCollectionView;case"list:paired":return c.ListOfPairsCollectionView;case"list:list":return c.ListOfListsCollectionView}throw new TypeError("Uknown collection_type: "+this.model.get("collection_type"))},_swapNewRender:function(b){f.prototype._swapNewRender.call(this,b);var c=this.model.get("populated")?a.OK:a.RUNNING;return this.$el.addClass("state-"+c),this.$el},toString:function(){var a=this.model?this.model+"":"(no model)";return"HDCAListItemView("+a+")"}});return g.prototype.templates=function(){var a=_.extend({},f.prototype.templates.warnings,{hidden:d.wrapTemplate(["<% if( !collection.visible ){ %>",'<div class="hidden-msg warningmessagesmall">',e("This collection has been hidden"),"</div>","<% } %>"],"collection")}),b=d.wrapTemplate(['<div class="title-bar clear" tabindex="0">','<span class="state-icon"></span>','<div class="title">','<span class="hid"><%- collection.hid %></span> ','<span class="name"><%- collection.name %></span>',"</div>",'<div class="subtitle"></div>','<span class="nametags">',"<% _.each(_.uniq(collection.tags), function(tag){ %>",'<% if (tag.indexOf("name:") == 0){ %>','<span class="label label-info"><%- tag.slice(5) %></span>',"<% } %>","<% }); %>","</span>","</div>"],"collection");return _.extend({},f.prototype.templates,{warnings:a,titleBar:b})}(),{HDCAListItemView:g}});
|
||||
define(["mvc/dataset/states","mvc/collection/collection-li","mvc/collection/collection-view","mvc/base-mvc","utils/localization"],function(a,b,c,d,e){"use strict";var f=b.DCListItemView,g=f.extend({className:f.prototype.className+" history-content",_setUpListeners:function(){f.prototype._setUpListeners.call(this),this.listenTo(this.model,{"change:tags change:populated change:visible":function(){this.render()}})},_getFoldoutPanelClass:function(){switch(this.model.get("collection_type")){case"list":return c.ListCollectionView;case"paired":return c.PairCollectionView;case"list:paired":return c.ListOfPairsCollectionView;case"list:list":return c.ListOfListsCollectionView}throw new TypeError("Uknown collection_type: "+this.model.get("collection_type"))},_swapNewRender:function(b){f.prototype._swapNewRender.call(this,b);var c=this.model.get("populated")?a.OK:a.RUNNING;return this.$el.addClass("state-"+c),this.$el},toString:function(){var a=this.model?this.model+"":"(no model)";return"HDCAListItemView("+a+")"}});return g.prototype.templates=function(){var a=_.extend({},f.prototype.templates.warnings,{hidden:d.wrapTemplate(["<% if( !collection.visible ){ %>",'<div class="hidden-msg warningmessagesmall">',e("This collection has been hidden"),"</div>","<% } %>"],"collection")}),b=d.wrapTemplate(['<div class="title-bar clear" tabindex="0">','<span class="state-icon"></span>','<div class="title">','<span class="hid"><%- collection.hid %></span> ','<span class="name"><%- collection.name %></span>',"</div>",'<div class="subtitle"></div>','<span class="nametags">',"<% _.each(_.sortBy(_.uniq(collection.tags), function(x) { return x }), function(tag){ %>",'<% if (tag.indexOf("name:") == 0){ %>','<span class="label label-info"><%- tag.slice(5) %></span>',"<% } %>","<% }); %>","</span>","</div>"],"collection");return _.extend({},f.prototype.templates,{warnings:a,titleBar:b})}(),{HDCAListItemView:g}});
|
||||
//# sourceMappingURL=../../../maps/mvc/history/hdca-li.js.map
|
||||
Reference in New Issue
Block a user