mirror of
https://github.com/rmontanana/inventario2.git
synced 2025-08-15 15:35:56 +00:00
solve #7 Completado el procedimiento para cambiar el color. Solucionado que en la cabecera de los informes hubiese desaparecido el nombre del centro.
Falta ver por qué aparece el nombre de la aplicación con caracteres raros en los informes. html_decode
This commit is contained in:
@@ -106,17 +106,21 @@
|
||||
}
|
||||
break;
|
||||
case 'COLORLAT':
|
||||
$this->colorLateral=$valor;
|
||||
$valor = trim($valor);
|
||||
$this->colorLateral = $valor;
|
||||
if ($grabar) {
|
||||
$linea=str_replace($valor,$_POST['colorLat'],$linea);
|
||||
$this->colorLateral=$_POST['colorLat'];
|
||||
}
|
||||
break;
|
||||
case 'COLORFON':
|
||||
$this->colorFondo=$valor;
|
||||
$valor = trim($valor);
|
||||
$this->colorFondo = $valor;
|
||||
if ($grabar) {
|
||||
$linea=str_replace($valor,$_POST['colorFon'],$linea);
|
||||
$this->colorFondo=$_POST['colorFon'];
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
if ($grabar) {
|
||||
@@ -132,59 +136,56 @@
|
||||
unlink($this->confAnterior);
|
||||
rename($this->configuracion,$this->confAnterior);
|
||||
rename($this->confNueva,$this->configuracion);
|
||||
// Actualiza la plantilla bootstrap con los cambios de color
|
||||
$plantilla = file_get_contents("css/dashboard.css");
|
||||
|
||||
}
|
||||
return $salida;
|
||||
}
|
||||
private function formulario()
|
||||
{
|
||||
$coloresLateral = array( "Original" => "#C4FAEC", "Verde" => "#7bd148", "Azul marino" => "#5484ed", "Azul" => "#a4bdfc", "Turquesa" => "#46d6db",
|
||||
"Verde claro" => "#7ae7bf", "Verde oscuro" => "#51b749", "Amarillo" => "#fbd75b", "Naranja" => "#ffb878", "Morado" => "#6633FF",
|
||||
"Rojo oscuro" => "#dc2127", "Púrpura" => "#dbadff", "Gris" => "#e1e1e1");
|
||||
$coloresFondo = array( "Verde" => "#7bd148", "Azul marino" => "#5484ed", "Azul" => "#a4bdfc", "Turquesa" => "#46d6db",
|
||||
"Verde claro" => "#7ae7bf", "Verde oscuro" => "#51b749", "Amarillo" => "#fbd75b", "Naranja" => "#ffb878", "Rojo" => "#ff887c",
|
||||
"Rojo oscuro" => "#dc2127", "Púrpura" => "#dbadff", "Gris" => "#e1e1e1", "Original" => '#F3FEC8');
|
||||
$personal=$this->estilo=="personal"?'selected':' ';
|
||||
$bluecurve=$this->estilo=="bluecurve"?'selected':' ';
|
||||
$cristal=$this->estilo=="cristal"?'selected':' ';
|
||||
$normal=$this->plantilla=="normal"? 'selected':' ';
|
||||
$bootstrap=$this->plantilla=="bootstrap" ? 'selected':' ';
|
||||
$salida='<center><div class="col-sm-2 col-md-6"><form name="configura" method="post">';
|
||||
$salida='<center><div class="col-sm-4 col-md-6"><form name="configura" method="post">';
|
||||
//$salida.='<p align="center"><table border=1 class="tablaDatos"><tbody>';
|
||||
$salida.='<p align="center"><table border=2 class="table table-hover"><tbody>';
|
||||
$salida.='<th colspan=2 class="info"><center><b>Preferencias</b></center></th>';
|
||||
$salida.='<tr><td>Nombre del Centro</td><td><input type="text" name="centro" value="'.$this->nombreCentro.'" size="30" /></td></tr>';
|
||||
$salida.='<tr><td>Número de filas</td><td><input type="text" name="filas" value="'.$this->numFilas.'" size="3" /></td></tr>';
|
||||
$salida.='<tr><td>Plantilla</td><td><select name="plantilla" class="form-control">';
|
||||
$salida.='<tr><td style="vertical-align:middle">Plantilla</td><td><select name="plantilla" class="form-control">';
|
||||
$salida.='<option value="normal" '.$normal.'>normal</option>';
|
||||
$salida.='<option '.$bootstrap.'>bootstrap</option></select></td></tr>';
|
||||
$salida.='<tr><td>Estilo</td><td><select name="estilo" class="form-control">';
|
||||
$salida.='<tr><td style="vertical-align:middle">Estilo</td><td><select name="estilo" class="form-control">';
|
||||
$salida.='<option value="personal" '.$personal.'>personal</option>';
|
||||
$salida.='<option '.$bluecurve.'>bluecurve</option>';
|
||||
$salida.='<option '.$cristal.'>cristal</option></select></td></tr>';
|
||||
$salida.='<tr><td>Color Lateral</td><td><select name="colorLat" id="colorLat" class="form-control">
|
||||
<option value="#C4FAEC">Original</option>
|
||||
<option value="#7bd148">Green</option>
|
||||
<option value="#5484ed">Bold blue</option>
|
||||
<option value="#a4bdfc">Blue</option>
|
||||
<option value="#46d6db">Turquoise</option>
|
||||
<option value="#7ae7bf">Light green</option>
|
||||
<option value="#51b749">Bold green</option>
|
||||
<option value="#fbd75b">Yellow</option>
|
||||
<option value="#ffb878">Orange</option>
|
||||
<option value="#ff887c">Red</option>
|
||||
<option value="#dc2127">Bold red</option>
|
||||
<option value="#dbadff">Purple</option>
|
||||
<option value="#e1e1e1">Gray</option>
|
||||
</select></td></tr>';
|
||||
$salida.='<tr><td>Color Fondo</td><td><select name="colorFon" id="colorFon" class="form-control">
|
||||
<option value="#F3FEC8">Original</option>
|
||||
<option value="#7bd148">Green</option>
|
||||
<option value="#5484ed">Bold blue</option>
|
||||
<option value="#a4bdfc">Blue</option>
|
||||
<option value="#46d6db">Turquoise</option>
|
||||
<option value="#7ae7bf">Light green</option>
|
||||
<option value="#51b749">Bold green</option>
|
||||
<option value="#fbd75b">Yellow</option>
|
||||
<option value="#ffb878">Orange</option>
|
||||
<option value="#ff887c">Red</option>
|
||||
<option value="#dc2127">Bold red</option>
|
||||
<option value="#dbadff">Purple</option>
|
||||
<option value="#e1e1e1">Gray</option>
|
||||
</select></td></tr>';
|
||||
$salida.='<tr><td style="vertical-align:middle">Color Lateral (bootstrap)</td><td style="vertical-align:middle"><select name="colorLat" id="colorLat" class="form-control">';
|
||||
foreach ($coloresLateral as $color => $codigo) {
|
||||
$selec = "";
|
||||
if ($this->colorLateral == $codigo) {
|
||||
$selec = "selected";
|
||||
}
|
||||
$salida.='<option value="'.$codigo.'" '.$selec.' >'.$color.'</option>';
|
||||
}
|
||||
$salida.='</select></td></tr>';
|
||||
$salida.='<tr><td style="vertical-align:middle">Color Fondo (bootstrap)</td><td style="vertical-align:middle"><select name="colorFon" id="colorFon" class="form-control">';
|
||||
foreach ($coloresFondo as $color => $codigo) {
|
||||
$selec = "";
|
||||
if ($this->colorFondo == $codigo) {
|
||||
$selec = "selected";
|
||||
}
|
||||
$salida.='<option value="'.$codigo.'" '.$selec.' >'.$color.'</option>';
|
||||
}
|
||||
$salida.='</select></td></tr>';
|
||||
$salida.='<th colspan=2 class="danger"><center><b>Base de datos</b></center></th>';
|
||||
$salida.='<tr><td>Servidor</td><td><input type="text" name="servidor" value="'.$this->servidor.'" size="30" /></td></tr>';
|
||||
$salida.='<tr><td>Base de datos</td><td><input type="text" name="baseDatos" value="'.$this->baseDatos.'" size="30" /></td></tr>';
|
||||
@@ -194,26 +195,18 @@
|
||||
$salida.='</form></div></center>';
|
||||
$salida.="<script>
|
||||
$(document).ready(function() {
|
||||
$('#init').on('click', function() {
|
||||
$('#colorLat').simplecolorpicker({theme: 'glyphicons'});
|
||||
$('select[name=" .'"colorFon"'. "]').on('change', function() {
|
||||
$(document.body).css('background-color', $('select[name=" .'"colorFon"'. "]').val());
|
||||
$('.main').css('background-color', $('select[name=" .'"colorFon"'. "]').val());
|
||||
});
|
||||
|
||||
$('#destroy').on('click', function() {
|
||||
$('select').simplecolorpicker('destroy');
|
||||
$('select[name=" .'"colorLat"'. "]').on('change', function() {
|
||||
$('.sidebar').css('background-color', $('select[name=" .'"colorLat"'. "]').val());
|
||||
});
|
||||
// By default, activate simplecolorpicker plugin on HTML selects
|
||||
$('#init').trigger('click');
|
||||
$('select[name=". '"colorLat"' ."]').simplecolorpicker({theme: 'glyphicons'});
|
||||
$('select[name=" .'"colorFon"' ."]').simplecolorpicker({theme: 'glyphicons'});
|
||||
});
|
||||
</script>";
|
||||
$salida .= '<script type="text/javascript">
|
||||
$(function () {
|
||||
$('."'#ColorLat".$nfechas."').datetimepicker({
|
||||
pick12HourFormat: false,
|
||||
language: 'es',
|
||||
pickTime: false
|
||||
});
|
||||
});
|
||||
</script>";
|
||||
//$salida.="<br>fondo=[$this->colorFondo] lateral=[$this->colorLateral]<br>";
|
||||
return $salida;
|
||||
}
|
||||
}
|
||||
|
@@ -55,7 +55,8 @@ class InformePDF {
|
||||
//echo $def->Titulo.$def->Cabecera;
|
||||
$this->pdf->Open();
|
||||
$this->pdf->setAuthor(utf8_decode(AUTOR));
|
||||
$this->pdf->setCreator(html_entity_decode(APLICACION));
|
||||
$creador = CENTRO . " " . APLICACION;
|
||||
$this->pdf->setCreator(utf8_decode(html_entity_decode($creador)));
|
||||
$this->pdf->setSubject(utf8_decode($this->def->Titulo));
|
||||
$this->pdf->setAutoPageBreak(true, 10);
|
||||
}
|
||||
|
@@ -61,7 +61,7 @@ class Pdf_mysql_table extends Fpdf
|
||||
//Titulo
|
||||
$fecha=strftime("%d-%b-%Y %H:%M");
|
||||
$this->SetFont('Arial','',8);
|
||||
$this->Cell(0,4,html_entity_decode(APLICACION),0,1,'L');
|
||||
$this->Cell(0,4,html_entity_decode(CENTRO . " " . APLICACION),0,1,'L');
|
||||
$this->SetFont('Arial','',18);
|
||||
$this->Cell(0,6,utf8_decode($this->titulo),0,1,'C');
|
||||
$this->SetFont('Arial','',8);
|
||||
|
102
css/dashboard.php
Normal file
102
css/dashboard.php
Normal file
@@ -0,0 +1,102 @@
|
||||
<?php
|
||||
include('../inc/configuracion.inc');
|
||||
header("Content-type: text/css");
|
||||
?>
|
||||
/*
|
||||
* Base structure
|
||||
*/
|
||||
|
||||
/* Move down content because we have a fixed navbar that is 50px tall */
|
||||
body {
|
||||
padding-top: 50px;
|
||||
background-color: <?php echo COLORFON; ?>; /*Fondo*/
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Global add-ons
|
||||
*/
|
||||
|
||||
.sub-header {
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Sidebar
|
||||
*/
|
||||
|
||||
/* Hide for mobile, show later */
|
||||
.sidebar {
|
||||
display: none;
|
||||
}
|
||||
@media (min-width: 768px) {
|
||||
.sidebar {
|
||||
position: fixed;
|
||||
top: 51px;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
z-index: 1000;
|
||||
display: block;
|
||||
padding: 5px;
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto; /* Scrollable contents if viewport is shorter than content. */
|
||||
background-color: <?php echo COLORLAT; ?>;/*Lateral*/
|
||||
border-right: 1px solid #eee;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/* Sidebar navigation */
|
||||
.nav-sidebar {
|
||||
margin-right: -6px; /* 20px padding + 1px border */
|
||||
margin-bottom: 1px;
|
||||
margin-left: -1px;
|
||||
}
|
||||
.nav-sidebar > li > a {
|
||||
padding-right: 5px;
|
||||
padding-left: 5px;
|
||||
}
|
||||
.nav-sidebar > .active > a {
|
||||
color: #fff;
|
||||
background-color: #428bca;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Main content
|
||||
*/
|
||||
|
||||
.main {
|
||||
padding: 10px;
|
||||
}
|
||||
@media (min-width: 768px) {
|
||||
.main {
|
||||
padding-right: 20px;
|
||||
padding-left: 20px;
|
||||
}
|
||||
}
|
||||
.main .page-header {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Placeholder dashboard ideas
|
||||
*/
|
||||
|
||||
.placeholders {
|
||||
margin-bottom: 5px;
|
||||
text-align: center;
|
||||
}
|
||||
.placeholders h4 {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.placeholder {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
.placeholder img {
|
||||
display: inline-block;
|
||||
border-radius: 25%;
|
||||
}
|
21
fpdf.css
21
fpdf.css
@@ -1,21 +0,0 @@
|
||||
body {font-family:"Times New Roman",serif}
|
||||
h1 {font:bold 135% Arial,sans-serif; color:#4000A0; margin-bottom:0.9em}
|
||||
h2 {font:bold 95% Arial,sans-serif; color:#900000; margin-top:1.5em; margin-bottom:1em}
|
||||
dl.param dt {text-decoration:underline}
|
||||
dl.param dd {margin-top:1em; margin-bottom:1em}
|
||||
dl.param ul {margin-top:1em; margin-bottom:1em}
|
||||
tt, code, kbd {font-family:"Courier New",Courier,monospace; font-size:82%}
|
||||
div.source {margin-top:1.4em; margin-bottom:1.3em}
|
||||
div.source pre {display:table; border:1px solid #24246A; width:100%; margin:0em; font-family:inherit; font-size:100%}
|
||||
div.source code {display:block; border:1px solid #C5C5EC; background-color:#F0F5FF; padding:6px; color:#000000}
|
||||
div.doc-source {margin-top:1.4em; margin-bottom:1.3em}
|
||||
div.doc-source pre {display:table; width:100%; margin:0em; font-family:inherit; font-size:100%}
|
||||
div.doc-source code {display:block; background-color:#E0E0E0; padding:4px}
|
||||
.kw {color:#000080; font-weight:bold}
|
||||
.str {color:#CC0000}
|
||||
.cmt {color:#008000}
|
||||
p.demo {text-align:center; margin-top:-0.9em}
|
||||
a.demo {text-decoration:none; font-weight:bold; color:#0000CC}
|
||||
a.demo:link {text-decoration:none; font-weight:bold; color:#0000CC}
|
||||
a.demo:hover {text-decoration:none; font-weight:bold; color:#0000FF}
|
||||
a.demo:active {text-decoration:none; font-weight:bold; color:#0000FF}
|
@@ -33,6 +33,6 @@ define('NUMFILAS',17); // Número de registros a mostrar en las pantallas de con
|
||||
define('PAUSA',2);//Nº segundos de pausa para mostrar mensaje id insertado
|
||||
define('ESTILO','personal'); //Estilo de los iconos de edición (personal, personal, personal)
|
||||
define('PLANTILLA','bootstrap'); //Estilo de la plantilla y recursos a utilizar
|
||||
define('COLORLAT', '#C4FAEC'); //Color de la barra de menú lateral
|
||||
define('COLORLAT', '#a4bdfc'); //Color de la barra de menú lateral
|
||||
define('COLORFON', '#F3FEC8'); //Color del fondo de la pantalla
|
||||
?>
|
||||
|
@@ -33,6 +33,6 @@ define('NUMFILAS',17); // Número de registros a mostrar en las pantallas de con
|
||||
define('PAUSA',2);//Nº segundos de pausa para mostrar mensaje id insertado
|
||||
define('ESTILO','personal'); //Estilo de los iconos de edición (personal, personal, personal)
|
||||
define('PLANTILLA','bootstrap'); //Estilo de la plantilla y recursos a utilizar
|
||||
define('COLORLAT', '#C4FAEC'); //Color de la barra de menú lateral
|
||||
define('COLORLAT', '#a4bdfc'); //Color de la barra de menú lateral
|
||||
define('COLORFON', '#F3FEC8'); //Color del fondo de la pantalla
|
||||
?>
|
||||
|
@@ -13,29 +13,15 @@
|
||||
<!-- Bootstrap core CSS -->
|
||||
<link href="css/bootstrap/css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Custom styles for this template -->
|
||||
<link href="css/dashboard.css" rel="stylesheet">
|
||||
<link href="css/dashboard.php" rel="stylesheet">
|
||||
<link href="css/bootstrap-datetimepicker.min.css" rel="stylesheet">
|
||||
<link rel="stylesheet" href="css/jquery.simplecolorpicker.css">
|
||||
<link rel="stylesheet" href="css/jquery.simplecolorpicker-glyphicons.css">
|
||||
<style type="text/css"></style>
|
||||
<style id="clearly_highlighting_css" type="text/css">
|
||||
/* selection */
|
||||
html.clearly_highlighting_enabled ::-moz-selection { background: rgba(246, 238, 150, 0.99); }
|
||||
html.clearly_highlighting_enabled ::selection { background: rgba(246, 238, 150, 0.99); }
|
||||
/* cursor */
|
||||
html.clearly_highlighting_enabled {
|
||||
/* cursor and hot-spot position -- requires a default cursor, after the URL one */
|
||||
cursor: url("chrome-extension://pioclpoplcdbaefihamjohnefbikjilc/clearly/images/highlight--cursor.png") 14 16, text; }
|
||||
/* highlight tag */
|
||||
em.clearly_highlight_element { font-style: inherit !important; font-weight: inherit !important; background-image: url("chrome-extension://pioclpoplcdbaefihamjohnefbikjilc/clearly/images/highlight--yellow.png"); background-repeat: repeat-x; background-position: top left; background-size: 100% 100%; }
|
||||
/* the delete-buttons are positioned relative to this */
|
||||
em.clearly_highlight_element.clearly_highlight_first { position: relative; }
|
||||
/* delete buttons */
|
||||
em.clearly_highlight_element a.clearly_highlight_delete_element { display: none; cursor: pointer; padding: 0; margin: 0; line-height: 0; position: absolute; width: 34px; height: 34px; left: -17px; top: -17px; background-image: url("chrome-extension://pioclpoplcdbaefihamjohnefbikjilc/clearly/images/highlight--delete-sprite.png"); background-repeat: no-repeat; background-position: 0px 0px; } em.clearly_highlight_element a.clearly_highlight_delete_element:hover { background-position: -34px 0px; } /* retina */ @media (min--moz-device-pixel-ratio: 2), (-webkit-min-device-pixel-ratio: 2), (min-device-pixel-ratio: 2) { em.clearly_highlight_element { background-image: url("chrome-extension://pioclpoplcdbaefihamjohnefbikjilc/clearly/images/highlight--yellow@2x.png"); } em.clearly_highlight_element a.clearly_highlight_delete_element { background-image: url("chrome-extension://pioclpoplcdbaefihamjohnefbikjilc/clearly/images/highlight--delete-sprite@2x.png"); background-size: 68px 34px; } } </style><style id="holderjs-style" type="text/css"></style><style>[touch-action="none"]{ -ms-touch-action: none; touch-action: none; }[touch-action="pan-x"]{ -ms-touch-action: pan-x; touch-action: pan-x; }[touch-action="pan-y"]{ -ms-touch-action: pan-y; touch-action: pan-y; }[touch-action="scroll"],[touch-action="pan-x pan-y"],[touch-action="pan-y pan-x"]{ -ms-touch-action: pan-x pan-y; touch-action: pan-x pan-y; }
|
||||
</style>
|
||||
|
||||
<script type="text/javascript" src="./css/jquery.min.js"></script>
|
||||
</head>
|
||||
<body bgcolor="#C4FAEC">
|
||||
<body>
|
||||
<div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
|
||||
<div class="container-fluid">
|
||||
<div class="navbar-header">
|
||||
|
Reference in New Issue
Block a user