PDA

View Full Version : [DUP] [4.0.1] Ext.grid.plugin.RowEditing errorSummary=true doesn't prevent all tooltips



snoorani
22 Jul 2011, 11:48 AM
Ext.grid.plugin.RowEditing sets errorSummary on Ext.grid.RowEditor in its initEditor function.

RowEditor honors errorSummary in the onFieldChange function, but doesn't check for it in the loadRecord and beforeEdit functions.

So even if errorSummary is set to false, when editing a grid, if a field is marked as allowBlank: false but is blank, then the summary tooltip is shown since loadRecord is calling showToolTip() without checking for errorSummary.

mike.estes
22 Jul 2011, 1:47 PM
providing a test case, even for issues that seem to be obvious, helps us process bug reports efficiently.

snoorani
22 Jul 2011, 1:55 PM
Ext.create('Ext.data.Store', {
storeId:'simpsonsStore',
fields:['name', 'email', 'phone'],
data:{'items':[
{"name":"", "email":"lisa@simpsons.com", "phone":"555-111-1224"},
{"name":"Bart", "email":"bart@simpsons.com", "phone":"555--222-1234"},
{"name":"Homer", "email":"home@simpsons.com", "phone":"555-222-1244"},
{"name":"Marge", "email":"marge@simpsons.com", "phone":"555-222-1254"}
]},
proxy: {
type: 'memory',
reader: {
type: 'json',
root: 'items'
}
}
});

Ext.create('Ext.grid.Panel', {
title: 'Simpsons',
store: Ext.data.StoreManager.lookup('simpsonsStore'),
columns: [
{header: 'Name', dataIndex: 'name', field: {xtype: 'textfield', allowBlank: false}},
{header: 'Email', dataIndex: 'email', flex:1,
editor: {
xtype:'textfield',
allowBlank:false
}
},
{header: 'Phone', dataIndex: 'phone'}
],
selType: 'rowmodel',
plugins: [
Ext.create('Ext.grid.plugin.RowEditing', {
clicksToEdit: 1,
errorSummary: false
})
],
height: 200,
width: 400,
renderTo: Ext.getBody()
});


1. Enter row 2 and erase "Bart" which should trigger onFieldChange(). Confirm that the tooltip doesn't show. Hit Cancel.

2. Enter row 1. Confirm that tooltip shows.

Desired:

Enter row 1. Tooltip should not show.

mike.estes
22 Jul 2011, 2:46 PM
thank you, bug filed as EXTJSIV-3556

Machiavelli79
4 Oct 2011, 6:56 AM
In Function loadRecord of Ext.grid.RowEditor errorSummary isn't asked to show the tooltip.

evant
5 Oct 2011, 12:40 AM
Dupe of: http://www.sencha.com/forum/showthread.php?132214

This will be resolved in 4.1.