<?php
/**
* @Copyright Copyright (C) 2010 www.profinvent.com. All rights reserved.
* Copyright (C) 2011 Open Source Group GmbH www.osg-gmbh.de
* @website http://www.profinvent.com
* @license GNU/GPL http://www.gnu.org/copyleft/gpl.html
**/

defined('_JEXEC') or die('Restricted access');

JHTML::_('behavior.formvalidation');

$params = JComponentHelper::getParams('com_seminarman');
$Itemid = JRequest::getInt('Itemid');
$rowid = (int)JRequest::getVar('row');
?>
<script type="text/javascript">
function submitbuttonSeminarman(task)
{
	var form = document.adminForm;
	Joomla.submitform( task );
}
</script>
<?php if ($this->courses[$rowid]->cancel_allowed): ?>
<h2><?php echo JText::_('COM_SEMINARMAN_CANCEL_CONFIRM'); ?></h2>
<h3><?php echo JText::_('COM_SEMINARMAN_CANCEL_CONFIRM_ASK'); ?></h3>
<form action="<?php echo $this->action ?>" method="post" name="adminForm" id="adminForm" class="form-validate"  enctype="multipart/form-data">
<?php echo JText::_('COM_SEMINARMAN_COURSE_CODE').": ".$this->courses[$rowid]->code;?><br />
<?php echo JText::_('COM_SEMINARMAN_COURSE_TITLE').": ".$this->courses[$rowid]->title;?><br />
<?php echo JText::_('COM_SEMINARMAN_DATE').": ".$this->courses[$rowid]->start." - ".$this->courses[$rowid]->finish;?><br />
<?php echo JText::_('COM_SEMINARMAN_LOCATION').": ".$this->courses[$rowid]->location;?><br />
    <input type="hidden" name="application_id" value="<?php echo $this->courses[$rowid]->applicationid;?>" />
    <input type="hidden" name="option" value="com_seminarman" />
    <input type="hidden" name="controller" value="application" />
    <input type="hidden" name="task" value="" />
    <?php echo JHTML::_('form.token'); ?>
<button onclick="submitbuttonSeminarman('cancel_booking_process');"><?php echo JText::_('JYES'); ?></button>&nbsp;&nbsp;<button onclick="submitbuttonSeminarman('no_cancel_booking');"><?php echo JText::_('JNO'); ?></button>
</form>
<?php else: ?>
<h3><?php echo JText::_('COM_SEMINARMAN_CANCEL_NOT_ALLOWED'); ?></h3>
<?php endif; ?>