fix mimize js/css cleanup on browse

git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1245403 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Olivier Lamy 2012-02-17 11:35:50 +00:00
parent 5021358d30
commit 53f479e409
5 changed files with 15 additions and 22 deletions

View File

@ -71,7 +71,6 @@ public class DefaultBrowseService
{
namespacesToCollapse.addAll( metadataResolver.resolveRootNamespaces( repositorySession, repoId ) );
}
for ( String n : namespacesToCollapse )
{
// TODO: check performance of this

View File

@ -182,3 +182,6 @@ repository-groups.grid.tab.title=Repository Groups
roles.bulk.save.confirm=Are you sure to update {0} Role(s)
roles.bulk.save.confirm.title=Roles Bulk Save
#browse
browse.repository=Browse Repository

View File

@ -557,8 +557,8 @@
<cssSourceFiles>
<cssSourceFile>jquery-ui-1.8.16.custom.css</cssSourceFile>
<cssSourceFile>jquery.ui.1.8.16.ie.css</cssSourceFile>
<cssSourceFile>bootstrap.css</cssSourceFile>
<cssSourceFile>archiva.2.0.1.css</cssSourceFile>
<cssSourceFile>bootstrap.2.0.1.css</cssSourceFile>
<cssSourceFile>archiva.css</cssSourceFile>
</cssSourceFiles>
<cssFinalFile>apache-archiva-${project.version}.css</cssFinalFile>
<jsSourceDir>js</jsSourceDir>

View File

@ -47,7 +47,7 @@ $(function() {
$.log("size:"+browseIdEntries.length);
var browseTopViewModel = new BrowseTopViewModel(browseIdEntries);
ko.applyBindings(browseTopViewModel,mainContent.find("#browse_result" ).get(0));
ko.applyBindings(browseTopViewModel,mainContent.get(0));
}
});
}
@ -65,10 +65,10 @@ $(function() {
dataType: 'json',
success: function(data) {
var browseIdEntries = mapBrowseIdEntries(data);
browseResult.html($("#browse-groups-div-tmpl" ).tmpl());
//browseResult.html($("#browse-groups-div-tmpl" ).tmpl());
var browseGroupsViewModel = new BrowseGroupsViewModel(browseIdEntries,parentGroupdId);
ko.applyBindings(browseGroupsViewModel,mainContent.find("#browse-groups-div" ).get(0));
ko.applyBindings(browseGroupsViewModel,mainContent.get(0));
}
});
}

View File

@ -20,27 +20,18 @@
<script id="browse-tmpl" type="text/html">
<div>
<div class="page-header">
<h2>${$.i18n.prop('browse.groups')}</h2>
<h2>${$.i18n.prop('browse.repository')}</h2>
</div>
</div>
<div id="browse_breadcrumb">
</div>
<div id="browse_result" class="well" data-bind='template:{name:"browse-top-tmpl"}'>
</div>
</script>
<script id="browse-top-tmpl" type="text/html">
<div>
<ul>
{{each(i,browseIdEntry) browseIdEntries}}
<li class="browse-list">
<a href="#" data-bind="click: function(){displayGroupId(browseIdEntry.name)}">&nbsp;${browseIdEntry.name}</a>
</li>
{{/each}}
<ul class="breadcrumb">
<li><a href="#"><i class="icon-home"/>&nbsp;</a>&nbsp;<span class="divider">/</span></li>
<li><a href="#">org</a>&nbsp;<span class="divider">/</span></li>
</ul>
</div>
<div id="browse_result" class="well" data-bind='template:{name:"browse-groups-tmpl"}'>
</div>
</script>
<script id="browse-groups-div-tmpl" type="text/html">