2 /**********************************************************************
3 Copyright (C) FrontAccounting, LLC.
4 Released under the terms of the GNU General Public License, GPL,
5 as published by the Free Software Foundation, either version 3
6 of the License, or (at your option) any later version.
7 This program is distributed in the hope that it will be useful,
8 but WITHOUT ANY WARRANTY; without even the implied warranty of
9 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10 See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
11 ***********************************************************************/
12 include_once($path_to_root . "/admin/db/company_db.inc");
17 var $db_ok; // check whether database has been upgraded after src update.
21 // $this->prefs = get_company_prefs();
25 function allow_negative_stock()
27 return $this->prefs['allow_negative_stock'];
30 /* Sherifoz 26.06.03 Proportion by which items can be received over the quantity that is specified in a purchase
32 The figure entered is interpreted as a percentage ie 10 means 0.1 or 10% not 10 times
34 function over_receive_allowance()
36 return $this->prefs['po_over_receive'];
39 /* Proportion by which a purchase invoice line is an overcharge for a purchase order item received
40 is an overcharge. If the overcharge is more than this percentage then an error is reported and
41 purchase invoice line cannot be entered
42 The figure entered is interpreted as a percentage ie 20 means 0.2 or 20% not 20 times
44 function over_charge_allowance()
46 return $this->prefs['po_over_charge'];
49 function default_credit_limit()
51 return $this->prefs['default_credit_limit'];
54 function default_wo_required_by()
56 return $this->prefs['default_workorder_required'];
59 function default_delivery_required_by()
61 return $this->prefs['default_delivery_required'];
64 function default_receival_required_by()
66 return $this->prefs['default_receival_required'];
69 function default_dimension_required_by()
71 return $this->prefs['default_dim_required'];
74 function auto_currency_revaluation()
76 return $this->prefs['auto_curr_reval'];
79 function allocation_settled_allowance()
81 global $config_allocation_settled_allowance;
82 return $config_allocation_settled_allowance;