Allow cost center in entry of balance sheet accounts (#14972)

* Allow Cost Center In Entry of Balance Sheet Account

* Add parent cost center in get payment entry

* Add Tests for Allow Cost Center In Entry of Balance Sheet Account

* Add tests for cost center wise account and party balance

* set parent cost center in taxes

* 1. Remove copy parent cost_center to child
2. Improve update party and account balance functionality on cost_center change
3. Add cost_center filter to get_outstanding_documents

* fix Codacy and Travis issue
diff --git a/erpnext/public/js/utils.js b/erpnext/public/js/utils.js
index 682577b..434b58c 100644
--- a/erpnext/public/js/utils.js
+++ b/erpnext/public/js/utils.js
@@ -201,7 +201,18 @@
 		} else {
 			return options[0];
 		}
-	}
+	},
+	copy_parent_value_in_all_row: function(doc, dt, dn, table_fieldname, fieldname, parent_fieldname) {
+		var d = locals[dt][dn];
+		if(d[fieldname]){
+			var cl = doc[table_fieldname] || [];
+			for(var i = 0; i < cl.length; i++) {
+				cl[i][fieldname] = doc[parent_fieldname];
+			}
+		}
+		refresh_field(table_fieldname);
+	},
+
 });
 
 erpnext.utils.select_alternate_items = function(opts) {