mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-12 00:15:44 +01:00
improve changesetviewer
This commit is contained in:
@@ -126,7 +126,7 @@ public class RepositoryResource
|
|||||||
@Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
|
@Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
|
||||||
public Response getChangesets(@PathParam("id") String id,
|
public Response getChangesets(@PathParam("id") String id,
|
||||||
@DefaultValue("0") @QueryParam("start") int start,
|
@DefaultValue("0") @QueryParam("start") int start,
|
||||||
@DefaultValue("25") @QueryParam("limit") int limit)
|
@DefaultValue("20") @QueryParam("limit") int limit)
|
||||||
throws RepositoryException
|
throws RepositoryException
|
||||||
{
|
{
|
||||||
Response response = null;
|
Response response = null;
|
||||||
|
|||||||
@@ -811,29 +811,36 @@ Sonia.repository.ChangesetViewerGrid = Ext.extend(Ext.grid.GridPanel, {
|
|||||||
root: 'changesets',
|
root: 'changesets',
|
||||||
idProperty: 'id',
|
idProperty: 'id',
|
||||||
totalProperty: 'total',
|
totalProperty: 'total',
|
||||||
autoLoad: true,
|
autoLoad: false,
|
||||||
autoDestroy: true
|
autoDestroy: true
|
||||||
});
|
});
|
||||||
|
|
||||||
|
changesetStore.load({params:{start:0, limit:20}});
|
||||||
|
|
||||||
var changesetColModel = new Ext.grid.ColumnModel({
|
var changesetColModel = new Ext.grid.ColumnModel({
|
||||||
defaults: {
|
defaults: {
|
||||||
sortable: false
|
sortable: false
|
||||||
},
|
},
|
||||||
columns: [
|
columns: [{
|
||||||
{id: 'changeset', dataIndex: 'id', xtype: 'templatecolumn', tpl: this.changesetTemplate}
|
id: 'changeset',
|
||||||
]
|
dataIndex: 'id',
|
||||||
|
xtype: 'templatecolumn',
|
||||||
|
tpl: this.changesetTemplate
|
||||||
|
}]
|
||||||
});
|
});
|
||||||
|
|
||||||
var config = {
|
var config = {
|
||||||
header: false,
|
header: false,
|
||||||
|
autoScroll: true,
|
||||||
autoExpandColumn: 'changeset',
|
autoExpandColumn: 'changeset',
|
||||||
autoHeight: true,
|
height: '100%',
|
||||||
|
hideHeaders: true,
|
||||||
store: changesetStore,
|
store: changesetStore,
|
||||||
colModel: changesetColModel,
|
colModel: changesetColModel,
|
||||||
bbar: new Ext.PagingToolbar({
|
bbar: new Ext.PagingToolbar({
|
||||||
store: changesetStore,
|
store: changesetStore,
|
||||||
displayInfo: true,
|
displayInfo: true,
|
||||||
pageSize: 25,
|
pageSize: 20,
|
||||||
prependButtons: true
|
prependButtons: true
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user