From: Gonzalo Merayo Date: Wed, 2 Jul 2003 20:51:44 +0000 (+0000) Subject: Se arreglan bugs. X-Git-Tag: svn_import~410 X-Git-Url: https://git.llucax.com/mecon/meconlib.git/commitdiff_plain/e98a38c3bcf5bf2f5da82c9a01f9f6d008b4c537?ds=inline Se arreglan bugs. --- diff --git a/lib/MECON/HTML/QuickForm/Renderer/Tabla.php b/lib/MECON/HTML/QuickForm/Renderer/Tabla.php index 2a82680..7f7432e 100644 --- a/lib/MECON/HTML/QuickForm/Renderer/Tabla.php +++ b/lib/MECON/HTML/QuickForm/Renderer/Tabla.php @@ -250,11 +250,11 @@ class MECON_HTML_QuickForm_Renderer_Tabla extends HTML_QuickForm_Renderer { $id = $this->_tabla->addRow( array(join('', $this->_groupElements)) ); - $this->_tabla->updateCellAttributes($id, 0, array('align' => 'right', 'colspan' => 2)); + $this->_tabla->updateCellAttributes($id, 0, array('valign' => 'middle', 'align' => 'right', 'colspan' => 2)); } else { $id = $this->_tabla->addRow( array($group->getLabel(), join($sep, $this->_groupElements)), - array('align' => 'left') + array('valign' => 'middle', 'align' => 'left') ); $this->_tabla->updateCellAttributes($id, 0, array('titulo' => true, 'align' => 'left', 'nowrap' => true)); } diff --git a/lib/MECON/HTML/Tabla.php b/lib/MECON/HTML/Tabla.php index f764ba9..f9f48a4 100644 --- a/lib/MECON/HTML/Tabla.php +++ b/lib/MECON/HTML/Tabla.php @@ -59,7 +59,7 @@ class Tabla extends HTML_Table { */ function Tabla($attrs = null) { - $this->_conf = include 'Tabla/conf_Tabla.php'; // Obtengo los valores particulares de configuracion + $this->_conf = include 'MECON/HTML/Tabla/conf_Tabla.php'; // Obtengo los valores particulares de configuracion // Seteo los atributos para la tabla $this->_attrs = $this->_conf['atributos']['tabla_comun']; //Genero el objeto HTML_Table @@ -258,15 +258,16 @@ class Tabla extends HTML_Table { function toHtml($simple = 0) { // Agregar la tabla de fondo. - if ($simple == 0) { - $tmp = $this->_parseAttributes($this->_conf['atributos']['tabla_contenedora']); - $tabla_externa = new HTML_Table(array('width' => '100%')); - $tabla_externa->setCellContents(0, 0, parent::toHtml()); - $tabla_externa->setCellAttributes(0, 0, $this->_conf['atributos']['celda_contenedora']); - $result = $tabla_externa->toHtml(); - } - else { + if ($simple) { $result = parent::toHtml(); + } else { + $contenedora = $this->_conf['atributos']['tabla_contenedora']; + $contenedora['width'] = $this->getAttribute('width'); + $this->updateAttributes(array('width' => '100%')); + $tabla_externa = new HTML_Table($contenedora); + $tabla_externa->addRow(array(parent::toHtml()), + $this->_conf['atributos']['celda_contenedora']); + $result = $tabla_externa->toHtml(); } return $result;