fix: minor issues (#29130)
diff --git a/erpnext/accounts/doctype/account/account.js b/erpnext/accounts/doctype/account/account.js
index 7a1d735..320e1ca 100644
--- a/erpnext/accounts/doctype/account/account.js
+++ b/erpnext/accounts/doctype/account/account.js
@@ -43,12 +43,12 @@
frm.trigger('add_toolbar_buttons');
}
if (frm.has_perm('write')) {
- frm.add_custom_button(__('Update Account Name / Number'), function () {
- frm.trigger("update_account_number");
- });
frm.add_custom_button(__('Merge Account'), function () {
frm.trigger("merge_account");
- });
+ }, __('Actions'));
+ frm.add_custom_button(__('Update Account Name / Number'), function () {
+ frm.trigger("update_account_number");
+ }, __('Actions'));
}
}
},
@@ -59,11 +59,12 @@
}
},
add_toolbar_buttons: function(frm) {
- frm.add_custom_button(__('Chart of Accounts'),
- function () { frappe.set_route("Tree", "Account"); });
+ frm.add_custom_button(__('Chart of Accounts'), () => {
+ frappe.set_route("Tree", "Account");
+ }, __('View'));
if (frm.doc.is_group == 1) {
- frm.add_custom_button(__('Group to Non-Group'), function () {
+ frm.add_custom_button(__('Convert to Non-Group'), function () {
return frappe.call({
doc: frm.doc,
method: 'convert_group_to_ledger',
@@ -71,10 +72,11 @@
frm.refresh();
}
});
- });
+ }, __('Actions'));
+
} else if (cint(frm.doc.is_group) == 0
&& frappe.boot.user.can_read.indexOf("GL Entry") !== -1) {
- frm.add_custom_button(__('Ledger'), function () {
+ frm.add_custom_button(__('General Ledger'), function () {
frappe.route_options = {
"account": frm.doc.name,
"from_date": frappe.sys_defaults.year_start_date,
@@ -82,9 +84,9 @@
"company": frm.doc.company
};
frappe.set_route("query-report", "General Ledger");
- });
+ }, __('View'));
- frm.add_custom_button(__('Non-Group to Group'), function () {
+ frm.add_custom_button(__('Convert to Group'), function () {
return frappe.call({
doc: frm.doc,
method: 'convert_ledger_to_group',
@@ -92,7 +94,7 @@
frm.refresh();
}
});
- });
+ }, __('Actions'));
}
},
diff --git a/erpnext/regional/doctype/uae_vat_settings/uae_vat_settings.js b/erpnext/regional/doctype/uae_vat_settings/uae_vat_settings.js
index 07a9301..6653141 100644
--- a/erpnext/regional/doctype/uae_vat_settings/uae_vat_settings.js
+++ b/erpnext/regional/doctype/uae_vat_settings/uae_vat_settings.js
@@ -2,7 +2,13 @@
// For license information, please see license.txt
frappe.ui.form.on('UAE VAT Settings', {
- // refresh: function(frm) {
-
- // }
+ onload: function(frm) {
+ frm.set_query('account', 'uae_vat_accounts', function() {
+ return {
+ filters: {
+ 'company': frm.doc.company
+ }
+ };
+ });
+ }
});
diff --git a/erpnext/selling/page/point_of_sale/pos_item_selector.js b/erpnext/selling/page/point_of_sale/pos_item_selector.js
index 4963852..a30bcd7 100644
--- a/erpnext/selling/page/point_of_sale/pos_item_selector.js
+++ b/erpnext/selling/page/point_of_sale/pos_item_selector.js
@@ -113,7 +113,7 @@
`<div class="item-wrapper"
data-item-code="${escape(item.item_code)}" data-serial-no="${escape(serial_no)}"
data-batch-no="${escape(batch_no)}" data-uom="${escape(stock_uom)}"
- data-rate="${escape(price_list_rate)}"
+ data-rate="${escape(price_list_rate || 0)}"
title="${item.item_name}">
${get_item_image_html()}