Merge pull request #22762 from DeeMysterio/financial-stat

fix(report): fix alignment in script report that extends financial_statements.js
This commit is contained in:
Deepesh Garg 2020-07-22 14:45:22 +05:30 committed by GitHub
commit d6615248a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,7 +3,7 @@ frappe.provide("erpnext.financial_statements");
erpnext.financial_statements = { erpnext.financial_statements = {
"filters": get_filters(), "filters": get_filters(),
"formatter": function(value, row, column, data, default_formatter) { "formatter": function(value, row, column, data, default_formatter) {
if (column.fieldname=="account") { if (data && column.fieldname=="account") {
value = data.account_name || value; value = data.account_name || value;
column.link_onclick = column.link_onclick =
@ -13,7 +13,7 @@ erpnext.financial_statements = {
value = default_formatter(value, row, column, data); value = default_formatter(value, row, column, data);
if (!data.parent_account) { if (data && !data.parent_account) {
value = $(`<span>${value}</span>`); value = $(`<span>${value}</span>`);
var $value = $(value).css("font-weight", "bold"); var $value = $(value).css("font-weight", "bold");