Skip to content

Commit 488d808

Browse files
mergify[bot]mahsemnabinhait
authored
fix: strings for translation (backport frappe#44816) (frappe#44927)
* fix: strings for translation (cherry picked from commit 3be633f) # Conflicts: # erpnext/accounts/utils.py * fix: resolved conflict --------- Co-authored-by: mahsem <[email protected]> Co-authored-by: Nabin Hait <[email protected]>
1 parent 5cc9e10 commit 488d808

File tree

7 files changed

+11
-11
lines changed

7 files changed

+11
-11
lines changed

erpnext/accounts/report/item_wise_sales_register/item_wise_sales_register.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ def get_columns(additional_table_columns, filters):
318318
"width": 100,
319319
},
320320
{
321-
"label": _("Rate"),
321+
"label": _("Tax Rate"),
322322
"fieldname": "rate",
323323
"fieldtype": "Float",
324324
"options": "currency",

erpnext/accounts/utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ def get_fiscal_years(
130130
else:
131131
return ((fy.name, fy.year_start_date, fy.year_end_date),)
132132

133-
error_msg = _("""{0} {1} is not in any active Fiscal Year""").format(label, formatdate(transaction_date))
133+
error_msg = _("""{0} {1} is not in any active Fiscal Year""").format(_(label), formatdate(transaction_date))
134134
if company:
135135
error_msg = _("""{0} for {1}""").format(error_msg, frappe.bold(company))
136136

erpnext/manufacturing/report/exponential_smoothing_forecasting/exponential_smoothing_forecasting.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -230,8 +230,8 @@ def get_chart_data(self):
230230
"data": {
231231
"labels": labels,
232232
"datasets": [
233-
{"name": "Demand", "values": self.total_demand},
234-
{"name": "Forecast", "values": self.total_forecast},
233+
{"name": _("Demand"), "values": self.total_demand},
234+
{"name": _("Forecast"), "values": self.total_forecast},
235235
],
236236
},
237237
"type": "line",

erpnext/manufacturing/report/production_analytics/production_analytics.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ def get_data(filters, columns):
106106

107107
for label in labels:
108108
work = {}
109-
work["Status"] = label
109+
work["Status"] = _(label)
110110
for _dummy, end_date in ranges:
111111
period = get_period(end_date, filters)
112112
if periodic_data.get(label).get(period):

erpnext/public/js/bom_configurator/bom_configurator.bundle.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -147,10 +147,10 @@ class BOMConfigurator {
147147
if (!node.expanded) {
148148
view.tree.load_children(node, true);
149149
$(node.parent[0]).find(".tree-children").show();
150-
node.$toolbar.find(".expand-all-btn").html("Collapse All");
150+
node.$toolbar.find(".expand-all-btn").html(__("Collapse All"));
151151
} else {
152152
node.$tree_link.trigger("click");
153-
node.$toolbar.find(".expand-all-btn").html("Expand All");
153+
node.$toolbar.find(".expand-all-btn").html(__("Expand All"));
154154
}
155155
},
156156
condition: function (node) {
@@ -190,10 +190,10 @@ class BOMConfigurator {
190190
if (!node.expanded) {
191191
view.tree.load_children(node, true);
192192
$(node.parent[0]).find(".tree-children").show();
193-
node.$toolbar.find(".expand-all-btn").html("Collapse All");
193+
node.$toolbar.find(".expand-all-btn").html(__("Collapse All"));
194194
} else {
195195
node.$tree_link.trigger("click");
196-
node.$toolbar.find(".expand-all-btn").html("Expand All");
196+
node.$toolbar.find(".expand-all-btn").html(__("Expand All"));
197197
}
198198
},
199199
condition: function (node) {

erpnext/stock/doctype/material_request/material_request.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ frappe.ui.form.on("Material Request", {
322322
default: 1,
323323
},
324324
],
325-
primary_action_label: "Get Items",
325+
primary_action_label: __("Get Items"),
326326
primary_action(values) {
327327
if (!values) return;
328328
values["company"] = frm.doc.company;

erpnext/templates/includes/footer/footer_extension.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
if($("#footer-subscribe-email").val() && validate_email($("#footer-subscribe-email").val())) {
1919
$("#footer-subscribe-email").attr('disabled', true);
20-
$("#footer-subscribe-button").html("Sending...")
20+
$("#footer-subscribe-button").html(__("Sending..."))
2121
.attr("disabled", true);
2222
erpnext.subscribe_to_newsletter({
2323
email: $("#footer-subscribe-email").val(),

0 commit comments

Comments
 (0)