Hello,
I'm facing an issue that i'm not able to resolve.
I'm trying to cancel edit action on some cells.
I saw on the forum that there is a cancel property in cellSelecting and/or actionBegin.
But i'm facing 2 problems.
The first one is that cellSelecting doesn't trigger so i can't cancel here and secondly actionBegin does start but the cancel property change doesn't stop the edit action...
The cell i want to cancel the edit are on a colum and on some rows that have a particular property;
Here is my treegrid template declaration :
<template>
<div>
<ejs-treegrid :dataSource="tree"
:treeColumnIndex='1'
:editSettings='editSettings'
:rowDataBound='rowDataBound'
:cellSelecting="cellSelecting"
:actionBegin="actionBegin"
:actionComplete="actionComplete"
:queryCellInfo="queryCellInfo"
:allowSorting='true'
locale='fr-FR'
childMapping='Children'
gridLines='None'
width='auto'>
<e-columns>
The Column declaration :
<e-column
:customAttributes="{class: 'fraction-libre'}"
field='FractionLibre'
headerText='Fraction Libre'
textAlign='Left'
width=80>
</e-column>
Here the methods:
methods: {
cellSelecting: function (args){
console.log('CELL SELECTING : ', args);
},
/**
*/
actionBegin: function (args){
console.log('ACTION BEGIN : ', args);
if (args.type === "edit" && args.columnName === "FractionLibre" && args.rowData.TypeLigne !== "FR") {
console.log('CANCEL');
args.cancel = true;
}
},And the console :
Not sure where the problem is, if you have any ideas...
Thanks you very much for your support !