mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-22 06:29:20 +00:00
Merge branch '1310' of github.com:webnotes/erpnext
Conflicts: accounts/doctype/account/account.py controllers/accounts_controller.py patches/patch_list.py selling/doctype/sales_common/sales_common.py stock/doctype/purchase_receipt/purchase_receipt.py
This commit is contained in:
@@ -3,10 +3,6 @@
|
||||
|
||||
wn.require('app/setup/doctype/contact_control/contact_control.js');
|
||||
|
||||
cur_frm.cscript.onload = function(doc,dt,dn){
|
||||
|
||||
}
|
||||
|
||||
cur_frm.cscript.refresh = function(doc,dt,dn) {
|
||||
cur_frm.cscript.make_dashboard(doc);
|
||||
erpnext.hide_naming_series();
|
||||
@@ -32,7 +28,8 @@ cur_frm.cscript.make_dashboard = function(doc) {
|
||||
cur_frm.dashboard.reset();
|
||||
if(doc.__islocal)
|
||||
return;
|
||||
cur_frm.dashboard.set_headline('<span class="text-muted">Loading...</span>')
|
||||
if (in_list(user_roles, "Accounts User") || in_list(user_roles, "Accounts Manager"))
|
||||
cur_frm.dashboard.set_headline('<span class="text-muted">Loading...</span>')
|
||||
|
||||
cur_frm.dashboard.add_doctype_badge("Supplier Quotation", "supplier");
|
||||
cur_frm.dashboard.add_doctype_badge("Purchase Order", "supplier");
|
||||
@@ -46,12 +43,14 @@ cur_frm.cscript.make_dashboard = function(doc) {
|
||||
supplier: cur_frm.doc.name
|
||||
},
|
||||
callback: function(r) {
|
||||
cur_frm.dashboard.set_headline(
|
||||
wn._("Total Billing This Year: ") + "<b>"
|
||||
+ format_currency(r.message.total_billing, cur_frm.doc.default_currency)
|
||||
+ '</b> / <span class="text-muted">' + wn._("Unpaid") + ": <b>"
|
||||
+ format_currency(r.message.total_unpaid, cur_frm.doc.default_currency)
|
||||
+ '</b></span>');
|
||||
if (in_list(user_roles, "Accounts User") || in_list(user_roles, "Accounts Manager")) {
|
||||
cur_frm.dashboard.set_headline(
|
||||
wn._("Total Billing This Year: ") + "<b>"
|
||||
+ format_currency(r.message.total_billing, cur_frm.doc.default_currency)
|
||||
+ '</b> / <span class="text-muted">' + wn._("Unpaid") + ": <b>"
|
||||
+ format_currency(r.message.total_unpaid, cur_frm.doc.default_currency)
|
||||
+ '</b></span>');
|
||||
}
|
||||
cur_frm.dashboard.set_badge_count(r.message);
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user