Enabling popup search in Customers, branches, suppliers, inventory, fixed assets...
[fa-stable.git] / reporting / reports_main.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 $path_to_root="..";
13 $page_security = 'SA_OPEN';
14 include_once($path_to_root . "/includes/session.inc");
15
16 include_once($path_to_root . "/includes/date_functions.inc");
17 include_once($path_to_root . "/includes/data_checks.inc");
18 include_once($path_to_root . "/includes/ui.inc");
19 include_once($path_to_root . "/reporting/includes/reports_classes.inc");
20 $js = "";
21 if ($SysPrefs->use_popup_windows && $SysPrefs->use_popup_search)
22         $js .= get_js_open_window(900, 500);
23 if (user_use_date_picker())
24         $js .= get_js_date_picker();
25
26 add_js_file('reports.js');
27
28 page(_($help_context = "Reports and Analysis"), false, false, "", $js);
29
30 $reports = new BoxReports;
31
32 $dim = get_company_pref('use_dimension');
33
34 $reports->addReportClass(_('Customer'), RC_CUSTOMER);
35 $reports->addReport(RC_CUSTOMER, 101, _('Customer &Balances'),
36         array(  _('Start Date') => 'DATEBEGIN',
37                         _('End Date') => 'DATEENDM',
38                         _('Customer') => 'CUSTOMERS_NO_FILTER',
39                         _('Show Balance') => 'YES_NO',
40                         _('Currency Filter') => 'CURRENCY',
41                         _('Suppress Zeros') => 'YES_NO',
42                         _('Comments') => 'TEXTBOX',
43                         _('Orientation') => 'ORIENTATION',
44                         _('Destination') => 'DESTINATION'));
45 $reports->addReport(RC_CUSTOMER, 102, _('&Aged Customer Analysis'),
46         array(  _('End Date') => 'DATE',
47                         _('Customer') => 'CUSTOMERS_NO_FILTER',
48                         _('Currency Filter') => 'CURRENCY',
49                         _('Show Also Allocated') => 'YES_NO',
50                         _('Summary Only') => 'YES_NO',
51                         _('Suppress Zeros') => 'YES_NO',
52                         _('Graphics') => 'GRAPHIC',
53                         _('Comments') => 'TEXTBOX',
54                         _('Orientation') => 'ORIENTATION',
55                         _('Destination') => 'DESTINATION'));
56 $reports->addReport(RC_CUSTOMER, 103, _('Customer &Detail Listing'),
57         array(  _('Activity Since') => 'DATEBEGIN',
58                         _('Sales Areas') => 'AREAS',
59                         _('Sales Folk') => 'SALESMEN',
60                         _('Activity Greater Than') => 'TEXT',
61                         _('Activity Less Than') => 'TEXT',
62                         _('Comments') => 'TEXTBOX',
63                         _('Orientation') => 'ORIENTATION',
64                         _('Destination') => 'DESTINATION'));
65 $reports->addReport(RC_CUSTOMER, 114, _('Sales &Summary Report'),
66         array(  _('Start Date') => 'DATEBEGINTAX',
67                         _('End Date') => 'DATEENDTAX',
68                         _('Tax Id Only') => 'YES_NO',
69                         _('Comments') => 'TEXTBOX',
70                         _('Orientation') => 'ORIENTATION',
71                         _('Destination') => 'DESTINATION'));
72 $reports->addReport(RC_CUSTOMER, 104, _('&Price Listing'),
73         array(  _('Currency Filter') => 'CURRENCY',
74                         _('Inventory Category') => 'CATEGORIES',
75                         _('Sales Types') => 'SALESTYPES',
76                         _('Show Pictures') => 'YES_NO',
77                         _('Show GP %') => 'YES_NO',
78                         _('Comments') => 'TEXTBOX',
79                         _('Orientation') => 'ORIENTATION',
80                         _('Destination') => 'DESTINATION'));
81 $reports->addReport(RC_CUSTOMER, 105, _('&Order Status Listing'),
82         array(  _('Start Date') => 'DATEBEGINM',
83                         _('End Date') => 'DATEENDM',
84                         _('Inventory Category') => 'CATEGORIES',
85                         _('Stock Location') => 'LOCATIONS',
86                         _('Back Orders Only') => 'YES_NO',
87                         _('Comments') => 'TEXTBOX',
88                         _('Orientation') => 'ORIENTATION',
89                         _('Destination') => 'DESTINATION'));
90 $reports->addReport(RC_CUSTOMER, 106, _('&Salesman Listing'),
91         array(  _('Start Date') => 'DATEBEGINM',
92                         _('End Date') => 'DATEENDM',
93                         _('Summary Only') => 'YES_NO',
94                         _('Comments') => 'TEXTBOX',
95                         _('Orientation') => 'ORIENTATION',
96                         _('Destination') => 'DESTINATION'));
97 $reports->addReport(RC_CUSTOMER, 107, _('Print &Invoices'),
98         array(  _('From') => 'INVOICE',
99                         _('To') => 'INVOICE',
100                         _('Currency Filter') => 'CURRENCY',
101                         _('email Customers') => 'YES_NO',
102                         _('Payment Link') => 'PAYMENT_LINK',
103                         _('Comments') => 'TEXTBOX',
104                         _('Customer') => 'CUSTOMERS_NO_FILTER',
105                         _('Orientation') => 'ORIENTATION'
106 ));
107 $reports->addReport(RC_CUSTOMER, 113, _('Print &Credit Notes'),
108         array(  _('From') => 'CREDIT',
109                         _('To') => 'CREDIT',
110                         _('Currency Filter') => 'CURRENCY',
111                         _('email Customers') => 'YES_NO',
112                         _('Payment Link') => 'PAYMENT_LINK',
113                         _('Comments') => 'TEXTBOX',
114                         _('Orientation') => 'ORIENTATION'));
115 $reports->addReport(RC_CUSTOMER, 110, _('Print &Deliveries'),
116         array(  _('From') => 'DELIVERY',
117                         _('To') => 'DELIVERY',
118                         _('email Customers') => 'YES_NO',
119                         _('Print as Packing Slip') => 'YES_NO',
120                         _('Comments') => 'TEXTBOX',
121                         _('Orientation') => 'ORIENTATION'));
122 $reports->addReport(RC_CUSTOMER, 108, _('Print &Statements'),
123         array(  _('Customer') => 'CUSTOMERS_NO_FILTER',
124                         _('Currency Filter') => 'CURRENCY',
125                         _('Show Also Allocated') => 'YES_NO',
126                         _('Email Customers') => 'YES_NO',
127                         _('Comments') => 'TEXTBOX',
128                         _('Orientation') => 'ORIENTATION'));
129 $reports->addReport(RC_CUSTOMER, 109, _('&Print Sales Orders'),
130         array(  _('From') => 'ORDERS',
131                         _('To') => 'ORDERS',
132                         _('Currency Filter') => 'CURRENCY',
133                         _('Email Customers') => 'YES_NO',
134                         _('Print as Quote') => 'YES_NO',
135                         _('Comments') => 'TEXTBOX',
136                         _('Orientation') => 'ORIENTATION'));
137 $reports->addReport(RC_CUSTOMER, 111, _('&Print Sales Quotations'),
138         array(  _('From') => 'QUOTATIONS',
139                         _('To') => 'QUOTATIONS',
140                         _('Currency Filter') => 'CURRENCY',
141                         _('Email Customers') => 'YES_NO',
142                         _('Comments') => 'TEXTBOX',
143                         _('Orientation') => 'ORIENTATION'));
144 $reports->addReport(RC_CUSTOMER, 112, _('Print Receipts'),
145         array(  _('From') => 'RECEIPT',
146                         _('To') => 'RECEIPT',
147                         _('Currency Filter') => 'CURRENCY',
148                         _('Comments') => 'TEXTBOX',
149                         _('Orientation') => 'ORIENTATION'));
150
151 $reports->addReportClass(_('Supplier'), RC_SUPPLIER);
152 $reports->addReport(RC_SUPPLIER, 201, _('Supplier &Balances'),
153         array(  _('Start Date') => 'DATEBEGIN',
154                         _('End Date') => 'DATEENDM',
155                         _('Supplier') => 'SUPPLIERS_NO_FILTER',
156                         _('Show Balance') => 'YES_NO',
157                         _('Currency Filter') => 'CURRENCY',
158                         _('Suppress Zeros') => 'YES_NO',
159                         _('Comments') => 'TEXTBOX',
160                         _('Orientation') => 'ORIENTATION',
161                         _('Destination') => 'DESTINATION'));
162 $reports->addReport(RC_SUPPLIER, 202, _('&Aged Supplier Analyses'),
163         array(  _('End Date') => 'DATE',
164                         _('Supplier') => 'SUPPLIERS_NO_FILTER',
165                         _('Currency Filter') => 'CURRENCY',
166                         _('Show Also Allocated') => 'YES_NO',
167                         _('Summary Only') => 'YES_NO',
168                         _('Suppress Zeros') => 'YES_NO',
169                         _('Graphics') => 'GRAPHIC',
170                         _('Comments') => 'TEXTBOX',
171                         _('Orientation') => 'ORIENTATION',
172                         _('Destination') => 'DESTINATION'));
173 $reports->addReport(RC_SUPPLIER, 203, _('&Payment Report'),
174         array(  _('End Date') => 'DATE',
175                         _('Supplier') => 'SUPPLIERS_NO_FILTER',
176                         _('Currency Filter') => 'CURRENCY',
177                         _('Suppress Zeros') => 'YES_NO',
178                         _('Comments') => 'TEXTBOX',
179                         _('Orientation') => 'ORIENTATION',
180                         _('Destination') => 'DESTINATION'));
181 $reports->addReport(RC_SUPPLIER, 204, _('Outstanding &GRNs Report'),
182         array(  _('Supplier') => 'SUPPLIERS_NO_FILTER',
183                         _('Comments') => 'TEXTBOX',
184                         _('Orientation') => 'ORIENTATION',
185                         _('Destination') => 'DESTINATION'));
186 $reports->addReport(RC_SUPPLIER, 205, _('Supplier &Detail Listing'),
187         array(  _('Activity Since') => 'DATEBEGIN',
188                         _('Activity Greater Than') => 'TEXT',
189                         _('Activity Less Than') => 'TEXT',
190                         _('Comments') => 'TEXTBOX',
191                         _('Orientation') => 'ORIENTATION',
192                         _('Destination') => 'DESTINATION'));
193 $reports->addReport(RC_SUPPLIER, 209, _('Print Purchase &Orders'),
194         array(  _('From') => 'PO',
195                         _('To') => 'PO',
196                         _('Currency Filter') => 'CURRENCY',
197                         _('Email Suppliers') => 'YES_NO',
198                         _('Comments') => 'TEXTBOX',
199                         _('Orientation') => 'ORIENTATION'));
200 $reports->addReport(RC_SUPPLIER, 210, _('Print Remi&ttances'),
201         array(  _('From') => 'REMITTANCE',
202                         _('To') => 'REMITTANCE',
203                         _('Currency Filter') => 'CURRENCY',
204                         _('Email Suppliers') => 'YES_NO',
205                         _('Comments') => 'TEXTBOX',
206                         _('Orientation') => 'ORIENTATION'));
207
208 $reports->addReportClass(_('Inventory'), RC_INVENTORY);
209 $reports->addReport(RC_INVENTORY,  301, _('Inventory &Valuation Report'),
210         array(  _('End Date') => 'DATE',
211                         _('Inventory Category') => 'CATEGORIES',
212                         _('Location') => 'LOCATIONS',
213                         _('Summary Only') => 'YES_NO',
214                         _('Comments') => 'TEXTBOX',
215                         _('Orientation') => 'ORIENTATION',
216                         _('Destination') => 'DESTINATION'));
217 $reports->addReport(RC_INVENTORY,  302, _('Inventory &Planning Report'),
218         array(  _('Inventory Category') => 'CATEGORIES',
219                         _('Location') => 'LOCATIONS',
220                         _('Comments') => 'TEXTBOX',
221                         _('Orientation') => 'ORIENTATION',
222                         _('Destination') => 'DESTINATION'));
223 $reports->addReport(RC_INVENTORY, 303, _('Stock &Check Sheets'),
224         array(  _('Inventory Category') => 'CATEGORIES',
225                         _('Location') => 'LOCATIONS',
226                         _('Show Pictures') => 'YES_NO',
227                         _('Inventory Column') => 'YES_NO',
228                         _('Show Shortage') => 'YES_NO',
229                         _('Suppress Zeros') => 'YES_NO',
230                         _('Item Like') => 'TEXT',
231                         _('Comments') => 'TEXTBOX',
232                         _('Orientation') => 'ORIENTATION',
233                         _('Destination') => 'DESTINATION'));
234 $reports->addReport(RC_INVENTORY, 304, _('Inventory &Sales Report'),
235         array(  _('Start Date') => 'DATEBEGINM',
236                         _('End Date') => 'DATEENDM',
237                         _('Inventory Category') => 'CATEGORIES',
238                         _('Location') => 'LOCATIONS',
239                         _('Customer') => 'CUSTOMERS_NO_FILTER',
240                         _('Show Service Items') => 'YES_NO',
241                         _('Comments') => 'TEXTBOX',
242                         _('Orientation') => 'ORIENTATION',
243                         _('Destination') => 'DESTINATION'));
244 $reports->addReport(RC_INVENTORY, 305, _('&GRN Valuation Report'),
245         array(  _('Start Date') => 'DATEBEGINM',
246                         _('End Date') => 'DATEENDM',
247                         _('Comments') => 'TEXTBOX',
248                         _('Orientation') => 'ORIENTATION',
249                         _('Destination') => 'DESTINATION'));
250 $reports->addReport(RC_INVENTORY, 306, _('Inventory P&urchasing Report'),
251         array(  _('Start Date') => 'DATEBEGINM',
252                         _('End Date') => 'DATEENDM',
253                         _('Inventory Category') => 'CATEGORIES',
254                         _('Location') => 'LOCATIONS',
255                         _('Supplier') => 'SUPPLIERS_NO_FILTER',
256                         _('Items') => 'ITEMS_P',
257                         _('Comments') => 'TEXTBOX',
258                         _('Orientation') => 'ORIENTATION',
259                         _('Destination') => 'DESTINATION'));
260 $reports->addReport(RC_INVENTORY, 307, _('Inventory &Movement Report'),
261         array(  _('Start Date') => 'DATEBEGINM',
262                         _('End Date') => 'DATEENDM',
263                         _('Inventory Category') => 'CATEGORIES',
264                         _('Location') => 'LOCATIONS',
265                         _('Comments') => 'TEXTBOX',
266                         _('Orientation') => 'ORIENTATION',
267                         _('Destination') => 'DESTINATION'));                            
268 $reports->addReport(RC_INVENTORY, 308, _('C&osted Inventory Movement Report'),
269         array(  _('Start Date') => 'DATEBEGINM',
270                         _('End Date') => 'DATEENDM',
271                         _('Inventory Category') => 'CATEGORIES',
272                         _('Location') => 'LOCATIONS',
273                         _('Comments') => 'TEXTBOX',
274                         _('Orientation') => 'ORIENTATION',
275                         _('Destination') => 'DESTINATION'));                            
276 $reports->addReport(RC_INVENTORY, 309,_('Item &Sales Summary Report'),
277         array(  _('Start Date') => 'DATEBEGINM',
278                         _('End Date') => 'DATEENDM',
279                         _('Inventory Category') => 'CATEGORIES',
280                         _('Comments') => 'TEXTBOX',
281                         _('Orientation') => 'ORIENTATION',
282                         _('Destination') => 'DESTINATION'));                            
283
284 $reports->addReportClass(_('Manufacturing'), RC_MANUFACTURE);
285 $reports->addReport(RC_MANUFACTURE, 401, _('&Bill of Material Listing'),
286         array(  _('From product') => 'ITEMS',
287                         _('To product') => 'ITEMS',
288                         _('Comments') => 'TEXTBOX',
289                         _('Orientation') => 'ORIENTATION',
290                         _('Destination') => 'DESTINATION'));
291 $reports->addReport(RC_MANUFACTURE, 402, _('Work Order &Listing'),
292         array(  _('Items') => 'ITEMS_ALL',
293                         _('Location') => 'LOCATIONS',
294                         _('Outstanding Only') => 'YES_NO',
295                         _('Comments') => 'TEXTBOX',
296                         _('Orientation') => 'ORIENTATION',
297                         _('Destination') => 'DESTINATION'));
298 $reports->addReport(RC_MANUFACTURE, 409, _('Print &Work Orders'),
299         array(  _('From') => 'WORKORDER',
300                         _('To') => 'WORKORDER',
301                         _('Email Locations') => 'YES_NO',
302                         _('Comments') => 'TEXTBOX',
303                         _('Orientation') => 'ORIENTATION'));
304 $reports->addReportClass(_('Fixed Assets'), RC_FIXEDASSETS);
305 $reports->addReport(RC_FIXEDASSETS, 451, _('&Fixed Assets Valuation'),
306         array(  _('End Date') => 'DATE',
307                         _('Fixed Assets Class') => 'FCLASS',
308                         _('Fixed Assets Location') => 'FLOCATIONS',
309                         _('Summary Only') => 'YES_NO',
310                         _('Comments') => 'TEXTBOX',
311                         _('Orientation') => 'ORIENTATION',
312                         _('Destination') => 'DESTINATION'));
313 $reports->addReportClass(_('Dimensions'), RC_DIMENSIONS);
314 if ($dim > 0)
315 {
316         $reports->addReport(RC_DIMENSIONS, 501, _('Dimension &Summary'),
317         array(  _('From Dimension') => 'DIMENSION',
318                         _('To Dimension') => 'DIMENSION',
319                         _('Show Balance') => 'YES_NO',
320                         _('Comments') => 'TEXTBOX',
321                         _('Orientation') => 'ORIENTATION',
322                         _('Destination') => 'DESTINATION'));
323 }
324 $reports->addReportClass(_('Banking'), RC_BANKING);
325         $reports->addReport(RC_BANKING,  601, _('Bank &Statement'),
326         array(  _('Bank Accounts') => 'BANK_ACCOUNTS',
327                         _('Start Date') => 'DATEBEGINM',
328                         _('End Date') => 'DATEENDM',
329                         _('Zero values') => 'YES_NO',
330                         _('Comments') => 'TEXTBOX',
331                         _('Orientation') => 'ORIENTATION',
332                         _('Destination') => 'DESTINATION'));
333         $reports->addReport(RC_BANKING,  602, _('Bank Statement w/ &Reconcile'),
334         array(  _('Bank Accounts') => 'BANK_ACCOUNTS',
335                         _('Start Date') => 'DATEBEGINM',
336                         _('End Date') => 'DATEENDM',
337                         _('Comments') => 'TEXTBOX',
338                         _('Destination') => 'DESTINATION'));
339
340 $reports->addReportClass(_('General Ledger'), RC_GL);
341 $reports->addReport(RC_GL, 701, _('Chart of &Accounts'),
342         array(  _('Show Balances') => 'YES_NO',
343                         _('Comments') => 'TEXTBOX',
344                         _('Orientation') => 'ORIENTATION',
345                         _('Destination') => 'DESTINATION'));
346 $reports->addReport(RC_GL, 702, _('List of &Journal Entries'),
347         array(  _('Start Date') => 'DATEBEGINM',
348                         _('End Date') => 'DATEENDM',
349                         _('Type') => 'SYS_TYPES',
350                         _('Comments') => 'TEXTBOX',
351                         _('Orientation') => 'ORIENTATION',
352                         _('Destination') => 'DESTINATION'));
353
354 if ($dim == 2)
355 {
356         $reports->addReport(RC_GL, 704, _('GL Account &Transactions'),
357         array(  _('Start Date') => 'DATEBEGINM',
358                         _('End Date') => 'DATEENDM',
359                         _('From Account') => 'GL_ACCOUNTS',
360                         _('To Account') => 'GL_ACCOUNTS',
361                         _('Dimension')." 1" =>  'DIMENSIONS1',
362                         _('Dimension')." 2" =>  'DIMENSIONS2',
363                         _('Comments') => 'TEXTBOX',
364                         _('Orientation') => 'ORIENTATION',
365                         _('Destination') => 'DESTINATION'));
366         $reports->addReport(RC_GL, 705, _('Annual &Expense Breakdown'),
367         array(  _('Year') => 'TRANS_YEARS',
368                         _('Dimension')." 1" =>  'DIMENSIONS1',
369                         _('Dimension')." 2" =>  'DIMENSIONS2',
370                         _('Account Tags') =>  'ACCOUNTTAGS',
371                         _('Comments') => 'TEXTBOX',
372                         _('Orientation') => 'ORIENTATION',
373                         _('Destination') => 'DESTINATION'));
374         $reports->addReport(RC_GL, 706, _('&Balance Sheet'),
375         array(  _('Start Date') => 'DATEBEGIN',
376                         _('End Date') => 'DATEENDM',
377                         _('Dimension')." 1" => 'DIMENSIONS1',
378                         _('Dimension')." 2" => 'DIMENSIONS2',
379                         _('Account Tags') =>  'ACCOUNTTAGS',
380                         _('Decimal values') => 'YES_NO',
381                         _('Graphics') => 'GRAPHIC',
382                         _('Comments') => 'TEXTBOX',
383                         _('Orientation') => 'ORIENTATION',
384                         _('Destination') => 'DESTINATION'));
385         $reports->addReport(RC_GL, 707, _('&Profit and Loss Statement'),
386         array(  _('Start Date') => 'DATEBEGINM',
387                         _('End Date') => 'DATEENDM',
388                         _('Compare to') => 'COMPARE',
389                         _('Dimension')." 1" =>  'DIMENSIONS1',
390                         _('Dimension')." 2" =>  'DIMENSIONS2',
391                         _('Account Tags') =>  'ACCOUNTTAGS',
392                         _('Decimal values') => 'YES_NO',
393                         _('Graphics') => 'GRAPHIC',
394                         _('Comments') => 'TEXTBOX',
395                         _('Orientation') => 'ORIENTATION',
396                         _('Destination') => 'DESTINATION'));
397         $reports->addReport(RC_GL, 708, _('Trial &Balance'),
398         array(  _('Start Date') => 'DATEBEGINM',
399                         _('End Date') => 'DATEENDM',
400                         _('Zero values') => 'YES_NO',
401                         _('Only balances') => 'YES_NO',
402                         _('Dimension')." 1" =>  'DIMENSIONS1',
403                         _('Dimension')." 2" =>  'DIMENSIONS2',
404                         _('Comments') => 'TEXTBOX',
405                         _('Orientation') => 'ORIENTATION',
406                         _('Destination') => 'DESTINATION'));
407 }
408 elseif ($dim == 1)
409 {
410         $reports->addReport(RC_GL, 704, _('GL Account &Transactions'),
411         array(  _('Start Date') => 'DATEBEGINM',
412                         _('End Date') => 'DATEENDM',
413                         _('From Account') => 'GL_ACCOUNTS',
414                         _('To Account') => 'GL_ACCOUNTS',
415                         _('Dimension') =>  'DIMENSIONS1',
416                         _('Comments') => 'TEXTBOX',
417                         _('Orientation') => 'ORIENTATION',
418                         _('Destination') => 'DESTINATION'));
419         $reports->addReport(RC_GL, 705, _('Annual &Expense Breakdown'),
420         array(  _('Year') => 'TRANS_YEARS',
421                         _('Dimension') =>  'DIMENSIONS1',
422                         _('Account Tags') =>  'ACCOUNTTAGS',
423                         _('Comments') => 'TEXTBOX',
424                         _('Orientation') => 'ORIENTATION',
425                         _('Destination') => 'DESTINATION'));
426         $reports->addReport(RC_GL, 706, _('&Balance Sheet'),
427         array(  _('Start Date') => 'DATEBEGIN',
428                         _('End Date') => 'DATEENDM',
429                         _('Dimension') => 'DIMENSIONS1',
430                         _('Account Tags') =>  'ACCOUNTTAGS',
431                         _('Decimal values') => 'YES_NO',
432                         _('Graphics') => 'GRAPHIC',
433                         _('Comments') => 'TEXTBOX',
434                         _('Orientation') => 'ORIENTATION',
435                         _('Destination') => 'DESTINATION'));
436         $reports->addReport(RC_GL, 707, _('&Profit and Loss Statement'),
437         array(  _('Start Date') => 'DATEBEGINM',
438                         _('End Date') => 'DATEENDM',
439                         _('Compare to') => 'COMPARE',
440                         _('Dimension') => 'DIMENSIONS1',
441                         _('Account Tags') =>  'ACCOUNTTAGS',
442                         _('Decimal values') => 'YES_NO',
443                         _('Graphics') => 'GRAPHIC',
444                         _('Comments') => 'TEXTBOX',
445                         _('Orientation') => 'ORIENTATION',
446                         _('Destination') => 'DESTINATION'));
447         $reports->addReport(RC_GL, 708, _('Trial &Balance'),
448         array(  _('Start Date') => 'DATEBEGINM',
449                         _('End Date') => 'DATEENDM',
450                         _('Zero values') => 'YES_NO',
451                         _('Only balances') => 'YES_NO',
452                         _('Dimension') => 'DIMENSIONS1',
453                         _('Comments') => 'TEXTBOX',
454                         _('Orientation') => 'ORIENTATION',
455                         _('Destination') => 'DESTINATION'));
456 }
457 else
458 {
459         $reports->addReport(RC_GL, 704, _('GL Account &Transactions'),
460         array(  _('Start Date') => 'DATEBEGINM',
461                         _('End Date') => 'DATEENDM',
462                         _('From Account') => 'GL_ACCOUNTS',
463                         _('To Account') => 'GL_ACCOUNTS',
464                         _('Comments') => 'TEXTBOX',
465                         _('Orientation') => 'ORIENTATION',
466                         _('Destination') => 'DESTINATION'));
467         $reports->addReport(RC_GL, 705, _('Annual &Expense Breakdown'),
468         array(  _('Year') => 'TRANS_YEARS',
469                         _('Account Tags') =>  'ACCOUNTTAGS',
470                         _('Comments') => 'TEXTBOX',
471                         _('Orientation') => 'ORIENTATION',
472                         _('Destination') => 'DESTINATION'));
473         $reports->addReport(RC_GL, 706, _('&Balance Sheet'),
474         array(  _('Start Date') => 'DATEBEGIN',
475                         _('End Date') => 'DATEENDM',
476                         _('Account Tags') =>  'ACCOUNTTAGS',
477                         _('Decimal values') => 'YES_NO',
478                         _('Graphics') => 'GRAPHIC',
479                         _('Comments') => 'TEXTBOX',
480                         _('Orientation') => 'ORIENTATION',
481                         _('Destination') => 'DESTINATION'));
482         $reports->addReport(RC_GL, 707, _('&Profit and Loss Statement'),
483         array(  _('Start Date') => 'DATEBEGINM',
484                         _('End Date') => 'DATEENDM',
485                         _('Compare to') => 'COMPARE',
486                         _('Account Tags') =>  'ACCOUNTTAGS',
487                         _('Decimal values') => 'YES_NO',
488                         _('Graphics') => 'GRAPHIC',
489                         _('Comments') => 'TEXTBOX',
490                         _('Orientation') => 'ORIENTATION',
491                         _('Destination') => 'DESTINATION'));
492         $reports->addReport(RC_GL, 708, _('Trial &Balance'),
493         array(  _('Start Date') => 'DATEBEGINM',
494                         _('End Date') => 'DATEENDM',
495                         _('Zero values') => 'YES_NO',
496                         _('Only balances') => 'YES_NO',
497                         _('Comments') => 'TEXTBOX',
498                         _('Orientation') => 'ORIENTATION',
499                         _('Destination') => 'DESTINATION'));
500 }
501 $reports->addReport(RC_GL, 709, _('Ta&x Report'),
502         array(  _('Start Date') => 'DATEBEGINTAX',
503                         _('End Date') => 'DATEENDTAX',
504                         _('Summary Only') => 'YES_NO',
505                         _('Comments') => 'TEXTBOX',
506                         _('Orientation') => 'ORIENTATION',
507                         _('Destination') => 'DESTINATION'));
508 $reports->addReport(RC_GL, 710, _('Audit Trail'),
509         array(  _('Start Date') => 'DATEBEGINM',
510                         _('End Date') => 'DATEENDM',
511                         _('Type') => 'SYS_TYPES_ALL',
512                         _('User') => 'USERS',
513                         _('Comments') => 'TEXTBOX',
514                         _('Orientation') => 'ORIENTATION',
515                         _('Destination') => 'DESTINATION'));
516
517 add_custom_reports($reports);
518
519 echo $reports->getDisplay();
520
521 end_page();