REQUIRED INFORMATION
Ext version tested:- Ext 4.1 Beta 1 - Nightly Build 20120125
Browser versions tested against:DOCTYPE tested against:Description:- A store that has a field named "delete" will cause a hard JS error.
Steps to reproduce the problem:The result that was expected:The result that occurs instead:- Error: SyntaxError: Unexpected token delete
Test Case:
Code:
Ext.create('Ext.data.Store', {
storeId:'simpleStore',
fields:[
{name:'id',type:'int'},
'name',
{name:'delete',type:'bool'}
//'create',
//'update'
],
data:{'items':[
{"id":"1","name":"Lisa","delete":"true"},
{"id":"2","name":"Bart","delete":"false"},
{"id":"3","name":"Homer","delete":"false"},
{"id":"4","name":"Marge","delete":"true"}
]},
proxy: {
type: 'memory',
reader: {
type: 'json',
root: 'items'
}
}
});
Ext.create('Ext.grid.Panel', {
title: 'Simple Grid',
store: Ext.data.StoreManager.lookup('simpleStore'),
columns: [
{header: 'Id', dataIndex: 'id', hidden: true },
{header: 'Name', dataIndex: 'name', flex:1}
],
height: 200,
width: 500,
renderTo: Ext.getBody()
});
HELPFUL INFORMATION
Additional CSS used:Operating System: