<?php
/**
 * Log details controller
 *
 * @package 	CSVIVirtueMart
 * @author 		Roland Dalmulder
 * @link 		http://www.csvimproved.com
 * @copyright 	Copyright (C) 2006 - 2012 RolandD Cyber Produksi
 * @license 	GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
 * @version 	$Id: logdetails.php 1892 2012-02-11 11:01:09Z RolandD $
 */

defined( '_JEXEC' ) or die( 'Direct Access to this location is not allowed.' );

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

/**
 * Log details Controller
 *
 * @package    CSVIVirtueMart
 */
class CsvivirtuemartControllerLogdetails extends JController {
	
	/**
	 * Constructor 
	 * 
	 * @copyright 
	 * @author 		RolandD
	 * @todo 
	 * @see 
	 * @access 		public
	 * @param 
	 * @return 
	 * @since 		3.0
	 */
	public function __construct() {
		parent::__construct();
	}
	
	/**
	 * Show the log details 
	 * 
	 * @copyright 
	 * @author 		RolandD
	 * @todo 
	 * @see 
	 * @access 		public
	 * @param 
	 * @return 
	 * @since 		3.0
	 */
	public function logDetails() {
		// Check if the run ID is set
		if (JRequest::getInt('run_id', 0) == 0) {
			$cid = JRequest::getVar('cid');
			if (is_array($cid)) JRequest::setVar('run_id', $cid[0]);
		}
		
		// Create the view object
		$view = $this->getView('logdetails', 'html');
		
		// Standard model
		$view->setModel( $this->getModel( 'logdetails', 'CsvivirtuemartModel' ), true );
		
		// Log functions
		$view->setModel( $this->getModel( 'log', 'CsvivirtuemartModel' ));
		
		// Now display the view
		$view->display();
	}
}
?>
