Files
opensourcepos/app/Language/ta/Sales.php
objecttothis 9c542efaf6 Feature: Payment reference code (#4587)
* Add `reference_code` to sale payment queries and group by statements

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* Refactor `Sales` controller to improve payment handling readability and replace snake_case with camelCase variables

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* Add missing translations for `Sales` language file and include new keys like `must_enter_rrn` and `reference_code`

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* Refactor `Sales` payment handling to use camelCase and extend `addPayment` with `referenceCode` support

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* Refactor `Sales` models, controllers, and libraries to adopt camelCase naming conventions and improve readability

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* Add translations and updates for `must_enter_reference_code` and `reference_code` across language files and update `Sales` controller to replace `must_enter_rrn` with the new key

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* feat(sales): add reference code input and payment type helper

- Add `get_reference_code_payment_types()` to locale_helper as single
  source of truth for card-requiring payment types
- Add reference code row to register view, shown/hidden via JS based
  on selected payment type
- Fix payment type dropdown width to 100% for consistent layout
- Add min-width to payment buttons and right-padding to button group

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* feat(config): add payment reference code length configuration

- Add payment_reference_code_min and payment_reference_code_max fields
  to Config controller save logic
- Add translation keys for reference code length limits across all
  language files (min/max label + section header)
- Align array key formatting in Config controller for readability

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* style(lang): normalize string delimiters to single quotes across all language files

Convert double-quoted array keys and values to single quotes in all
app/Language/*/Config.php and app/Language/*/Sales.php variants.
No translation content changed — formatting only.

Also add Localization section to AGENTS.md documenting language file
conventions for new keys and fallback behavior.

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* feat(lang): add payment reference code length translations

Add localized strings for payment_reference_code_length_limits,
payment_reference_code_length_max_label, and
payment_reference_code_length_min_label across all supported locales.

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* test(config,sales): add payment reference code min/max validation tests

- Add baseLocalePayload() helper in ConfigTest for postSaveLocale tests
- Add testSaveLocale_AcceptsValidReferenceCodeMinMax and related boundary tests
- Add Sale_libPaymentTest for payment reference code validation in Sale_lib

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* fix(sales): add type-specific validation for amount_tendered

Gift card payments use amount_tendered as giftcard number (integer);
cash/other payments require decimal_locale format. Apply correct
validation rule per payment type instead of generic required.

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* fix(lang): replace self-closing </br> with <br> in all locales

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* fix(sales): use configurable precision in discount comparison

Replace hardcoded precision 2 with totals_decimals() when comparing
discount against item total via bccomp/bcmul, so discount validation
respects the configured decimal precision setting.

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* fix(lang): correct Azerbaijani translations in Config.php

Replace placeholder/mismatched strings with accurate translations:
- email_mailpath, email_smtp_pass, invoice_email_message
- number_locale_invalid/required, receipt_template
- reward_configuration, right, tax_decimals, theme

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* feat(sales): add reference code support to payment edit flow

- Add reference_code field to new payment row in sale edit form
- Persist reference_code on insert in Sale model
- Validate reference_code_new in Sales controller using configurable min/max length rules

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* feat(lang): add Georgian (ka) language stubs for Config and Sales

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* Match the fallback maximum reference_code length to the maximum of the field in the db

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

* Bug fixes

- Add validation of UI settings to prevent overridden values from being passed.
- Correct maximum value in JS for payment_reference_code maximum length to 40.
- Fix bug causing copy_entire_sale() to incorrectly copy the reference code and cash_adjustment

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>

---------

Signed-off-by: Travis Garrison <travis@chiraqbookstore.com>
Co-authored-by: Travis Garrison <travis@chiraqbookstore.com>
2026-07-10 13:49:05 +04:00

236 lines
20 KiB
PHP

<?php
return [
'account_number' => 'கணக்கு #',
'add_payment' => 'கட்டணத்தைச் சேர்க்கவும்',
'amount_due' => 'செலுத்த வேண்டிய தொகை',
'amount_tendered' => 'கொடுத்த தொகை',
'authorized_signature' => 'அங்கீகரிக்கப்பட்ட கையெழுத்து',
'cancel_sale' => 'ரத்துசெய்',
'cash' => 'பணம்',
'cash_1' => '',
'cash_2' => '',
'cash_3' => '',
'cash_4' => '',
'cash_adjustment' => 'பண சரிசெய்தல்',
'cash_deposit' => 'பண வைப்பு',
'cash_filter' => 'பணம்',
'change_due' => 'நிலுவை',
'change_price' => 'விற்பனை விலையை மாற்றவும்',
'check' => 'சோதி',
'check_balance' => 'மீதமுள்ளதை சோதி',
'check_filter' => 'சோதி',
'close' => '',
'comment' => 'குறிப்புரை',
'comments' => 'குறிப்புரைகள்',
'company_name' => '',
'complete' => '',
'complete_sale' => 'நிறைவுறு',
'confirm_cancel_sale' => 'இந்த விற்பனையை அழிக்க விரும்புகிறீர்களா? அனைத்து பொருட்களும் அழிக்கப்படும்.',
'confirm_delete' => 'தேர்ந்தெடுக்கப்பட்ட விற்பனை (களை) நீக்க விரும்புகிறீர்களா?',
'confirm_restore' => 'தேர்ந்தெடுக்கப்பட்ட விற்பனை (களை) மீட்டமைக்க விரும்புகிறீர்களா?',
'credit' => 'கடன் அட்டை',
'credit_deposit' => 'கடன் வைப்பு',
'credit_filter' => 'கடன் அட்டை',
'current_table' => '',
'customer' => 'வாடிக்கையாளர்',
'customer_address' => 'முகவரி',
'customer_discount' => 'தள்ளுபடி',
'customer_email' => 'மின்னஞ்சல்',
'customer_location' => 'இடம்',
'customer_mailchimp_status' => 'மெயில்சிம்ப் நிலை',
'customer_optional' => '(நிலுவை தொகை வைக்க அவசியம்)',
'customer_required' => '(தேவை)',
'customer_total' => 'மொத்தம்',
'customer_total_spent' => '',
'customers_available_points' => 'இருப்பு புள்ளிகள்',
'daily_sales' => '',
'date' => 'விற்பனை தேதி',
'date_range' => 'தேதி வரம்பு',
'date_required' => 'சரியான தேதியை உள்ளிட வேண்டும்.',
'date_type' => 'தேதி தேவையான உள்ளீடு.',
'debit' => 'பற்று அட்டை',
'debit_filter' => '',
'delete' => 'நீக்க அனுமதிக்கவும்',
'delete_confirmation' => 'இந்த விற்பனையை நீக்க விரும்புகிறீர்களா? இந்த செயலை திரும்ப பெற முடியாது.',
'delete_entire_sale' => 'முழு விற்பனையையும் நீக்கு',
'delete_successful' => 'விற்பனை நீக்கப்பட்டது.',
'delete_unsuccessful' => 'விற்பனை நீக்கப்படவில்லை.',
'description_abbrv' => 'பொருள்.',
'discard' => 'கைவிடு',
'discard_quote' => '',
'discount' => 'தள்ளு',
'discount_exceeds_item_total' => '',
'discount_included' => '% தள்ளுபடி',
'discount_percent_exceeds_100' => '',
'discount_short' => '%',
'due' => 'நிலுவை',
'due_filter' => 'நிலுவை',
'edit' => 'திருத்து',
'edit_item' => 'பொருளை திருத்து',
'edit_sale' => 'விற்பனையை திருத்து',
'email_receipt' => 'மின்னஞ்சல் ரசீது',
'employee' => 'ஊழியர்',
'entry' => 'உள்ளீடு',
'error_editing_item' => 'பொருளை திருத்துவதில் பிழை',
'find_or_scan_item' => 'பொருளைக் தேடு அல்லது ஸ்கேன் செய்யுங்கள்',
'find_or_scan_item_or_receipt' => 'தேடு அல்லது பொருளை வருடு அல்லது ரசீது',
'giftcard' => 'பரிசு அட்டை',
'giftcard_balance' => 'பரிசு அட்டை இருப்பு',
'giftcard_filter' => '',
'giftcard_number' => 'பரிசு அட்டை எண்',
'group_by_category' => 'வகை வாரியாக',
'group_by_type' => 'வகை வாரியாக',
'hsn' => 'HSN',
'id' => 'விற்பனை எண்',
'include_prices' => 'விலைகளைச் சேர்க்கவா?',
'invoice' => 'விற்பனைச்சிட்டை',
'invoice_confirm' => 'இந்த விற்பனைச்சிட்டை அனுப்பப்படும்',
'invoice_enable' => 'விற்பனைச்சிட்டை எண்',
'invoice_filter' => 'விற்பனைச்சிட்டைகள்',
'invoice_no_email' => 'இந்த வாடிக்கையாளருக்கு சரியான மின்னஞ்சல் முகவரி இல்லை.',
'invoice_number' => 'விற்பனைச்சிட்டை #',
'invoice_number_duplicate' => 'விற்பனைச்சிட்டை எண் {0} தனித்துவமாக இருக்க வேண்டும்.',
'invoice_sent' => 'விற்பனைச்சிட்டை அனுப்பப்பட்டது',
'invoice_total' => 'விற்பனைச்சிட்டை மொத்தம்',
'invoice_type_custom_invoice' => 'தனிப்பயன் விலைப்பட்டியல் (custom_invoice.php)',
'invoice_type_custom_tax_invoice' => 'தனிப்பயன் வரி விலைப்பட்டியல் (custom_tax_invoice.php)',
'invoice_type_invoice' => 'விலைப்பட்டியல் (விலைப்பட்டியல். Php)',
'invoice_type_tax_invoice' => 'வரி விலைப்பட்டியல் (tax_invoice.php)',
'invoice_unsent' => 'விற்பனைச்சிட்டை அனுப்பப்படவில்லை',
'invoice_update' => 'மறுபரிசீலனை',
'item_insufficient_of_stock' => 'உருப்படிக்கு போதுமான பங்கு இல்லை.',
'item_name' => 'பொருளின் பெயர்',
'item_number' => 'பொருள் #',
'item_out_of_stock' => 'பொருள் கையிருப்பில் இல்லை.',
'key_browser' => '',
'key_cancel' => 'Cancels Current Quote/Invoice/Sale',
'key_customer_search' => 'Customer Search',
'key_finish_quote' => 'Finish Quote/Invoice witdout payment',
'key_finish_sale' => 'Add Payment and Complete Invoice/Sale',
'key_full' => '',
'key_function' => 'Function',
'key_help' => 'Shortcuts',
'key_help_modal' => 'Open Shortcuts Window',
'key_in' => '',
'key_item_search' => 'Item Search',
'key_out' => '',
'key_payment' => 'Add Payment',
'key_print' => '',
'key_restore' => '',
'key_search' => '',
'key_suspend' => 'Suspend Current Sale',
'key_suspended' => 'Show Suspended Sales',
'key_system' => '',
'key_tendered' => 'Edit Amount Tendered',
'key_title' => 'Sales Keyboard Shortcuts',
'mc' => '',
'mode' => 'சில்லரை வணிகம்',
'must_enter_numeric' => 'தொகை ஒரு எண்ணாக இருக்க வேண்டும்.',
'must_enter_numeric_giftcard' => 'பரிசு அட்டை எண் ஒரு எண்ணாக இருக்க வேண்டும்.',
'must_enter_reference_code' => 'குறிப்பு/மீட்டெடுப்பு எண் உள்ளிட வேண்டும்.',
'negative_discount_invalid' => '',
'negative_price_invalid' => '',
'negative_quantity_invalid' => '',
'negative_total_invalid' => '',
'new_customer' => 'புது வாடிக்கையாளர்',
'new_item' => 'புதிய பொருள்',
'no_description' => 'No description',
'no_filter' => 'அனைத்தும்',
'no_items_in_cart' => 'வண்டியில் எந்த பொருட்களும் இல்லை.',
'no_sales_to_display' => 'காண்பிக்க எந்த விற்பனையும் இல்லை.',
'none_selected' => 'விற்பனை(களை) நீக்க நீங்கள் எந்தப் பொருட்களையும் தேர்ந்தெடுக்கவில்லை.',
'nontaxed_ind' => ' ',
'not_authorized' => 'இந்த செயலுக்கு அங்கீகாரம் இல்லை.',
'one_or_multiple' => 'விற்பனை(கள்)',
'payment' => 'கட்டண வகை',
'payment_amount' => 'தொகை',
'payment_not_cover_total' => 'கட்டண தொகை மொத்தத்தை விட அதிகமாகவோ அல்லது சமமாகவோ இருக்க வேண்டும்.',
'payment_type' => 'Type',
'payments' => '',
'payments_total' => 'மொத்தக் கட்டணம்',
'price' => 'விலை',
'print_after_sale' => 'விற்பனைக்குப் பிறகு அச்சிடு',
'quantity' => 'அளவு',
'quantity_less_than_reorder_level' => 'எச்சரிக்கை: விரும்பிய அளவு அந்த உருப்படிக்கான மறுவரிசை நிலைக்கு கீழே உள்ளது.',
'quantity_less_than_zero' => 'எச்சரிக்கை: விரும்பிய அளவு போதுமானதாக இல்லை. இருப்பினும் நீங்கள் விற்பனையைச் செயல்படுத்தலாம், ஆனால் உங்கள் சரக்குகளைத் தணிக்கை செய்யுங்கள்.',
'quantity_of_items' => '{0} பொருட்களின் அளவு',
'quote' => 'விலைப்புள்ளி',
'quote_number' => 'விலைப்புள்ளி எண்',
'quote_number_duplicate' => 'விலைப்புள்ளி எண் தனித்துவமாக இருக்க வேண்டும்.',
'quote_sent' => 'விலைப்புள்ளி அனுப்பப்பட்டது',
'quote_unsent' => 'விலைப்புள்ளியை அனுப்ப இயலவில்லை',
'receipt' => 'விற்பனை ரசீது',
'receipt_no_email' => 'இந்த வாடிக்கையாளருக்கு சரியான மின்னஞ்சல் முகவரி இல்லை.',
'receipt_number' => 'விற்பனை #',
'receipt_sent' => 'ரசீது அனுப்பப்பட்டது',
'receipt_unsent' => 'ரசீதை அனுப்ப இயலவில்லை',
'reference_code' => 'கட்டண குறிப்பு குறியீடு',
'reference_code_invalid_characters' => 'குறிப்பு குறியீடு எழுத்துக்கள் மற்றும் எண்கள் மட்டுமே கொண்டிருக்க வேண்டும்.',
'reference_code_length_error' => 'குறிப்பு குறியீட்டின் நீளம் தவறானது.',
'refund' => 'பணத்தைத் திரும்பப்பெறுதல் வகை',
'register' => 'விற்பனை பதிவு',
'remove_customer' => 'வாடிக்கையாளரை அகற்று',
'remove_discount' => '',
'return' => 'Return',
'rewards' => 'வெகுமதி புள்ளிகள்',
'rewards_balance' => 'வெகுமதி புள்ளிகள் இருப்பு',
'rewards_package' => 'வெகுமதிகள்',
'rewards_remaining_balance' => 'வெகுமதி புள்ளிகள் மீதமுள்ள மதிப்பு ',
'sale' => 'விற்பனை',
'sale_by_invoice' => 'விலைப்பட்டியல் மூலம் விற்பனை',
'sale_for_customer' => 'வாடிக்கையாளர்:',
'sale_time' => 'நேரம்',
'sales_tax' => 'விற்பனை வரி',
'sales_total' => '',
'select_customer' => 'வாடிக்கையாளரைத் தேர்ந்தெடு',
'send_invoice' => 'விலைப்பட்டியல் அனுப்பு',
'send_quote' => 'விலைப்புள்ளியை அனுப்பு',
'send_receipt' => 'ரசீதை அனுப்பு',
'send_work_order' => 'பணி ஆணையை அனுப்பவும்',
'serial' => 'வரிசை',
'service_charge' => '',
'show_due' => '',
'show_invoice' => 'விலைப்பட்டியலைக் காட்டு',
'show_receipt' => 'ரசீதைக் காட்டு',
'start_typing_customer_name' => 'வாடிக்கையாளர் விவரங்களைத் தட்டச்சு செய்யத் தொடங்கு...',
'start_typing_item_name' => 'Start typing Item Name or scan Barcode...',
'stock' => 'Stock',
'stock_location' => 'Stock Location',
'sub_total' => 'Subtotal',
'successfully_deleted' => 'You have successfully deleted',
'successfully_restored' => 'You have successfully restored',
'successfully_suspended_sale' => 'Sale suspend successful.',
'successfully_updated' => 'Sale update successful.',
'suspend_sale' => 'Suspend',
'suspended_doc_id' => 'Document',
'suspended_sale_id' => 'ID',
'suspended_sales' => 'Suspended',
'table' => 'Table',
'takings' => 'Daily Sales',
'tax' => 'Tax',
'tax_id' => 'Tax Id',
'tax_invoice' => 'Tax Invoice',
'tax_percent' => 'Tax %',
'taxed_ind' => 'வ',
'total' => 'Total',
'total_tax_exclusive' => 'Tax excluded',
'transaction_failed' => 'Sales Transaction failed.',
'unable_to_add_item' => 'Item add to Sale failed',
'unsuccessfully_deleted' => 'Sale(s) delete failed.',
'unsuccessfully_restored' => 'Sale(s) restore failed.',
'unsuccessfully_suspended_sale' => 'Sale suspend failed.',
'unsuccessfully_updated' => 'Sale update failed.',
'unsuspend' => 'Unsuspend',
'unsuspend_and_delete' => 'Action',
'update' => 'Update',
'upi' => 'UPI',
'visa' => '',
'wholesale' => '',
'work_order' => 'Work Order',
'work_order_number' => 'Work Order Number',
'work_order_number_duplicate' => 'Work Order Number must be unique.',
'work_order_sent' => 'Work Order sent to',
'work_order_unsent' => 'Work Order failed to be sent to',
];