Merge branch 'master' of github.com:webnotes/erpnext
This commit is contained in:
commit
9f8edda6a2
@ -163,7 +163,7 @@ cur_frm.cscript.account = function(doc,dt,dn) {
|
|||||||
method: "accounts.utils.get_balance_on",
|
method: "accounts.utils.get_balance_on",
|
||||||
args: {account: d.account, date: doc.posting_date},
|
args: {account: d.account, date: doc.posting_date},
|
||||||
callback: function(r) {
|
callback: function(r) {
|
||||||
d.balance = format_currency(r.message, erpnext.get_currency(doc.company));
|
d.balance = r.message;
|
||||||
refresh_field('balance', d.name, 'entries');
|
refresh_field('balance', d.name, 'entries');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
@ -119,7 +119,7 @@ def get_balance_on(account=None, date=None):
|
|||||||
bal = -bal
|
bal = -bal
|
||||||
|
|
||||||
# if bal is None, return 0
|
# if bal is None, return 0
|
||||||
return bal or 0
|
return flt(bal)
|
||||||
|
|
||||||
@webnotes.whitelist()
|
@webnotes.whitelist()
|
||||||
def add_ac(args=None):
|
def add_ac(args=None):
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
import webnotes
|
import webnotes
|
||||||
def execute():
|
def execute():
|
||||||
webnotes.reload_doc("setup", "doctype", "company")
|
webnotes.reload_doc("setup", "doctype", "company")
|
||||||
|
webnotes.reload_doc("accounts", "doctype", "cost_center")
|
||||||
create_chart_of_accounts_if_not_exists()
|
create_chart_of_accounts_if_not_exists()
|
||||||
add_group_accounts()
|
add_group_accounts()
|
||||||
add_ledger_accounts()
|
add_ledger_accounts()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user