Пример #1
0
 function osC_Account_Orders()
 {
     global $osC_Services, $osC_Language, $osC_Customer, $osC_Breadcrumb;
     $this->_page_title = $osC_Language->get('orders_heading');
     $osC_Language->load('order');
     if ($osC_Services->isStarted('breadcrumb')) {
         $osC_Breadcrumb->add($osC_Language->get('breadcrumb_my_orders'), osc_href_link(FILENAME_ACCOUNT, $this->_module, 'SSL'));
         if (is_numeric($_GET[$this->_module])) {
             $osC_Breadcrumb->add(sprintf($osC_Language->get('breadcrumb_order_information'), $_GET[$this->_module]), osc_href_link(FILENAME_ACCOUNT, $this->_module . '=' . $_GET[$this->_module], 'SSL'));
         }
     }
     if (is_numeric($_GET[$this->_module])) {
         if (osC_Order::getCustomerID($_GET[$this->_module]) !== $osC_Customer->getID()) {
             osc_redirect(osc_href_link(FILENAME_ACCOUNT, $this->_module, 'SSL'));
         }
         $this->_page_title = sprintf($osC_Language->get('order_information_heading'), $_GET[$this->_module]);
         $this->_page_contents = 'account_history_info.php';
     }
 }
Пример #2
0
 function osC_Account_Orders()
 {
     global $osC_Services, $osC_Language, $osC_Customer, $breadcrumb, $returns_orders;
     $this->_page_title = $osC_Language->get('orders_heading');
     $osC_Language->load('order');
     if ($osC_Services->isStarted('breadcrumb')) {
         $breadcrumb->add($osC_Language->get('breadcrumb_my_orders'), osc_href_link(FILENAME_ACCOUNT, $this->_module, 'SSL'));
         if (is_numeric($_REQUEST[$this->_module])) {
             $breadcrumb->add(sprintf($osC_Language->get('breadcrumb_order_information'), $_REQUEST[$this->_module]), osc_href_link(FILENAME_ACCOUNT, $this->_module . '=' . $_REQUEST[$this->_module], 'SSL'));
         }
     }
     if (is_numeric($_GET[$this->_module])) {
         if (osC_Order::getCustomerID($_GET[$this->_module]) !== $osC_Customer->getID()) {
             osc_redirect(osc_href_link(FILENAME_ACCOUNT, $this->_module, 'SSL'));
         }
         $this->_page_title = sprintf($osC_Language->get('order_information_heading'), $_GET[$this->_module]);
         $this->_page_contents = 'account_history_info.php';
     } else {
         if (!empty($_GET[$this->_module])) {
             switch ($_GET[$this->_module]) {
                 case 'list_return_requests':
                     $this->_page_title = $osC_Language->get('orders_returns_heading');
                     $this->_page_contents = 'return_requests_history.php';
                     break;
                 case 'list_credit_slips':
                     $this->_page_title = $osC_Language->get('credit_slips_heading');
                     $this->_page_contents = 'credit_slips_history.php';
                     break;
                 case 'new_return_request':
                     $this->_page_title = sprintf($osC_Language->get('orders_returns_information_heading'), $_GET['orders_id']);
                     $this->_page_contents = 'return_request_process.php';
                     break;
                 case 'save_return_request':
                     $this->_page_title = sprintf($osC_Language->get('orders_returns_information_heading'), $_GET['orders_id']);
                     $this->_page_contents = 'return_request_process.php';
                     $this->_save_orders_returns();
                     break;
             }
         }
     }
 }