commit | da629810ad129fbde879de8190b6bdb3511ec20e | [log] [tgz] |
---|---|---|
author | Suraj Shetty <surajshetty3416@gmail.com> | Thu Jun 20 17:20:19 2019 +0530 |
committer | Suraj Shetty <surajshetty3416@gmail.com> | Thu Jun 20 17:20:19 2019 +0530 |
tree | b5382124632e20843692d7af8b7489b29749352f | |
parent | 5162b7457f123b40af8dcfe102b6b7155f7860f3 [diff] |
fix: Get accounting dimensions only if user has access
diff --git a/erpnext/public/js/utils.js b/erpnext/public/js/utils.js index f44fb0c..86fa70d 100755 --- a/erpnext/public/js/utils.js +++ b/erpnext/public/js/utils.js
@@ -65,6 +65,9 @@ }, get_dimension_filters: async function() { + if (!frappe.boot.user.can_read.includes('Accounting Dimension')) { + return + } let dimensions = await frappe.db.get_list('Accounting Dimension', { fields: ['label', 'fieldname', 'document_type'], filters: {