Update payroll_entry.js

This commit is contained in:
rohitwaghchaure 2020-07-08 12:34:15 +05:30 committed by GitHub
parent 020c6e9175
commit e862b3f9ce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -51,7 +51,7 @@ frappe.ui.form.on('Payroll Entry', {
doc: frm.doc,
method: 'fill_employee_details',
}).then(r => {
if (r.docs[0].employees){
if (r.docs && r.docs[0].employees){
frm.employees = r.docs[0].employees;
frm.dirty();
frm.save();