fix: declare data before assigining

This commit is contained in:
prssanna 2021-04-12 12:01:20 +05:30
parent be26e59087
commit 42f4a00c88

View File

@ -916,7 +916,7 @@ frappe.ui.form.on('Sales Invoice Timesheet', {
},
callback: function(r, rt) {
if(r.message){
data = r.message;
let data = r.message;
frappe.model.set_value(cdt, cdn, "billing_hours", data.billing_hours);
frappe.model.set_value(cdt, cdn, "billing_amount", data.billing_amount);
frappe.model.set_value(cdt, cdn, "timesheet_detail", data.timesheet_detail);