ExtJS rownumberer未按顺序排列

ExtJS rownumberer未按顺序排列,extjs,row-number,Extjs,Row Number,rownumberer字段不按顺序排列,而是从我用于idProperty的id字段中提取值。因此使不有序 模型 商场 网格 始终;订单是根据“id”字段确定的,并且从来没有保证会按顺序排列 我试过了;删除idProperty,但它不起作用 我哪里错了请帮忙 谢谢你想做什么?是否要在id列上订购?为什么不使用sortIfo@Oğuzğelikdemir我希望“rownumberer”独立工作,但它使用“id”字段的值,因此无法维持秩序。@naresh“sortInfo”关于什么“rownumber

rownumberer
字段不按顺序排列,而是从我用于
idProperty
id
字段中提取值。因此使不有序

模型 商场 网格 始终;订单是根据“id”字段确定的,并且从来没有保证会按顺序排列

我试过了;删除
idProperty
,但它不起作用

我哪里错了请帮忙


谢谢

你想做什么?是否要在
id
列上订购?为什么不使用sortIfo@Oğuzğelikdemir我希望“rownumberer”独立工作,但它使用“id”字段的值,因此无法维持秩序。@naresh“sortInfo”关于什么“rownumberer”或“grid”我使用的是Ext JS 4.0,很抱歉回复太晚。。我所做的是'xtype:'rownumberer',text:'Sn',width:15,renderer:function(v,p,record,rowIndex){if(this.rowspan){p.cellAttr='rowspan=“”+this.rowspan+”;}返回行索引+1;}'。但我必须说,UI不像“rownumberer”那样。
Ext.define('DataModel', {
    extend : 'Ext.data.Model',
    idProperty : 'id',
    fields : [ 
       { name : 'id', type : 'int' },
       { name : 'openDate', type : 'string' },
       { name : 'comment', type : 'string' }
    ]
});
var openDateStore = Ext.create('Ext.data.Store', {
    model : 'DataModel',
    proxy : {
        type : 'ajax',
        url : contextPath + 'data.do',
        reader : {
            totalProperty : 'results',
            type : 'json',
            root : 'data'
        }
    },
    autoLoad : false
});
xtype : 'gridpanel', title : 'Open Date(s)', store : openDateStore ,
columns : [
        { xtype : 'rownumberer', text : 'Sn', width : 15 },
        { xtype : 'gridcolumn', dataIndex : 'openDate', text : 'Date'},
        { xtype : 'gridcolumn', dataIndex : 'comment', text : 'Comment'}
]