Ext 分页后PagingToolbar显示条数的问题。

分页后有这么一条:
[code="java"]displayMsg : '显示第 {0}条到 {1}条记录,一共 {2}条',[/code]
其中的参数{2}是通过ds.data.length来的,还是通过ds里面的:totalProperty来的。

因为现在出现这个问题:ds中的totalProperty为6,但是我分页是3条一页的,
结果出来是这样的:
[code="java"]显示第 1条到 3条记录,一共 3条[/code]

请各位帮忙看看。

[code="java"] var cm = new Ext.grid.ColumnModel([ {
header : "customerId",
width : 120,
dataIndex : 'customerId',
hidden : true
}, {
header : "客户名称",
width : 120,
dataIndex : 'name'
}, {
header : "电子邮件",
width : 200,
dataIndex : 'email',
align : 'right'
}]);

var ds = new Ext.data.Store( {
    proxy : new Ext.data.HttpProxy( {
        url : 'listFollowingCustomerAjax.action'
    }),
    reader : new Ext.data.JsonReader( {
        totalProperty : 'count',
        root : 'values'
    }, [ {
        name : 'customerId'
    }, {
        name : 'name'
    }, {
        name : 'email'
    }])
});

ds.load( {
    params : {
        start : 0,
        limit : 3
    }
});

var grid = new Ext.grid.GridPanel( {
    ds : ds,
    cm : cm,
    id : 'followingCusotmer',
    title : '跟进中客户列表',
    autoHeight : true,
    width : '100%',
    loadMask : true,
    buttons : [ {
        text : '查询',
        tooltip : '客户查询',
        handler : function() {
            alert(ds.data.length);
        }
    }, {
        text : '关闭',
        tooltip : '关闭窗口'
    }],
    buttonAlign : 'right',
    bbar : new Ext.PagingToolbar( {
        id : 'pagingbar',
        pageSize : 3,
        store : ds,
        displayInfo : true,
        displayMsg : '显示第 {0}条到 {1}条记录,一共 {2}条',
        emptyMsg : "没有记录"
    })
});[/code]

[b]问题补充:[/b]
但是在totalProperty中是6,而显示的是3,这是怎么回事呢?

[quote]其中的参数{2}是通过ds.data.length来的,还是通过ds里面的:totalProperty来的。 [/quote]

[code="js"]
reader : new Ext.data.JsonReader( {

totalProperty : 'count', //通过这个属性来获得记录总数
root : 'values'

}
[/code]

下面是源代码
[code="js"]// private
updateInfo : function(){
if(this.displayItem){
var count = this.store.getCount();
var msg = count == 0 ?
this.emptyMsg :
String.format(
this.displayMsg,
this.cursor+1, this.cursor+count, this.store.getTotalCount()
);
this.displayItem.setText(msg);
}
}[/code]

totalProperty 里面来的

你返回数据的 count 中是6吗?

你能把listFollowingCustomerAjax.action 这个方法的 json贴出来吗?我好测试