Skip to content

fix(dashboard): configured currency + localized widget labels - #27

Merged
Panelica merged 2 commits into
Panelica:mainfrom
hedon77:fix/dashboard-currency
Sep 6, 2026
Merged

fix(dashboard): configured currency + localized widget labels#27
Panelica merged 2 commits into
Panelica:mainfrom
hedon77:fix/dashboard-currency

Conversation

@hedon77

@hedon77 hedon77 commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

Problem

Dashboard admina pokazywał kwoty ze znakiem \$\ mimo domyślnej waluty PLN — bo widgety \BillingWidget\ i \OrdersWidget\ miały hardcoded '$'.

Zmiana

Zamieniono '$'.number_format(...)\ na helper \money_fmt(...), który używa waluty domyślnej z \Currency::getDefault()\ (prefix + suffix). Kwoty dostosowują się do skonfigurowanej waluty (np. \1200.00 zł).

  • \�pp/Widgets/BillingWidget.php\ — 4 kwoty (dzisiaj/miesiąc/rok/całościowo)
  • \�pp/Widgets/OrdersWidget.php\ — kwota zamówienia

@hedon77 hedon77 changed the title fix(dashboard): use configured currency instead of hardcoded dollar sign fix(dashboard): configured currency + localized widget labels Sep 6, 2026
@Panelica
Panelica merged commit a8f672a into Panelica:main Sep 6, 2026
1 check passed
Panelica pushed a commit that referenced this pull request Sep 6, 2026
PRs #27 (dashboard currency/labels) and #28 (KSeF invoice email) added new
strings to en+pl only. Add the Turkish and Simplified Chinese translations for
the 42 admin.dashboard.* keys, the email.ksef_issued.* block and pdf.ksef_number,
and realign the zh files to English's exact structure (mirror test). Also
exclude KsefInvoiceIssuedMail from the template-coverage test: like BulkMassMail
it renders its own fixed layout (with the PDF and verification QR) and is not an
operator-edited template. Parity and the Simplified Chinese mirror stay green.
@Panelica

Panelica commented Sep 6, 2026

Copy link
Copy Markdown
Owner

Merged — thank you. Killing the hardcoded $ and the inline English in the widgets was overdue; routing everything through money_fmt() and __('admin.dashboard.*') is exactly right, and I confirmed the money_fmt / invoice_status_label / company_name helpers all exist on main.

One thing I completed on merge: the 42 new admin.dashboard.* keys landed in en + pl only, which would have failed our TranslationParityTest (every en key must exist in pl/tr/zh) and the SimplifiedChineseTranslationTest (zh must mirror en's structure). I added the Turkish and Simplified Chinese translations and realigned zh — follow-up commit 09b7c5c. Full suite is green (2333 passing).

For future PRs that touch lang/: adding tr and zh alongside en/pl keeps those two tests green — happy to take them exactly as you did here and fill the rest in on our side, just flagging it so you know why the extra commit appeared.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants