Commit Graph

87 Commits

Author SHA1 Message Date
objecttothis
5500d3989f Filtering
- Added filtering to decimals which may have different comma separator
- Added formatting of decimals before concatenating into string
- Cast int to string in form_hidden() call

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
73cec25468 Clean up code
- Removed unneeded use statements

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
8197e1918a - Refactor file name to match class name.
- Updated autoload in composer.json to reflect actual structure.
- Removed unneeded use statements

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
e8c6d7e01d - Updated .gitattributes to automatically convert line endings on commit to LF.
- Changed Line endings.
- Prepared Decimals before filtering them for number_float.
- Refactored variable names
- Reworked code for clarity
- Added empty check to POST var.
- Removed unneeded code.
- Removed old TODO.
- changed POST variable check to !empty

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
730d01fb74 CI 4.5.1 fixes
Changed .editorconfig
- Force lf line endings for compatibility with all systems.

Fixed Login
- Removed strtolower() call because getMethod() now returns all uppercase

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
4c689ec6fd Bump CodeIgniter to 4.5.1
- CodeIgniter 4.5.1
- PSR/Log 3.0.0
- PHP >= 8.1
- Replaced mandatory files.
- Modified breaking change code.
- Modified updated code.
- Added missing files.

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
68d3482065 Attribute item form and decimal fixes
- Updated formatting to reflect standard
- Wrapped Decimal type in to_decimals() function for localization
- Fixed function name
- Removed unneeded TODO
- Fixed problems with sales register not receiving decimals with comma for separator properly.

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
34476ce374 Bump CI4 to 4.4.8
- Merged changed files since 4.4.8
- Fixed Breaking changes

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00
objecttothis
21c84efd2d Formatting
- Added missing ; to "nbsp"
- Remove filtering from checkbox items in controller
- Added null check to checkboxes in controller
- Fixed function naming to avoid 404
- Removed escaping from fixed urls
- Removed esc() wrapping around site_url() which already returns escaped urls.
2024-06-15 17:19:15 +02:00
objecttothis
e71c035671 Formatting
- Made view CI form helper function call format uniform.
- replaced calls to array() with []
- Placed { on its own line
- Removed empty lines where there shouldn't be any.
- Replaced text/javascript with application/javascript as the former is deprecated
2024-06-15 17:19:15 +02:00
odiea
27a4ccdff6 Update Persons.php (#3962)
Back to the original
2024-06-15 17:19:15 +02:00
odiea
ab88f1eec1 Update Persons.php (#3961)
added use Tamtamchik\NameCase\Formatter;
2024-06-15 17:19:15 +02:00
odiea
0f33c399a9 Changed < 0 to == NEW_ENTRY (#3960)
* Update Cashup.php

If(!count_only) was causing the table view to not show properly.

* Update Cashups.php

empty it must not be.

* Update Cashups.php

* Update Expenses.php

* Update Persons.php
2024-06-15 17:19:15 +02:00
odiea
9f78a8a075 Changes to Cash_up and Cash_ups for better date feature and Table view to show data (#3958)
* Update Cashup.php

If(!count_only) was causing the table view to not show properly.

* Update Cashups.php

empty it must not be.
2024-06-15 17:19:15 +02:00
objecttothis
a6b674e995 Barcode & escaping
- Removed overflow-visible as it is not needed.
- Bumped TamTamChik/nameCase to latest.
- Workaround to prevent nameCase from capitalizing the first letter of html entities
- Autoload security_helper.php
- Develop means of escaping outputs without encoding characters we don't want encoded.
- proof of concept in form_basic_info.php
2024-06-15 17:19:15 +02:00
odiea
a2df771f19 Update Customers.php
To keep coding the same
2024-06-15 17:19:15 +02:00
odiea
9926577b2f Update Suppliers.php
this allows correct sorting
2024-06-15 17:19:15 +02:00
objecttothis
e327bb3780 Suppliers Fixes
- Added html_entity_decode() to outputs which had been html encoded
- Added escaping of direct data from the database.
2024-06-15 17:19:15 +02:00
odiea
3555de87f6 Item Kits updates for form and Barcodes to show (#3949)
* Update Item_kits.php

* Update Item_kits.php Barcode Issue

public function Generate Barcodes
changed Code to just c and it started working
2024-06-15 17:19:15 +02:00
objecttothis
7356500d86 - Fixed missing call to helper and helper function
- Format percentage per locale rules
- Moved constants to Constants.php
- Added PHPdoc comments
- Refactor code for clarity and simplicity.
- Added decimal formatting per locale for display.
- autoload locale helper
- Remove unneeded calls to helpers
- Removed unneeded comments
- fixed errors causing checks in parse_decimals to return false due to locales which use a comma.
2024-06-15 17:19:15 +02:00
objecttothis
a5b5fccd5e Barcode Changes
- Strip out old code
- Added missing variable declaration
2024-06-15 17:19:15 +02:00
objecttothis
24fd80e4fd Barcode Changes
- Removed mixed type-hint
- Replacing emberlabs code with picquer/php-barcode-generator
2024-06-15 17:19:15 +02:00
objecttothis
bf167a06b6 Removed log_message() call for debugging 2024-06-15 17:19:15 +02:00
objecttothis
5b725d04d5 Company logo upload
- Added conversion to migration file for delimiter in image_allowed_types
- Corrected business logic for image upload in items form.
- Removed log message used for debugging.
- Replaced '|' with ',' in image_allowed_types save/populate.
2024-06-15 17:19:15 +02:00
objecttothis
5c0325511c Company logo upload
- Corrected errors uploading file
- Renamed remove_logo for proper routing
- Corrected name
- Assigned file extension based on guessFileExtension() for security
- Don't call file upload if no file was specified
- added missing jpeg mime type
- fixed company logo change
2024-06-15 17:19:15 +02:00
jekkos
cefd200b29 Add suggestion for receiving validation (#3878) 2024-06-15 17:19:15 +02:00
objecttothis
34bc4540bf Added Error log
- Logs message when error encountered during Customers CSV Import
2024-06-15 17:19:15 +02:00
Doug Hutcheson
9315d56408 ci4-bugfix to stock locations and item csv import
Stock locations are now being handled correctly in the Configuration stock page, due to a fix to Models/Stock_locations.php  and imports to stock locations from csv are now working due to a correction to Controllers/Items.php
2024-06-15 17:19:15 +02:00
Doug Hutcheson
b36ef3a603 ci4-bugfix to items customers and attributes
Attributes: Noticed log_message() being called with uppercase letters in the level which causes errors in the system; Customers: improved the layout of the stats page in the information dialog issue 3892; Items: got csv import working issue 3896 and bulk edits working - barcode generation does not work yet.
2024-06-15 17:19:15 +02:00
Doug Hutcheson
c01b514596 ci4-bugfix further corrections for lang calls
These files have been patched to correct anomalies in the calls to lang().
2024-06-15 17:19:15 +02:00
Doug Hutcheson
9723e82b61 CI4 bug fixes on behalf of DEV-byoos 3776
Changes to Controllers/Receivings.php and Controllers/Sales.php identified by @DEV-byoos, plus a change to Controllers/Customers.php to deal with the new way PHP 8.2 handles missing array keys.
2024-06-15 17:19:15 +02:00
objecttothis
60a5bfdc9a Corrected Function names for routes
- generate_barcode function name changes in Controllers
- generate_barcode function name calls in views
- Added PHPdocs
2024-06-15 17:19:15 +02:00
objecttothis
b5f93b6325 Fixed Customer CSV import
- Corrected function name for CI4
- Removed trailing whitespace
2024-06-15 17:19:15 +02:00
objecttothis
2efda51309 Fixes
- Removed unneeded use statements
- Corrected function name for routes
- Moved import_customers.csv to writable folder to prevent unauthorized access
- Added return to function to force download
2024-06-15 17:19:15 +02:00
objecttothis
ae44e38855 Dependencies
- Updated bootstrap-table
- Updated jquery
- Refactored local variable name
- fixed problem with null being sent on no filters
- fixed incorrect reference in view of variables
2024-06-15 17:19:15 +02:00
objecttothis
d18d2cf814 PHPdocs
- Removed unnecessary ReflectionException in PHPdoc
- Corrected return details of insert function
- Replaced deprecated class
- Removed Inventory model's insert function because it wasn't providing functionality that the Model class wasn't.
- Corrected the calling method signature for Inventory->insert()
2024-06-15 17:19:15 +02:00
objecttothis
cc58cecff0 Compatibility changes
- Removed `mixed` function return type from some functions for backward compatibility with php 7.4
- Refactored string concatination for readability.
- Added TODO for later
- Corrected PHPdocs
- Removed unneeded TODO
- Refactored function names with mixed snake and pascal case names
2024-06-15 17:19:15 +02:00
objecttothis
ba9bcd7786 PHPdocs
- Added missing PHPdocs
- Corrected Syntax
- Added noinspection parameters to PHPdoc for AJAX called functions
- Added missing function return types
- Added missing parameter types
- Added public keyword to functions without visibility modifier
- Corrected incorrectly formatted PHPdocs
- Added public to constants and functions missing a visibility keyword
2024-06-15 17:19:15 +02:00
objecttothis
88007f56be Fixed enforce_privacy checkbox 2024-06-15 17:19:15 +02:00
objecttothis
4a23adbb2f Corrected Function call
- setAttribute() expects the second parameter to be an int or float. setTextAttribute() resolves this.
- Added TODO
2024-06-15 17:19:15 +02:00
objecttothis
2245aacf81 Refactoring
- Minor formatting fix
- Refactored function name for clarity
- Corrected name of route
2024-06-15 17:19:15 +02:00
objecttothis
2a3317a270 Removed htmlspecialchars() calls 2024-06-15 17:19:15 +02:00
objecttothis
01512b0835 Fixed incorrectly named function for route. 2024-06-15 17:19:15 +02:00
objecttothis
3e3da57543 Fixed multiselect form issues
- Missing `[]` in name of multiselect form.
2024-06-15 17:19:15 +02:00
odiea
d5c767aeb9 Update Config.php (#3884) 2024-06-15 17:19:15 +02:00
objecttothis
7b224be665 PSR compliance and formatting changes
- Replaced TRUE/FALSE constants with true/false keywords
- Replaced NULL constant with null keyword
- Replaced `<?php echo` in views with shortened `<?=`
- Added missing variable declaration
- Added missing function return type in declaration
- replaced `== true`, `== false`, `=== true` and `=== false` in if statements with simplified forms
2024-06-15 17:19:15 +02:00
objecttothis
588f96a945 Added missing return type to function 2024-06-15 17:19:15 +02:00
objecttothis
0754f2f6e6 Fix Request variable retrieval
- getSearch functions to properly retrieve HTTP vars.
- getVar() function calls replaced with getGet() or getPost()
- replaced TRUE/FALSE constants with true/false keywords
2024-06-15 17:19:15 +02:00
objecttothis
48c04417b8 Fixes
- PHP 8.2 deprecates dynamically declared class properties. Adding these declarations removes deprecation warnings and makes the code PHP 8.3 compatible.
- Add Elvis operator to set search string to an empty string when it's value is null to get rid of an error in the search function call.
- Imported class for OSPOS config
- Replaced private with protected in parent controller's property.
- Removed unneeded TODO
- Refactored local variables
- Replaced ternary notation
- Removed unneeded comments
- Removed unneeded class property
- Removed unneeded @property declarations
- Fixed database version
2024-06-15 17:19:15 +02:00
objecttothis
0a527abfa0 Corrected Problems
- Corrected type of config property.
- Added property declarations.
2024-06-15 17:19:15 +02:00