View Full Version : CellEditing problem column without editor

18 Nov 2015, 11:36 PM

I am facing the following problem related to cell edition in a tree grid. I have two columns, the first one not to be editable and the second one I want to edit with CellEditing plugin.
The problem is that when I click over the first column the CellEditing plugin property, editing, is set to true as if it was opening an editor (which is not showing since it was not configured).
For other purposes I need the editing property to only set to true only when the second column is being edited and showing the editor.
I think it may be a misconfiguration problem. Maybe some property I am missing.

My panel is configured as follows:

Ext.define('sf.view.MainTree', {
extend: 'Ext.tree.Panel',
alias: 'widget.maintreeEditor',
store: storeEditor,
autoScroll: false,
title: 'Editor',
header : {
bodyStyle: 'margin: 0px;'
titleAlign: 'right',
iconCls: 'logo-icon',
id: 'documentTree',
rootVisible: false,
listeners: {
itemclick: focusOnRight
//Cell Editing event
plugins: [
Ext.create('Ext.grid.plugin.CellEditing', {
clicksToEdit: 1,
listeners: {
edit: celledition,
beforeedit: editAscii
//the firt column renders the tree,the second column renders the input widget of each node
columns: [{
xtype: 'treecolumn', //thisis so we know which column will show the tree
text: 'Document Tree',
flex: 2,
editable: false,
sortable: false,
dataIndex: 'tag',
renderer: renderTag
text: 'Input',
flex: 1,
dataIndex: 'input',
sortable: false,
renderer: renderInput,
getEditor: editorInput

As it is shown, the first column does not have a getEditor property because I don't want to be edited, but the plugin ignore it and changes the property "editing" when I click on the column.

Any idea of what could be happening?

Gary Schlosberg
20 Nov 2015, 1:50 PM
Does it work if you configure it with the editor (http://docs.sencha.com/extjs/4.2.5/#!/api/Ext.grid.column.Column-cfg-editor) config as in this example?

22 Nov 2015, 11:53 PM
I created a Fiddle to easily reproduce the problem:

(https://fiddle.sencha.com/#fiddle/11b0)I saw that it's working properly in the last Extjs version (6.0.1) but it isn't working in 4.2. So maybe it is a bug solved after 4.2.
Anyway, I managed to change the solution enough to avoid this problem.

The fiddle has my current configuration, but I also tried with the example you suggested and both are having the same behaviour.

Gary Schlosberg
4 Dec 2015, 11:59 AM
I see the issue you are describing using 4.2.1, but it seems to have been fixed in 4.2.2.