Prepared for category icons in applications/application.php for themes
authorJoe Hunt <joe.hunt.consulting@gmail.com>
Mon, 27 Dec 2010 15:46:44 +0000 (15:46 +0000)
committerJoe Hunt <joe.hunt.consulting@gmail.com>
Mon, 27 Dec 2010 15:46:44 +0000 (15:46 +0000)
12 files changed:
CHANGELOG.txt
applications/application.php
applications/customers.php
applications/dimensions.php
applications/generalledger.php
applications/inventory.php
applications/manufacturing.php
applications/setup.php
applications/suppliers.php
themes/aqua/renderer.php
themes/cool/renderer.php
themes/default/renderer.php

index 89cede4113d6928af635f8ddc4e514f6e85cb4ec..b5dc90dd9d51e2e9e5be8232c03316486707a8ae 100644 (file)
@@ -19,6 +19,20 @@ Legend:
 ! -> Note
 $ -> Affected files
 
+27-Dec-2010 Joe Hunt
+! Prepared for category icons in applications/application.php for themes
+$ /applications/application.php
+  /applications/customers.php
+  /applications/dimensions.php
+  /applications/generalledger.php
+  /applications/inventory.php
+  /applications/manufacturing.php
+  /applications/setup.php
+  /applications/supplier.php
+  /themes/aqua/renderer.php (commented member for the future)
+  /themes/cool/renderer.php (commented member for the future)
+  /themes/default/renderer.php (commented member for the future)
+  
 27-Dec-2010 Janusz Dobrowolski
 + Option for allowing negative prices for dummy/service items [0000343]
 $ /config.default.php
index 430b20c80a531b741632b9daaf9f00e2168ba2f3..c16ef2069704aa33b8b440a35e3722d2dbdb665e 100644 (file)
@@ -9,7 +9,17 @@
     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
     See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
 ***********************************************************************/
-       class menu_item 
+
+define('MENU_ENTRY', 'menu_entry');
+define('MENU_TRANSACTION', 'menu_transaction');
+define('MENU_INQUIRY', 'menu_inquiry');
+define('MENU_REPORT', 'menu_report');
+define('MENU_MAINTENANCE', 'menu_maintenance');
+define('MENU_UPDATE', 'menu_update');
+define('MENU_SETTINGS', 'menu_settings');
+define('MENU_SYSTEM', 'menu_system');
+
+        class menu_item
        {
                var $label;
                var $link;
                var $label;
                var $link;
                var $access;
+                var $category;
                
-               function app_function($label,$link,$access='SA_OPEN'
+               function app_function($label,$link,$access='SA_OPEN',$category='')
                {
                        $this->label = $label;
                        $this->link = $link;
                        $this->access = $access;
+            $this->category = $category;
                }
        }
 
                        $this->rappfunctions = array();
                }
                
-               function add_lapp_function($label,$link="",$access='SA_OPEN'
+               function add_lapp_function($label,$link="",$access='SA_OPEN',$category='')
                {
-                       $appfunction = new app_function($label,$link,$access);
+                       $appfunction = new app_function($label,$link,$access,$category);
                        //array_push($this->lappfunctions,$appfunction);
                        $this->lappfunctions[] = $appfunction;
                        return $appfunction;
                }
 
-               function add_rapp_function($label,$link="",$access='SA_OPEN'
+               function add_rapp_function($label,$link="",$access='SA_OPEN',$category='')
                {
-                       $appfunction = new app_function($label,$link,$access);
+                       $appfunction = new app_function($label,$link,$access,$category);
                        //array_push($this->rappfunctions,$appfunction);
                        $this->rappfunctions[] = $appfunction;
                        return $appfunction;
                        return $module;
                }
                
-               function add_lapp_function($level, $label,$link="",$access='SA_OPEN'
+               function add_lapp_function($level, $label,$link="",$access='SA_OPEN',$category='')
                {
-                       $this->modules[$level]->lappfunctions[] = new app_function($label, $link, $access);
+                       $this->modules[$level]->lappfunctions[] = new app_function($label, $link, $access, $category);
                }
                
-               function add_rapp_function($level, $label,$link="",$access='SA_OPEN'
+               function add_rapp_function($level, $label,$link="",$access='SA_OPEN',$category='')
                {
-                       $this->modules[$level]->rappfunctions[] = new app_function($label, $link, $access);
+                       $this->modules[$level]->rappfunctions[] = new app_function($label, $link, $access, $category);
                }
                
                function add_extensions()
index d99e8fbbb562d6d017a2302000419fa16b1fca82..ff161af8f41c6ff06730c6d4086250f9f9319d37 100644 (file)
@@ -17,64 +17,64 @@ class customers_app extends application
        
                $this->add_module(_("Transactions"));
                $this->add_lapp_function(0, _("Sales &Quotation Entry"),
-                       "sales/sales_order_entry.php?NewQuotation=Yes", 'SA_SALESQUOTE');
+                       "sales/sales_order_entry.php?NewQuotation=Yes", 'SA_SALESQUOTE', MENU_TRANSACTION);
                $this->add_lapp_function(0, _("Sales &Order Entry"),
-                       "sales/sales_order_entry.php?NewOrder=Yes", 'SA_SALESORDER');
+                       "sales/sales_order_entry.php?NewOrder=Yes", 'SA_SALESORDER', MENU_TRANSACTION);
                $this->add_lapp_function(0, _("Direct &Delivery"),
-                       "sales/sales_order_entry.php?NewDelivery=0", 'SA_SALESDELIVERY');
+                       "sales/sales_order_entry.php?NewDelivery=0", 'SA_SALESDELIVERY', MENU_TRANSACTION);
                $this->add_lapp_function(0, _("Direct &Invoice"),
-                       "sales/sales_order_entry.php?NewInvoice=0", 'SA_SALESINVOICE');
+                       "sales/sales_order_entry.php?NewInvoice=0", 'SA_SALESINVOICE', MENU_TRANSACTION);
                $this->add_lapp_function(0, "","");
                $this->add_lapp_function(0, _("&Delivery Against Sales Orders"),
-                       "sales/inquiry/sales_orders_view.php?OutstandingOnly=1", 'SA_SALESDELIVERY');
+                       "sales/inquiry/sales_orders_view.php?OutstandingOnly=1", 'SA_SALESDELIVERY', MENU_INQUIRY);
                $this->add_lapp_function(0, _("&Invoice Against Sales Delivery"),
-                       "sales/inquiry/sales_deliveries_view.php?OutstandingOnly=1", 'SA_SALESINVOICE');
+                       "sales/inquiry/sales_deliveries_view.php?OutstandingOnly=1", 'SA_SALESINVOICE', MENU_INQUIRY);
 
                $this->add_rapp_function(0, _("&Template Delivery"),
-                       "sales/inquiry/sales_orders_view.php?DeliveryTemplates=Yes", 'SA_SALESDELIVERY');
+                       "sales/inquiry/sales_orders_view.php?DeliveryTemplates=Yes", 'SA_SALESDELIVERY', MENU_INQUIRY);
                $this->add_rapp_function(0, _("&Template Invoice"),
-                       "sales/inquiry/sales_orders_view.php?InvoiceTemplates=Yes", 'SA_SALESINVOICE');
+                       "sales/inquiry/sales_orders_view.php?InvoiceTemplates=Yes", 'SA_SALESINVOICE', MENU_INQUIRY);
                $this->add_rapp_function(0, _("&Create and Print Recurrent Invoices"),
-                       "sales/create_recurrent_invoices.php?", 'SA_SALESINVOICE');
+                       "sales/create_recurrent_invoices.php?", 'SA_SALESINVOICE', MENU_INQUIRY);
                $this->add_rapp_function(0, "","");
                $this->add_rapp_function(0, _("Customer &Payments"),
-                       "sales/customer_payments.php?", 'SA_SALESPAYMNT');
+                       "sales/customer_payments.php?", 'SA_SALESPAYMNT', MENU_ENTRY);
                $this->add_rapp_function(0, _("Customer &Credit Notes"),
-                       "sales/credit_note_entry.php?NewCredit=Yes", 'SA_SALESCREDIT');
+                       "sales/credit_note_entry.php?NewCredit=Yes", 'SA_SALESCREDIT', MENU_ENTRY);
                $this->add_rapp_function(0, _("&Allocate Customer Payments or Credit Notes"),
-                       "sales/allocations/customer_allocation_main.php?", 'SA_SALESALLOC');
+                       "sales/allocations/customer_allocation_main.php?", 'SA_SALESALLOC', MENU_INQUIRY);
 
                $this->add_module(_("Inquiries and Reports"));
                $this->add_lapp_function(1, _("Sales Quotation I&nquiry"),
-                       "sales/inquiry/sales_orders_view.php?type=32", 'SA_SALESTRANSVIEW');
+                       "sales/inquiry/sales_orders_view.php?type=32", 'SA_SALESTRANSVIEW', MENU_INQUIRY);
                $this->add_lapp_function(1, _("Sales Order &Inquiry"),
-                       "sales/inquiry/sales_orders_view.php?type=30", 'SA_SALESTRANSVIEW');
+                       "sales/inquiry/sales_orders_view.php?type=30", 'SA_SALESTRANSVIEW', 'MENU_INQUIRY');
                $this->add_lapp_function(1, _("Customer Transaction &Inquiry"),
-                       "sales/inquiry/customer_inquiry.php?", 'SA_SALESTRANSVIEW');
+                       "sales/inquiry/customer_inquiry.php?", 'SA_SALESTRANSVIEW', MENU_INQUIRY);
                $this->add_lapp_function(1, "","");
                $this->add_lapp_function(1, _("Customer Allocation &Inquiry"),
-                       "sales/inquiry/customer_allocation_inquiry.php?", 'SA_SALESALLOC');
+                       "sales/inquiry/customer_allocation_inquiry.php?", 'SA_SALESALLOC', MENU_INQUIRY);
 
                $this->add_rapp_function(1, _("Customer and Sales &Reports"),
-                       "reporting/reports_main.php?Class=0", 'SA_SALESTRANSVIEW');
+                       "reporting/reports_main.php?Class=0", 'SA_SALESTRANSVIEW', MENU_REPORT);
 
                $this->add_module(_("Maintenance"));
                $this->add_lapp_function(2, _("Add and Manage &Customers"),
-                       "sales/manage/customers.php?", 'SA_CUSTOMER');
+                       "sales/manage/customers.php?", 'SA_CUSTOMER', MENU_ENTRY);
                $this->add_lapp_function(2, _("Customer &Branches"),
-                       "sales/manage/customer_branches.php?", 'SA_CUSTOMER');
+                       "sales/manage/customer_branches.php?", 'SA_CUSTOMER', MENU_ENTRY);
                $this->add_lapp_function(2, _("Sales &Groups"),
-                       "sales/manage/sales_groups.php?", 'SA_SALESGROUP');
+                       "sales/manage/sales_groups.php?", 'SA_SALESGROUP', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("Recurrent &Invoices"),
-                       "sales/manage/recurrent_invoices.php?", 'SA_SRECURRENT');
+                       "sales/manage/recurrent_invoices.php?", 'SA_SRECURRENT', MENU_INQUIRY);
                $this->add_rapp_function(2, _("Sales T&ypes"),
-                       "sales/manage/sales_types.php?", 'SA_SALESTYPES');
+                       "sales/manage/sales_types.php?", 'SA_SALESTYPES', MENU_MAINTENANCE);
                $this->add_rapp_function(2, _("Sales &Persons"),
-                       "sales/manage/sales_people.php?", 'SA_SALESMAN');
+                       "sales/manage/sales_people.php?", 'SA_SALESMAN', MENU_INQUIRY);
                $this->add_rapp_function(2, _("Sales &Areas"),
-                       "sales/manage/sales_areas.php?", 'SA_SALESAREA');
+                       "sales/manage/sales_areas.php?", 'SA_SALESAREA', MENU_MAINTENANCE);
                $this->add_rapp_function(2, _("Credit &Status Setup"),
-                       "sales/manage/credit_status.php?", 'SA_CRSTATUS');
+                       "sales/manage/credit_status.php?", 'SA_CRSTATUS', MENU_MAINTENANCE);
 
                $this->add_extensions();
        }
index 0af8fc75d028f5b91f48b86271da01473baf5515..88f05e314603b65b9d172915472439a04aef37a5 100644 (file)
@@ -20,20 +20,20 @@ class dimensions_app extends application
                {
                        $this->add_module(_("Transactions"));
                        $this->add_lapp_function(0, _("Dimension &Entry"),
-                               "dimensions/dimension_entry.php?", 'SA_DIMENSION');
+                               "dimensions/dimension_entry.php?", 'SA_DIMENSION', MENU_ENTRY);
                        $this->add_lapp_function(0, _("&Outstanding Dimensions"),
-                               "dimensions/inquiry/search_dimensions.php?outstanding_only=1", 'SA_DIMTRANSVIEW');
+                               "dimensions/inquiry/search_dimensions.php?outstanding_only=1", 'SA_DIMTRANSVIEW', MENU_INQUIRY);
 
                        $this->add_module(_("Inquiries and Reports"));
                        $this->add_lapp_function(1, _("Dimension &Inquiry"),
-                               "dimensions/inquiry/search_dimensions.php?", 'SA_DIMTRANSVIEW');
+                               "dimensions/inquiry/search_dimensions.php?", 'SA_DIMTRANSVIEW', MENU_INQUIRY);
 
                        $this->add_rapp_function(1, _("Dimension &Reports"),
-                               "reporting/reports_main.php?Class=4", 'SA_DIMENSIONREP');
+                               "reporting/reports_main.php?Class=4", 'SA_DIMENSIONREP', MENU_REPORT);
                        
                        $this->add_module(_("Maintenance"));
                        $this->add_lapp_function(2, _("Dimension &Tags"),
-                               "admin/tags.php?type=dimension", 'SA_DIMTAGS');
+                               "admin/tags.php?type=dimension", 'SA_DIMTAGS', MENU_MAINTENANCE);
 
                        $this->add_extensions();
                }
index 1bbea0d4c5779a0e65b2d69b3d0019d4ff1bd308..670f27aace65cd2b590d78f6ef7c06241b805ab7 100644 (file)
@@ -17,63 +17,63 @@ class general_ledger_app extends application
 
                $this->add_module(_("Transactions"));
                $this->add_lapp_function(0, _("&Payments"),
-                       "gl/gl_bank.php?NewPayment=Yes", 'SA_PAYMENT');
+                       "gl/gl_bank.php?NewPayment=Yes", 'SA_PAYMENT', MENU_ENTRY);
                $this->add_lapp_function(0, _("&Deposits"),
-                       "gl/gl_bank.php?NewDeposit=Yes", 'SA_DEPOSIT');
+                       "gl/gl_bank.php?NewDeposit=Yes", 'SA_DEPOSIT', MENU_ENTRY);
                $this->add_lapp_function(0, _("Bank Account &Transfers"),
-                       "gl/bank_transfer.php?", 'SA_BANKTRANSFER');
+                       "gl/bank_transfer.php?", 'SA_BANKTRANSFER', MENU_ENTRY);
                $this->add_rapp_function(0, _("&Journal Entry"),
-                       "gl/gl_journal.php?NewJournal=Yes", 'SA_JOURNALENTRY');
+                       "gl/gl_journal.php?NewJournal=Yes", 'SA_JOURNALENTRY', MENU_ENTRY);
                $this->add_rapp_function(0, _("&Budget Entry"),
-                       "gl/gl_budget.php?", 'SA_BUDGETENTRY');
+                       "gl/gl_budget.php?", 'SA_BUDGETENTRY', MENU_ENTRY);
                $this->add_rapp_function(0, _("&Reconcile Bank Account"),
-                       "gl/bank_account_reconcile.php?", 'SA_RECONCILE');
+                       "gl/bank_account_reconcile.php?", 'SA_RECONCILE', MENU_INQUIRY);
                $this->add_rapp_function(0, _("Revenue / &Costs Accruals"),
-                       "gl/accruals.php?", 'SA_ACCRUALS');
+                       "gl/accruals.php?", 'SA_ACCRUALS', MENU_INQUIRY);
 
                $this->add_module(_("Inquiries and Reports"));
                $this->add_lapp_function(1, _("&Journal Inquiry"),
-                       "gl/inquiry/journal_inquiry.php?", 'SA_GLANALYTIC');
+                       "gl/inquiry/journal_inquiry.php?", 'SA_GLANALYTIC', MENU_INQUIRY);
                $this->add_lapp_function(1, _("GL &Inquiry"),
-                       "gl/inquiry/gl_account_inquiry.php?", 'SA_GLTRANSVIEW');
+                       "gl/inquiry/gl_account_inquiry.php?", 'SA_GLTRANSVIEW', MENU_INQUIRY);
                $this->add_lapp_function(1, _("Bank Account &Inquiry"),
-                       "gl/inquiry/bank_inquiry.php?", 'SA_BANKTRANSVIEW');
+                       "gl/inquiry/bank_inquiry.php?", 'SA_BANKTRANSVIEW', MENU_INQUIRY);
                $this->add_lapp_function(1, _("Ta&x Inquiry"),
-                       "gl/inquiry/tax_inquiry.php?", 'SA_TAXREP');
+                       "gl/inquiry/tax_inquiry.php?", 'SA_TAXREP', MENU_INQUIRY);
 
                $this->add_rapp_function(1, _("Trial &Balance"),
-                       "gl/inquiry/gl_trial_balance.php?", 'SA_GLANALYTIC');
+                       "gl/inquiry/gl_trial_balance.php?", 'SA_GLANALYTIC', MENU_INQUIRY);
                $this->add_rapp_function(1, _("Balance &Sheet Drilldown"),
-                       "gl/inquiry/balance_sheet.php?", 'SA_GLANALYTIC');
+                       "gl/inquiry/balance_sheet.php?", 'SA_GLANALYTIC', MENU_INQUIRY);
                $this->add_rapp_function(1, _("&Profit and Loss Drilldown"),
-                       "gl/inquiry/profit_loss.php?", 'SA_GLANALYTIC');
+                       "gl/inquiry/profit_loss.php?", 'SA_GLANALYTIC', MENU_INQUIRY);
                $this->add_rapp_function(1, _("Banking &Reports"),
-                       "reporting/reports_main.php?Class=5", 'SA_BANKREP');
+                       "reporting/reports_main.php?Class=5", 'SA_BANKREP', MENU_REPORT);
                $this->add_rapp_function(1, _("General Ledger &Reports"),
-                       "reporting/reports_main.php?Class=6", 'SA_GLREP');
+                       "reporting/reports_main.php?Class=6", 'SA_GLREP', MENU_REPORT);
 
                $this->add_module(_("Maintenance"));
                $this->add_lapp_function(2, _("Bank &Accounts"),
-                       "gl/manage/bank_accounts.php?", 'SA_BANKACCOUNT');
+                       "gl/manage/bank_accounts.php?", 'SA_BANKACCOUNT', MENU_ENTRY);
                $this->add_lapp_function(2, _("&Quick Entries"),
-                       "gl/manage/gl_quick_entries.php?", 'SA_QUICKENTRY');
+                       "gl/manage/gl_quick_entries.php?", 'SA_QUICKENTRY', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("Account &Tags"),
-                       "admin/tags.php?type=account", 'SA_GLACCOUNTTAGS');
+                       "admin/tags.php?type=account", 'SA_GLACCOUNTTAGS', MENU_MAINTENANCE);
                $this->add_lapp_function(2, "","");
                $this->add_lapp_function(2, _("&Currencies"),
-                       "gl/manage/currencies.php?", 'SA_CURRENCY');
+                       "gl/manage/currencies.php?", 'SA_CURRENCY', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("&Exchange Rates"),
-                       "gl/manage/exchange_rates.php?", 'SA_EXCHANGERATE');
+                       "gl/manage/exchange_rates.php?", 'SA_EXCHANGERATE', MENU_MAINTENANCE);
 
                $this->add_rapp_function(2, _("&GL Accounts"),
-                       "gl/manage/gl_accounts.php?", 'SA_GLACCOUNT');
+                       "gl/manage/gl_accounts.php?", 'SA_GLACCOUNT', MENU_ENTRY);
                $this->add_rapp_function(2, _("GL Account &Groups"),
-                       "gl/manage/gl_account_types.php?", 'SA_GLACCOUNTGROUP');
+                       "gl/manage/gl_account_types.php?", 'SA_GLACCOUNTGROUP', MENU_MAINTENANCE);
                $this->add_rapp_function(2, _("GL Account &Classes"),
-                       "gl/manage/gl_account_classes.php?", 'SA_GLACCOUNTCLASS');
+                       "gl/manage/gl_account_classes.php?", 'SA_GLACCOUNTCLASS', MENU_MAINTENANCE);
                $this->add_rapp_function(2, "","");
                $this->add_rapp_function(2, _("&Revaluation of Currency Accounts"),
-                       "gl/manage/revaluate_currencies.php?", 'SA_EXCHANGERATE');
+                       "gl/manage/revaluate_currencies.php?", 'SA_EXCHANGERATE', MENU_MAINTENANCE);
 
                $this->add_extensions();
        }
index b5b32f53e285c7967b0d4db021613235f9507375..30fd7b4ae9c1f2fbde72fbadf7d895a4045a567c 100644 (file)
@@ -17,43 +17,43 @@ class inventory_app extends application
 
                $this->add_module(_("Transactions"));
                $this->add_lapp_function(0, _("Inventory Location &Transfers"),
-                       "inventory/transfers.php?NewTransfer=1", 'SA_LOCATIONTRANSFER');
+                       "inventory/transfers.php?NewTransfer=1", 'SA_LOCATIONTRANSFER', MENU_TRANSACTION);
                $this->add_lapp_function(0, _("Inventory &Adjustments"),
-                       "inventory/adjustments.php?NewAdjustment=1", 'SA_INVENTORYADJUSTMENT');
+                       "inventory/adjustments.php?NewAdjustment=1", 'SA_INVENTORYADJUSTMENT', MENU_TRANSACTION);
 
                $this->add_module(_("Inquiries and Reports"));
                $this->add_lapp_function(1, _("Inventory Item &Movements"),
-                       "inventory/inquiry/stock_movements.php?", 'SA_ITEMSTRANSVIEW');
+                       "inventory/inquiry/stock_movements.php?", 'SA_ITEMSTRANSVIEW', MENU_INQUIRY);
                $this->add_lapp_function(1, _("Inventory Item &Status"),
-                       "inventory/inquiry/stock_status.php?", 'SA_ITEMSSTATVIEW');
+                       "inventory/inquiry/stock_status.php?", 'SA_ITEMSSTATVIEW', MENU_INQUIRY);
                $this->add_rapp_function(1, _("Inventory &Reports"),
-                       "reporting/reports_main.php?Class=2", 'SA_ITEMSTRANSVIEW');
+                       "reporting/reports_main.php?Class=2", 'SA_ITEMSTRANSVIEW', MENU_REPORT);
 
                $this->add_module(_("Maintenance"));
                $this->add_lapp_function(2, _("&Items"),
-                       "inventory/manage/items.php?", 'SA_ITEM');
+                       "inventory/manage/items.php?", 'SA_ITEM', MENU_ENTRY);
                $this->add_lapp_function(2, _("&Foreign Item Codes"),
-                       "inventory/manage/item_codes.php?", 'SA_FORITEMCODE');
+                       "inventory/manage/item_codes.php?", 'SA_FORITEMCODE', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("Sales &Kits"),
-                       "inventory/manage/sales_kits.php?", 'SA_SALESKIT');
+                       "inventory/manage/sales_kits.php?", 'SA_SALESKIT', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("Item &Categories"),
-                       "inventory/manage/item_categories.php?", 'SA_ITEMCATEGORY');
+                       "inventory/manage/item_categories.php?", 'SA_ITEMCATEGORY', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("Inventory &Locations"),
-                       "inventory/manage/locations.php?", 'SA_INVENTORYLOCATION');
+                       "inventory/manage/locations.php?", 'SA_INVENTORYLOCATION', MENU_MAINTENANCE);
                $this->add_rapp_function(2, _("Inventory &Movement Types"),
-                       "inventory/manage/movement_types.php?", 'SA_INVENTORYMOVETYPE');
+                       "inventory/manage/movement_types.php?", 'SA_INVENTORYMOVETYPE', MENU_MAINTENANCE);
                $this->add_rapp_function(2, _("&Units of Measure"),
-                       "inventory/manage/item_units.php?", 'SA_UOM');
+                       "inventory/manage/item_units.php?", 'SA_UOM', MENU_MAINTENANCE);
                $this->add_rapp_function(2, _("&Reorder Levels"),
-                       "inventory/reorder_level.php?", 'SA_REORDER');
+                       "inventory/reorder_level.php?", 'SA_REORDER', MENU_MAINTENANCE);
 
                $this->add_module(_("Pricing and Costs"));
                $this->add_lapp_function(3, _("Sales &Pricing"),
-                       "inventory/prices.php?", 'SA_SALESPRICE');
+                       "inventory/prices.php?", 'SA_SALESPRICE', MENU_MAINTENANCE);
                $this->add_lapp_function(3, _("Purchasing &Pricing"),
-                       "inventory/purchasing_data.php?", 'SA_PURCHASEPRICING');
+                       "inventory/purchasing_data.php?", 'SA_PURCHASEPRICING', MENU_MAINTENANCE);
                $this->add_rapp_function(3, _("Standard &Costs"),
-                       "inventory/cost_update.php?", 'SA_STANDARDCOST');
+                       "inventory/cost_update.php?", 'SA_STANDARDCOST', MENU_MAINTENANCE);
 
                $this->add_extensions();
        }
index 3c9c861fcd685f25270e7de0340b2cbc209dd0dd..b876a5ecd56c06731cf27c606767bf0ecfbede17 100644 (file)
@@ -17,25 +17,25 @@ class manufacturing_app extends application
 
                $this->add_module(_("Transactions"));
                $this->add_lapp_function(0, _("Work &Order Entry"),
-                       "manufacturing/work_order_entry.php?", 'SA_WORKORDERENTRY');
+                       "manufacturing/work_order_entry.php?", 'SA_WORKORDERENTRY', MENU_ENTRY);
                $this->add_lapp_function(0, _("&Outstanding Work Orders"),
-                       "manufacturing/search_work_orders.php?outstanding_only=1", 'SA_MANUFTRANSVIEW');
+                       "manufacturing/search_work_orders.php?outstanding_only=1", 'SA_MANUFTRANSVIEW', MENU_INQUIRY);
 
                $this->add_module(_("Inquiries and Reports"));
                $this->add_lapp_function(1, _("Costed Bill Of Material Inquiry"),
-                       "manufacturing/inquiry/bom_cost_inquiry.php?", 'SA_WORKORDERCOST');
+                       "manufacturing/inquiry/bom_cost_inquiry.php?", 'SA_WORKORDERCOST', MENU_INQUIRY);
                $this->add_lapp_function(1, _("Inventory Item Where Used &Inquiry"),
-                       "manufacturing/inquiry/where_used_inquiry.php?", 'SA_WORKORDERANALYTIC');
+                       "manufacturing/inquiry/where_used_inquiry.php?", 'SA_WORKORDERANALYTIC', MENU_INQUIRY);
                $this->add_lapp_function(1, _("Work Order &Inquiry"),
-                       "manufacturing/search_work_orders.php?", 'SA_MANUFTRANSVIEW');
+                       "manufacturing/search_work_orders.php?", 'SA_MANUFTRANSVIEW', MENU_INQUIRY);
                $this->add_rapp_function(1, _("Manufacturing &Reports"),
-                       "reporting/reports_main.php?Class=3", 'SA_MANUFTRANSVIEW');
+                       "reporting/reports_main.php?Class=3", 'SA_MANUFTRANSVIEW', MENU_REPORT);
 
                $this->add_module(_("Maintenance"));
                $this->add_lapp_function(2, _("&Bills Of Material"),
-                       "manufacturing/manage/bom_edit.php?", 'SA_BOM');
+                       "manufacturing/manage/bom_edit.php?", 'SA_BOM', MENU_INQUIRY);
                $this->add_lapp_function(2, _("&Work Centres"),
-                       "manufacturing/manage/work_centres.php?", 'SA_WORKCENTRES');
+                       "manufacturing/manage/work_centres.php?", 'SA_WORKCENTRES', MENU_MAINTENANCE);
 
                $this->add_extensions();
        }
index 3e2f3b8681406a9fc15a43cd49277ff9f703c146..6e48fc710dbee56ae9eea07391bc8199766d2488 100644 (file)
@@ -17,64 +17,64 @@ class setup_app extends application
 
                $this->add_module(_("Company Setup"));
                $this->add_lapp_function(0, _("&Company Setup"),
-                       "admin/company_preferences.php?", 'SA_SETUPCOMPANY');
+                       "admin/company_preferences.php?", 'SA_SETUPCOMPANY', MENU_SETTINGS);
                $this->add_lapp_function(0, _("&User Accounts Setup"),
-                       "admin/users.php?", 'SA_USERS');
+                       "admin/users.php?", 'SA_USERS', MENU_SETTINGS);
                $this->add_lapp_function(0, _("&Access Setup"),
-                       "admin/security_roles.php?", 'SA_SECROLES');
+                       "admin/security_roles.php?", 'SA_SECROLES', MENU_SETTINGS);
                $this->add_lapp_function(0, _("&Display Setup"),
-                       "admin/display_prefs.php?", 'SA_SETUPDISPLAY');
+                       "admin/display_prefs.php?", 'SA_SETUPDISPLAY', MENU_SETTINGS);
                $this->add_lapp_function(0, _("&Forms Setup"),
-                       "admin/forms_setup.php?", 'SA_FORMSETUP');
+                       "admin/forms_setup.php?", 'SA_FORMSETUP', MENU_SETTINGS);
                $this->add_rapp_function(0, _("&Taxes"),
-                       "taxes/tax_types.php?", 'SA_TAXRATES');
+                       "taxes/tax_types.php?", 'SA_TAXRATES', MENU_MAINTENANCE);
                $this->add_rapp_function(0, _("Tax &Groups"),
-                       "taxes/tax_groups.php?", 'SA_TAXGROUPS');
+                       "taxes/tax_groups.php?", 'SA_TAXGROUPS', MENU_MAINTENANCE);
                $this->add_rapp_function(0, _("Item Ta&x Types"),
-                       "taxes/item_tax_types.php?", 'SA_ITEMTAXTYPE');
+                       "taxes/item_tax_types.php?", 'SA_ITEMTAXTYPE', MENU_MAINTENANCE);
                $this->add_rapp_function(0, _("System and &General GL Setup"),
-                       "admin/gl_setup.php?", 'SA_GLSETUP');
+                       "admin/gl_setup.php?", 'SA_GLSETUP', MENU_MAINTENANCE);
                $this->add_rapp_function(0, _("&Fiscal Years"),
-                       "admin/fiscalyears.php?", 'SA_FISCALYEARS');
+                       "admin/fiscalyears.php?", 'SA_FISCALYEARS', MENU_MAINTENANCE);
                $this->add_rapp_function(0, _("&Print Profiles"),
-                       "admin/print_profiles.php?", 'SA_PRINTPROFILE');
+                       "admin/print_profiles.php?", 'SA_PRINTPROFILE', MENU_MAINTENANCE);
 
                $this->add_module(_("Miscellaneous"));
                $this->add_lapp_function(1, _("Pa&yment Terms"),
-                       "admin/payment_terms.php?", 'SA_PAYTERMS');
+                       "admin/payment_terms.php?", 'SA_PAYTERMS', MENU_MAINTENANCE);
                $this->add_lapp_function(1, _("Shi&pping Company"),
-                       "admin/shipping_companies.php?", 'SA_SHIPPING');
+                       "admin/shipping_companies.php?", 'SA_SHIPPING', MENU_MAINTENANCE);
                $this->add_rapp_function(1, _("&Points of Sale"),
-                       "sales/manage/sales_points.php?", 'SA_POSSETUP');
+                       "sales/manage/sales_points.php?", 'SA_POSSETUP', MENU_MAINTENANCE);
                $this->add_rapp_function(1, _("&Printers"),
-                       "admin/printers.php?", 'SA_PRINTERS');
+                       "admin/printers.php?", 'SA_PRINTERS', MENU_MAINTENANCE);
                $this->add_rapp_function(1, _("Contact &Categories"),
-                       "admin/crm_categories.php?", 'SA_CRMCATEGORY');
+                       "admin/crm_categories.php?", 'SA_CRMCATEGORY', MENU_MAINTENANCE);
 
                $this->add_module(_("Maintenance"));
                $this->add_lapp_function(2, _("&Void a Transaction"),
-                       "admin/void_transaction.php?", 'SA_VOIDTRANSACTION');
+                       "admin/void_transaction.php?", 'SA_VOIDTRANSACTION', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("View or &Print Transactions"),
-                       "admin/view_print_transaction.php?", 'SA_VIEWPRINTTRANSACTION');
+                       "admin/view_print_transaction.php?", 'SA_VIEWPRINTTRANSACTION', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("&Attach Documents"),
-                       "admin/attachments.php?filterType=20", 'SA_ATTACHDOCUMENT');
+                       "admin/attachments.php?filterType=20", 'SA_ATTACHDOCUMENT', MENU_MAINTENANCE);
                $this->add_lapp_function(2, _("System &Diagnostics"),
-                       "admin/system_diagnostics.php?", 'SA_OPEN');
+                       "admin/system_diagnostics.php?", 'SA_OPEN', MENU_SYSTEM);
 
                $this->add_rapp_function(2, _("&Backup and Restore"),
-                       "admin/backups.php?", 'SA_BACKUP');
+                       "admin/backups.php?", 'SA_BACKUP', MENU_SYSTEM);
                $this->add_rapp_function(2, _("Create/Update &Companies"),
-                       "admin/create_coy.php?", 'SA_CREATECOMPANY');
+                       "admin/create_coy.php?", 'SA_CREATECOMPANY', MENU_UPDATE);
                $this->add_rapp_function(2, _("Install/Update &Languages"),
-                       "admin/inst_lang.php?", 'SA_CREATELANGUAGE');
+                       "admin/inst_lang.php?", 'SA_CREATELANGUAGE', MENU_UPDATE);
                $this->add_rapp_function(2, _("Install/Activate &Extensions"),
-                       "admin/inst_module.php?", 'SA_CREATEMODULES');
+                       "admin/inst_module.php?", 'SA_CREATEMODULES', MENU_UPDATE);
                $this->add_rapp_function(2, _("Install/Activate &Themes"),
-                       "admin/inst_theme.php?", 'SA_CREATEMODULES');
+                       "admin/inst_theme.php?", 'SA_CREATEMODULES', MENU_UPDATE);
                $this->add_rapp_function(2, _("Install/Activate &Chart of Accounts"),
-                       "admin/inst_chart.php?", 'SA_CREATEMODULES');
+                       "admin/inst_chart.php?", 'SA_CREATEMODULES', MENU_UPDATE);
                $this->add_rapp_function(2, _("Software &Upgrade"),
-                       "admin/inst_upgrade.php?", 'SA_SOFTWAREUPGRADE');
+                       "admin/inst_upgrade.php?", 'SA_SOFTWAREUPGRADE', MENU_UPDATE);
 
                $this->add_extensions();
        }
index 173a8c03ac386a5cb478816fe6d885fbc6bda392..ab1d002e3369042705ff27af9aacc5145ef3a60b 100644 (file)
@@ -17,39 +17,39 @@ class suppliers_app extends application
 
                $this->add_module(_("Transactions"));
                $this->add_lapp_function(0, _("Purchase &Order Entry"),
-                       "purchasing/po_entry_items.php?NewOrder=Yes", 'SA_PURCHASEORDER');
+                       "purchasing/po_entry_items.php?NewOrder=Yes", 'SA_PURCHASEORDER', MENU_TRANSACTION);
                $this->add_lapp_function(0, _("&Outstanding Purchase Orders Maintenance"),
-                       "purchasing/inquiry/po_search.php?", 'SA_GRN');
+                       "purchasing/inquiry/po_search.php?", 'SA_GRN', MENU_INQUIRY);
                $this->add_lapp_function(0, _("Direct &GRN"),
-                       "purchasing/po_entry_items.php?NewGRN=Yes", 'SA_GRN');
+                       "purchasing/po_entry_items.php?NewGRN=Yes", 'SA_GRN', MENU_TRANSACTION);
                $this->add_lapp_function(0, _("Direct &Invoice"),
-                       "purchasing/po_entry_items.php?NewInvoice=Yes", 'SA_SUPPLIERINVOICE');
+                       "purchasing/po_entry_items.php?NewInvoice=Yes", 'SA_SUPPLIERINVOICE', MENU_TRANSACTION);
 
                $this->add_rapp_function(0, _("&Payments to Suppliers"),
-                       "purchasing/supplier_payment.php?", 'SA_SUPPLIERPAYMNT');
+                       "purchasing/supplier_payment.php?", 'SA_SUPPLIERPAYMNT', MENU_ENTRY);
                $this->add_rapp_function(0, "","");
                $this->add_rapp_function(0, _("Supplier &Invoices"),
-                       "purchasing/supplier_invoice.php?New=1", 'SA_SUPPLIERINVOICE');
+                       "purchasing/supplier_invoice.php?New=1", 'SA_SUPPLIERINVOICE', MENU_ENTRY);
                $this->add_rapp_function(0, _("Supplier &Credit Notes"),
-                       "purchasing/supplier_credit.php?New=1", 'SA_SUPPLIERCREDIT');
+                       "purchasing/supplier_credit.php?New=1", 'SA_SUPPLIERCREDIT', MENU_ENTRY);
                $this->add_rapp_function(0, _("&Allocate Supplier Payments or Credit Notes"),
-                       "purchasing/allocations/supplier_allocation_main.php?", 'SA_SUPPLIERALLOC');
+                       "purchasing/allocations/supplier_allocation_main.php?", 'SA_SUPPLIERALLOC', MENU_INQUIRY);
 
                $this->add_module(_("Inquiries and Reports"));
                $this->add_lapp_function(1, _("Purchase Orders &Inquiry"),
-                       "purchasing/inquiry/po_search_completed.php?", 'SA_SUPPTRANSVIEW');
+                       "purchasing/inquiry/po_search_completed.php?", 'SA_SUPPTRANSVIEW', MENU_INQUIRY);
                $this->add_lapp_function(1, _("Supplier Transaction &Inquiry"),
-                       "purchasing/inquiry/supplier_inquiry.php?", 'SA_SUPPTRANSVIEW');
+                       "purchasing/inquiry/supplier_inquiry.php?", 'SA_SUPPTRANSVIEW', MENU_INQUIRY);
                $this->add_lapp_function(1, "","");
                $this->add_lapp_function(1, _("Supplier Allocation &Inquiry"),
-                       "purchasing/inquiry/supplier_allocation_inquiry.php?", 'SA_SUPPLIERALLOC');
+                       "purchasing/inquiry/supplier_allocation_inquiry.php?", 'SA_SUPPLIERALLOC', MENU_INQUIRY);
 
                $this->add_rapp_function(1, _("Supplier and Purchasing &Reports"),
-                       "reporting/reports_main.php?Class=1", 'SA_SUPPTRANSVIEW');
+                       "reporting/reports_main.php?Class=1", 'SA_SUPPTRANSVIEW', MENU_REPORT);
 
                $this->add_module(_("Maintenance"));
                $this->add_lapp_function(2, _("&Suppliers"),
-                       "purchasing/manage/suppliers.php?", 'SA_SUPPLIER');
+                       "purchasing/manage/suppliers.php?", 'SA_SUPPLIER', MENU_ENTRY);
 
                $this->add_extensions();
        }
index 8ee81f2dfa25cef7657b4f096d9bd981c0870976..12d31c47ddd686d1268a3179055b45d8e17a43ad 100644 (file)
 ***********************************************************************/
        class renderer
        {
+               /* Uncomment this member if you want to use the category icons defined in /applications/applications.php
+               function get_icon($category)
+               {
+                       global  $path_to_root;
+
+                       $img = $category == '' ? 'right.gif' : $category.'.png';
+                       return "<img src='$path_to_root/themes/cool/images/$img' style='vertical-align:middle;' border='0'>&nbsp;&nbsp;";
+               }
+               */
+
                function wa_header()
                {
                        page(_($help_context = "Main Menu"), false, true);
index 9bf46c95fc02cf736960d8cc1ae16b38e3313981..81528f1c67ae6f2b015af70378e600ff6ea74df5 100644 (file)
 ***********************************************************************/
        class renderer
        {
+               /* Uncomment this member if you want to use the category icons defined in /applications/applications.php
+               function get_icon($category)
+               {
+                       global  $path_to_root;
+
+                       $img = $category == '' ? 'right.gif' : $category.'.png';
+                       return "<img src='$path_to_root/themes/cool/images/$img' style='vertical-align:middle;' border='0'>&nbsp;&nbsp;";
+               }
+               */
+
                function wa_header()
                {
                        page(_($help_context = "Main Menu"), false, true);
index 03a56f2448ddc4127245b8872201a598d3fee088..950cd6a4ee86f8f63fe34ff08fd27ad4c999ebc7 100644 (file)
 ***********************************************************************/
        class renderer
        {
+               /* Uncomment this member if you want to use the category icons defined in /applications/applications.php
+               function get_icon($category)
+               {
+                       global  $path_to_root;
+
+                       $img = $category == '' ? 'right.gif' : $category.'.png';
+                       return "<img src='$path_to_root/themes/cool/images/$img' style='vertical-align:middle;' border='0'>&nbsp;&nbsp;";
+               }
+               */
+
                function wa_header()
                {
 //                     add_js_ufile("themes/default/renderer.js");