Merge branch 'hotfix'

This commit is contained in:
Nabin Hait 2016-09-28 10:46:36 +05:30
commit 63552166be
2 changed files with 21 additions and 2 deletions

View File

@ -2,7 +2,7 @@
from __future__ import unicode_literals
import frappe
__version__ = '7.0.49'
__version__ = '7.0.50'
def get_default_company(user=None):
'''Get default company for user'''

View File

@ -48,5 +48,24 @@ frappe.treeview_settings["Account"] = {
+ " " + dr_or_cr
+ '</span>').insertBefore(node.$ul);
}
}
},
toolbar: [
{
condition: function(node) {
return !node.root && frappe.boot.user.can_read.indexOf("GL Entry") !== -1
},
label: __("View Ledger"),
click: function(node, btn) {
frappe.route_options = {
"account": node.label,
"from_date": sys_defaults.year_start_date,
"to_date": sys_defaults.year_end_date,
"company": frappe.defaults.get_default('company') ? frappe.defaults.get_default('company'): ""
};
frappe.set_route("query-report", "General Ledger");
},
btnClass: "hidden-xs"
}
],
extend_toolbar: true
}