mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-07-26 06:37:02 -04:00
* 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>
336 lines
18 KiB
PHP
336 lines
18 KiB
PHP
<?php
|
|
|
|
return [
|
|
'address' => '',
|
|
'address_required' => '',
|
|
'all_set' => 'All file permissions are set correctly!',
|
|
'allow_duplicate_barcodes' => '',
|
|
'apostrophe' => '',
|
|
'backup_button' => '',
|
|
'backup_database' => '',
|
|
'barcode' => '',
|
|
'barcode_company' => '',
|
|
'barcode_configuration' => '',
|
|
'barcode_content' => '',
|
|
'barcode_first_row' => '',
|
|
'barcode_font' => '',
|
|
'barcode_formats' => '',
|
|
'barcode_generate_if_empty' => '',
|
|
'barcode_height' => '',
|
|
'barcode_id' => '',
|
|
'barcode_info' => '',
|
|
'barcode_layout' => '',
|
|
'barcode_name' => '',
|
|
'barcode_number' => '',
|
|
'barcode_number_in_row' => '',
|
|
'barcode_page_cellspacing' => '',
|
|
'barcode_page_width' => '',
|
|
'barcode_price' => '',
|
|
'barcode_second_row' => '',
|
|
'barcode_third_row' => '',
|
|
'barcode_tooltip' => '',
|
|
'barcode_type' => '',
|
|
'barcode_width' => '',
|
|
'bottom' => '',
|
|
'cash_button' => '',
|
|
'cash_button_1' => '',
|
|
'cash_button_2' => '',
|
|
'cash_button_3' => '',
|
|
'cash_button_4' => '',
|
|
'cash_button_5' => '',
|
|
'cash_button_6' => '',
|
|
'cash_decimals' => '',
|
|
'cash_decimals_tooltip' => '',
|
|
'cash_rounding' => '',
|
|
'category_dropdown' => '',
|
|
'center' => '',
|
|
'change_apperance_tooltip' => '',
|
|
'comma' => '',
|
|
'company' => '',
|
|
'company_avatar' => '',
|
|
'company_change_image' => '',
|
|
'company_logo' => '',
|
|
'company_remove_image' => '',
|
|
'company_required' => '',
|
|
'company_select_image' => '',
|
|
'company_website_url' => '',
|
|
'country_codes' => '',
|
|
'country_codes_tooltip' => '',
|
|
'currency_code' => '',
|
|
'currency_decimals' => '',
|
|
'currency_symbol' => '',
|
|
'current_employee_only' => '',
|
|
'customer_reward' => '',
|
|
'customer_reward_duplicate' => '',
|
|
'customer_reward_enable' => '',
|
|
'customer_reward_invalid_chars' => '',
|
|
'customer_reward_required' => '',
|
|
'customer_sales_tax_support' => '',
|
|
'date_or_time_format' => '',
|
|
'datetimeformat' => '',
|
|
'decimal_point' => '',
|
|
'default_barcode_font_size_number' => '',
|
|
'default_barcode_font_size_required' => '',
|
|
'default_barcode_height_number' => '',
|
|
'default_barcode_height_required' => '',
|
|
'default_barcode_num_in_row_number' => '',
|
|
'default_barcode_num_in_row_required' => '',
|
|
'default_barcode_page_cellspacing_number' => '',
|
|
'default_barcode_page_cellspacing_required' => '',
|
|
'default_barcode_page_width_number' => '',
|
|
'default_barcode_page_width_required' => '',
|
|
'default_barcode_width_number' => '',
|
|
'default_barcode_width_required' => '',
|
|
'default_item_columns' => '',
|
|
'default_origin_tax_code' => '',
|
|
'default_receivings_discount' => '',
|
|
'default_receivings_discount_number' => '',
|
|
'default_receivings_discount_required' => '',
|
|
'default_sales_discount' => '',
|
|
'default_sales_discount_number' => '',
|
|
'default_sales_discount_required' => '',
|
|
'default_tax_category' => '',
|
|
'default_tax_code' => '',
|
|
'default_tax_jurisdiction' => '',
|
|
'default_tax_name_number' => '',
|
|
'default_tax_name_required' => '',
|
|
'default_tax_rate' => '',
|
|
'default_tax_rate_1' => '',
|
|
'default_tax_rate_2' => '',
|
|
'default_tax_rate_3' => '',
|
|
'default_tax_rate_number' => '',
|
|
'default_tax_rate_required' => '',
|
|
'derive_sale_quantity' => '',
|
|
'derive_sale_quantity_tooltip' => '',
|
|
'dinner_table' => '',
|
|
'dinner_table_duplicate' => '',
|
|
'dinner_table_enable' => '',
|
|
'dinner_table_invalid_chars' => '',
|
|
'dinner_table_required' => '',
|
|
'dot' => '',
|
|
'email' => '',
|
|
'email_configuration' => '',
|
|
'email_mailpath' => '',
|
|
'email_protocol' => '',
|
|
'email_receipt_check_behaviour' => '',
|
|
'email_receipt_check_behaviour_always' => '',
|
|
'email_receipt_check_behaviour_last' => '',
|
|
'email_receipt_check_behaviour_never' => '',
|
|
'email_smtp_crypto' => '',
|
|
'email_smtp_host' => '',
|
|
'email_smtp_pass' => '',
|
|
'email_smtp_port' => '',
|
|
'email_smtp_timeout' => '',
|
|
'email_smtp_user' => '',
|
|
'enable_avatar' => '',
|
|
'enable_avatar_tooltip' => '',
|
|
'enable_dropdown_tooltip' => '',
|
|
'enable_new_look' => '',
|
|
'enable_right_bar' => '',
|
|
'enable_right_bar_tooltip' => '',
|
|
'enforce_privacy' => '',
|
|
'enforce_privacy_tooltip' => '',
|
|
'fax' => '',
|
|
'file_perm' => 'There are problems with file permissions please fix and reload this page.',
|
|
'financial_year' => '',
|
|
'financial_year_apr' => '',
|
|
'financial_year_aug' => '',
|
|
'financial_year_dec' => '',
|
|
'financial_year_feb' => '',
|
|
'financial_year_jan' => '',
|
|
'financial_year_jul' => '',
|
|
'financial_year_jun' => '',
|
|
'financial_year_mar' => '',
|
|
'financial_year_may' => '',
|
|
'financial_year_nov' => '',
|
|
'financial_year_oct' => '',
|
|
'financial_year_sep' => '',
|
|
'floating_labels' => '',
|
|
'gcaptcha_enable' => '',
|
|
'gcaptcha_secret_key' => '',
|
|
'gcaptcha_secret_key_required' => '',
|
|
'gcaptcha_site_key' => '',
|
|
'gcaptcha_site_key_required' => '',
|
|
'gcaptcha_tooltip' => '',
|
|
'general' => '',
|
|
'general_configuration' => '',
|
|
'giftcard_number' => '',
|
|
'giftcard_random' => '',
|
|
'giftcard_series' => '',
|
|
'image_allowed_file_types' => '',
|
|
'image_max_height_tooltip' => '',
|
|
'image_max_size_tooltip' => '',
|
|
'image_max_width_tooltip' => '',
|
|
'image_restrictions' => '',
|
|
'include_hsn' => '',
|
|
'info' => '',
|
|
'info_configuration' => '',
|
|
'input_groups' => '',
|
|
'integrations' => '',
|
|
'integrations_configuration' => '',
|
|
'invoice' => '',
|
|
'invoice_configuration' => '',
|
|
'invoice_default_comments' => '',
|
|
'invoice_email_message' => '',
|
|
'invoice_enable' => '',
|
|
'invoice_printer' => '',
|
|
'invoice_type' => '',
|
|
'is_readable' => '',
|
|
'is_writable' => 'is writable, but the permissions are higher than 750.',
|
|
'item_markup' => '',
|
|
'jsprintsetup_required' => '',
|
|
'language' => '',
|
|
'last_used_invoice_number' => '',
|
|
'last_used_quote_number' => '',
|
|
'last_used_work_order_number' => '',
|
|
'left' => '',
|
|
'license' => '',
|
|
'license_configuration' => '',
|
|
'line_sequence' => '',
|
|
'lines_per_page' => '',
|
|
'lines_per_page_number' => '',
|
|
'lines_per_page_required' => '',
|
|
'locale' => '',
|
|
'locale_configuration' => '',
|
|
'locale_info' => '',
|
|
'location' => '',
|
|
'location_configuration' => '',
|
|
'location_info' => '',
|
|
'login_form' => '',
|
|
'logout' => '',
|
|
'mailchimp' => '',
|
|
'mailchimp_api_key' => '',
|
|
'mailchimp_configuration' => '',
|
|
'mailchimp_key_successfully' => '',
|
|
'mailchimp_key_unsuccessfully' => '',
|
|
'mailchimp_lists' => '',
|
|
'mailchimp_tooltip' => '',
|
|
'message' => '',
|
|
'message_configuration' => '',
|
|
'msg_msg' => '',
|
|
'msg_msg_placeholder' => '',
|
|
'msg_pwd' => '',
|
|
'msg_pwd_required' => '',
|
|
'msg_src' => '',
|
|
'msg_src_required' => '',
|
|
'msg_uid' => '',
|
|
'msg_uid_required' => '',
|
|
'multi_pack_enabled' => '',
|
|
'no_risk' => 'No security/vulnerability risks.',
|
|
'none' => '',
|
|
'notify_alignment' => '',
|
|
'number_format' => '',
|
|
'number_locale' => '',
|
|
'number_locale_invalid' => '',
|
|
'number_locale_required' => '',
|
|
'number_locale_tooltip' => '',
|
|
'os_timezone' => '',
|
|
'ospos_info' => '',
|
|
'payment_options_order' => '',
|
|
'payment_reference_code_length_limits' => 'പേയ്മെന്റ് റഫറൻസ് കോഡ്<br>ദൈർഘ്യ പരിധികൾ',
|
|
'payment_reference_code_length_max_label' => 'പരമാവധി',
|
|
'payment_reference_code_length_min_label' => 'കുറഞ്ഞത്',
|
|
'perm_risk' => 'Permissions higher than 750 leaves this software at risk.',
|
|
'phone' => '',
|
|
'phone_required' => '',
|
|
'print_bottom_margin' => '',
|
|
'print_bottom_margin_number' => '',
|
|
'print_bottom_margin_required' => '',
|
|
'print_delay_autoreturn' => '',
|
|
'print_delay_autoreturn_number' => '',
|
|
'print_delay_autoreturn_required' => '',
|
|
'print_footer' => '',
|
|
'print_header' => '',
|
|
'print_left_margin' => '',
|
|
'print_left_margin_number' => '',
|
|
'print_left_margin_required' => '',
|
|
'print_receipt_check_behaviour' => '',
|
|
'print_receipt_check_behaviour_always' => '',
|
|
'print_receipt_check_behaviour_last' => '',
|
|
'print_receipt_check_behaviour_never' => '',
|
|
'print_right_margin' => '',
|
|
'print_right_margin_number' => '',
|
|
'print_right_margin_required' => '',
|
|
'print_silently' => '',
|
|
'print_top_margin' => '',
|
|
'print_top_margin_number' => '',
|
|
'print_top_margin_required' => '',
|
|
'quantity_decimals' => '',
|
|
'quick_cash_enable' => '',
|
|
'quote_default_comments' => '',
|
|
'receipt' => '',
|
|
'receipt_category' => '',
|
|
'receipt_configuration' => '',
|
|
'receipt_default' => '',
|
|
'receipt_font_size' => '',
|
|
'receipt_font_size_number' => '',
|
|
'receipt_font_size_required' => '',
|
|
'receipt_info' => '',
|
|
'receipt_printer' => '',
|
|
'receipt_short' => '',
|
|
'receipt_show_company_name' => '',
|
|
'receipt_show_description' => '',
|
|
'receipt_show_serialnumber' => '',
|
|
'receipt_show_tax_ind' => '',
|
|
'receipt_show_taxes' => '',
|
|
'receipt_show_total_discount' => '',
|
|
'receipt_template' => '',
|
|
'receiving_calculate_average_price' => '',
|
|
'recv_invoice_format' => '',
|
|
'register_mode_default' => '',
|
|
'report_an_issue' => '',
|
|
'return_policy_required' => '',
|
|
'reward' => '',
|
|
'reward_configuration' => '',
|
|
'right' => '',
|
|
'sales_invoice_format' => '',
|
|
'sales_quote_format' => '',
|
|
'mailpath_invalid' => '',
|
|
'saved_successfully' => '',
|
|
'saved_unsuccessfully' => '',
|
|
'security_issue' => 'Security Vulnerability Warning',
|
|
'server_notice' => 'Please use the below info for issue reporting.',
|
|
'service_charge' => '',
|
|
'show_due_enable' => '',
|
|
'show_office_group' => '',
|
|
'statistics' => '',
|
|
'statistics_tooltip' => '',
|
|
'stock_location' => '',
|
|
'stock_location_duplicate' => '',
|
|
'stock_location_invalid_chars' => '',
|
|
'stock_location_required' => '',
|
|
'suggestions_fifth_column' => '',
|
|
'suggestions_first_column' => '',
|
|
'suggestions_fourth_column' => '',
|
|
'suggestions_layout' => '',
|
|
'suggestions_second_column' => '',
|
|
'suggestions_third_column' => '',
|
|
'system_conf' => 'Setup & Conf',
|
|
'system_info' => 'System Info',
|
|
'table' => '',
|
|
'table_configuration' => '',
|
|
'takings_printer' => '',
|
|
'tax' => '',
|
|
'tax_category' => '',
|
|
'tax_category_duplicate' => '',
|
|
'tax_category_invalid_chars' => '',
|
|
'tax_category_required' => '',
|
|
'tax_category_used' => '',
|
|
'tax_configuration' => '',
|
|
'tax_decimals' => '',
|
|
'tax_id' => '',
|
|
'tax_included' => '',
|
|
'theme' => '',
|
|
'theme_preview' => '',
|
|
'thousands_separator' => '',
|
|
'timezone' => '',
|
|
'timezone_error' => '',
|
|
'top' => '',
|
|
'use_destination_based_tax' => '',
|
|
'user_timezone' => '',
|
|
'website' => '',
|
|
'wholesale_markup' => '',
|
|
'work_order_enable' => '',
|
|
'work_order_format' => '',
|
|
];
|