diff options
author | ramon <ramongomez@us.es> | 2013-04-01 12:44:52 +0000 |
---|---|---|
committer | ramon <ramongomez@us.es> | 2013-04-01 12:44:52 +0000 |
commit | ed5611d0cc3206d4fdc10881f421ef10e12020cb (patch) | |
tree | 71af0cdb4717e41deb151087cc6b76d1ce5b233c /admin/Database | |
parent | 9535b595359563ecdab7a842ff789cd62192914b (diff) |
#594: Incluir en la BD los sistemas de ficheros soportados por el comando Formatear.
git-svn-id: https://opengnsys.es/svn/branches/version1.0@3723 a21b9725-9963-47de-94b9-378ad31fedc9
Diffstat (limited to 'admin/Database')
-rw-r--r-- | admin/Database/ogAdmBD-1.0.5pre.sql | 34 | ||||
-rw-r--r-- | admin/Database/ogAdmBD.sql | 20 |
2 files changed, 51 insertions, 3 deletions
diff --git a/admin/Database/ogAdmBD-1.0.5pre.sql b/admin/Database/ogAdmBD-1.0.5pre.sql index 84deef01..9537e236 100644 --- a/admin/Database/ogAdmBD-1.0.5pre.sql +++ b/admin/Database/ogAdmBD-1.0.5pre.sql @@ -48,15 +48,19 @@ CREATE PROCEDURE addcols() BEGIN ADD ruta VARCHAR(250) NULL; UPDATE grupos SET tipo=70 WHERE tipo=50; END IF; + # Comando Particionar y formatear. + IF NOT EXISTS (SELECT * FROM information_schema.STATISTICS + WHERE INDEX_NAME='descripcion' AND TABLE_NAME='sistemasficheros' AND TABLE_SCHEMA=DATABASE()) + THEN + ALTER TABLE sistemasficheros + ADD UNIQUE INDEX descripcion (descripcion); + END IF; END// # Ejecutar actualizaciĆ³n condicional. delimiter ';' CALL addcols(); DROP PROCEDURE addcols; -# Habilita el comando Particionar y formatear. -UPDATE comandos SET activo = '1' WHERE idcomando = 10; - # Nuevos comandos. INSERT INTO comandos (idcomando, descripcion, pagina, gestor, funcion, urlimg, aplicambito, visuparametros, parametros, comentarios, activo, submenu) VALUES (11, 'Eliminar Imagen Cache', '../comandos/EliminarImagenCache.php', '../comandos/gestores/gestor_Comandos.php', 'EliminarImagenCache', '', 31, 'iph;tis;dcr;scp', 'nfn;iph;tis;dcr;scp', '', 1, ''), @@ -113,3 +117,27 @@ ALTER TABLE ordenadores UPDATE ordenadores SET arranque = '01' WHERE arranque = '1'; UPDATE ordenadores SET arranque = '19pxeadmin' WHERE arranque = 'pxeADMIN'; + +# Habilitar el comando Particionar y formatear. +UPDATE comandos SET activo = '1' WHERE idcomando = 10; +INSERT INTO sistemasficheros (descripcion, nemonico) VALUES + ('EMPTY', 'EMPTY'), + ('CACHE', 'CACHE'), + ('BTRFS', 'BTRFS'), + ('EXT2', 'EXT2'), + ('EXT3', 'EXT3'), + ('EXT4', 'EXT4'), + ('FAT12', 'FAT12'), + ('FAT16', 'FAT16'), + ('FAT32', 'FAT32'), + ('HFS', 'HFS'), + ('HFSPLUS', 'HFSPLUS'), + ('JFS', 'JFS'), + ('NTFS', 'NTFS'), + ('REISERFS', 'REISERFS'), + ('REISER4', 'REISER4'), + ('UFS', 'UFS'), + ('XFS', 'XFS') + ON DUPLICATE KEY UPDATE + descripcion=VALUES(descripcion), nemonico=VALUES(nemonico); + diff --git a/admin/Database/ogAdmBD.sql b/admin/Database/ogAdmBD.sql index 7b8ab121..7dc8f173 100644 --- a/admin/Database/ogAdmBD.sql +++ b/admin/Database/ogAdmBD.sql @@ -761,7 +761,27 @@ CREATE TABLE IF NOT EXISTS `sistemasficheros` ( `nemonico` varchar(16) DEFAULT NULL, `codpar` int(8) NOT NULL, PRIMARY KEY (`idsistemafichero`) + UNIQUE KEY (`descripcion`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ; +INSERT INTO `sistemasficheros` (`idsistemafichero`, `descripcion`, `nemonico`, `codpar`) VALUES + (1, 'EMPTY', 'EMPTY', 0), + (2, 'CACHE', 'CACHE', 0), + (3, 'BTRFS', 'BTRFS', 0), + (4, 'EXT2', 'EXT2', 0), + (5, 'EXT3', 'EXT3', 0), + (6, 'EXT4', 'EXT4', 0), + (7, 'FAT12', 'FAT12', 0), + (8, 'FAT16', 'FAT16', 0), + (9, 'FAT32', 'FAT32', 0), + (10, 'HFS', 'HFS', 0), + (11, 'HFSPLUS', 'HFSPLUS', 0), + (12, 'JFS', 'JFS', 0), + (13, 'NTFS', 'NTFS', 0), + (14, 'REISERFS', 'REISERFS', 0), + (15, 'REISER4', 'REISER4', 0), + (16, 'UFS', 'UFS', 0), + (17, 'XFS', 'XFS', 0); + -- -------------------------------------------------------- |