Commit Graph
429 Commits
Author SHA1 Message Date
objecttothis aa0107ccce i18n: remove unused integrations translation keys
Remove 'integrations' and 'integrations_configuration' (and
'plugins'/'plugins_configuration' in ckb) entries from Config.php
across all language files under app/Language/*.

- Dead keys no longer referenced in UI, dropped repo-wide for
  consistency across locales (ar-EG, ar-LB, az, bg, bs, ckb, cs,
  da, de-CH, de-DE, el, en-GB, en, es-ES, es-MX, fa, fr, and others)
- Keeps all language Config.php files structurally in sync

Signed-off-by: objecttothis <17935339+objecttothis@users.noreply.github.com>
2026-11-06 14:22:46 +04:00
objecttothisandClaude Sonnet 5 3b36c20f68 Merge remote-tracking branch 'OpensourcePOS/master' into plugin-system-fresh
Resolve language-file conflicts by taking master's English-removal
cleanup across non-English locales, while stripping the MailChimp
keys master reintroduced (already moved to MailchimpPlugin on this
branch) and reapplying this branch's plugins/integrations rename and
new Module.php plugins keys where master lacked them.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-11-06 13:43:47 +04:00
BudsieBuds 9a304c0183 refactor(i18n): standardize language catalogs, enforce dynamic fallback, and add test coverage
- Replace untranslated English strings with empty fallback ('') across all non-English catalogs and sort keys alphabetically (closes #4783, closes #4660)
- Restore missing Sales.no_sales_to_display in English while preserving existing translations (closes #4794, references #4637, #4795)
- Register Georgian (ka) and Swahili (sw-KE, sw-TZ) locales, normalize Croatian to hr per BCP 47, and fix datepicker long month keys (partially addresses #4476, references #3891)
- Hardcode invariant brand constants (OSPOS, website, copyrights) in login/footer views, remove from catalogs, and standardize Latin OSPOS branding
- Fix English catalog typos and maintain consistent British English variants in en-GB
- Add LanguageFilesTest with 4,418 automated tests for syntax, key parity, sorting, and bidirectional locale registrations
- Update AGENTS.md with localization guidelines and development best practices
2026-11-04 15:23:50 +01:00
jekkos 3a1ddc69f8 fix(receivings): gate per-record endpoints behind reports_receivings grant (#4798)
getEdit, postDelete, getReceipt, and postSave all accept a
user-controlled receiving_id and previously only checked the class-level
receivings module grant. This allowed any employee with basic receiving
permissions to read, modify, or delete historical receiving records
belonging to other employees.

Add reports_receivings permission checks to all four per-record
endpoints, following the same pattern as Sales (PR #4627).
2026-11-03 00:00:43 +01:00
jekkos 8a8736ad0d fix(i18n): migrate powered_by to named placeholders across all locales (#4661, #4727)
Replace hardcoded string concatenation of the app name and version in the
document <title> with named-placeholder interpolation, consistent with the
existing Common.migration_needed pattern.

- header.php passes ['OSPOS', application_version] as the lang() array
  argument instead of concatenating values around the translation
- All 46 Common.php locale files convert powered_by to a named-placeholder
  template, preserving current rendered output while allowing each locale
  to reorder the app name and version as needed
- hy, ml, nb, and ur leave powered_by empty so MY_Language::getLine()
  falls back to English rather than rendering bare placeholder strings
- de-CH powered_by translated to German
- Codify named-placeholder + ICU MessageFormat as the localization standard
  in the agents documentation
2026-10-28 14:10:27 +04:00
objecttothis 0302808961 Merge remote-tracking branch 'OpensourcePOS/master' into plugin-system-fresh
# Conflicts:
#	app/Controllers/Items.php
#	app/Models/Item.php
#	app/Models/Stock_location.php
#	app/Views/items/form_count_details.php
2026-10-27 15:32:14 +04:00
richardmillesandobjecttothis b07f5e3ebb chore(i18n): remove unused Sales language keys (#4637)
Drop verified-unused keys from Sales.php across all locales to reduce
translation burden. Retained:
- invoice_type_* keys (referenced by Sale_lib)
- rewards_package key (built dynamically by register.php)

Fixes #4586

Co-authored-by: objecttothis <17935339+objecttothis@users.noreply.github.com>
2026-10-27 15:24:21 +04:00
objecttothisandClaude Sonnet 4.6 74e825ba6f feat(stock-locations): add default location and sort order support (#4643)
Refactor Stock_location model to camelCase naming and introduce
is_default and sort_order fields with full migration, UI, and
item-sync support. Multiple follow-up fixes consolidated.

Database
- Add is_default (TINYINT, backfilled to oldest non-deleted row) and
  sort_order (nullable unsigned TINYINT unique, dense 0..N-1) columns
  via new migration; MySQL 5.7-compatible backfill using user variables
  instead of ROW_NUMBER(); down() drops both columns

Model
- Rename show_locations → showLocations (camelCase convention)
- Add getDefaultLocationId(), setDefaultLocation(), saveSortOrder();
  validate location existence before setting as default
- delete() compacts sort_order via two-pass CASE update to avoid
  collisions after prior reorders
- Atomic sort_order assignment via explicit SQL COUNT query

Controller / Config
- Modularize save logic into sanitizeSubmittedLocations(),
  deleteRemovedLocations(), saveSubmittedLocations(),
  saveLocationOrderAndDefault(); wrap in single transaction
- Support stock_location_new inputs for new-row creation
- Resolve new-* ID placeholders to real IDs post-save
- Abort loop on save failure; default missing POST arrays to []
- Validate that at least one location array is non-empty

Views
- Add Default column with center-aligned radio buttons; disable for
  unsaved rows; use attr() instead of data() for location IDs
- Escape dynamic location IDs against XSS in all affected partials
- form_count_details.php: fall back to default location when current
  is undefined; guard quantity input similarly
- Add aria-label to default radio inputs

Libraries / Items
- Widen Item_lib::get_item_location() and get_stock_destination() to
  nullable return types
- Guard null location_id in Items::getRow() and getGenerateBarcodes()
- Item::get_multiple_info(): accept ?int $location_id; short-circuit
  with where('item_id', -1) instead of always-false where('1','0')

i18n
- Add stock_location_default, stock_location_default_header,
  stock_location_name_header across all locale files

Tests
- Stock_locationTest: getDefaultLocationId, setDefaultLocation,
  saveSortOrder, delete compaction, saveValue; rename to
  testMethod_Scenario convention
- Add ConfigControllerTest / StockLocationsControllerTest with
  AdminAuthTrait covering CRUD, reorder, default assignment, and
  malformed/empty/blank payload validation
- DatabaseBootstrapTrait-based setup for ItemTest and Stock_locationTest

Signed-off-by: objecttothis <17935339+objecttothis@users.noreply.github.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-10-27 14:36:34 +04:00
objecttothis 1aab0aa69d chore(lang): remove unused mailchimp translation keys
Remove Georgian (ka) locale entries for mailchimp integration
strings that are no longer referenced in the app.

- app/Language/ka/Config.php: drop mailchimp_* config labels
- app/Language/ka/Customers.php: drop mailchimp_activity_*,
  mailchimp_info, mailchimp_member_rating, mailchimp_status,
  mailchimp_vip entries

Signed-off-by: objecttothis <17935339+objecttothis@users.noreply.github.com>
2026-10-26 17:32:16 +04:00
objecttothisandClaude Sonnet 5 8cda8551d7 Merge branch 'master' into plugin-system-fresh
Resolve language file conflicts: take master's translations, strip
MailChimp phrases (MailChimp is now a plugin instead of core), and
retain plugin-system additions (plugins/plugins_configuration keys).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-10-26 17:31:32 +04:00
khao_lek 1f5c8de4a8 Translated using Weblate (Thai)
Currently translated at 100.0% (238 of 238 strings)

Translation: opensourcepos/sales
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/sales/th/
2026-10-25 21:33:52 +01:00
khao_lek e2203e1580 Translated using Weblate (Thai)
Currently translated at 100.0% (80 of 80 strings)

Translation: opensourcepos/taxes
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/taxes/th/
2026-10-25 21:33:51 +01:00
khao_lek fe97de45a6 Translated using Weblate (Thai)
Currently translated at 100.0% (10 of 10 strings)

Translation: opensourcepos/error
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/error/th/
2026-10-25 21:33:51 +01:00
khao_lek 0a1cf0c3fb Translated using Weblate (Thai)
Currently translated at 100.0% (147 of 147 strings)

Translation: opensourcepos/reports
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/reports/th/
2026-10-25 21:33:51 +01:00
khao_lek d4b96f5928 Translated using Weblate (Thai)
Currently translated at 100.0% (32 of 32 strings)

Translation: opensourcepos/attributes
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/attributes/th/
2026-10-25 14:17:45 +01:00
khao_lek 84be6a3369 Translated using Weblate (Thai)
Currently translated at 100.0% (53 of 53 strings)

Translation: opensourcepos/customers
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/customers/th/
2026-10-25 14:17:45 +01:00
khao_lek 4be632dac6 Translated using Weblate (Thai)
Currently translated at 100.0% (341 of 341 strings)

Translation: opensourcepos/config
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/config/th/
2026-10-25 14:17:44 +01:00
khao_lek 1b988b0346 Translated using Weblate (Thai)
Currently translated at 99.3% (146 of 147 strings)

Translation: opensourcepos/reports
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/reports/th/
2026-10-25 14:17:43 +01:00
khao_lek 91e49cf049 Translated using Weblate (Thai)
Currently translated at 80.0% (8 of 10 strings)

Translation: opensourcepos/error
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/error/th/
2026-10-25 14:17:43 +01:00
khao_lek b063373d23 Translated using Weblate (Thai)
Currently translated at 96.6% (230 of 238 strings)

Translation: opensourcepos/sales
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/sales/th/
2026-10-25 14:17:42 +01:00
khao_lek 28d99c18cd Translated using Weblate (Thai)
Currently translated at 100.0% (121 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/th/
2026-10-25 14:17:42 +01:00
khao_lek 8de93daf2e Translated using Weblate (Thai)
Currently translated at 100.0% (27 of 27 strings)

Translation: opensourcepos/login
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/login/th/
2026-10-25 14:17:41 +01:00
JisooMx 82468e6665 Translated using Weblate (Spanish (Mexico))
Currently translated at 77.9% (53 of 68 strings)

Translation: opensourcepos/giftcards
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/giftcards/es_MX/
2026-10-25 02:33:44 +01:00
JisooMx 317d1431e5 Translated using Weblate (Spanish (Mexico))
Currently translated at 99.7% (340 of 341 strings)

Translation: opensourcepos/config
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/config/es_MX/
2026-10-25 02:33:44 +01:00
JisooMx 08ecb15f0f Translated using Weblate (Spanish)
Currently translated at 100.0% (27 of 27 strings)

Translation: opensourcepos/login
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/login/es/
2026-10-25 02:33:44 +01:00
JisooMx b3a95840c3 Translated using Weblate (Spanish (Mexico))
Currently translated at 90.3% (215 of 238 strings)

Translation: opensourcepos/sales
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/sales/es_MX/
2026-10-25 02:33:43 +01:00
JisooMx d71e7df04e Translated using Weblate (Spanish (Mexico))
Currently translated at 99.3% (146 of 147 strings)

Translation: opensourcepos/reports
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/reports/es_MX/
2026-10-25 00:41:50 +02:00
JisooMx ee68bbe315 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (121 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-25 00:41:50 +02:00
JisooMx b723130f52 Translated using Weblate (Spanish (Mexico))
Currently translated at 99.7% (340 of 341 strings)

Translation: opensourcepos/config
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/config/es_MX/
2026-10-25 00:41:50 +02:00
JisooMx cdcf6a988b Translated using Weblate (Spanish (Mexico))
Currently translated at 90.3% (215 of 238 strings)

Translation: opensourcepos/sales
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/sales/es_MX/
2026-10-25 00:41:50 +02:00
JisooMx 11678447b8 Translated using Weblate (Spanish (Mexico))
Currently translated at 98.1% (52 of 53 strings)

Translation: opensourcepos/customers
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/customers/es_MX/
2026-10-25 00:41:50 +02:00
JisooMx 8056580e55 Translated using Weblate (Spanish (Mexico))
Currently translated at 77.9% (53 of 68 strings)

Translation: opensourcepos/giftcards
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/giftcards/es_MX/
2026-10-25 00:41:50 +02:00
JisooMx c136832174 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (21 of 21 strings)

Translation: opensourcepos/suppliers
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/suppliers/es_MX/
2026-10-25 00:41:50 +02:00
JisooMx 9cd4f84689 Translated using Weblate (Spanish (Mexico))
Currently translated at 99.3% (146 of 147 strings)

Translation: opensourcepos/reports
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/reports/es_MX/
2026-10-24 22:08:45 +02:00
JisooMx 55d0534bf8 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (80 of 80 strings)

Translation: opensourcepos/taxes
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/taxes/es_MX/
2026-10-24 22:08:44 +02:00
JisooMx 2ad1c7033a Translated using Weblate (Spanish (Mexico))
Currently translated at 98.1% (52 of 53 strings)

Translation: opensourcepos/customers
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/customers/es_MX/
2026-10-24 22:08:44 +02:00
JisooMx 7ec6ad5554 Translated using Weblate (Spanish (Mexico))
Currently translated at 77.9% (53 of 68 strings)

Translation: opensourcepos/giftcards
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/giftcards/es_MX/
2026-10-24 22:08:44 +02:00
JisooMx 1f58afae90 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (46 of 46 strings)

Translation: opensourcepos/cashups
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/cashups/es_MX/
2026-10-24 22:08:44 +02:00
JisooMx 09e36ee77d Translated using Weblate (Spanish (Mexico))
Currently translated at 96.1% (328 of 341 strings)

Translation: opensourcepos/config
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/config/es_MX/
2026-10-24 22:08:43 +02:00
JoseLuisKukMagana f12cb3b498 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (121 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-24 22:08:43 +02:00
JisooMx a614d8ad57 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (121 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-24 22:08:43 +02:00
Ezequiel Gonzalez L 0b3c781f90 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (121 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-24 22:08:42 +02:00
JoseLuisKukMagana 2debbf84f1 Translated using Weblate (Spanish (Mexico))
Currently translated at 65.2% (79 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-24 21:36:23 +02:00
JisooMx 8e8d07534e Translated using Weblate (Spanish (Mexico))
Currently translated at 65.2% (79 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-24 21:36:23 +02:00
JisooMx ee31ad534d Translated using Weblate (Spanish (Mexico))
Currently translated at 98.1% (52 of 53 strings)

Translation: opensourcepos/customers
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/customers/es_MX/
2026-10-24 21:35:47 +02:00
JisooMx c20dd53e32 Translated using Weblate (Spanish (Mexico))
Currently translated at 69.1% (47 of 68 strings)

Translation: opensourcepos/giftcards
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/giftcards/es_MX/
2026-10-24 21:35:47 +02:00
JoseLuisKukMagana 50c1f7ce06 Translated using Weblate (Spanish (Mexico))
Currently translated at 64.4% (78 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-24 21:35:47 +02:00
JisooMx 1f10c1b694 Translated using Weblate (Spanish (Mexico))
Currently translated at 64.4% (78 of 121 strings)

Translation: opensourcepos/items
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/items/es_MX/
2026-10-24 21:35:47 +02:00
JisooMx 2b9fceab94 Translated using Weblate (Spanish (Mexico))
Currently translated at 100.0% (27 of 27 strings)

Translation: opensourcepos/login
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/login/es_MX/
2026-10-24 21:35:46 +02:00
JisooMx 06c77868fc Translated using Weblate (Spanish (Mexico))
Currently translated at 98.7% (79 of 80 strings)

Translation: opensourcepos/taxes
Translate-URL: https://translate.opensourcepos.org/projects/opensourcepos/taxes/es_MX/
2026-10-24 21:26:36 +02:00