Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要将编辑前的值和更新后的值与行编辑器更新进行比较。我需要将 json 字符串发送到后端,只包含编辑后的值。请让我知道最好的方法。
谢谢你。
您附加到网格的编辑事件并收集所有更改的值
var changes = []; grid.on('edit', function(editor, context) { var originalValue = context.value; var newValue = record.get(context.field); if ( originalValue !== newValue ) { changes.push(context); } });