-<?php
-// vim: set expandtab tabstop=4 softtabstop=4 shiftwidth=4:
-// +----------------------------------------------------------------------+
-// | PHP Version 4 |
-// +----------------------------------------------------------------------+
-// | Copyright (c) 1997-2003 The PHP Group |
-// +----------------------------------------------------------------------+
-// | This source file is subject to version 2.02 of the PHP license, |
-// | that is bundled with this package in the file LICENSE, and is |
-// | available at through the world-wide-web at |
-// | http://www.php.net/license/2_02.txt. |
-// | If you did not receive a copy of the PHP license and are unable to |
-// | obtain it through the world-wide-web, please send a note to |
-// | license@php.net so we can mail you a copy immediately. |
-// +----------------------------------------------------------------------+
-// | Created: Tue Apr 29 12:35:45 2003
-// | Author: Martin Marrese <mmarre@mecon.gov.ar>
-// +----------------------------------------------------------------------+
-//
-// $Id$
-// $Author$
-// $URL$
-// $Date$
-// $Rev$
-//
+<?php /* vim: set binary expandtab tabstop=4 shiftwidth=4 textwidth=80:
+-------------------------------------------------------------------------------
+ Ministerio de EconomÃa
+ meconlib
+-------------------------------------------------------------------------------
+This file is part of meconlib.
-#require_once 'PEAR.php';
+meconlib is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 2 of the License, or (at your option)
+any later version.
+meconlib is distributed in the hope that it will be useful, but WITHOUT
+ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License; if not,
+write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
+Boston, MA 02111-1307 USA
+-------------------------------------------------------------------------------
+Creado: Tue Apr 29 12:35:45 2003
+Autor: Martin Marrese <mmarre@mecon.gov.ar>
+-------------------------------------------------------------------------------
+$Id$
+-----------------------------------------------------------------------------*/
// +X2C includes
require_once 'MECON/Marco/Menu.php';
// ~X2C
-// +X2C Class 103 :MenuVertical
+// +X2C Class 103 :MECON_Marco_MenuVertical
/**
* Clase que se encarga del manejo de los menues verticales
*
+ * @package MECON_Marco
* @access public
*/
-class MenuVertical extends Menu {
+class MECON_Marco_MenuVertical extends MECON_Marco_Menu {
// ~X2C
-
- // +X2C Operation 110
- /**
- * Constructor. Recibe el nombre del directorio en donde esta instalado el sistema
- *
- * @param array $configuracion Configuracion del sistema
- *
- * @return void
- * @access public
- */
- function MenuVertical($configuracion = null) // ~X2C
- {
- parent::Menu($configuracion);
- }
- // -X2C
-
// +X2C Operation 141
/**
* Funcion para agregar el cuerpo de la pagina a la pagina
*
* @param string $body Cuerpo del mensaje para agregar a la pagina
* @param string $titulo Titulo de la seccion seleccionada
+ * @param mixed $menu Menu a mostrar
*
* @return void
* @access public
*/
- function addBody($body, $titulo) // ~X2C
+ function addBody($body, $titulo, $menu = null) // ~X2C
{
$c= count($this->_componentes);
$this->_componentes = array ();
$this->_armarArraySecciones($tmp);
- $TABLA = new HTML_Table('width=160 align="left" bgcolor="#FFFFFF" cellspacing="0" cellpadding="0" border="0" height="1"');
- $menu ='<img src="/MECON/images/general_carpeta0" border="0"> <font face="Arial, Helvetica, sans-serif" size="2" color="#000000"><b>'.$titulo.'</b></font>';
- $row = array ($menu);
- $TABLA->addRow($row,'align="left" bgcolor="#FFFFFF" height="1"');
+ $TABLA = new HTML_Table('width=152 align="left" cellspacing="0"
+ cellpadding="0" border="0" height="1"
+ background="/MECON/images/general_titulo_menu.gif"');
+
+ $menutmp ='<font face="Arial, Helvetica, sans-serif" size="3"
+ color="#000000"><p> '.$titulo.'</p></font>';
+ $row = array ($menutmp);
+ $TABLA->addRow($row,'align="left"');
$TABLA->updateCellAttributes(0,0,'colspan="2"');
+
+ $SEP = array('<IMG height="3" src="/MECON/images/general_linea_relieve.gif" width=36>',
+ '<IMG height="3" src="/MECON/images/general_linea_relieve.gif" width=118>'
+ );
+ $TABLA->addRow($SEP);
foreach ($this->_componentesVertical as $comp) {
- $row = array ('<img src="/MECON/images/general_carp" border="0">',' ');
- $TABLA->addRow($row);
- $TABLA->addRow($comp,'align="left" bgcolor="#FFFFFF" height="1"');
- $TABLA->updateColAttributes(0,'align="right" width="34"');
- $TABLA->updateColAttributes(1,'align="left"');
+ $TABLA->addRow($comp,'align="left" height="3"
+ background="/MECON/images/general_fondo_gris"');
+ $TABLA->updateColAttributes(0,'align="right" width="34" height="3"');
+ $TABLA->updateColAttributes(1,'align="left" width="118"');
+ $TABLA->addRow($SEP);
}
$TABLA->updateCellAttributes(0,0,'align="left"');
$row = array ($TABLA->toHtml());
- $this->_tabla->addRow($row,'width=160 align="left" bgcolor="#FFFFFF" valign="top" rowspan="2"');
-
- $tmp='<BR>';
+
+ $this->_tabla->addRow($row,'width=152 align="left" bgcolor="#FFFFFF" valign="top"');
+
+//AGREGO EL CUERPO
+ $TABLA2 = new HTML_Table('width="600"align="right" bgcolor="#FFFFFF" cellspacing="0" cellpadding="0" border="0"');
+ $row = array();
+ $tmp = '';
+ //AGREGO EL MENU VERTICAL
+ if ($menu) {
+ if (is_object($menu)) {
+ if (method_exists($menu,'toHtml')) {
+ $tmp.=$menu->toHtml();
+ }
+ else {
+ trigger_error('El metodo no existe!', E_USER_WARNING);
+ }
+ }
+ else {
+ $tmp.=$menu;
+ }
+ $row[] = $tmp;
+ }
+ //
+ $tmp = '';
+ //Agrego si corresponde el espacio al inicio
+ if ($this->_configuracion['espacios']) {
+ $tmp.=' <BR>';
+ }
+ //
+
foreach ($body as $bod) {
if (is_object($bod)) {
if (method_exists($bod,'toHtml')) {
$tmp.=$bod;
}
}
- $row = array ($tmp);
- $this->_tabla->setCellContents (1,1,$row);
- $this->_tabla->setCellAttributes(1,1,'align="center" bgcolor="#FFFFFF"');
+ //Agrego si corresponde el espacio al final
+ if ($this->_configuracion['espacios']) {
+ $tmp.='<BR> ';
+ }
+ //
+ $row[] = $tmp;
+ $TABLA2->addRow($row, 'valign="top"');
+ $row = array ($TABLA2->toHtml());
+ $this->_tabla->setCellContents (0,2,$row);
+ $this->_tabla->setCellAttributes(0,2,'align="center" bgcolor="#FFFFFF" valign="top"');
- $this->_tabla->updateColAttributes (1,'width="600"');
+ $this->_tabla->updateColAttributes (1,'width="8" bgcolor="#FFFFFF"');
+ $this->_tabla->updateColAttributes (2,'width="600"');
+//
}
// -X2C
-} // -X2C Class :MenuVertical
+} // -X2C Class :MECON_Marco_MenuVertical
?>
\ No newline at end of file