{{function page_tree aPageTree=[] bMenu=true}}{{if $bMenu && isset($aPageTree.sMenu)}}{{$aPageTree.sMenu}}&nbsp;&raquo;&nbsp;{{/if}}{{foreach from=$aPageTree.aPath item=aPage}}{{$aPage.sName}}&nbsp;&raquo;&nbsp;{{/foreach}}{{/function}}
<table class="list">
	<thead>
		<tr>
			<th class="id">{{$lang.smartoffer_id}}</th>
			<th class="photo">{{$lang.Photo}}</th>
			<th class="name">{{$lang.smartoffer_name}}</th>
			<th class="smartoffer">{{$lang.smartoffer_price}}<br/>{{$lang.smartoffer_current}} / {{$lang.smartoffer_seen}}</th>
			<th class="smartoffer">{{$lang.smartoffer_avail}}<br/>{{$lang.smartoffer_current}}<br/>{{$lang.smartoffer_seen}}</th>
		</tr>
	</thead>
	{{$iCurrentTime = 0}}
	{{foreach from=$aSmartoffer.aCompare item=SOaProduct}}
		{{if abs( $SOaProduct.iTime - $iCurrentTime ) > 5}}{{$iCurrentTime = $SOaProduct.iTime}}
		<tr>
			<td colspan="5">{{$lang.smartoffer_time}}: {{date( 'Y-m-d H:i:s', $SOaProduct.iTime )}}<br/>{{$lang.smartoffer_time_ago}}: {{$SOaProduct.sTimeDifference}}</th>
		</tr>
		{{/if}}
		<tr {{if $SOaProduct.fCurrentPrice < ( $SOaProduct.fOldPrice - 0.01 ) || $SOaProduct.TiAvailable < $SOaProduct.iAvailable}}class="modified"{{/if}}>
			<td class="id">{{$SOaProduct.iProduct}}</td>
			<td class="photo">{{if isset( $SOaProduct.aDataImage )}}<a href="{{$config.dir_files}}{{$SOaProduct.aDataImage.sFileName}}" class="photo"><img src="{{$config.dir_files}}30/{{$SOaProduct.aDataImage.sFileName}}" alt="(f)"/></a>{{/if}}</td>
			<td class="name">{{page_tree aPageTree=$SOaProduct.aPageTree}}<strong>{{$SOaProduct.sName}}</strong></td>
			<td class="smartoffer">{{number_format( $SOaProduct.fCurrentPrice, 2, '.', '' )}} / {{number_format( $SOaProduct.fOldPrice, 2, '.', '' )}}</td>
			<td class="available smartoffer">{{$aSmartoffer.aAvailabilities[$SOaProduct.TiAvailable]}}<br/>{{$aSmartoffer.aAvailabilities[$SOaProduct.iAvailable]}}</td>
		</tr>
	{{/foreach}}
	<tr class="legend"><td colspan="5">{{$lang.smartoffer_legend}}</td></tr>
	<tr class="legend"><td colspan="5"><div></div>{{$lang.smartoffer_legend_products_white}}</td></tr>
	<tr class="legend modified"><td colspan="5"><div></div>{{$lang.smartoffer_legend_products_green}}</td></tr>
</table>