<?php 
$STORE = @$_SESSION[$controller->defaultStore];
if(isset($STORE['services']) && !empty($STORE['services']))
{
	?>
	<ul class="list-unstyled pjCcAsideBookings">
		<li class="pjCcAsideBooking">
			<div class="pull-left pjCcAsideBookingImage">
				<span class="glyphicon glyphicon-ok" aria-hidden="true"></span>
			</div><!-- /.pull-left pjCcAsideBookingImage -->
	
			<div class="pjCcAsideBookingContent">
				<p class="pjCcAsideBookingTitle">
					<?php echo $tpl['price_arr']['hours']?> <?php __('front_hours_booking');?>
				</p><!-- /.pjCcAsideBookingTitle -->
	
				<div class="pjCcAsideBookingPrice">(<?php echo pjUtil::formatCurrencySign($tpl['arr']['price_per_hour'], $tpl['option_arr']['o_currency'])?>/hr)</div><!-- /.pjCcAsideBookingPrice -->
	
				<?php
				if(!empty($tpl['price_arr']['extra_arr']))
				{ 
					foreach($tpl['price_arr']['extra_arr'] as $k => $v)
					{
						?>
						<dl class="dl-horizontal pjCcAsideBookingExtras">
							<dt>+ <?php echo pjSanitize::html($v['name']);?></dt>
							<dd><?php echo pjUtil::convertToHoursMins($v['time_needed']);?></dd>
						</dl><!-- /.dl-horizontal pjCcAsideBookingExtras -->
						<?php
					}
				}
				if(isset($STORE['services']['cleaning_materials']) && $STORE['services']['cleaning_materials'] == 'F')
				{
					?>
					<dl class="dl-horizontal pjCcAsideBookingExtras">
						<dt>+ <?php __('front_cleaning_materials');?></dt>
					</dl><!-- /.dl-horizontal pjCcAsideBookingExtras -->
					<?php
				} 
				?>
				
			</div><!-- /.pjCcAsideBookingContent -->
		</li><!-- /.pjCcAsideBooking -->
		
		<?php
		if(isset($STORE['datetime']) && !empty($STORE['datetime']) && $_GET['action'] != 'pjActionServices')
		{ 
			$datetime = $STORE['datetime'];
			$when_options =  __('when_options', true);
			$how_often = __('how_often', true);
			?>
			<li class="pjCcAsideBooking">
				<div class="pull-left pjCcAsideBookingImage">
					<span class="glyphicon glyphicon-ok" aria-hidden="true"></span>
				</div><!-- /.pull-left pjCcAsideBookingImage -->
	
				<div class="pjCcAsideBookingContent">
					<?php
					if(isset($datetime['date']) && !empty($datetime['date']))
					{ 
						?>
						<p class="pjCcAsideBookingTitle"><?php echo $datetime['date'];?></p><!-- /.pjCcAsideBookingTitle -->
						<?php
					} 
					?>
					<div class="pjCcAsideBookingPrice"><?php echo $when_options[$datetime['when']];?></div><!-- /.pjCcAsideBookingPrice -->
					<?php
					if(isset($datetime['how_often']) && !empty($datetime['how_often']))
					{ 
						?>
						<dl class="dl-horizontal pjCcAsideBookingExtras">
							<dt><?php echo $how_often[$datetime['how_often']];?></dt>
						</dl><!-- /.dl-horizontal pjCcAsideBookingExtras -->
						<?php
					} 
					?>
				</div><!-- /.pjCcAsideBookingContent -->
			</li><!-- /.pjCcAsideBooking -->
			<?php
		} 
		?>
	</ul><!-- /.list-unstyled pjCcAsideBookings -->
	
	<div class="pjCcAsidePrice">
		<dl class="dl-horizontal">
			<dt><?php __('front_price');?></dt>
			<dd><?php echo pjUtil::formatCurrencySign(number_format($tpl['price_arr']['subtotal'], 2), $tpl['option_arr']['o_currency']);?></dd>
		</dl><!-- /.dl-horizontal -->
	</div><!-- /.pjCcAsidePrice -->
	<?php
}else{
	?>
	<ul class="list-unstyled pjCcAsideBookings">
		
	</ul><!-- /.list-unstyled pjCcAsideBookings -->
	
	<div class="pjCcAsidePrice">
		<dl class="dl-horizontal">
			<dt><?php __('front_price');?></dt>
			<dd><?php echo pjUtil::formatCurrencySign('0.00', $tpl['option_arr']['o_currency']);?></dd>
		</dl><!-- /.dl-horizontal -->
	</div><!-- /.pjCcAsidePrice -->
	<?php 
} 
?>