Replace per-doctype scorecard list scripts with one shared
translate_listview_subjects.js covering Activity Type, Market Segment,
Role, Role Profile, UOM, Territory, Price List, and the supplier
scorecards. Add missing az/ru translations for Communication and
Azerbaijan.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Frappe's gettext extractor misses two categories of translatable strings:
bare literals in source code that get wrapped in __() only at render time
(e.g. "Save Current Filter" in list_filter.js:88), and labels stored as
data in DocType fixtures (e.g. Number Card / Dashboard Chart labels like
"Open Opportunity", "Incoming Leads"). These never make it into upstream
.pot files, so they cannot be translated via the standard cycle.
Adding such msgids directly to the main <lang>.po works but is fragile:
the next bench update-po-files run marks them obsolete because the .pot
doesn't contain them.
This change introduces extras.po sibling files in each translations_<lang>/
<app>/ directory. setup_locale() copies the main <lang>.po to the target
app's locale dir as before, then overlays extras.po on top via babel's
read_po/write_po. Obsolete (#~) entries are promoted back to active when
a matching extras msgid exists. Extras wins on conflict.
Seeded extras files cover currently-known gaps in frappe (Save Current
Filter) and erpnext (Open Opportunity plus 30 other CRM/dashboard labels).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Country DocType values (e.g. Country.name = "Azerbaijan") are kept as-is
to preserve ERPNext Link references.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Rewrite setup_locale.py to dynamically scan translations_{lang}/ folders
and copy .po files for all languages (az, ru) to frappe/erpnext/hrms
- Remove old root-level translation files (az.po, az_erpnext.po, bg.po, main.pot)
- Add per-language translation folders (translations_az/, translations_ru/)
- Fix setup_chart.py path to use locale/data/
- Remove unused data files and dead scripts (update_item_groups, update_languages)
- Move item group renaming to jey_erp via frappe.rename_doc
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>