I use the $("- sharprrepairOrderGrid"). DataGrid) method to display data, and
my column is a button
{header:"xxx", name:"repairWorkshopUser", index:"repairWorkshopUser", width:150, align:"center",formatter:function (val, obj, row, act) {debugger;
var actions = [];
console.log(" "+row.repairWorkshopUser);
actions.push("<input type="button" value="" id="id1" onclick="craftClick("+obj.rowId+")"></input>");
return actions.join("");
}},
each row has an action button. I want to click the button and set the formatter of this column to empty. I wrote
$("- sharprrepairOrderGrid"). SetColProp ("repairWorkshopUser", {formatter: {}});
and then there is a button that clicks and sets the formatter of this column back to
function (val, obj, row, act) {debugger;
var actions = [];
console.log(" "+row.repairWorkshopUser);
actions.push("<input type="button" value="" id="id1" onclick="craftClick("+obj.rowId+")"></input>");
return actions.join("");
}},