PHP 8.2 Compatibility Improvement, better implementation.
authorJoe <joe.hunt.consulting@gmail.com>
Mon, 7 Aug 2023 19:17:15 +0000 (21:17 +0200)
committerJoe <joe.hunt.consulting@gmail.com>
Mon, 7 Aug 2023 19:17:15 +0000 (21:17 +0200)
includes/hooks.inc
includes/prefs/userprefs.inc
includes/ui/allocation_cart.inc
reporting/includes/class.graphic.inc
sales/includes/cart_class.inc

index 63e1684ce853f990eef9ca71866da04d5ee384d1..1fbcd0e79b2d317da7439e1659bd8e6cbbebd737 100644 (file)
@@ -18,9 +18,9 @@
 //
 // To find how various hooks are processed look into respective hook_* functions below.
 //
-class hooks extends \stdClass {
+class hooks {
        var $module_name; // extension module name.
-
+       var $path = null;
        // 
        // Helper for updating databases with extension scheme
        //
index 24cd15c5cca9dbdc353025230122916ae284a341..1939d6f44d935431f32bbdda4b392f017a9c6469 100644 (file)
@@ -10,7 +10,7 @@
     See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
 ***********************************************************************/
 
-class user_prefs extends \stdClass
+class user_prefs
 {
 
        var $language;
@@ -37,7 +37,7 @@ class user_prefs extends \stdClass
        var $sticky_date;       // save date on subsequent document entry
        var $startup_tab;  // default start-up menu tab
        var $transaction_days; // transaction days in inquiries
-       var $save_report_selection; // save report selections days 0...
+       var $save_report_selections; // save report selections days 0...
        var $use_date_picker; // use date picker for all date fields
        var $def_print_destination; // default print destination. 0 = PDF/Printer, 1 = Excel
        var $def_print_orientation; // default print orientation. 0 = Portrait. 1 = Landscape
index 34f1784c85155111a31037ad2ca3229dda3176e4..fe232f069af586b4255127c7b23ca3432779ff31 100644 (file)
@@ -15,7 +15,7 @@
 */
 //-----------------------------------------------------------------------------------
 
-class allocation extends \stdClass
+class allocation
 {
 
        var $trans_no; 
@@ -26,6 +26,7 @@ class allocation extends \stdClass
        var $person_curr;
        var $date_;
        var $amount = 0; /*Total amount of the transaction in FX */
+       var $bank_amount = 0;
        var $currency;
 
        var $allocs; /*array of transactions allocated to */
index 2e37b24df241db5c3eb2b117b20a1e6f4c6ae29f..8cfc2ed3ad681ae8ecd20e4dc1af1718b48bb551 100644 (file)
@@ -60,7 +60,7 @@ file for later presentation.
        Joe Hunt
 */
 define('MAXLEN', 27); // we cut after 25 chars + ...
-class Chart extends \stdClass
+class Chart
 {
        var $id;
        var $labels = array();
@@ -102,6 +102,23 @@ class Chart extends \stdClass
        var $lang;
        var $font;
        var $path;
+       var $bar_width = 0;
+       var $space_between_dots = 0;
+       var $higher_value = 0;
+       var $higher_value_str = null;
+       var $graphic_area_width = 0;
+       var $graphic_area_height = 0;
+       var $graphic_area_x1 = 0;
+       var $graphic_area_x2 = 0;
+       var $graphic_area_y1 = 0;
+       var $graphic_area_y2 = 0;
+       var $legend_exists = false;
+       var $legend_box_width = 0;
+       var $legend_box_x1 = 0;
+       var $legend_box_x2 = 0;
+       var $legend_box_y1 = 0;
+       var $legend_box_y2 = 0;
+
 
        function __construct($type = 1, $id = 'id', $width = 0, $height = 0)
        {
index 11b2029dc5a296b64cb0de748d27d345d58feeb7..4bef4cd102432d1a02329941bd0b00c8ffa4805a 100644 (file)
@@ -21,7 +21,7 @@ iv)  a delivery note
 include_once($path_to_root . "/inventory/includes/inventory_db.inc");
 include_once($path_to_root . "/taxes/tax_calc.inc");
 
-class Cart extends \stdClass
+class Cart 
 {
        var $trans_type; // invoice, order, quotation, delivery note ...
        var $trans_no = array();// array (num1=>ver1,..) or 0 for new
@@ -82,6 +82,7 @@ class Cart extends \stdClass
        var $ex_rate;
 
        var $fixed_asset = false;
+       var $bo_policy = null;
 
        //-------------------------------------------------------------------------
        //