2
に変更されていない値Iは、次の機能があります。data.formType
は、「編集」と変更しましたが、イベント値内のページの更新までは変更されません、レコードを保存した後のkeydownイベント
formCreated = function (event, data) {
console.log(data.formType); // output: 'edit'
$('body').on('keydown', function (e) {
if (e.ctrlKey && e.which == 80) {
e.preventDefault();
e.stopPropagation();
if (data.formType == 'create') // not changed until page refresh
alert('save the record');
else if (data.formType == 'edit')
_connectPrinter(data);
}
});
}
を。
新しい値で登録する必要があります。以前の値は閉鎖にあった。 –