PDA

View Full Version : BUG in ie only Panel with DataView



wki01
18 Jan 2011, 1:24 AM
I am using 3.3.1.
It works on FF3 and chrome but not on ie8 (error in line 1124)
THANKS

My test case


Ext.onReady(function(){
var store1 = new Ext.data.JsonStore({
data : {"data": [{"surename":"kids_hug2.jpg","lastname":2476,"lastm od":1208572360000}]},
autoLoad : true,
root:'data',
fields: [
'surename', 'lastname', 'lastmod'
]
});

var panel = new Ext.Panel({
frame:true,
layout:'fit',
items: new Ext.DataView({
store: store1,
tpl: new Ext.XTemplate(
'<tpl for=".">',
'<span class="x-editable">{surename}</span></div>',
'</tpl>',

'<div class="x-clear"></div>'
)
})
});
new Ext.Window({
width : 400,
height : 400,
items : panel
}).show();
});

Condor
18 Jan 2011, 4:12 AM
1. You are specifying 'data' for the store, so you should not use autoLoad:true!
2. Your window also needs layout:'fit' (why are you even using that extra panel?).

wki01
18 Jan 2011, 5:03 AM
Same problem.

My online demo:

http://partnerzone2.wki.it/test.nsf/test

thank you

wki01
19 Jan 2011, 12:07 AM
Apparently this solves the problem ...
thanks



...........
jsSelect: function(path, root, type){

root = root || document;

if(typeof root == "string"){
root = document.getElementById(root);
}
if (path == undefined) {
results = [];
return results;
}
var paths = path.split(","),
results = [];


for(var i = 0, len = paths.length; i < len; i++){
var subPath = paths[i].replace(trimRe, "");
.........

Condor
19 Jan 2011, 12:10 AM
Nonsense.

The correct solution is to specify the proper itemSelector in the dataview!

itemSelector: 'span.x-editable'