<?php
require_once 'modules/admin/models/Package.php';
require_once 'modules/admin/models/PackageTypeGateway.php';
require_once 'modules/admin/views/public/SignupView.php';

/**
* @package Admin
*/
class ViewSignup_3_Summary extends SignupView
{
    var $permission     = '';

    function dispatch()
    {

        $this->initialize();

        // Init some vars
        $this->templateInit();
        $this->currencys = new Currency($this->user);

        // Set header info
        $this->headerlabel = $this->lang("Order - Step 3 - Order Summmary");

        // Process the form post
        if($_POST) {
            $this->processFormPost($_REQUEST, @$_REQUEST['formId'], 'cartSummary');
        }

        // Allow Coupons?
        if(@$this->settings->get("Accept Coupons") == 1) {
            $this->tplView->acceptCoupons = true;
        }
        
        //$this->destroyCart();

        // Process the cart summary
        $cartSummary = $this->getCartSummary();
        $this->tplView->cartItems = $cartSummary['items'];
        $this->tplView->cartTotal = $cartSummary['total'];
        $this->tplView->cartCount = $cartSummary['totalCount'];
        
        // Process the progress bar
        $this->tplView->progress = $this->getProgressBar();
        $this->tplView->progressBar = $this->tplView->fetch('progressBar.tpl.php');

        // Output the template
        $this->tplView->display('signup_3_Summary.tpl.php');

        // Show the footer
        $this->tplView->display('signup_footer.tpl.php');


    }
}

?>
