					</div>
				</main>
				<footer class="mt-3 footer-color" style="padding: 12px;">
					<div class="container-fluid">
						<div class="align-items-center justify-content-between text-center">
							<div class="text-muted" style="line-height: 20px;">
								Desenvolvido por SoftSolution | Copyright © <?php echo SYS_NAME." ".date("Y"); ?>
							</div>
						</div>
					</div>
				</footer>
			</div>
		</div>

		<script src="<?php echo show_file_link("/assets/bootstrap/js/bootstrap.bundle.min.js"); ?>"></script>
		<script src="<?php echo show_file_link("/assets/custom/js/scripts.js"); ?>"></script>
		<script src="<?php echo show_file_link("/assets/jquery-loading-overlay/loading-overlay.js"); ?>"></script>
		<script src="<?php echo show_file_link("/assets/ckeditor/config.js"); ?>"></script>

		<script>
			<?php if (!isset($loading) or $loading == true): ?>
				$(document).ajaxStart(function(){
					$.LoadingOverlay("show", {
						fontawesome : "",
						image: "<?php echo show_file_link("/assets/img/loading.svg"); ?>"
					});
				});

				$(document).ajaxStop(function(){
					$.LoadingOverlay("hide");
				});

				$(".loadAjax").on("click", function(){
					$.LoadingOverlay("show", {
						fontawesome : "",
						image: "<?php echo show_file_link("/assets/img/loading.svg"); ?>"
					});
				});

				$("body").on("click", ".loadAjax", function(){
					$.LoadingOverlay("show", {
						fontawesome : "",
						image: "<?php echo show_file_link("/assets/img/loading.svg"); ?>"
					});
				});
			<?php endif; ?>
			
			$(function(){
				if ($_GET("cadastro") == "true") {
					$.toast({
						heading: "Aviso",
						text: "Dados Cadastrados com Sucesso!",
						icon: "success",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}
				else if ($_GET("cadastro") == "false") {
					$.toast({
						heading: "Aviso",
						text: "Erro ao Cadastrar os Dados!",
						icon: "error",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}

				if ($_GET("editar") == "true") {
					$.toast({
						heading: "Aviso",
						text: "Dados Editados com Sucesso!",
						icon: "success",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}
				else if ($_GET("editar") == "false") {
					$.toast({
						heading: "Aviso",
						text: "Erro ao Editar os Dados!",
						icon: "error",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}

				if ($_GET("excluir") == "true") {
					$.toast({
						heading: "Aviso",
						text: "Dados Excluido com Sucesso!",
						icon: "success",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}
				else if ($_GET("excluir") == "false") {
					$.toast({
						heading: "Aviso",
						text: "Erro ao Excluir os Dados!",
						icon: "error",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}

				if ($_GET("status") == "true") {
					$.toast({
						heading: "Aviso",
						text: "Sucesso!",
						icon: "success",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}
				else if ($_GET("status") == "false") {
					$.toast({
						heading: "Aviso",
						text: "Erro!",
						icon: "error",
						loader: true
					});
					window.history.pushState("", "", "<?php echo show_link(); ?>");
				}

				$(window).keydown(function(event){
					if(event.keyCode == 13) {
						event.preventDefault();
					}
				});

				if (window.active_page != "") {
					$(`a[data-active-page="${window.active_page}"]`).addClass("selected");
				}

				$("[data-toggle='tooltip']").tooltip();
				$("[data-toggle='popover']").popover();

				$(".valor-monetario").mask("000.000.000.000.000,00", {reverse: true});
				$(".data").mask("00/00/0000");
				$(".data-hora").mask("00/00/0000 00:00:00");
				$(".cpf").mask("000.000.000-00", {reverse: true});
				$(".cnpj").mask("00.000.000/0000-00", {reverse: true});
				$(".telefone-fixo").mask("(00) 0000-0000");
				$(".telefone-celular").mask("(00) 00000-0000");

				$("#btn-dropdown-user").click();
			});
		</script>
	</body>
</html>