<?php
/**
* @version		3.0.0
* @package		JomLand TicketCenter
* @copyright	Copyright (C) 2010 JomLand.com. All rights reserved.
* @link 		www.jomland.com
* @license		GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
*/
defined( '_JEXEC' ) or die( 'Restricted access' );

jimport( 'joomla.application.component.view');

class JLTicketCenterViewOrder extends JViewLegacy
{
	function display($tpl = null)
	{
        $app = JFactory::getApplication();
		$document = JFactory::getDocument();
		$document->addStyleSheet(JURI::base().'components/com_jlticketcenter/assets/jlticketcenter.css');
		
		$pparams = new JLTicketCenterHelperSetup;
		
		$order_id = $this->get('order');
		$paid	  = $this->get('Payment');
		
		$menu = $app->getMenu()->getActive();
		if (!isset($menu->id)){
			$menu 		= $app->getMenu();
			$bit_itemid = $menu->getItems('component','com_jlticketcenter');
			$Itemid  	= $bit_itemid[0]->id;
		}
		else{
			$Itemid  	= $menu->id;
		}
		
		if (!empty($menuitemid))
		{
		    $menu = $app->getMenu();
		    $menuparams = $menu->getParams( $menuitemid );
		 }else{
			$menuparams = JComponentHelper::getParams('com_jlticketcenter');
		 }
		
		$this->assignRef('itemid',	$Itemid );
		$this->assignRef('params',	$pparams);
		$this->assignRef('menuparams',	$menuparams );
		$this->assignRef('order_id',$order_id);
		$this->assignRef('paid'		,$paid);
		
		parent::display();
		JLTicketCenterLinksHelper::renderinfo();
	}//EOF display
} // EOC VIEW