@@ -31,27 +31,47 @@ define(["underscore", "gettext", "js/views/baseview"], function(_, gettext, Base
},
messageHtml:function(){
varmessage;
if(this.view.collection.sortDirection==='asc'){
// Translators: sample result: "Showing 0-9 out of 25, sorted by name ascending"
message=gettext('Showing %(current_item_range)s out of %(total_items_count)s, sorted by %(sort_name)s ascending');
}else{
// Translators: sample result: "Showing 0-9 out of 25, sorted by name descending"
message=gettext('Showing %(current_item_range)s out of %(total_items_count)s, sorted by %(sort_name)s descending');
}
return'<p>'+interpolate(message,{
current_item_range:this.currentItemRangeLabel(),
total_items_count:this.totalItemsCountLabel(),
sort_name:this.sortNameLabel()
},true)+"</p>";
},
currentItemRangeLabel:function(){
varview=this.view,
collection=view.collection,
start=collection.start,
count=collection.size(),
sortName=view.sortDisplayName(),
sortDirectionName=view.sortDirectionName(),
end=start+count,
total=collection.totalCount,
fmts=gettext('Showing %(current_span)s%(start)s-%(end)s%(end_span)s out of %(total_span)s%(total)s total%(end_span)s, sorted by %(order_span)s%(sort_order)s%(end_span)s %(sort_direction)s');