. ***********************************************************************/ class renderer { function wa_header() { page(_($help_context = "Main Menu"), false, true); } function wa_footer() { end_page(false, true); } function shortcut($url, $label) { echo "
  • "; $pars = access_string($label); echo "$pars[0]"; echo "
  • "; } function menu_header($title, $no_menu, $is_index) { global $path_to_root, $SysPrefs, $version; $sel_app = $_SESSION['sel_app']; echo "
    \n"; if (!$no_menu) { $applications = $_SESSION['App']->applications; $local_path_to_root = $path_to_root; $img = ""._(  "; $pimg = ""._(  "; $limg = ""._(  "; $himg = ""._(  "; echo "\n"; // header echo "
    "; echo "\n"; echo "
    \n"; // menu echo "
    \n"; } echo "
    \n"; if (!$no_menu) { echo "
    \n"; echo "
      \n"; switch ($sel_app) // Shortcuts { case "orders": $this->shortcut($local_path_to_root."/sales/sales_order_entry.php?NewOrder=Yes'",_("Sales Order")); $this->shortcut($local_path_to_root."/sales/sales_order_entry.php?NewInvoice=0",_("Direct Invoice")); $this->shortcut($local_path_to_root."/sales/customer_payments.php?", _("Payments")); $this->shortcut($local_path_to_root."/sales/inquiry/sales_orders_view.php?", _("Sales Order Inquiry")); $this->shortcut($local_path_to_root."/sales/inquiry/customer_inquiry.php?", _("Transactions")); $this->shortcut($local_path_to_root."/sales/manage/customers.php?", _("Customers")); $this->shortcut($local_path_to_root."/sales/manage/customer_branches.php?", _("Branch")); $this->shortcut($local_path_to_root."/reporting/reports_main.php?Class=0", _("Reports and Analysis")); break; case "AP": $this->shortcut($local_path_to_root."/purchasing/po_entry_items.php?NewOrder=0", _("Purchase Order")); $this->shortcut($local_path_to_root."/purchasing/inquiry/po_search.php?", _("Receive")); $this->shortcut($local_path_to_root."/purchasing/supplier_invoice.php?New=1", _("Supplier Invoice")); $this->shortcut($local_path_to_root."/purchasing/supplier_payment.php?", _("Payments")); $this->shortcut($local_path_to_root."/purchasing/inquiry/supplier_inquiry.php?", _("Transactions")); $this->shortcut($local_path_to_root."/purchasing/manage/suppliers.php?", _("Suppliers")); $this->shortcut($local_path_to_root."/reporting/reports_main.php?Class=1", _("Reports and Analysis")); break; case "stock": $this->shortcut($local_path_to_root."/inventory/adjustments.php?NewAdjustment=1", _("Inventory Adjustments")); $this->shortcut($local_path_to_root."/inventory/inquiry/stock_movements.php?", _("Inventory Movements")); $this->shortcut($local_path_to_root."/inventory/manage/items.php?", _("Items")); $this->shortcut($local_path_to_root."/inventory/prices.php?", _("Sales Pricing")); $this->shortcut($local_path_to_root."/reporting/reports_main.php?Class=2", _("Reports and Analysis")); break; case "manuf": $this->shortcut($local_path_to_root."/manufacturing/work_order_entry.php?", _("Work Order Entry")); $this->shortcut($local_path_to_root."/manufacturing/search_work_orders.php?outstanding_only=1", _("Ourstanding Work Orders")); $this->shortcut($local_path_to_root."/manufacturing/search_work_orders.php?", _("Work Order Inquiry")); $this->shortcut($local_path_to_root."/manufacturing/manage/bom_edit.php?", _("Bills Of Material")); $this->shortcut($local_path_to_root."/reporting/reports_main.php?Class=3", _("Reports and Analysis")); break; case "assets": $this->shortcut($local_path_to_root."/purchasing/po_entry_items.php?NewInvoice=Yes&FixedAsset=1", _("Fixed Assets Purchase")); $this->shortcut($local_path_to_root."/fixed_assets/inquiry/stock_inquiry.php?", _("Fixed Assets Inquiry")); $this->shortcut($local_path_to_root."/inventory/manage/items.php?FixedAsset=1", _("Fixed Assets")); $this->shortcut($local_path_to_root."/fixed_assets/process_depreciation.php?", _("Depreciations")); $this->shortcut($local_path_to_root."/reporting/reports_main.php?Class=7", _("Reports and Analysis")); break; case "proj": $this->shortcut($local_path_to_root."/dimensions/dimension_entry.php?", _("Dimension Entry")); $this->shortcut($local_path_to_root."/dimensions/inquiry/search_dimensions.php?", _("Dimension Inquiry")); $this->shortcut($local_path_to_root."/reporting/reports_main.php?Class=4", _("Reports and Analysis")); break; case "GL": $this->shortcut($local_path_to_root."/gl/gl_bank.php?NewPayment=Yes",_("Payments")); $this->shortcut($local_path_to_root."/gl/gl_bank.php?NewDeposit=Yes",_("Deposits")); $this->shortcut($local_path_to_root."/gl/gl_journal.php?NewJournal=Yes",_("Journal Entry")); $this->shortcut($local_path_to_root."/gl/inquiry/bank_inquiry.php?",_("Bank Account Inquiry")); //$this->shortcut($local_path_to_root."/gl/inquiry/gl_account_inquiry.php?",_("GL Account Inquiry")); $this->shortcut($local_path_to_root."/gl/inquiry/gl_trial_balance.php?",_("Trial Balance")); $this->shortcut($local_path_to_root."/gl/manage/exchange_rates.php?",_("Exchange Rates")); $this->shortcut($local_path_to_root."/gl/manage/gl_accounts.php?",_("GL Accounts")); $this->shortcut($local_path_to_root."/reporting/reports_main.php?Class=6",_("Reports and Analysis")); break; case "system": $this->shortcut($local_path_to_root."/admin/company_preferences.php?",_("Company Setup")); $this->shortcut($local_path_to_root."/admin/gl_setup.php?",_("General GL")); $this->shortcut($local_path_to_root."/taxes/tax_types.php?",_("Taxes")); $this->shortcut($local_path_to_root."/taxes/tax_groups.php?",_("Tax Groups")); $this->shortcut($local_path_to_root."/admin/forms_setup.php?",_("Forms Setup")); $this->shortcut($local_path_to_root."/admin/backups.php?",_("Backup and Restore")); break; } $this->shortcut($local_path_to_root."/admin/dashboard.php?sel_app=$sel_app", _("Dashboard")); echo "
    \n"; echo "
    \n"; // fa-submenu echo "
    \n"; echo "
    \n"; } if ($no_menu) echo "
    "; elseif ($title && !$no_menu && !$is_index) { echo "
    " ."" ."
    $title" .(user_hints() ? "" : '') ."
    "; } } function menu_footer($no_menu, $is_index) { global $path_to_root, $SysPrefs, $version, $db_connections; include_once($path_to_root . "/includes/date_functions.inc"); if (!$no_menu) echo "
    \n"; // fa-content echo "
    \n"; // fa-body if (!$no_menu) { echo "\n"; // footer } echo "
    \n"; // fa-main } function display_applications(&$waapp) { global $path_to_root; $i = 0; $sel_app = $waapp->get_selected_application(); if (!$_SESSION["wa_current_user"]->check_application_access($sel_app)) return; if ($sel_app->id == "system") $imgs2 = array("page_edit.png", "page_edit.png", "page_edit.png", "page_edit.png", "folder.gif"); else $imgs2 = array("folder.gif", "report.png", "page_edit.png", "money.png", "folder.gif"); foreach ($sel_app->modules as $module) { if (!$_SESSION["wa_current_user"]->check_module_access($module)) continue; // image echo ""; echo "
    \n"; $i++; } } }