diff options
author | Javier Sánchez Parra <jsanchez@soleta.eu> | 2020-11-26 14:25:12 +0100 |
---|---|---|
committer | OpenGnSys Support Team <soporte-og@soleta.eu> | 2020-11-27 12:51:24 +0100 |
commit | 5d05b06d0591c6df06b7a459e589011895b78114 (patch) | |
tree | 52411f513403ac8526e6f2688f6eceff8f23322d /admin/WebConsole/comandos | |
parent | 4c4ea59598d9a432068dd8034005759fbfa54386 (diff) |
#1008 Add support to work with GPT tables
WebConsole needs to rely on /shell/run to work with GPT tables. Because
"Partition and Format"/"Particionar y Formatear" form always supposes
that the partition table is MBR/MSDOS.
"Setup"/"Configurar" script from "Cloning Engine" also supposes that the
partition table is MBR/MSDOS. But it uses "Boot.lib" library, that can
create MBR and GTP partitions.
This commit:
* Adds WebConsole support to work with GPT tables.
- Adds input field where the user can select between MSDOS and
GPT table types.
* Adds "Setup" support to work with GPT tables.
- Adds script parameter that expects a string with "MSDOS" or
"GPT".
Diffstat (limited to 'admin/WebConsole/comandos')
-rw-r--r-- | admin/WebConsole/comandos/Configurar.php | 20 | ||||
-rw-r--r-- | admin/WebConsole/comandos/jscripts/Configurar.js | 3 |
2 files changed, 22 insertions, 1 deletions
diff --git a/admin/WebConsole/comandos/Configurar.php b/admin/WebConsole/comandos/Configurar.php index 2ab5380c..cefc7990 100644 --- a/admin/WebConsole/comandos/Configurar.php +++ b/admin/WebConsole/comandos/Configurar.php @@ -124,6 +124,26 @@ if (isset($_POST["numdisk"])) $numdisk=$_POST["numdisk"]; </FORM> <?php } + $rs = new Recordset; + $cmd->texto = "SELECT codpar FROM ordenadores_particiones WHERE idordenador='" + .$idambito."' AND numdisk='".$numdisk."'"; + $rs->Comando = &$cmd; + if ($rs->Abrir()) { // Error al abrir recordset + $rs->Primero(); + if (!$rs->EOF){ + $current_table_type = $rs->campos["codpar"]; + } + $rs->Cerrar(); + } +?> + <div> + Tabla de particiones: + <select name="table_type" id="table_type"> + <option value="MSDOS">MSDOS</option> + <option value="GPT" <?php echo $current_table_type == 2 ? "selected" : ""; ?>>GPT</option> + </select> + </div> +<?php $sws=$fk_sysFi | $fk_tamano | $fk_nombreSO; $configs = pintaConfiguraciones($cmd, $idambito, $ambito, 7, $sws, false, "pintaParticionesConfigurar", "idordenador", $numdisk); diff --git a/admin/WebConsole/comandos/jscripts/Configurar.js b/admin/WebConsole/comandos/jscripts/Configurar.js index 85e94264..bda09401 100644 --- a/admin/WebConsole/comandos/jscripts/Configurar.js +++ b/admin/WebConsole/comandos/jscripts/Configurar.js @@ -240,8 +240,9 @@ function comprobarDatos(cc) var RC="!"; var disco = document.disk.current_numdisk.value; + var table_type = document.getElementById("table_type").value; - atributos="dsk="+disco+"@"+"cfg="; // Inicializa variable global de parámetros del comando + atributos="ttp="+table_type+"@"+"dsk="+disco+"@"+"cfg="; // Inicializa variable global de parámetros del comando if(swc){ |