Update training_result.js (#27615)

cur_frm is deprecated
This commit is contained in:
François de Ryckel 2021-09-21 06:59:15 +03:00 committed by GitHub
parent 6d8e869a92
commit 5c400da4e2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -21,7 +21,7 @@ frappe.ui.form.on('Training Result', {
frm.set_value("employees" ,"");
if (r.message) {
$.each(r.message, function(i, d) {
var row = frappe.model.add_child(cur_frm.doc, "Training Result Employee", "employees");
var row = frappe.model.add_child(frm.doc, "Training Result Employee", "employees");
row.employee = d.employee;
row.employee_name = d.employee_name;
});