fix store filter on reload

This commit is contained in:
Sebastian Sdorra
2012-03-30 10:44:14 +02:00
parent d34a96259d
commit aeb0b2d415

View File

@@ -41,6 +41,8 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
formTitleText: 'Repository Form',
unknownType: 'Unknown',
archiveIcon: 'resources/images/archive.png',
filterRequest: null,
/**
@@ -155,7 +157,9 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
header: this.colArchiveText,
dataIndex: 'archived',
width: 40,
hidden: true //! state.clientConfig.enableRepositoryArchive
hidden: ! state.clientConfig.enableRepositoryArchive,
renderer: this.renderArchive,
scope: this
},{
id: 'group',
dataIndex: 'group',
@@ -207,6 +211,10 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
}
},
renderArchive: function(v){
return v ? '<img src=' + this.archiveIcon + ' alt=' + v + '>' : '';
},
convertToGroup: function(v, data){
var name = data.name;
var i = name.lastIndexOf('/');
@@ -238,6 +246,9 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
if (this.searchValue){
this.filterStore();
}
if (this.filterRequest){
this.filterByRequest();
}
},
onFallBelowMinHeight: function(height, minHeight){