<?php
class ModuleMenu extends Controller { 
	function fetch() {
		$config   =& $this->locator->get('config');
		$language =& $this->locator->get('language');
		$url      =& $this->locator->get('url');
		$user     =& $this->locator->get('user');

		if (($user->isLogged()) && ($config->get('menu_status'))) {
	  		$language->load('extension/module/menu.php');
       	
	  		$view = $this->locator->create('template');

      		$view->set('text_admin', $language->get('text_admin'));
    	  	$view->set('text_configuration', $language->get('text_configuration'));
      		$view->set('text_users', $language->get('text_users'));
      		$view->set('text_localisation', $language->get('text_localisation'));
     	 	$view->set('text_catalog', $language->get('text_catalog'));
     	 	$view->set('text_extension', $language->get('text_extension'));
     		$view->set('text_customers', $language->get('text_customers'));
      		$view->set('text_reports', $language->get('text_reports'));
      		$view->set('text_home', $language->get('text_home'));
      		$view->set('text_shop', $language->get('text_catalog'));
     		$view->set('text_setting', $language->get('text_setting'));
      		$view->set('text_user', $language->get('text_user'));
      		$view->set('text_user_group', $language->get('text_user_group'));
      		$view->set('text_language', $language->get('text_language'));
      		$view->set('text_currency', $language->get('text_currency'));
      		$view->set('text_order_status', $language->get('text_order_status'));
      		$view->set('text_country', $language->get('text_country'));
      		$view->set('text_zone', $language->get('text_zone'));
      		$view->set('text_geo_zone', $language->get('text_geo_zone'));
      		$view->set('text_tax_class', $language->get('text_tax_class'));
      		$view->set('text_weight_class', $language->get('text_weight_class'));
      		$view->set('text_url_alias', $language->get('text_url_alias'));
      		$view->set('text_backup', $language->get('text_backup'));
			$view->set('text_server_info', $language->get('text_server_info'));
      		$view->set('text_logout', $language->get('text_logout'));
      		$view->set('text_category', $language->get('text_category'));
      		$view->set('text_product', $language->get('text_product'));
      		$view->set('text_option', $language->get('text_option'));
			$view->set('text_manufacturer', $language->get('text_manufacturer'));
      		$view->set('text_image', $language->get('text_image'));
      		$view->set('text_download', $language->get('text_download'));
      		$view->set('text_review', $language->get('text_review'));
      		$view->set('text_information', $language->get('text_information'));
      		$view->set('text_module', $language->get('text_module'));
			$view->set('text_shipping', $language->get('text_shipping'));
      		$view->set('text_payment', $language->get('text_payment'));
      		$view->set('text_calculate', $language->get('text_calculate'));
      		$view->set('text_customer', $language->get('text_customer'));
      		$view->set('text_order', $language->get('text_order'));
			$view->set('text_coupon', $language->get('text_coupon'));
			$view->set('text_mail', $language->get('text_mail'));
			$view->set('text_newsletter', $language->get('text_newsletter'));
      		$view->set('text_online', $language->get('text_online'));
      		$view->set('text_sale', $language->get('text_sale'));
      		$view->set('text_viewed', $language->get('text_viewed'));
      		$view->set('text_purchased', $language->get('text_purchased'));		

    	  	$view->set('home', $url->ssl('home')); 
      		$view->set('shop', HTTP_CATALOG);
      		$view->set('setting', $url->ssl('setting'));
      		$view->set('user', $url->ssl('user'));
      		$view->set('user_group', $url->ssl('user_group'));
      		$view->set('language', $url->ssl('language'));
      		$view->set('currency', $url->ssl('currency'));
      		$view->set('order_status', $url->ssl('order_status'));
      		$view->set('country', $url->ssl('country'));
      		$view->set('zone', $url->ssl('zone'));
      		$view->set('geo_zone', $url->ssl('geo_zone'));
      		$view->set('tax_class', $url->ssl('tax_class'));
      		$view->set('weight_class', $url->ssl('weight_class'));
      		$view->set('url_alias', $url->ssl('url_alias'));
			$view->set('backup', $url->ssl('backup'));
      		$view->set('server_info', $url->ssl('server_info'));
      		$view->set('logout', $url->ssl('logout'));
      		$view->set('category', $url->ssl('category'));
      		$view->set('product', $url->ssl('product'));
     		$view->set('option', $url->ssl('option'));
      		$view->set('manufacturer', $url->ssl('manufacturer'));
			$view->set('image', $url->ssl('image'));
      		$view->set('download', $url->ssl('download'));
     	 	$view->set('review', $url->ssl('review'));
    	  	$view->set('information', $url->ssl('information'));
      		$view->set('information', $url->ssl('information'));
      		$view->set('module', $url->ssl('extension', false, array('type' => 'module')));
			$view->set('shipping', $url->ssl('extension', false, array('type' => 'shipping')));
      		$view->set('payment', $url->ssl('extension', false, array('type' => 'payment')));
      		$view->set('calculate', $url->ssl('extension', false, array('type' => 'calculate')));
      		$view->set('customer', $url->ssl('customer'));
      		$view->set('order', $url->ssl('order'));
			$view->set('coupon', $url->ssl('coupon'));
			$view->set('mail', $url->ssl('mail'));
			$view->set('newsletter', $url->ssl('newsletter'));
      		$view->set('online', $url->ssl('report_online'));
      		$view->set('sale', $url->ssl('report_sale'));
      		$view->set('viewed', $url->ssl('report_viewed'));
      		$view->set('purchased', $url->ssl('report_purchased'));

      		return $view->fetch('module/menu.tpl');
		}
  	}
}
?>
