quitando el rebote de los formularios #191

Merged
humano merged 22 commits from h4ckypurpl3/tupali_fork:master into master 2019-03-25 23:20:30 +00:00
2 changed files with 119 additions and 17 deletions
Showing only changes of commit 70f1f6d103 - Show all commits

120
index.php
View File

@ -6,9 +6,12 @@
$xajax = new xajax("");
//$xajax = new xajax("https://tupale.co/index.php");
require ("milfs/funciones/conex.php");
include ('milfs/librerias/parsedown/Parsedown.php');
require ('milfs/funciones/funciones.php');
include ('milfs/addon/funciones.php');
require ("milfs/includes/markdown.php");
// require ("milfs/includes/markdown.php");
require ("milfs/includes/parametrizacion.php");
require ("milfs/includes/simple_html_dom.php");
$xajax->processRequests();
@ -90,8 +93,8 @@ $librerias_pie ="";
/// m = checklist
/// n=notas
/// o=parallax
/// p= Planilla
/// q = lab
/// s= SET DE DATOS *
/// S= SET DE DATOS EMBEBIDO
@ -128,6 +131,9 @@ if ($v[0] =='e') {
// $onload = "<script type=\"text/javascript\">window.location.href='$vista_favorita';</script> ";
if($vista_favorita[0] !=""){
$variable = $vista_favorita;//"e".$_REQUEST['empresa'];
}else{
$variable= "$v[0]$v[1]";
}
}
}
@ -330,7 +336,11 @@ if ($variable !=''){
elseif($v[0] =='p') {
$set =$v[1];
$form =$v[1];
$librerias_cabeza='
<link rel="stylesheet" type="text/css" href="librerias/datatables/datatables.css">
<script type="text/javascript" charset="utf8" src="librerias/datatables/datatables.js"></script>
';
$empresa = remplacetas('form_id','id',$form,'id_empresa',"") ;
$razon_social_portal = remplacetas('empresa','id',"$empresa[0]",'razon_social','') ;
$titulo = remplacetas('empresa','id',"$empresa[0]",'razon_social','') ;
@ -338,7 +348,9 @@ if ($variable !=''){
/// s= SET DE DATOS
$embebido = "1";
if(isset($_REQUEST['print'])) { $print = "window.print()";}
$onload = "".planilla("$set","$_REQUEST[registros]",'')." <script type=\"text/javascript\">$print</script> ";
$onload = "".planilla("$set","$_REQUEST[registros]",'')." <script type=\"text/javascript\">$print</script>
";
}
elseif($v[0] =='i') {
@ -659,6 +671,90 @@ if('serviceWorker' in navigator) {
";
$onload = vista_aplicacion($form);
}elseif($v[0] =='q') {
$form =$v[1];
if($form==""){$form='0';}
$embebido = "1";
$no_mostrar ="display:none; ";
$librerias_galeria ="
<!-- <link rel='manifest' href='manifest.json'> -->
<link rel='stylesheet' type='text/css' href='librerias/slick/slick.css'>
<link rel='stylesheet' type='text/css' href='librerias/slick/slick-theme.css'>
<link rel='stylesheet' type='text/css' href='librerias/slick/style.css'>
<script src='manup.js'></script>
";
$registros=1;
$registros_pagina=5;
$plantilla="landingpage";
$librerias_cabeza ="
<style>
img { display: block;
max-width: 100%;
height: auto;}
.control_planilla{
display:none
}
</style>
$librerias_galeria
";
$librerias_pie ="
<script type = 'text/javascript' >
$(document).ready(function() {
loadArticle(1,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(2,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(3,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(4,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(5,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(6,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(7,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(8,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(9,$form,'galeria',$registros,'scroll-galeria','voyeur');
loadArticle(10,$form,'galeria',$registros,'scroll-galeria','voyeur');
var count2 = 11;
$('div').scroll(function() {
var offset = $('#scroll-galeria div').length;
var \$this = $(this);
var height = this.scrollHeight - \$this.height(); // Get the height of the div
var scroll = \$this.scrollTop(); // Get the vertical scroll position
var isScrolledToEnd = (scroll >= height);
if (isScrolledToEnd) {
loadArticle(count2,$form,'voyeur',$registros,'scroll-galeria','voyeur');
count2++;
}
});
});
</script>
";
$onload = vista_voyeur($form);
}
elseif($v[0] =='g') {
/// g=FORMULARIO EMBEBIDO
@ -674,6 +770,7 @@ if('serviceWorker' in navigator) {
$embebido = "1";
$onload = formulario_embebido($form,$opciones);
$librerias_cabeza ="
<script src='./librerias/summernote/summernote.js'></script>
<link href='./librerias/summernote/summernote.css' rel='stylesheet'>
";
@ -916,7 +1013,7 @@ $aplicacion_pie="
<a href='#' class='dropdown-toggle ' data-toggle='dropdown' role='button' aria-haspopup='true' aria-expanded='false'>
Secciones<span class='caret'></span>
</a>
<ul class='dropdown-menu'>
<ul class='dropdown-menu' id='listado_aplicaciones'>
$aplicaciones_listado
</ul>
</li>
@ -1194,6 +1291,7 @@ else {
<meta name='apple-mobile-web-app-status-bar-style' content='black-translucent'/>
";
echo $librerias_cabeza;
include("temas/$tema/cabecera");
include("temas/$tema/pie");
$barra="
@ -1372,7 +1470,7 @@ $css_adicional
right: 'listMonth,month,agendaWeek,agendaDay,listYear,timeLineYear'
},
//defaultDate: '2017-10-12',
defaultView: 'listMonth',
defaultView: 'listYear',
themeSystem: 'bootstrap3',
navLinks: true, // can click day/week names to navigate views
editable: false,
@ -1695,12 +1793,20 @@ $(document).delegate('*[data-toggle="lightbox"]', 'click', function(event) {
<script type="text/javascript" src="librerias/landingjs/scripts_landing.js"></script>
<?php
if(isset($_SESSION['id'] )) {
echo "
<form name='form_session' class='navbar-form navbar-left'>
<div class='input-group'>
<input type='text' name='tiempo_session' size='18' class='form-control input-sm' readonly>
<span class='input-group-addon'><a href='#' onclick="location.reload();" title='Renovar'> <i class='fa fa-refresh' aria-hidden='true'></i></a></span>
<span class='input-group-addon'><a href='#' onclick=\"location.reload();\" title='Renovar'> <i class='fa fa-refresh' aria-hidden='true'></i></a></span>
</div>
</form>
</form>";
}
?>
<script type="text/javascript">
$('.navbar-collapse a').click(function(){
$(".navbar-collapse").collapse('hide');

View File

@ -9,7 +9,3 @@ $(window).scroll(function() {
$(window).scroll(function(){
$(".top").css("opacity", 1 - $(window).scrollTop() / 100);
});
$('.dropdown-menu').click(function(e) {
e.stopPropagation(); //This will prevent the event from bubbling up and close the dropdown when you type/click on text boxes.
});