Added repo address.
[fa-stable.git] / config.default.php
1 <?php
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     //--------------------------------------------------
13
14         // User configurable variables
15         //---------------------------------------------------
16
17         /*Show debug messages returned from an error on the page.
18         Debugging info level also determined by settings in PHP.ini
19         if $debug=1 show debugging info, dont show if $debug=0 */
20
21 if (!isset($path_to_root) || isset($_GET['path_to_root']) || isset($_POST['path_to_root']))
22         die("Restricted access");
23         // Log file for error/warning messages. Should be set to any location
24         // writable by www server. When set to empty string logging is switched off. 
25         // Special value 'syslog' can be used for system logger usage (see php manual).
26         //$error_logfile = '';
27         $error_logfile = dirname(__FILE__).'/tmp/errors.log';
28         $debug                  = 1;    // show sql on database errors
29
30         $show_sql               = 0;    // show all sql queries in page footer for debugging purposes
31         $go_debug               = 0;    // set to 1 for basic debugging, or 2 to see also backtrace after failure.
32         $pdf_debug              = 0;    // display pdf source instead reports for debugging when $go_debug!=0
33         // set $sql_trail to 1 only if you want to perform bugtracking sql trail
34         // Warning: this produces huge amount of data in sql_trail table.
35         // Don't forget switch the option off and flush the table manually after 
36         // trail, or your future backup files are overloaded with unneeded data.
37         //
38         $sql_trail              = 0; // save all sql queries in sql_trail
39         $select_trail   = 0; // track also SELECT queries
40         if ($go_debug > 0)
41         {
42                 error_reporting(E_ALL);
43                 ini_set("display_errors", "On");
44         }
45         else
46         {
47                 error_reporting(E_USER_WARNING|E_USER_ERROR|E_USER_NOTICE);
48                 // ini_alter("error_reporting","E_COMPILE_ERROR|E_ERROR|E_CORE_ERROR|E_PARSE");
49                 ini_set("display_errors", "On");
50         }
51
52         if($error_logfile != '') {
53                 ini_set("error_log", $error_logfile);
54                 ini_set("ignore_repeated_errors", "On");
55                 ini_set("log_errors", "On");
56         }               
57         // Main Title
58         $app_title = "FrontAccounting";
59         // application version
60         $version                = "2.3 Beta";
61          // src-data compatibility check. Do not change.
62         $core_version = "2.3";
63
64         // Extension packages repository
65         $FA_repo_version = '2.3';
66
67         $repo_auth = array(
68                  'login' => 'anonymous',
69                  'pass' => 'password',
70         );
71         
72         $repository = 'http://'.$repo_auth['login'].':'.$repo_auth['pass'].'@'.'repo.frontaccounting.eu'
73                 .'/index.php?path=';
74                 
75         // Build for development purposes
76         $build_version  = date("d.m.Y", filemtime("$path_to_root/CHANGELOG.txt"));
77
78         // Powered by
79         $power_by               = "FrontAccounting";
80         $power_url              = "http://frontaccounting.com";
81
82         /* use popup windows for views */
83         $use_popup_windows = 1;
84
85         /* use date picker for all date fields */
86         $use_date_picker = 1;
87
88         /* use Audit Trails in GL */
89         $use_audit_trail = 0;
90
91         /* use old style convert (income and expense in BS, PL) */
92         $use_oldstyle_convert = 0;
93
94         /* show users online discretely in the footer */
95         $show_users_online = 0;
96
97         /* default print destination. 0 = PDF/Printer, 1 = Excel */
98         $def_print_destination = 0;
99
100         // Wiki context help configuration
101         // If your help wiki use translated page titles uncomment next line
102         // $old_style_help = 1; // this setting is depreciated and subject to removal in next FA versions
103         //      locally installed wiki module
104         // $help_base_url = $path_to_root.'/modules/wiki/index.php?n='._('Help').'.';
105         //      context help feed from frontaccounting.com
106         // $help_base_url = 'http://frontaccounting.com/fawiki/index.php?n=Help.';
107         //      not used
108         $help_base_url = null;
109
110         /* per user data/cache directory */
111         $comp_path = $path_to_root.'/company';
112
113         /* allow alpha characters in accounts. 0 = numeric, 1 = alpha numeric, 2 = uppercase alpha numeric */
114         $accounts_alpha = 0;
115
116         /* Date systems. 0 = traditional, 1 = Jalali used by Iran, nabour countries, Afghanistan and some other Central Asian nations,
117         2 = Islamic used by other arabic nations. 3 = traditional, but where non-workday is Friday and start of week is Saturday */
118         $date_system = 0;
119
120         /* email stock location if order below reorder-level */
121         $loc_notification = 0;
122
123         /* print_invoice_no. 0 = print reference number, 1 = print invoice number */
124         $print_invoice_no = 0;
125
126         /* 1 = print Subtotal tax excluded, tax and Total tax included */
127         $alternative_tax_include_on_docs = 0;
128
129         /* suppress tax rates on documents. 0 = no, 1 = yes. */
130         $suppress_tax_rates = 0;
131         
132         $dateformats    = array("MMDDYYYY", "DDMMYYYY", "YYYYMMDD");
133         $dateseps               = array("/", ".", "-", " ");
134         $thoseps                = array(",", ".", " ");
135         $decseps                = array(".", ",");
136         // defalt dateformats and dateseps indexes used before user login
137         $dflt_date_fmt = 0;
138         $dflt_date_sep = 0;
139
140         $pagesizes              = array("Letter", "A4"); // default PDF pagesize
141
142         /* Accounts Payable */
143         /* System check to see if quantity charged on purchase invoices exceeds the quantity received.
144         If this parameter is checked the proportion by which the purchase invoice is an overcharge
145         referred to before reporting an error */
146
147         $check_qty_charged_vs_del_qty = true;
148
149         /* System check to see if price charged on purchase invoices exceeds the purchase order price.
150         If this parameter is checked the proportion by which the purchase invoice is an overcharge
151         referred to before reporting an error */
152
153         $check_price_charged_vs_order_price = True;
154
155         $config_allocation_settled_allowance = 0.005;
156
157         // Internal configurable variables
158         //-----------------------------------------------------------------------------------
159
160         /* Whether to display the demo login and password or not */
161
162         $allow_demo_mode = false;
163
164         /* for uploaded item pictures */
165         $pic_width              = 80;
166         $pic_height     = 50;
167         $max_image_size = 500;
168
169         /* skin for Business Graphics, 1, 2 or 3 */
170         $graph_skin     = 1;
171
172 /*      
173         Before upgrade from pre-2.2 FA you have to move here your customized
174         security roles definitions. If you have used standard roles, you
175         can simply uncomment following two arrays. After upgrade both arrays need 
176         to be deleted or commented out. You may wish to change user roles to
177         new better defined in Users Setup. Old not used roles can be set inactive 
178         or deleted.
179 */
180 /* Standard FA2.1 Security Group definitions
181
182         $security_headings = array(
183                         _("Inquiries"),
184                         _("Accountant"),
185                         _("System Administrator"),
186         );
187
188         $security_groups = array(
189                         array(1,2),
190                         array(1,2,3,4,5,6,7,8,9,10,11,12,13,14,16),
191                         array(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,20),
192         );
193 */
194
195         //MySQL Backup and Restore Settings
196
197 if(isset($_SESSION["wa_current_user"])) {
198         define("BACKUP_PATH", $comp_path.'/'.user_company()."/backup/");
199 }
200         // static js files path
201         $js_path = $path_to_root.'/js/';
202         // standard external js scripts included in all files
203         $js_static = array('JsHttpRequest.js', 'behaviour.js', 'utils.js', 'inserts.js');
204         // additional js source included in header
205         $js_lib = $js_userlib = array();
206
207 if (!defined('ICON_EDIT'))
208 {
209         define("ICON_EDIT", "edit.gif");        
210         define("ICON_DELETE", "delete.gif");    
211         define("ICON_ADD", "ok.gif");   
212         define("ICON_UPDATE", "ok.gif");        
213         define("ICON_OK", "ok.gif");    
214         define("ICON_CANCEL", "cancel.png");    
215         define("ICON_GL", "gl.png");    
216         define("ICON_PRINT", "print.png");      
217         define("ICON_PDF", "pdf.gif");  
218         define("ICON_DOC", "invoice.gif");      
219         define("ICON_CREDIT", "credit.gif");    
220         define("ICON_RECEIVE", "receive.gif");  
221         define("ICON_DOWN", "download.gif");    
222         define("ICON_MONEY", "money.png");      
223         define("ICON_REMOVE", "remove.png");    
224         define("ICON_REPORT", "report.png");    
225         define("ICON_VIEW", "view.gif");        
226         define("ICON_SUBMIT", "ok.gif");
227         define("ICON_ESCAPE", "escape.png");    
228 }
229
230 ?>