

				
				<div class="configuratorMenu">
					<div class="configuratorMenuElement" data-field="sizeBox"><?php if( $this->ProductFieldnameInfo['product_fieldname_size'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size']; else echo @Lib_Lang::translate(front_configurator_size); ?><div class="infoElement" id="sizeInfoElement"></div><div class="configuratorMenuElementZR" id="sizeProductShopTable"><?php /*echo @Lib_Lang::translate(front_configurator_zr);*/ ?></div></div>
					

				<div class="configuratorDiv">
				
					<div class="configuratorDivElement" id="sizeBox">
					
					<table width="100%">
						<tr>
						<td>
						<h4 style="display:inline-block;"><?php if( $this->ProductFieldnameInfo['product_fieldname_size_top'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_top']; else echo @Lib_Lang::translate(front_configurator_size); ?></h4>
						<div style="float:right;display:inline-block;padding-top:10px;padding-right:2px;">
							<a href="javascript:void(0);" cmd="mm" class="changeUnit">mm</a> 
							<a href="javascript:void(0);" cmd="cm" class="changeUnit">cm</a>
						</div>
						<table width="100%" class="tr12">
							<tr id="wysokoscHover">
								<td width="100px"><?php if( $this->ProductFieldnameInfo['product_fieldname_size_height'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_height']; else echo @Lib_Lang::translate(front_configurator_height); ?>:
								<br/><font class="unitElement" unit=""><?php echo$this->rowProduct['product_height_min'];?></font>-<font class="unitElement" unit=""><?php echo$this->rowProduct['product_height_max'];?></font> <font class="unitInfo"></font></td>
								<td width="60px">
								
								<input class="unitInput" type="number" step="1" min="<?php echo$this->rowProduct['product_height_min'];?>" max="<?php echo$this->rowProduct['product_height_max'];?>" name="input_height_view" nF="input_height" style="width:60px;" <?php if( $this->rowProduct['product_height_def_only'] == 1 ) echo' readonly="readonly"'; ?>/>
								
								<input class="unitInputHidden" type="number" step="1" min="<?php echo$this->rowProduct['product_height_min'];?>" max="<?php echo$this->rowProduct['product_height_max'];?>" value="<?php echo isset($this->dataSelect['product_height'])?$this->dataSelect['product_height']:$this->rowProduct['product_height_default'];?>" name="input_height" style="width:60px;" <?php if( $this->rowProduct['product_height_def_only'] == 1 ) echo' readonly="readonly"'; ?>/>
								
								</td>
								<td>
									<div id="product_height">
									

									<script type="text/javascript" language="javascript">
										$(document).ready(function () {											
											$('.changeHeight').click(function(){
												var t = $(this).attr('cmd');
												$('[name="input_height"]').val(t);
												$("#product_height").slider( "value", t );
											//	changeSize();
											});	
										});
									</script>	
									<?php /*$i=0; foreach ( $this->ProductHeight as $key => $val ): $i++; ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_height_value']; ?>" class="changeHeight"><div style="background-color: #ddd;border: 1px solid rgb(85, 85, 85);color: #555;height:19px;width:19px;border-radius:4px;margin-left:<?php $wartosc=($val['product_height_value']-$this->rowProduct['product_height_min'])*226/($this->rowProduct['product_height_max']-$this->rowProduct['product_height_min'])-9-$i; echo$wartosc; ?>px;margin-top:-5px;position:absolute;z-index:9900;"></div></a>
									<?php endforeach;*/ ?>	
									</div>
								</td>
							</tr> 
							<tr id="wysokoscHover2">
								<td colspan="3" style="text-align:right;" class="marginBottomConfig">

									<?php if( $this->ProductFieldnameInfo['product_fieldname_size_heightstand'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_heightstand']; else echo @Lib_Lang::translate(front_configurator_standard1); ?>
									<?php foreach ( $this->ProductHeight as $key => $val ): ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_height_value']; ?>" unit="mm" class="unitElement changeHeight standardSize"><?php echo $val['product_height_value']; ?></a>
									<?php endforeach; ?>	
									
								</td>
							</tr>
							<tr id="szerokoscHover">
								<td width="100px"><?php if( $this->ProductFieldnameInfo['product_fieldname_size_width'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_width']; else echo @Lib_Lang::translate(front_configurator_width); ?>:
								<br/><font class="unitElement" unit=""><?php echo$this->rowProduct['product_width_min'];?></font>-<font class="unitElement" unit=""><?php echo$this->rowProduct['product_width_max'];?></font> <font class="unitInfo"></font></td>
								<td width="60px">
								
								<input class="unitInput" type="number" step="1" min="<?php echo$this->rowProduct['product_width_min'];?>" max="<?php echo$this->rowProduct['product_width_max'];?>" name="input_width_view" nF="input_width" style="width:60px;" <?php if( $this->rowProduct['product_width_def_only'] == 1 ) echo' readonly="readonly"'; ?>/>
								
								<input class="unitInputHidden" type="number" step="1" min="<?php echo$this->rowProduct['product_width_min'];?>" max="<?php echo$this->rowProduct['product_width_max'];?>" value="<?php echo isset($this->dataSelect['product_width'])?$this->dataSelect['product_width']:$this->rowProduct['product_width_default'];?>" name="input_width" style="width:60px;" <?php if( $this->rowProduct['product_width_def_only'] == 1 ) echo' readonly="readonly"'; ?>/>
								
								</td>
								<td>
									<div id="product_width">
									<script type="text/javascript" language="javascript">
										$(document).ready(function () {	
											$('.changeWidth').click(function(){
												var t = $(this).attr('cmd');
												$('[name="input_width"]').val(t);
												$("#product_width").slider( "value", t );
											//	changeSize();
											});	
										});
									</script>	
									
									<?php /*$i=0; foreach ( $this->ProductWidth as $key => $val ): $i++; ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_width_value']; ?>" class="changeWidth"><div style="background-color: #ddd;border: 1px solid rgb(85, 85, 85);color: #555;height:19px;width:19px;border-radius:4px;margin-left:<?php $wartosc=($val['product_width_value']-$this->rowProduct['product_width_min'])*226/($this->rowProduct['product_width_max']-$this->rowProduct['product_width_min'])-9-$i; echo$wartosc; ?>px;margin-top:-5px;position:absolute;z-index:9900;"></div></a>
									<?php endforeach;*/ ?>	
									</div>
								</td>
							</tr> 
							<tr id="szerokoscHover2">
								<td colspan="3" style="text-align:right;" class="marginBottomConfig">
									<?php if( $this->ProductFieldnameInfo['product_fieldname_size_widthstand'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_widthstand']; else echo @Lib_Lang::translate(front_configurator_standard2); ?>
									<?php foreach ( $this->ProductWidth as $key => $val ): ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_width_value']; ?>" unit="mm" class="unitElement changeWidth standardSize"><?php echo $val['product_width_value']; ?></a>
									<?php endforeach; ?>	
									
								</td>
							</tr>
							<tr id="glebokoscHover">
								<td width="100px"><?php if( $this->ProductFieldnameInfo['product_fieldname_size_depth'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_depth']; else echo @Lib_Lang::translate(front_configurator_depth); ?>:
								<br/><font class="unitElement" unit=""><?php echo$this->rowProduct['product_depth_min'];?></font>-<font class="unitElement" unit=""><?php echo$this->rowProduct['product_depth_max'];?></font> <font class="unitInfo"></font></td>
								<td width="60px">
								
								<input class="unitInput" type="number" step="1" min="<?php echo$this->rowProduct['product_depth_min'];?>" max="<?php echo$this->rowProduct['product_depth_max'];?>" name="input_depth_view" nF="input_depth" style="depth:60px;" <?php if( $this->rowProduct['product_depth_def_only'] == 1 ) echo' readonly="readonly"'; ?>/>
								
								<input class="unitInputHidden" type="number" step="1" min="<?php echo$this->rowProduct['product_depth_min'];?>" max="<?php echo$this->rowProduct['product_depth_max'];?>" value="<?php echo isset($this->dataSelect['product_depth'])?$this->dataSelect['product_depth']:$this->rowProduct['product_depth_default'];?>" name="input_depth" style="width:60px;" <?php if( $this->rowProduct['product_depth_def_only'] == 1 ) echo' readonly="readonly"'; ?>/>
								
								</td>
								<td>
									<div id="product_depth">
									
									<?php /*$i=0; foreach ( $this->ProductDepth as $key => $val ): $i++; ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_depth_value']; ?>" class="changeDepth"><div style="background-color: #ddd;border: 1px solid rgb(85, 85, 85);color: #555;height:19px;width:19px;border-radius:4px;margin-left:<?php $wartosc=($val['product_depth_value']-$this->rowProduct['product_depth_min'])*226/($this->rowProduct['product_depth_max']-$this->rowProduct['product_depth_min'])-9-$i; echo$wartosc; ?>px;margin-top:-5px;position:absolute;z-index:9900;"></div></a>
									<?php endforeach;*/ ?>	
									</div>
								</td>
							</tr> 
							<tr id="glebokoscHover2">
								<td colspan="3" style="text-align:right;" class="marginBottomConfig">

									<?php if( $this->ProductFieldnameInfo['product_fieldname_size_depthstand'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_depthstand']; else echo @Lib_Lang::translate(front_configurator_standard3); ?>
									<script type="text/javascript" language="javascript">
										$(document).ready(function () {	
											$('.changeDepth').click(function(){
												var t = $(this).attr('cmd');
												$('[name="input_depth"]').val(t);
												$("#product_depth").slider( "value", t );
											//	changeSize();
											});	
										});
									</script>	
									<?php foreach ( $this->ProductDepth as $key => $val ): ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_depth_value']; ?>" unit="mm" class="unitElement changeDepth standardSize"><?php echo $val['product_depth_value']; ?></a>
									<?php endforeach; ?>	
									
								</td>
							</tr>
						</table>
				
				
				
				
				
				
					
				<?php if( $this->rowProduct['product_shelf'] == 1 ){ ?>
				

					<script type="text/javascript" language="javascript">

						$(document).ready(function () {		
						
							function changeShelf(){
								var idProduct = <?php echo$this->idProduct;?>;
								var product_shelfamount = $('[name="input_shelfamount"]').val();
								
								$('a.changeShelfamount > div').css('background-color','#ddd');
								$("a.changeShelfamount[cmd='"+product_shelfamount+"'] > div").css('background-color','none repeat scroll 0 0 rgb(242, 101, 34)');
								
								$('a.changeShelfamount > div').css('display','inline');
								$("a.changeShelfamount[cmd='"+product_shelfamount+"'] > div").css('display','none');
								
								$( "#shopProduct" ).load( "<?php echo $this->url(array('controller' => 'product', 'action' => 'productshop'), 'default', true); ?>", {product_id: idProduct, product_shelfamount: product_shelfamount}, function(){$('#productTable').load( "<?php echo $this->url(array('controller' => 'product', 'action' => 'productshoptable'), 'default', true); ?>", {product_id: <?php echo$this->idProduct; ?>}, function(){} );} );	
								
							}
						
						
							$(function(){	
								var currentValue = $('[name="input_shelfamount"]');	
								
								<?php if( $this->rowProduct['product_shelfamount_def_only'] == 1 ){
									$valMap = '';
									foreach ( $this->ProductShelfamount as $key => $val ):
										$valMap = $valMap.$val['product_shelfamount_value'].',';
									endforeach;
									echo'var valMap = ['.$valMap.'];';
								} ?>
								
								$("#product_shelfamount").slider({ 
									value: <?php echo isset($this->dataSelect['product_shelfamount'])?$this->dataSelect['product_shelfamount']:$this->rowProduct['product_shelfamount_default'];?>,
									max: <?php echo$this->rowProduct['product_shelfamount_max'];?>,
									min: <?php echo$this->rowProduct['product_shelfamount_min'];?>,
									change: function(event, ui) {
										currentValue.val(ui.value);
										changeShelf();
									}
									<?php if( $this->rowProduct['product_shelfamount_def_only'] == 1 ){
										echo',
											slide: function(event, ui) {
												return $.inArray(ui.value, valMap) != -1;
											}';
									} ?>
								});	
							});
							
							$('[name="input_shelfamount"]').change(function(){
								if( $(this).val() < <?php echo$this->rowProduct['product_shelfamount_min'];?> ){
									$(this).val(<?php echo$this->rowProduct['product_shelfamount_min'];?>);
								}
								if( $(this).val() > <?php echo$this->rowProduct['product_shelfamount_max'];?> ){
									$(this).val(<?php echo$this->rowProduct['product_shelfamount_max'];?>);
								}
								$("#product_shelfamount").slider( "value", $(this).val() );
							});
							
							$('#iloscpolekHover, #iloscpolekHover2').hover(function(){
								$('.wizualizacja').hide();
								$('#ilosc_polek').show();
							});
				
							changeShelf();
						});

					</script>	
					
						<h4><?php if( $this->ProductFieldnameInfo['product_fieldname_shelf_top'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_shelf_top']; else echo @Lib_Lang::translate(front_configurator_shelf); ?></h4>
						<table width="100%" class="tr12">
							<tr id="iloscpolekHover">
								<td width="100px"><?php if( $this->ProductFieldnameInfo['product_fieldname_size_shelf'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_shelf']; else echo @Lib_Lang::translate(front_configurator_shelfamount); ?>:
								<br/><?php echo$this->rowProduct['product_shelfamount_min'];?>-<?php echo$this->rowProduct['product_shelfamount_max'];?></td>
								<td width="60px"><input type="number" step="1" min="<?php echo$this->rowProduct['product_shelfamount_min'];?>" max="<?php echo$this->rowProduct['product_shelfamount_max'];?>" value="<?php echo isset($this->dataSelect['product_shelfamount'])?$this->dataSelect['product_shelfamount']:$this->rowProduct['product_shelfamount_default'];?>" name="input_shelfamount" style="width:60px;" <?php if( $this->rowProduct['product_shelfamount_def_only'] == 1 ) echo' readonly="readonly"'; ?>/></td>
								<td>
									<div id="product_shelfamount">
									<script type="text/javascript" language="javascript">
										$(document).ready(function () {	
											$('.changeShelfamount').click(function(){
												var t = $(this).attr('cmd');
												$('[name="input_shelfamount"]').val(t);
												$("#product_shelfamount").slider( "value", t );
											//	changeSize();
											});	
										});
									</script>	
									
									
									<?php /*$i=0; foreach ( $this->ProductShelfamount as $key => $val ): $i++; ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_shelfamount_value']; ?>" class="changeShelfamount"><div style="background-color: #ddd;border: 1px solid rgb(85, 85, 85);color: #555;height:19px;width:19px;border-radius:4px;margin-left:<?php $wartosc=($val['product_shelfamount_value']-$this->rowProduct['product_shelfamount_min'])*226/($this->rowProduct['product_shelfamount_max']-$this->rowProduct['product_shelfamount_min'])-9-$i; echo$wartosc; ?>px;margin-top:-5px;position:absolute;z-index:9900;"></div></a>
									<?php endforeach;*/ ?>
									</div>
								</td>
							</tr> 
							<tr id="iloscpolekHover2">
								<td colspan="3" style="text-align:right;" class="marginBottomConfig">

									<?php if( $this->ProductFieldnameInfo['product_fieldname_size_shelfstand'] != '' ) echo $this->ProductFieldnameInfo['product_fieldname_size_shelfstand']; else echo @Lib_Lang::translate(front_configurator_standard4); ?>
									
									<?php foreach ( $this->ProductShelfamount as $key => $val ): ?>
										<a href="javascript:void(0);" cmd="<?php echo $val['product_shelfamount_value']; ?>" class="changeShelfamount standardSize"><?php echo $val['product_shelfamount_value']; ?></a>
									<?php endforeach; ?>	
									
								</td>
							</tr>
						</table>
				
				<?php } ?>
				
				
				
				
				
				
				
<?php /* Parametry ABCDE - poczatek */ ?>

<?php echo $this->render('product/index_parametr_inc.phtml'); ?>





	
<?php /* Parametry ABCDE - koniec */ ?>
				
				
				
				
				

						</td>
						<td width="210px" align="center" style="background-color:#fff;" class="wizualizacjaBoxTd">
							
<?php

	$cmd = 'height';
	if( $this->rowProduct['product_'.$cmd.'_img'] ){
?>		
							<div class="wizualizacja" id="wysokosc" style=""><img src="<?php echo $this->escape($this->baseUrl); ?>/public/uploads/size/<?php echo$this->rowProduct['product_'.$cmd.'_img']; ?>.jpeg" style="width:180px;" /></div>
<?php
	}

?>
							
<?php

	$cmd = 'width';
	if( $this->rowProduct['product_'.$cmd.'_img'] ){
?>							
							<div class="wizualizacja" id="szerokosc" style="display:none;"><img src="<?php echo $this->escape($this->baseUrl); ?>/public/uploads/size/<?php echo$this->rowProduct['product_'.$cmd.'_img']; ?>.jpeg" style="width:180px;" /></div>
<?php
	}

?>
<?php

	$cmd = 'depth';
	if( $this->rowProduct['product_'.$cmd.'_img'] ){
?>							
							<div class="wizualizacja" id="glebokosc" style="display:none;"><img src="<?php echo $this->escape($this->baseUrl); ?>/public/uploads/size/<?php echo$this->rowProduct['product_'.$cmd.'_img']; ?>.jpeg" style="width:180px;" /></div>
<?php
	}

?>
<?php

	$cmd = 'shelfamount';
	if( $this->rowProduct['product_'.$cmd.'_img'] ){
?>							
							<div class="wizualizacja" id="ilosc_polek" style="display:none;"><img src="<?php echo $this->escape($this->baseUrl); ?>/public/uploads/size/<?php echo$this->rowProduct['product_'.$cmd.'_img']; ?>.jpeg" style="width:180px;" /></div>
<?php
	}

?>
<?php

$lit = array('A','B','C','D','E');
foreach( $lit as $key => $L ){
	$cmd = 'wysszer'.$L.'amount';
	if( $this->rowProduct['product_'.$cmd.'_img'] ){
?>							
							<div class="wizualizacja" id="wysszer<?php echo$L;?>" style="display:none;"><img src="<?php echo $this->escape($this->baseUrl); ?>/public/uploads/size/<?php echo$this->rowProduct['product_'.$cmd.'_img']; ?>.jpeg" style="width:180px;" /></div>
<?php
	}
}
?>
<?php
/*
	$cmd = 'wysszerBamount';
	if( $this->rowProduct['product_'.$cmd.'_img'] ){
?>							
							<div class="wizualizacja" id="wbb" style="display:none;"><img src="<?php echo $this->escape($this->baseUrl); ?>/public/uploads/size/<?php echo$this->rowProduct['product_'.$cmd.'_img']; ?>.jpeg" style="width:180px;" /></div>
<?php
	}
*/
?>
						
						</td>
						</tr>
					</table>
				
					</div>
				

				</div>