Solution for item editable description
[fa-stable.git] / includes / ui / ui_globals.inc
index a22c688647d677fb4285a15b267a7ffc804c9e84..15601c9f6915d1113490dacfccdd6d89d0bc2c04 100644 (file)
@@ -1,6 +1,15 @@
 <?php
-
-include_once($path_to_root . "/includes/reserved.inc");
+/**********************************************************************
+    Copyright (C) FrontAccounting, LLC.
+       Released under the terms of the GNU General Public License, GPL, 
+       as published by the Free Software Foundation, either version 3 
+       of the License, or (at your option) any later version.
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
+    See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
+***********************************************************************/
+//include_once($path_to_root . "/includes/reserved.inc");
 
 function set_global_supplier($supplier_id) 
 {
@@ -10,7 +19,7 @@ function set_global_supplier($supplier_id)
 function get_global_supplier($return_all=true) 
 {
        if (!isset($_SESSION['wa_global_supplier_id']) || 
-               ($return_all == false && $_SESSION['wa_global_supplier_id'] == reserved_words::get_all()))
+               ($return_all == false && $_SESSION['wa_global_supplier_id'] == ALL_TEXT))
                return "";      
        return $_SESSION['wa_global_supplier_id'];
 }
@@ -23,7 +32,7 @@ function set_global_stock_item($stock_id)
 function get_global_stock_item($return_all=true) 
 {
        if (!isset($_SESSION['wa_global_stock_id']) || 
-               ($return_all == false && $_SESSION['wa_global_stock_id'] == reserved_words::get_all()))
+               ($return_all == false && $_SESSION['wa_global_stock_id'] == ALL_TEXT))
                return "";              
        return $_SESSION['wa_global_stock_id'];
 }
@@ -36,7 +45,7 @@ function set_global_customer($customer_id)
 function get_global_customer($return_all=true) 
 {
        if (!isset($_SESSION['wa_global_customer_id']) || 
-               ($return_all == false && $_SESSION['wa_global_customer_id'] == reserved_words::get_all()))
+               ($return_all == false && $_SESSION['wa_global_customer_id'] == ALL_TEXT))
                return "";
        return $_SESSION['wa_global_customer_id'];
 }
@@ -57,4 +66,3 @@ function get_global_curr_code()
 
 //--------------------------------------------------------------------------------------
 
-?>
\ No newline at end of file