<!--	Loja Perfeita		-->
<?php
	$dir = $_SERVER['DOCUMENT_ROOT']."/".substr(substr($_SERVER['REQUEST_URI'], 1), 0, strpos(substr($_SERVER['REQUEST_URI'], 1), '/'))."/phone_gap/";
	require_once($dir."/classes/Dados.class.php");
	require_once($dir."/dao/ConfigDAO.class.php");
	$dados = new Dados();
	
	$configdao = new ConfigDAO();
	//$exibirData= $configdao->getDisponibilizar()->getData_rel_vendas();

	echo '<script src="lojaperfeita/lojaperfeita.js?ver='.$dados->getVersao().'"></script>';
?>
<div data-role="page" data-theme="b" data-control-title="Loja Perfeita" id="lojaperfeita" class="loading-show loading-hide mobipicker verifica-login">
	<div  data-role="header" data-position="fixed">
		<h3>
			Loja Perfeita
		</h3>
		<a href="#home" id="botaovoltarlojaperfeita" data-role="button" data-direction="reverse" data-transition="slide" class="ui-btn ui-shadow ui-corner-all ui-btn-icon-left ui-icon-back">
			Voltar
		</a>
	</div>
	<div data-role="content" class="conteudo">
		<div data-role="fieldcontain" data-controltype="dateinput">
			<label for="datainilojaperfeita">
				De:
			</label>
			<input class="mobipick" id="datainilojaperfeita" value='<?php echo date('Y-m-01'); ?>' type="text">
		</div>
		<div data-role="fieldcontain" data-controltype="dateinput">
			<label for="datafinlojaperfeita">
				Até:
			</label>
			<input class="mobipick" id="datafinlojaperfeita" value='<?php echo date('Y-m-t'); ?>' type="text">
		</div>
		
		<div data-role="fieldcontain" data-controltype="selectmenu">
			<label for="filtrogerentelp">Gerente: </label>
			<select id="filtrogerentelp" name="" class="filtro" ></select>
		</div>
		<div data-role="fieldcontain" data-controltype="selectmenu">
			<label for="filtrosupervisorlp">Supervisor: </label>
			<select id="filtrosupervisorlp" name="" class="filtro" ></select>
		</div>
		<div data-role="fieldcontain" data-controltype="selectmenu">
			<label for="filtrovendedorlp">Vendedor: </label>
			<select id="filtrovendedorlp" name="" class="filtro" ></select>
		</div>	
		<div data-role="fieldcontain">
			<label for="filtroclientelp">Cliente: </label>
			<form class="ui-filterable">
				<input type="hidden" id="codfiltroclientelp" value="">
				<input id="filtroclientelp" data-type="search" placeholder="Escolha um cliente">
				<ul id="autocomplete-filtroclientelp" data-role="listview", data-inset="true" data-filter="true" data-input="#filtroclientelp"></ul>
			</form>
		</div>
		<div data-role="fieldcontain" data-controltype="selectmenu">
			<label for="filtrosegmentolp">Segmento: </label>
			<select id="filtrosegmentolp" name="" class="filtro" ></select>
		</div>		
		
		<div data-role="fieldcontain" data-controltype="selectmenu">
			<label for="lojaperfeitalp">Loja Perfeita:</label>

			<select id="lojaperfeitalp" class="gambito" name="" >
				<option value="T">Todos</option>
				<option value="S">Sim</option>
				<option value="N">Não</option>
			</select>
		</div>
		<a id="botaovisualizarlojaperfeita" data-role="button" data-transition="slide"  data-icon="arrow-r" data-iconpos="right" href="#rellojaperfeita">
			Visualizar
		</a>
	</div>
</div>

<!--	VISUALIZAR Loja Perfeita	-->
<div data-role="page" data-theme="b" data-control-title="Home"  id="rellojaperfeita" class="loading-show verifica-login">
	<div  data-role="header" data-position="fixed" data-position="fixed">
		<h3 class="ui-title" role="heading" aria-level="1">
			Loja Perfeita
		</h3>
		<a href="#lojaperfeita" data-role="button" data-direction="reverse"  data-transition="slide" class="ui-btn ui-shadow ui-corner-all ui-btn-icon-left ui-icon-back" id="voltarrellojaperfeita">
			Voltar
		</a>
		<!--<a data-role="button"  class="ui-btn ui-shadow ui-corner-all ui-btn-icon-right ui-icon-action" id="btimprimirvendas" class="imprimir">
			Imprimir
		</a>-->
	</div>
	<div data-role="content" id='divtabelalojaperfeita' class="conteudo">
		<table data-role="table" id="tabelarellojaperfeita" data-mode="columntoggle" class="ui-body-d ui-shadow table-stripe ui-responsive" data-column-btn-theme="b" data-column-btn-text="Colunas" data-column-popup-theme="b" style="text-align: center;">
			<thead>
			  <tr class="ui-bar-d">
				<th data-priority="1" style="text-align: left;">Data</th>
				<th data-priority="1" id="colmostarporlojaperfeita"  style="text-align: left;">Cliente</th>
				<th data-priority="1">PDV</th>
				<th data-priority="1">MIX</th>
				<th data-priority="1">Loja Perfeita</th>
			  </tr>
			</thead>
			<tbody>

			</tbody>
		</table>
	</div>
</div>