mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-09-13 13:57:34 -04:00
bugfix(items, validation): reject unsafe tax names and fix payments temp table collision - Add unicode_alpha_numeric_punct rule (OSPOSRules) to allow accented/CJK chars in text fields while blocking HTML-unsafe chars (<, >) as defense-in-depth against injection - Items controller: extract validateItemFields/validateBulkUpdateFields, validate tax_names on save and bulk update using new rule; add shared validateFields helper in Secure_Controller to DRY up validation + JSON error response - Escape tax_group output in sales/quote.php and receipt_email.php views to harden output encoding at render time - Rename sales_payments_temp -> sales_report_payments_temp (Summary_report) and -> sales_search_payments_temp (Sale model) to avoid name collision between concurrently-created temp tables - AGENTS.md: document alignment rule for => columns when inserting new language keys Tests: - Add ItemsControllerTest covering postSave/bulkupdate tax_names validation - Reject <, > in tax_names on /items/save and /items/bulkupdate - Verify unicode and apostrophe-containing tax names are accepted - Cover CSV import helpers: header generation (basic, multiple locations, attributes), stock-location/attribute header builders, get_csv_file parsing (plain, BOM-prefixed, multi-row) - Validate required-header detection for import templates - Remove outdated tax name test from SalesControllerTest - Simplify Database class references in SalesControllerTest i18n: - Add tax_name_invalid translation to Items.php for 20+ locales, inserted alphabetically after tax_category in each file - Normalize quote style in ar-EG/Items.php to single quotes - Add ka/Items.php Georgian locale scaffold Signed-off-by: objecttothis <17935339+objecttothis@users.noreply.github.com>
125 lines
6.0 KiB
PHP
125 lines
6.0 KiB
PHP
<?php
|
|
|
|
return [
|
|
'add_minus' => '',
|
|
'allow_alt_description' => '',
|
|
'amount_entry' => '',
|
|
'bulk_edit' => '',
|
|
'buy_price_required' => '',
|
|
'cannot_be_deleted' => '',
|
|
'cannot_find_item' => '',
|
|
'categories' => '',
|
|
'category' => '',
|
|
'category_new' => '',
|
|
'category_required' => '',
|
|
'change_all_to_allow_alt_desc' => '',
|
|
'change_all_to_not_allow_allow_desc' => '',
|
|
'change_all_to_serialized' => '',
|
|
'change_all_to_unserialized' => '',
|
|
'change_image' => '',
|
|
'confirm_bulk_edit' => '',
|
|
'confirm_bulk_edit_wipe_taxes' => '',
|
|
'confirm_delete' => '',
|
|
'confirm_restore' => '',
|
|
'cost_price' => '',
|
|
'cost_price_number' => '',
|
|
'cost_price_required' => '',
|
|
'count' => '',
|
|
'csv_import_failed' => '',
|
|
'csv_import_invalid_location' => '',
|
|
'csv_import_nodata_wrongformat' => '',
|
|
'csv_import_partially_failed' => '',
|
|
'csv_import_success' => '',
|
|
'current_quantity' => '',
|
|
'default_pack_name' => '',
|
|
'description' => '',
|
|
'details_count' => '',
|
|
'do_nothing' => '',
|
|
'edit' => '',
|
|
'edit_fields_you_want_to_update' => '',
|
|
'edit_multiple_items' => '',
|
|
'empty_upc_items' => '',
|
|
'error_adding_updating' => '',
|
|
'error_updating_multiple' => '',
|
|
'generate_barcodes' => '',
|
|
'hsn_code' => '',
|
|
'image' => '',
|
|
'import_items_csv' => '',
|
|
'info_provided_by' => '',
|
|
'inventory' => '',
|
|
'inventory_CSV_import_quantity' => '',
|
|
'inventory_comments' => '',
|
|
'inventory_data_tracking' => '',
|
|
'inventory_date' => '',
|
|
'inventory_employee' => '',
|
|
'inventory_in_out_quantity' => '',
|
|
'inventory_remarks' => '',
|
|
'is_deleted' => '',
|
|
'is_printed' => '',
|
|
'is_serialized' => '',
|
|
'item' => '',
|
|
'item_id' => '',
|
|
'item_number' => '',
|
|
'item_number_duplicate' => '',
|
|
'item_number_invalid' => 'ഇനം നമ്പറിൽ അനുവദനീയമല്ലാത്ത അക്ഷരങ്ങൾ അടങ്ങിയിരിക്കുന്നു.',
|
|
'kit' => '',
|
|
'location' => '',
|
|
'low_inventory_items' => '',
|
|
'low_sell_item' => '',
|
|
'manually_editing_of_quantity' => '',
|
|
'markup' => '',
|
|
'name' => '',
|
|
'name_required' => '',
|
|
'new' => '',
|
|
'no_description_items' => '',
|
|
'no_items_to_display' => '',
|
|
'none' => '',
|
|
'none_selected' => '',
|
|
'nonstock' => '',
|
|
'number_information' => '',
|
|
'number_required' => '',
|
|
'one_or_multiple' => '',
|
|
'pack_name' => '',
|
|
'qty_per_pack' => '',
|
|
'quantity' => '',
|
|
'quantity_number' => '',
|
|
'quantity_required' => '',
|
|
'receiving_quantity' => '',
|
|
'remove_image' => '',
|
|
'reorder_level' => '',
|
|
'reorder_level_number' => '',
|
|
'reorder_level_required' => '',
|
|
'retrive_item_info' => '',
|
|
'sales_tax_1' => '',
|
|
'sales_tax_2' => '',
|
|
'search_attributes' => '',
|
|
'select_image' => '',
|
|
'serialized_items' => '',
|
|
'standard' => '',
|
|
'stock' => '',
|
|
'stock_location' => '',
|
|
'stock_type' => '',
|
|
'successful_adding' => '',
|
|
'successful_bulk_edit' => '',
|
|
'successful_deleted' => '',
|
|
'successful_updating' => '',
|
|
'supplier' => '',
|
|
'tax_1' => '',
|
|
'tax_2' => '',
|
|
'tax_3' => '',
|
|
'tax_category' => '',
|
|
'tax_name_invalid' => 'നികുതി പേരിൽ അനുവദനീയമല്ലാത്ത അക്ഷരങ്ങൾ അടങ്ങിയിരിക്കുന്നു.',
|
|
'tax_percent' => '',
|
|
'tax_percent_number' => '',
|
|
'tax_percent_required' => '',
|
|
'tax_percents' => '',
|
|
'temp' => '',
|
|
'type' => '',
|
|
'unit_price' => '',
|
|
'unit_price_number' => '',
|
|
'unit_price_required' => '',
|
|
'upc_database' => '',
|
|
'update' => '',
|
|
'use_inventory_menu' => '',
|
|
];
|