<!doctype html>
<html  {$html_attrs}>
	<head>
		<title>{$pagetitle}</title>
		<meta http-equiv="X-UA-Compatible" content="IE=7">
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
		<link REL="stylesheet" href="styles/default.css" type="text/css">
		{BEGIN rtlCSS}
		<link REL="stylesheet" href="styles/defaultRTL.css" type="text/css">
		{END rtlCSS}
		{BEGIN styleCSSFiles}
		<link REL="stylesheet" href="{$stylepath}" type="text/css">
		{END styleCSSFiles}
		{BEGIN pageCSSFiles}
		<link REL="stylesheet" href="{$pagestylepath}" type="text/css">
		{END pageCSSFiles}
		<!--[if IE]>
			<link REL="stylesheet" href="styles/defaultIE.css" type="text/css">
			{BEGIN IEcssFiles}
			<link REL="stylesheet" href="{$stylepathIE}" type="text/css">
			{END IEcssFiles}
		<![endif]-->
	</head>
	
	<body class="{$stylename}" {$bodyattrs}>
	{BEGIN body}
		{$header}
		<table   cellpadding="0" class="runner-toptable">
			<tr class="runner-header">
				<td class="runner-top" colspan=3>
					

{BEGIN container_toplinks}
<table class="runner-c runner-c-toplinks" cellpadding="0" >
<tr class="{$cheaderclass_toplinks}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
<tr class="runner-row style1">
<td class="runner-cl"></td>
<td class="runner-cc">
<table border="0" cellpadding="0" class="runner-hc">
<tr>
<td class="runner-cc filler"></td>
{BEGIN prints_block}
<td  class="runner-cc runner-br runner-b-toplinks_print" {$brickclass_toplinks_print}><span>{BEGIN print_link}
	<span class="runner-btnframe">
	<span class="runner-btnleft"></span>
	<span class="runner-btnright"></span>
	<a href="#" class="runner-button" {$printlink_attrs}>Impresora versión amigable</a>
	</span>
{END print_link}

{BEGIN printall_link}
	<span class="runner-btnframe">
	<span class="runner-btnleft"></span>
	<span class="runner-btnright"></span>
	<a href="#" class="runner-button" {$printalllink_attrs}>Imprimir el informe entero</a>
	</span>
{END printall_link}




</span></td>
{END prints_block}


{BEGIN asearch_link}
<td  class="runner-cc runner-br runner-b-toplinks_advsearch" {$brickclass_toplinks_advsearch}><span>	<span class="runner-btnframe">
	<span class="runner-btnleft"></span>
	<span class="runner-btnright"></span>
	<a href="#" class="runner-button" {$advsearchlink_attrs}>Búsqueda avanzada</a>
	</span>
</span></td>
{END asearch_link}




{BEGIN export_link}
<td  class="runner-cc runner-br runner-b-toplinks_export_links" {$brickclass_toplinks_export_links}><span>	<span id="export_links{$id}">
		<a href="#" {$excellink_attrs}><img alt="Exportar a Excel" src="images/excel.gif" border="0"></a>
		<a href="#" {$wordlink_attrs}><img alt="Exportar a Word " src="images/word.gif" border="0" ></a>
		</span>
</span></td>
{END export_link}


</tr>
</table></td>
<td class="runner-cr"></td>
</tr>

<tr class="{$cfooterclass_toplinks}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
</table>
{END container_toplinks}



{BEGIN container_search}
<table class="runner-c runner-c-search" cellpadding="0" >
<tr class="{$cheaderclass_search}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
<tr class="runner-row style1">
<td class="runner-cl"></td>
<td class="runner-cc">
<table border="0" cellpadding="0" class="runner-hc">
<tr>

{BEGIN searchform_block}
<td  class="runner-cc runner-bl runner-b-search" {$brickclass_search}><span>	<span>
		{BEGIN searchform_text}
		<input type="text" {$searchfor_attrs} size="25">
		{END searchform_text}
		&nbsp;
		{BEGIN searchform_search}
		<span class="runner-btnframe">
			<span class="runner-btnleft"></span>
			<span class="runner-btnright"></span>
			<a href="#" class="runner-button-img" {$searchbutton_attrs}><img src="images/search/search.gif"></a>
		</span>
		{END searchform_search}
		&nbsp;
		{BEGIN searchform_showall}
		
		<span class="runner-btnframe" {$showAllCont_attrs}>
			<span class="runner-btnleft"></span>
			<span class="runner-btnright"></span>
			<a href="#" class="runner-button" {$showallbutton_attrs}>Mostrar todo</a>
		</span>
		{END searchform_showall}
	</span>
</span></td>
{END searchform_block}


{BEGIN searchformbuttons_block}
<td  class="runner-cc runner-bl runner-b-search_buttons" {$brickclass_search_buttons}><span>	{BEGIN searchPanelTopButtons}
	<span>
		&nbsp;
		<span class="runner-btnframe">
		<span class="runner-btnleft"></span>
		<span class="runner-btnright"></span>
		<a href="#" class="runner-button-img" id="showSrchWin{$id}" {$showHideSearchWin_attrs}><img src="images/search/showWindowPin.gif"></a>
		</span>
		&nbsp;		
		<span class="runner-btnframe">
		<span class="runner-btnleft"></span>
		<span class="runner-btnright"></span>
		<a href="#" class="runner-button-img" id="showOptPanel{$id}" {$showHideSearchPanel_attrs}><img src="images/search/showOptions.gif"></a>
		</span>
	</span>
	{END searchPanelTopButtons}
</span></td>
{END searchformbuttons_block}

<td class="runner-cc filler"></td>
{BEGIN details_block}
<td  class="runner-cc runner-br runner-b-details_found" {$brickclass_details_found}><span>	<span {$details_attrs}>
		Detalles encontrados: <b><span class="runner-details_found_count">{$records_found}</span></b>
	</span>
</span></td>
{END details_block}


{BEGIN pages_block}
<td  class="runner-cc runner-br runner-b-page_of" {$brickclass_page_of}><span>	<span {$pages_attrs}>
		Página <b>{$page}</b> / <b>{$maxpages}</b>
	</span>

</span></td>
{END pages_block}


{BEGIN recordspp_block}
<td  class="runner-cc runner-br runner-b-recsperpage" {$brickclass_recsperpage}><span>	<span id="recordspp_block{$id}" name="recordspp_block{$id}">
			Grupos por página:&nbsp;{$grpsPerPage}
	</span>	
</span></td>
{END recordspp_block}


</tr>
</table></td>
<td class="runner-cr"></td>
</tr>

<tr class="{$cfooterclass_search}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
</table>
{END container_search}


				</td>
			</tr>
			<tr class="runner-body">
				
				<td class="runner-left {$blockclass_left}" >
					

{BEGIN container_left}
<table class="runner-c runner-c-left" cellpadding="0" >
<tr class="{$cheaderclass_left}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>


{BEGIN security_block}
<tr  class="runner-row style1 runner-b-loggedas {$brickclass_loggedas}"><td class="runner-cl"></td><td class="runner-cc runner-brickcontents" ><div id="login_block{$id}">
	{BEGIN loggedas_message}
	<span>Conectado como&nbsp;<b>{$username}</b><br><br>
	</span>
	{END loggedas_message}
	{BEGIN guestloginbutton}
	<span class="runner-btnframe">
	<span class="runner-btnleft"></span>
	<span class="runner-btnright"></span>
	<a href="#" class="runner-button" {$guestloginlink_attrs}>Conectar</a>
	</span>
	{END guestloginbutton}
	{BEGIN logoutbutton}
	<span class="runner-btnframe">
	<span class="runner-btnleft"></span>
	<span class="runner-btnright"></span>
	<a class="runner-button" href="login.php?a=logout" {$logoutlink_attrs}>Desconectarse</a>
	</span>
	{END logoutbutton}
<!-- Permissions -->
   {BEGIN adminarea_link}
<div>
	<span class="runner-btnframe">
	<span class="runner-btnleft"></span>
	<span class="runner-btnright"></span>
	<a class="runner-button" href="admin_rights_list.php" {$adminarealink_attrs}>Area Admin</a>
	</span>
</div>
  {END adminarea_link}
{BEGIN changepwd_link}
<div>
	<span class="runner-btnframe">
	<span class="runner-btnleft"></span>
	<span class="runner-btnright"></span>
	<a class="runner-button" href="changepwd.php" {$changepwdlink_attrs}>Cambiar contraseña</a>
	</span>
</div>
{END changepwd_link}
</div>
</td><td class="runner-cr"></td></tr>{END security_block}


{BEGIN menu_block}
{$mainmenu}
{END menu_block}


{BEGIN searchPanel}
<tr  class="runner-row style1 runner-b-searchpanel {$brickclass_searchpanel}"><td class="runner-cl"></td><td class="runner-cc runner-brickcontents" ><div class="searchPanelContainer">
{$adv_search_panel}
</div></td><td class="runner-cr"></td></tr>{END searchPanel}


<tr class="{$cfooterclass_left}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
</table>
{END container_left}


				</td>	
				
				<td class="runner-center {$blockclass_center}">
					

{BEGIN container_message}
<table class="runner-c runner-c-message" cellpadding="0" >
<tr class="{$cheaderclass_message}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
<tr class="runner-row style1">
<td class="runner-cl"></td>
<td class="runner-cc">
<table border="0" cellpadding="0" class="runner-hc">
<tr>

{BEGIN message_block}
<td  class="runner-cc runner-bc runner-b-message" {$brickclass_message}><span><div class="runner-message">{$message}</div></span></td>
{END message_block}


</tr>
</table></td>
<td class="runner-cr"></td>
</tr>

<tr class="{$cfooterclass_message}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
</table>
{END container_message}



{BEGIN container_grid}



			<style>
table.report {border-collapse: collapse} 
table.report td {padding: 2px;border-width: 1px; border-style: solid; border-color: #cccccc;}
div.page_block{clear:left;}
td.noborder{padding-right:8px}
td.data{padding-right:8px}
td.group_1{background-color: #90EE90;padding-right:8px}
td.group_2{background-color: #FFFFFF;padding-right:8px}
td.group_3{background-color: #FFFFFF;padding-right:8px}
td.group_4{background-color: #FFFFFF;padding-right:8px}
td.group_5{background-color: #FFFFFF;padding-right:8px}
td.group_6{background-color: #FFFFFF;padding-right:8px}
td.group_7{background-color: #FFFFFF;padding-right:8px}
td.nbgroup_1{background-color: #90EE90;border-style:none;padding-right:8px}
td.nbgroup_2{background-color: #FFFFFF;border-style:none;padding-right:8px}
td.nbgroup_3{background-color: #FFFFFF;border-style:none;padding-right:8px}
td.nbgroup_4{background-color: #FFFFFF;border-style:none;padding-right:8px}
td.nbgroup_5{background-color: #FFFFFF;border-style:none;padding-right:8px}
td.nbgroup_6{background-color: #FFFFFF;border-style:none;padding-right:8px}
td.nbgroup_7{background-color: #FFFFFF;border-style:none;padding-right:8px}
td.header_1{background-color: #7ACA7A;padding-right:8px}
td.header_2{background-color: #D8D8D8;padding-right:8px}
td.header_3{background-color: #D8D8D8;padding-right:8px}
td.header_4{background-color: #D8D8D8;padding-right:8px}
td.header_5{background-color: #D8D8D8;padding-right:8px}
td.header_6{background-color: #D8D8D8;padding-right:8px}
td.header_7{background-color: #D8D8D8;padding-right:8px}
td.pagesummary{background-color:#ffffbb;}
td.globalsummary{background-color:#ffe0b0;}
</style>
<TABLE CELLPADDING=5 CELLSPACING=0 BORDER=0 class="runner-b-report">
	<tr class="runner-toprow style1">
		<td class="runner-cl"><img src="images/spacer.gif"/></td>
		<td class="runner-cc"></td>
		<td class="runner-cr"><img src="images/spacer.gif"/></td>
	</tr>
	<tr class="runner-row style1">
		<td class="runner-cl"></td>
		<td class="runner-cc">
			<table cellspacing=0 cellpadding=0 border=0 style="padding:2px">
				{BEGIN grid_row}
				<!-------------------------------------  group headers ----------------------------------------->
				{BEGIN idventa_newgroup}
				<tr>
				<td class=header_1 colspan=15>
				Nº Venta:&nbsp;
				<font style="font-weight:900">{$idventa_grval}</font></td>
				</tr>
								{END idventa_newgroup}
				{BEGIN fecha_newgroup}
				<tr>
				<td class=group_1>&nbsp;</td>
				<td class=header_2 colspan=14>
				Fecha:&nbsp;
				<font style="font-weight:900">{$fecha_grval}</font></td>
				</tr>
								{END fecha_newgroup}
				{BEGIN cliente_newgroup}
				<tr>
				<td class=group_1>&nbsp;</td>
				<td class=group_2>&nbsp;</td>
				<td class=header_3 colspan=13>
				Cliente:&nbsp;
				<font style="font-weight:900">{$cliente_grval}</font></td>
				</tr>
								{END cliente_newgroup}
				{BEGIN observacion_newgroup}
				<tr>
				<td class=group_1>&nbsp;</td>
				<td class=group_2>&nbsp;</td>
				<td class=group_3>&nbsp;</td>
				<td class=header_4 colspan=12>
				Observación:&nbsp;
				<font style="font-weight:900">{$observacion_grval}</font></td>
				</tr>
								{END observacion_newgroup}
				{BEGIN cobrada_newgroup}
				<tr>
				<td class=group_1>&nbsp;</td>
				<td class=group_2>&nbsp;</td>
				<td class=group_3>&nbsp;</td>
				<td class=group_4>&nbsp;</td>
				<td class=header_5 colspan=11>
				Cobrada:&nbsp;
				<font style="font-weight:900">{$cobrada_grval}</font></td>
				</tr>
								{END cobrada_newgroup}
				{BEGIN total_venta_newgroup}
				<tr>
				<td class=group_1>&nbsp;</td>
				<td class=group_2>&nbsp;</td>
				<td class=group_3>&nbsp;</td>
				<td class=group_4>&nbsp;</td>
				<td class=group_5>&nbsp;</td>
				<td class=header_6 colspan=10>
				Total Venta:&nbsp;
				<font style="font-weight:900">{$total_venta_grval}</font></td>
				</tr>
								{END total_venta_newgroup}
				{BEGIN total_cobro_newgroup}
				<tr>
				<td class=group_1>&nbsp;</td>
				<td class=group_2>&nbsp;</td>
				<td class=group_3>&nbsp;</td>
				<td class=group_4>&nbsp;</td>
				<td class=group_5>&nbsp;</td>
				<td class=group_6>&nbsp;</td>
				<td class=header_7 colspan=9>
				Total Cobro:&nbsp;
				<font style="font-weight:900">{$total_cobro_grval}</font></td>
				</tr>
								<tr>
				<td class=group_1>&nbsp;</td>
				<td class=group_2>&nbsp;</td>
				<td class=group_3>&nbsp;</td>
				<td class=group_4>&nbsp;</td>
				<td class=group_5>&nbsp;</td>
				<td class=group_6>&nbsp;</td>
				<td class=group_7>&nbsp;</td>
				<td class=blackshade>Artículo</td>
				<td class=blackshade>Costo</td>
				<td class=blackshade>Precio</td>
				<td class=blackshade>Cantidad</td>
				<td class=blackshade>Importe</td>
				<td class=blackshade>Sub Total</td>
				<td class=blackshade>Descuento</td>
				<td class=blackshade>Ganancia</td>
				</tr>
				{END total_cobro_newgroup}
								<!-------------------------------------  data ----------------------------------------->
				{BEGIN row_data}
				<tr>
											<td class=group_1>&nbsp;</td>
											<td class=group_2>&nbsp;</td>
											<td class=group_3>&nbsp;</td>
											<td class=group_4>&nbsp;</td>
											<td class=group_5>&nbsp;</td>
											<td class=group_6>&nbsp;</td>
											<td class=group_7>&nbsp;</td>
					<td class=data>{$idarticulo_value}</td>
					<td class=data>{$costo_value}</td>
					<td class=data>{$precio_value}</td>
					<td class=data>{$cantidad_value}</td>
					<td class=data>{$importe_value}</td>
					<td class=data>{$subtotal_value}</td>
					<td class=data>{$descuento_value}</td>
					<td class=data>{$ganancia_value}</td>
				</tr>
				{END row_data}
				<!-------------------------------------  group summary ----------------------------------------->
																																{BEGIN idventa_endgroup}
				<tr>
					<td class=group_1 colspan=15 >
					Resumen de Nº Venta {$idventa_grval}
					 - {$groupidventa_total_cnt} Registros totales</div></td>
				</tr>
								<!--  Sum -->
				<tr>
											<td class=group_1 style="border-left: solid black 1px;">Sum</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>{$groupidventa_totalcosto_sum}</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>&nbsp;</td>
											<td class=group_1>{$groupidventa_totalimporte_sum}</td>
											<td class=group_1>{$groupidventa_totalsubtotal_sum}</td>
											<td class=group_1>{$groupidventa_totaldescuento_sum}</td>
											<td class=group_1>{$groupidventa_totalganancia_sum}</td>
				</tr>	
																{END idventa_endgroup}
				{END grid_row}
			</table>
		</td>
		<td class="runner-cr"></td>
	</tr>
	<tr class="runner-row style1">
		<td class="runner-cl"></td>
		<td class="runner-cc">
			<table cellspacing=0 cellpadding=0 border=0>
								<tr>
				<td class=blackshade>Nº Venta</td>
				<td class=blackshade>Fecha</td>
				<td class=blackshade>Cliente</td>
				<td class=blackshade>Observación</td>
				<td class=blackshade>Cobrada</td>
				<td class=blackshade>Total Venta</td>
				<td class=blackshade>Total Cobro</td>
				<td class=blackshade>Artículo</td>
				<td class=blackshade>Costo</td>
				<td class=blackshade>Precio</td>
				<td class=blackshade>Cantidad</td>
				<td class=blackshade>Importe</td>
				<td class=blackshade>Sub Total</td>
				<td class=blackshade>Descuento</td>
				<td class=blackshade>Ganancia</td>
				</tr>
								<!--------------------------------------page summary-------------------------------------------->
				<tr>
					<td class=pagesummary colspan=15>Resumen de la pagina 
					 {$page_total_cnt} - Registros totales</td>
				</tr>
								<!--  Sum -->
				<tr>
											<td class=pagesummary>Sum</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>{$page_totalcosto_sum}</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>&nbsp;</td>
											<td class=pagesummary>{$page_totalimporte_sum}</td>
											<td class=pagesummary>{$page_totalsubtotal_sum}</td>
											<td class=pagesummary>{$page_totaldescuento_sum}</td>
											<td class=pagesummary>{$page_totalganancia_sum}</td>
				</tr>	
																				<!--------------------------------------global summary-------------------------------------------->
				<tr>
					<td class=globalsummary colspan=15>Resumen global 
					 {$global_total_cnt} - Registros totales</td>
				</tr>
								<!--  Sum -->
				<tr>
											<td class=globalsummary>Sum</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>{$global_totalcosto_sum}</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>&nbsp;</td>
											<td class=globalsummary>{$global_totalimporte_sum}</td>
											<td class=globalsummary>{$global_totalsubtotal_sum}</td>
											<td class=globalsummary>{$global_totaldescuento_sum}</td>
											<td class=globalsummary>{$global_totalganancia_sum}</td>
				</tr>	
																</table>
			</td>
		<td class="runner-cr"></td>
	</tr>
	<tr class="runner-bottomrow style1">
		<td class="runner-cl"><img src="images/spacer.gif"/></td>
		<td class="runner-cc"></td>
		<td class="runner-cr"><img src="images/spacer.gif"/></td>
	</tr>
</table>







{END container_grid}



{BEGIN container_pagination}
<table class="runner-c runner-c-pagination" cellpadding="0" >
<tr class="{$cheaderclass_pagination}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
<tr class="runner-row style1">
<td class="runner-cl"></td>
<td class="runner-cc">
<table border="0" cellpadding="0" class="runner-hc">
<tr>

{BEGIN pagination_block}
<td  class="runner-cc runner-bc runner-b-pagination" {$brickclass_pagination}><span>{$pagination}</span></td>
{END pagination_block}


</tr>
</table></td>
<td class="runner-cr"></td>
</tr>

<tr class="{$cfooterclass_pagination}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
</table>
{END container_pagination}



{BEGIN container_form}
<table class="runner-c runner-c-form" cellpadding="0" >
<tr class="{$cheaderclass_form}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
<tr class="runner-row style1">
<td class="runner-cl"></td>
<td class="runner-cc">
<table border="0" cellpadding="0" class="runner-hc">
<tr>


<td  class="runner-cc runner-bl runner-b-reportvariable" {$brickclass_reportvariable}><span>{$report_filename}</span></td>


<td class="runner-cc filler"></td>
</tr>
</table></td>
<td class="runner-cr"></td>
</tr>

<tr class="{$cfooterclass_form}">
<td class="runner-cl"><img src="images/spacer.gif"></td>
<td class="runner-cc"></td><td class="runner-cr"><img src="images/spacer.gif"></td>
</tr>
</table>
{END container_form}


				</td>	

				<td class="runner-right {$blockclass_right}">
					
				</td>	
			</tr>
			<tr class="runner-footer">
				<td class="runner-bottom" colspan=3>
					<!--%%bottom%%-->
				</td>
			</tr>
		</table>
		{$footer}
	{END body}
	</body>
</html>
