PDA

View Full Version : Infinite scroll table dont work.



Forn
4 Sep 2012, 2:20 AM
Hello. I have DataStore:


var actionGoodsListForGenPrice = new JavaAction();
actionGoodsListForGenPrice.setActionCode("GoodsListForGenPrice");
var jsonGoodsListForGenPrice = Ext.JSON.encode(actionGoodsListForGenPrice);

/**
* Data source for Goods List.
*/
Ext.define('DSGoodsListForGenPrice', {
extend: 'Ext.data.Store',
model: 'ModelGood',

autoLoad: true,
remoteSort: true,
buffered: true,
pageSize: 50,
proxy: {
type: 'ajax',
url: baseJavaUrl+"?ulmartAction="+jsonGoodsListForGenPrice,
reader: {
type: 'json',
root: 'data',
totalProperty: 'totalCount'
},
simpleSortMode: true
}
});


And the table inside the card of the wizard:


{
id: 'card-6',
xtype:'fieldset',
title: 'Шаг 6 из 9: Выбор товаров для включения в прайс-лист',
layout: 'border',
cls: 'header',
items :[
{
xtype: 'gridpanel',
id: 'wizardGenPrice-includedGoods',
region: 'center',
loadMask: true,
store: 'DSGoodsListForGenPrice',
viewConfig: {
trackOver: false
},
selModel: {
pruneRemoved: false
},
multiSelect: true,

features: [{
ftype: 'filters',
encode: false,
local: true
}],

columns: [{
xtype: 'rownumberer',
width: 50,
sortable: false
}, {
text : 'ID',
width : 75,
sortable : true,
dataIndex: 'id',
filter: {
type: 'numeric'
}
}, {
text : 'Title',
flex : 3,
sortable : true,
dataIndex: 'name',
renderer: function(value, metaData, record, rowIdx, colIdx, store) {
value = Ext.String.htmlEncode(value);
metaData.tdAttr = 'data-qtip="' + Ext.String.htmlEncode(value) + '"';
return value;
},
filter: {
type: 'string'
}
}]
}
]
}


But my table always show only 50 rows, but in the example http://dev.sencha.com/deploy/ext-4.1.0-gpl/examples/grid/infinite-scroll.html it must show me scroll bar for all record.

Result resturn 50 recrod and totalCount more 60.000.

so what i do wrong?

scottmartin
4 Sep 2012, 6:33 AM
To narrow this down .. does the grid work if you remove it from card?
Does our example work in your card?

Scott.