[minor] budget link in cost center, fixes #6093
This commit is contained in:
parent
b8a8fb5877
commit
b969c2cb60
@ -32,8 +32,13 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) {
|
||||
cur_frm.toggle_display('sb1', doc.is_group==0)
|
||||
cur_frm.set_intro(intro_txt);
|
||||
|
||||
cur_frm.add_custom_button(__('Chart of Cost Centers'),
|
||||
function() { frappe.set_route("Tree", "Cost Center"); }, __("View"))
|
||||
if(!cur_frm.doc.__islocal) {
|
||||
cur_frm.add_custom_button(__('Chart of Cost Centers'),
|
||||
function() { frappe.set_route("Tree", "Cost Center"); });
|
||||
|
||||
cur_frm.add_custom_button(__('Budget'),
|
||||
function() { frappe.set_route("List", "Budget", {'cost_center': cur_frm.doc.name}); });
|
||||
}
|
||||
}
|
||||
|
||||
cur_frm.cscript.parent_cost_center = function(doc, cdt, cdn) {
|
||||
|
@ -80,7 +80,7 @@ erpnext.selling.SellingController = erpnext.TransactionController.extend({
|
||||
} else {
|
||||
filters = {
|
||||
'item_code': item.item_code,
|
||||
'posting_date': me.frm.doc.posting_date || nowdate(),
|
||||
'posting_date': me.frm.doc.posting_date || frappe.datetime.nowdate(),
|
||||
}
|
||||
if(item.warehouse) filters["warehouse"] = item.warehouse
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user