From baeaef02c45ee0a92cefe1970261f33aaba5a1dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ricardo=20Montan=CC=83ana?= Date: Tue, 15 Apr 2014 01:39:57 +0200 Subject: [PATCH] =?UTF-8?q?A=C3=B1adidos=20los=20comentarios=20en=20instal?= =?UTF-8?q?ar=20y=20en=20los=20archivos=20de=20SQL.=20Quitada=20la=20creac?= =?UTF-8?q?i=C3=B3n=20de=20tablas=20de=20los=20archivos=20inv-iso=20e=20in?= =?UTF-8?q?v-utf.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Instalar.php | 18 ++++---- Mantenimiento.php | 1 - sql/inv-iso.sql | 99 -------------------------------------------- sql/inv-utf.sql | 103 ---------------------------------------------- sql/setup.sql | 18 ++++---- 5 files changed, 18 insertions(+), 221 deletions(-) diff --git a/Instalar.php b/Instalar.php index 757848b..609b2a3 100644 --- a/Instalar.php +++ b/Instalar.php @@ -334,9 +334,9 @@ class Instalar { $articulos = "CREATE TABLE `Articulos` ( `id` smallint(6) NOT NULL auto_increment COMMENT 'ordenable', `descripcion` varchar(60) NOT NULL COMMENT 'ordenable,link/Articulo', - `marca` varchar(20) default NULL COMMENT 'ordenable', - `modelo` varchar(20) default NULL COMMENT 'ordenable', - `cantidad` int(11) default NULL COMMENT 'ordenable', + `marca` varchar(20) default NULL COMMENT 'ordenable,ajax/text', + `modelo` varchar(20) default NULL COMMENT 'ordenable,ajax/text', + `cantidad` int(11) default NULL COMMENT 'ordenable,ajax/number', `imagen` varchar(45) default NULL COMMENT 'imagen', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=769 DEFAULT CHARSET=utf8; @@ -352,9 +352,9 @@ class Instalar { `id` int(10) unsigned NOT NULL auto_increment COMMENT 'ordenable', `id_Articulo` smallint(6) NOT NULL COMMENT 'foreign(Articulos;id),ordenable', `id_Ubicacion` smallint(5) unsigned NOT NULL COMMENT 'foreign(Ubicaciones;id),ordenable', - `numserie` varchar(30) default NULL COMMENT 'ordenable', - `cantidad` int(10) unsigned default NULL COMMENT 'ordenable', - `fechaCompra` date NOT NULL COMMENT 'ordenable', + `numserie` varchar(30) default NULL COMMENT 'ordenable,ajax/text', + `cantidad` int(10) unsigned default NULL COMMENT 'ordenable,ajax/number', + `fechaCompra` date NOT NULL COMMENT 'ordenable,ajax/combodate', `imagen` varchar(45) default NULL COMMENT 'imagen', PRIMARY KEY (`id`), KEY `id` (`id`), @@ -366,9 +366,9 @@ class Instalar { "; $usuarios = "CREATE TABLE `Usuarios` ( `id` int(10) unsigned NOT NULL auto_increment COMMENT 'ordenable', - `nombre` varchar(16) NOT NULL default '', - `clave` varchar(32) NOT NULL default '', - `idSesion` varchar(20) NOT NULL default '', + `nombre` varchar(16) NOT NULL default '' COMMENT 'ajax/text', + `clave` varchar(32) NOT NULL default '' COMMENT 'ajax/text', + `idSesion` varchar(20) NOT NULL default '' COMMENT 'ajax/text', `alta` tinyint(1) NOT NULL default '0', `modificacion` tinyint(1) NOT NULL default '0', `borrado` tinyint(1) NOT NULL default '0', diff --git a/Mantenimiento.php b/Mantenimiento.php index e554f5f..fe1530f 100644 --- a/Mantenimiento.php +++ b/Mantenimiento.php @@ -808,7 +808,6 @@ class Mantenimiento { $(function(){' . " $('[name=\"".$clave.$num."\"]').editable({ url: 'ajax.php?opc=put&tabla=". $this->tabla . "', - title: '" . $titulo . ":', emptytext: 'VacĂ­o', success: function(respuesta, newValue) { if (respuesta.success === false) { diff --git a/sql/inv-iso.sql b/sql/inv-iso.sql index 3d03e9b..e542ee8 100644 --- a/sql/inv-iso.sql +++ b/sql/inv-iso.sql @@ -15,23 +15,6 @@ /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; --- --- Table structure for table `Articulos` --- - -DROP TABLE IF EXISTS `Articulos`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Articulos` ( - `id` smallint(6) NOT NULL auto_increment, - `descripcion` varchar(60) NOT NULL COMMENT 'ordenable,link/Articulo', - `marca` varchar(20) default NULL COMMENT 'ordenable', - `modelo` varchar(20) default NULL COMMENT 'ordenable', - `cantidad` int(11) default NULL COMMENT 'ordenable', - PRIMARY KEY (`id`) -) ENGINE=InnoDB AUTO_INCREMENT=785 DEFAULT CHARSET=latin1; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Articulos` -- @@ -42,29 +25,6 @@ INSERT INTO `Articulos` VALUES (589,'Armario con puertas y cajones','M. E. C.',' /*!40000 ALTER TABLE `Articulos` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `Elementos` --- - -DROP TABLE IF EXISTS `Elementos`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Elementos` ( - `id` int(10) unsigned NOT NULL auto_increment, - `id_Articulo` smallint(6) NOT NULL COMMENT 'foreign(Articulos;id),ordenable', - `id_Ubicacion` smallint(5) unsigned NOT NULL COMMENT 'foreign(Ubicaciones;id),ordenable', - `numserie` varchar(30) default NULL COMMENT 'ordenable', - `cantidad` int(10) unsigned default NULL COMMENT 'ordenable', - `fechaCompra` date NOT NULL COMMENT 'ordenable', - PRIMARY KEY (`id`), - KEY `id` (`id`), - KEY `id_Articulo` (`id_Articulo`), - KEY `id_Ubicacion` (`id_Ubicacion`), - CONSTRAINT `Elementos_ibfk_1` FOREIGN KEY (`id_Articulo`) REFERENCES `Articulos` (`id`) ON DELETE CASCADE, - CONSTRAINT `Elementos_ibfk_2` FOREIGN KEY (`id_Ubicacion`) REFERENCES `Ubicaciones` (`id`) ON UPDATE CASCADE -) ENGINE=InnoDB AUTO_INCREMENT=1884 DEFAULT CHARSET=latin1; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Elementos` -- @@ -75,20 +35,6 @@ INSERT INTO `Elementos` VALUES (1414,589,140,'',1,'2004-12-07 00:00:00'),(1415,5 /*!40000 ALTER TABLE `Elementos` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `Ubicaciones` --- - -DROP TABLE IF EXISTS `Ubicaciones`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Ubicaciones` ( - `id` smallint(5) unsigned NOT NULL auto_increment, - `Descripcion` varchar(50) NOT NULL COMMENT 'ordenable,link/Ubicacion', - PRIMARY KEY (`id`) -) ENGINE=InnoDB AUTO_INCREMENT=184 DEFAULT CHARSET=latin1; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Ubicaciones` -- @@ -99,30 +45,6 @@ INSERT INTO `Ubicaciones` VALUES (140,'Secretario'),(141,'Aula Althia'),(142,'Al /*!40000 ALTER TABLE `Ubicaciones` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `Usuarios` --- - -DROP TABLE IF EXISTS `Usuarios`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Usuarios` ( - `id` int(10) unsigned NOT NULL auto_increment, - `nombre` varchar(16) NOT NULL default '', - `clave` varchar(32) NOT NULL default '', - `idSesion` varchar(20) NOT NULL default '', - `alta` tinyint(1) NOT NULL default '0', - `modificacion` tinyint(1) NOT NULL default '0', - `borrado` tinyint(1) NOT NULL default '0', - `consulta` tinyint(1) NOT NULL default '1', - `informe` tinyint(1) NOT NULL default '1', - `usuarios` tinyint(1) NOT NULL default '0', - `config` tinyint(1) NOT NULL default '0', - PRIMARY KEY (`id`), - KEY `nombre` (`nombre`) -) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Usuarios` -- @@ -133,28 +55,7 @@ INSERT INTO `Usuarios` VALUES (2,'admin','galeote','s3LUSqxg{s',1,1,1,1,1,1,1),( /*!40000 ALTER TABLE `Usuarios` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `test` --- -DROP TABLE IF EXISTS `test`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `test` ( - `id` smallint(6) NOT NULL auto_increment, - `Descripcion` varchar(30) NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=latin1; -SET character_set_client = @saved_cs_client; - --- --- Dumping data for table `test` --- - -LOCK TABLES `test` WRITE; -/*!40000 ALTER TABLE `test` DISABLE KEYS */; -/*!40000 ALTER TABLE `test` ENABLE KEYS */; -UNLOCK TABLES; /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; diff --git a/sql/inv-utf.sql b/sql/inv-utf.sql index 7afd314..ad2f073 100644 --- a/sql/inv-utf.sql +++ b/sql/inv-utf.sql @@ -15,24 +15,6 @@ /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; --- --- Table structure for table `Articulos` --- - -DROP TABLE IF EXISTS `Articulos`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Articulos` ( - `id` smallint(6) NOT NULL auto_increment COMMENT 'ordenable', - `descripcion` varchar(60) NOT NULL COMMENT 'ordenable,link/Articulo', - `marca` varchar(20) default NULL COMMENT 'ordenable', - `modelo` varchar(20) default NULL COMMENT 'ordenable', - `cantidad` int(11) default NULL COMMENT 'ordenable', - `imagen` varchar(45) DEFAULT NULL COMMENT 'imagen', - PRIMARY KEY (`id`) -) ENGINE=InnoDB AUTO_INCREMENT=785 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Articulos` -- @@ -43,30 +25,6 @@ INSERT INTO `Articulos` (id, descripcion, marca, modelo, cantidad) VALUES (589,' /*!40000 ALTER TABLE `Articulos` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `Elementos` --- - -DROP TABLE IF EXISTS `Elementos`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Elementos` ( - `id` int(10) unsigned NOT NULL auto_increment COMMENT 'ordenable', - `id_Articulo` smallint(6) NOT NULL COMMENT 'foreign(Articulos;id),ordenable', - `id_Ubicacion` smallint(5) unsigned NOT NULL COMMENT 'foreign(Ubicaciones;id),ordenable', - `numserie` varchar(30) default NULL COMMENT 'ordenable', - `cantidad` int(10) unsigned default NULL COMMENT 'ordenable', - `fechaCompra` date NOT NULL COMMENT 'ordenable', - `imagen` varchar(45) DEFAULT NULL COMMENT 'imagen', - PRIMARY KEY (`id`), - KEY `id` (`id`), - KEY `id_Articulo` (`id_Articulo`), - KEY `id_Ubicacion` (`id_Ubicacion`), - CONSTRAINT `Elementos_ibfk_1` FOREIGN KEY (`id_Articulo`) REFERENCES `Articulos` (`id`) ON DELETE CASCADE, - CONSTRAINT `Elementos_ibfk_2` FOREIGN KEY (`id_Ubicacion`) REFERENCES `Ubicaciones` (`id`) ON UPDATE CASCADE -) ENGINE=InnoDB AUTO_INCREMENT=1884 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Elementos` -- @@ -77,21 +35,6 @@ INSERT INTO `Elementos` (id, id_Articulo, id_Ubicacion, numserie, cantidad, fech /*!40000 ALTER TABLE `Elementos` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `Ubicaciones` --- - -DROP TABLE IF EXISTS `Ubicaciones`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Ubicaciones` ( - `id` smallint(5) unsigned NOT NULL auto_increment COMMENT 'ordenable', - `Descripcion` varchar(50) NOT NULL COMMENT 'ordenable,link/Ubicacion', - `imagen` varchar(45) DEFAULT NULL COMMENT 'imagen', - PRIMARY KEY (`id`) -) ENGINE=InnoDB AUTO_INCREMENT=184 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Ubicaciones` -- @@ -102,30 +45,6 @@ INSERT INTO `Ubicaciones` (id,descripcion) VALUES (140,'Secretario'),(141,'Aula /*!40000 ALTER TABLE `Ubicaciones` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `Usuarios` --- - -DROP TABLE IF EXISTS `Usuarios`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `Usuarios` ( - `id` int(10) unsigned NOT NULL auto_increment COMMENT 'ordenable', - `nombre` varchar(16) NOT NULL default '', - `clave` varchar(32) NOT NULL default '', - `idSesion` varchar(20) NOT NULL default '', - `alta` tinyint(1) NOT NULL default '0', - `modificacion` tinyint(1) NOT NULL default '0', - `borrado` tinyint(1) NOT NULL default '0', - `consulta` tinyint(1) NOT NULL default '1', - `informe` tinyint(1) NOT NULL default '1', - `usuarios` tinyint(1) NOT NULL default '0', - `config` tinyint(1) NOT NULL default '0', - PRIMARY KEY (`id`), - KEY `nombre` (`nombre`) -) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; - -- -- Dumping data for table `Usuarios` -- @@ -136,28 +55,6 @@ INSERT INTO `Usuarios` VALUES (2,'admin','galeote','s3LUSqxg{s',1,1,1,1,1,1,1),( /*!40000 ALTER TABLE `Usuarios` ENABLE KEYS */; UNLOCK TABLES; --- --- Table structure for table `test` --- - -DROP TABLE IF EXISTS `test`; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; -CREATE TABLE `test` ( - `id` smallint(6) NOT NULL auto_increment, - `Descripcion` varchar(30) NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; - --- --- Dumping data for table `test` --- - -LOCK TABLES `test` WRITE; -/*!40000 ALTER TABLE `test` DISABLE KEYS */; -/*!40000 ALTER TABLE `test` ENABLE KEYS */; -UNLOCK TABLES; /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; diff --git a/sql/setup.sql b/sql/setup.sql index 7bcefb8..fd72b0c 100644 --- a/sql/setup.sql +++ b/sql/setup.sql @@ -24,9 +24,9 @@ SET character_set_client = utf8; CREATE TABLE `Articulos` ( `id` smallint(6) NOT NULL auto_increment COMMENT 'ordenable', `descripcion` varchar(60) NOT NULL COMMENT 'ordenable,link/Articulo', - `marca` varchar(20) default NULL COMMENT 'ordenable', - `modelo` varchar(20) default NULL COMMENT 'ordenable', - `cantidad` int(11) default NULL COMMENT 'ordenable', + `marca` varchar(20) default NULL COMMENT 'ordenable,ajax/text', + `modelo` varchar(20) default NULL COMMENT 'ordenable,ajax/text', + `cantidad` int(11) default NULL COMMENT 'ordenable,ajax/number', `imagen` varchar(45) default NULL COMMENT 'imagen', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=785 DEFAULT CHARSET=utf8; @@ -44,9 +44,9 @@ CREATE TABLE `Elementos` ( `id` int(10) unsigned NOT NULL auto_increment COMMENT 'ordenable', `id_Articulo` smallint(6) NOT NULL COMMENT 'foreign(Articulos;id),ordenable', `id_Ubicacion` smallint(5) unsigned NOT NULL COMMENT 'foreign(Ubicaciones;id),ordenable', - `numserie` varchar(30) default NULL COMMENT 'ordenable', - `cantidad` int(10) unsigned default NULL COMMENT 'ordenable', - `fechaCompra` date NOT NULL COMMENT 'ordenable', + `numserie` varchar(30) default NULL COMMENT 'ordenable,ajax/text', + `cantidad` int(10) unsigned default NULL COMMENT 'ordenable,ajax/number', + `fechaCompra` date NOT NULL COMMENT 'ordenable,ajax/combodate', `imagen` varchar(45) default NULL COMMENT 'imagen', PRIMARY KEY (`id`), KEY `id` (`id`), @@ -83,9 +83,9 @@ SET @saved_cs_client = @@character_set_client; SET character_set_client = utf8; CREATE TABLE `Usuarios` ( `id` int(10) unsigned NOT NULL auto_increment COMMENT 'ordenable', - `nombre` varchar(16) NOT NULL default '', - `clave` varchar(32) NOT NULL default '', - `idSesion` varchar(20) NOT NULL default '', + `nombre` varchar(16) NOT NULL default '' COMMENT 'ajax/text', + `clave` varchar(32) NOT NULL default '' COMMENT 'ajax/text', + `idSesion` varchar(20) NOT NULL default '' COMMENT 'ajax/text', `alta` tinyint(1) NOT NULL default '0', `modificacion` tinyint(1) NOT NULL default '0', `borrado` tinyint(1) NOT NULL default '0',