fix wrong id property

This commit is contained in:
Sebastian Sdorra
2011-11-19 16:49:08 +01:00
parent 1ec8771064
commit 8962797bc0
4 changed files with 6 additions and 3 deletions

View File

@@ -48,7 +48,7 @@ Sonia.group.Grid = Ext.extend(Sonia.rest.Grid, {
url: restUrl + 'groups.json',
disableCaching: false
}),
id: 'name',
idProperty: 'name',
fields: [ 'name', 'members', 'description', 'creationDate', 'type', 'properties'],
sortInfo: {
field: 'name'

View File

@@ -52,7 +52,7 @@ Sonia.repository.Grid = Ext.extend(Sonia.rest.Grid, {
url: restUrl + 'repositories.json',
disableCaching: false
}),
id: 'id',
idProperty: 'id',
fields: [ 'id', 'name', 'type', 'contact', 'description', 'creationDate', 'url', 'public', 'permissions', 'properties' ],
sortInfo: {
field: 'name'

View File

@@ -134,6 +134,9 @@ Sonia.rest.Grid = Ext.extend(Ext.grid.GridPanel, {
},
selectById: function(id){
if (debug){
console.debug( 'select by id ' + id );
}
var index = this.getStore().indexOfId(id);
if ( index >= 0 ){
this.getSelectionModel().selectRow(index);

View File

@@ -51,7 +51,7 @@ Sonia.user.Grid = Ext.extend(Sonia.rest.Grid, {
url: restUrl + 'users.json',
disableCaching: false
}),
id: 'name',
idProperty: 'name',
fields: [ 'name', 'displayName', 'mail', 'admin', 'creationDate', 'lastModified', 'type', 'properties'],
sortInfo: {
field: 'name'