[Alba-desarrollo] SVN Alba r5515 - in prosistem/alba/trunk/alba/apps/principal/modules/responsable: actions config templates

commits en pressenter.com.ar commits en pressenter.com.ar
Mie Abr 9 20:25:09 CEST 2008


Author: hsanchez
Date: 2008-04-09 15:25:09 -0300 (Wed, 09 Apr 2008)
New Revision: 5515

Modified:
   prosistem/alba/trunk/alba/apps/principal/modules/responsable/actions/actions.class.php
   prosistem/alba/trunk/alba/apps/principal/modules/responsable/config/generator.yml
   prosistem/alba/trunk/alba/apps/principal/modules/responsable/templates/editSuccess.php
Log:
Agregando apellido materno al responsable

Modified: prosistem/alba/trunk/alba/apps/principal/modules/responsable/actions/actions.class.php
===================================================================
--- prosistem/alba/trunk/alba/apps/principal/modules/responsable/actions/actions.class.php	2008-04-09 16:24:23 UTC (rev 5514)
+++ prosistem/alba/trunk/alba/apps/principal/modules/responsable/actions/actions.class.php	2008-04-09 18:25:09 UTC (rev 5515)
@@ -76,75 +76,78 @@
                 $this->responsable->setFkCuentaId($this->getRequestParameter('fk_cuenta_id'));
         }
     }
-     protected function updateResponsableFromRequest()
-  {
-    $responsable = $this->getRequestParameter('responsable');
+     protected function updateResponsableFromRequest(){
+        $responsable = $this->getRequestParameter('responsable');
 
-    if (isset($responsable['apellido']))
-    {
-      $this->responsable->setApellido($responsable['apellido']);
-    }
-    if (isset($responsable['nombre']))
-    {
-      $this->responsable->setNombre($responsable['nombre']);
-    }
-    if (isset($responsable['sexo']))
-    {
-      $this->responsable->setSexo($responsable['sexo']);
-    }
-    if (isset($responsable['fk_tipodocumento_id']))
-    {
-      $this->responsable->setFkTipodocumentoId($responsable['fk_tipodocumento_id']);
-    }
-    if (isset($responsable['nro_documento']))
-    {
-      $this->responsable->setNroDocumento($responsable['nro_documento']);
-    }
-    if (isset($responsable['direccion']))
-    {
-      $this->responsable->setDireccion($responsable['direccion']);
-    }
-    if (isset($responsable['ciudad']))
-    {
-      $this->responsable->setCiudad($responsable['ciudad']);
-    }
-    if (isset($responsable['fk_provincia_id']))
-    {
-      $this->responsable->setFkProvinciaId($responsable['fk_provincia_id']);
-    }
-    if (isset($responsable['codigo_postal']))
-    {
-      $this->responsable->setCodigoPostal($responsable['codigo_postal']);
-    }
-    if (isset($responsable['telefono']))
-    {
-      $this->responsable->setTelefono($responsable['telefono']);
-    }
-    if (isset($responsable['telefono_movil']))
-    {
-      $this->responsable->setTelefonoMovil($responsable['telefono_movil']);
-    }
-    if (isset($responsable['email']))
-    {
-      $this->responsable->setEmail($responsable['email']);
-    }
-    if (isset($responsable['relacion']))
-    {
-      $this->responsable->setRelacion($responsable['relacion']);
-    }
-    if (isset($responsable['observacion']))
-    {
-      $this->responsable->setObservacion($responsable['observacion']);
-    }
-    if (isset($responsable['fk_cuenta_id']))
-    {
-      $this->responsable->setFkCuentaId($responsable['fk_cuenta_id']);
-    }
-    if (isset($responsable['fk_rolresponsable_id']))
-    {
-      $this->responsable->setFkRolresponsableId($responsable['fk_rolresponsable_id']);
-    }    
-    $this->responsable->setAutorizacionRetiro(isset($responsable['autorizacion_retiro']) ? $responsable['autorizacion_retiro'] : 0);
+        if (isset($responsable['apellido']))
+        {
+          $this->responsable->setApellido($responsable['apellido']);
+        }
+        if (isset($responsable['apellido_materno']))
+        {
+          $this->responsable->setApellidoMaterno($responsable['apellido_materno']);
+        }
+        if (isset($responsable['nombre']))
+        {
+          $this->responsable->setNombre($responsable['nombre']);
+        }
+        if (isset($responsable['sexo']))
+        {
+          $this->responsable->setSexo($responsable['sexo']);
+        }
+        if (isset($responsable['fk_tipodocumento_id']))
+        {
+          $this->responsable->setFkTipodocumentoId($responsable['fk_tipodocumento_id']);
+        }
+        if (isset($responsable['nro_documento']))
+        {
+          $this->responsable->setNroDocumento($responsable['nro_documento']);
+        }
+        if (isset($responsable['direccion']))
+        {
+          $this->responsable->setDireccion($responsable['direccion']);
+        }
+        if (isset($responsable['ciudad']))
+        {
+          $this->responsable->setCiudad($responsable['ciudad']);
+        }
+        if (isset($responsable['fk_provincia_id']))
+        {
+          $this->responsable->setFkProvinciaId($responsable['fk_provincia_id']);
+        }
+        if (isset($responsable['codigo_postal']))
+        {
+          $this->responsable->setCodigoPostal($responsable['codigo_postal']);
+        }
+        if (isset($responsable['telefono']))
+        {
+          $this->responsable->setTelefono($responsable['telefono']);
+        }
+        if (isset($responsable['telefono_movil']))
+        {
+          $this->responsable->setTelefonoMovil($responsable['telefono_movil']);
+        }
+        if (isset($responsable['email']))
+        {
+          $this->responsable->setEmail($responsable['email']);
+        }
+        if (isset($responsable['relacion']))
+        {
+          $this->responsable->setRelacion($responsable['relacion']);
+        }
+        if (isset($responsable['observacion']))
+        {
+          $this->responsable->setObservacion($responsable['observacion']);
+        }
+        if (isset($responsable['fk_cuenta_id']))
+        {
+          $this->responsable->setFkCuentaId($responsable['fk_cuenta_id']);
+        }
+        if (isset($responsable['fk_rolresponsable_id']))
+        {
+          $this->responsable->setFkRolresponsableId($responsable['fk_rolresponsable_id']);
+        }    
+        $this->responsable->setAutorizacionRetiro(isset($responsable['autorizacion_retiro']) ? $responsable['autorizacion_retiro'] : 0);
   }
   
     public function executeIrCuenta() {

Modified: prosistem/alba/trunk/alba/apps/principal/modules/responsable/config/generator.yml
===================================================================
--- prosistem/alba/trunk/alba/apps/principal/modules/responsable/config/generator.yml	2008-04-09 16:24:23 UTC (rev 5514)
+++ prosistem/alba/trunk/alba/apps/principal/modules/responsable/config/generator.yml	2008-04-09 18:25:09 UTC (rev 5515)
@@ -4,8 +4,9 @@
       model_class:      Responsable
       theme:            default
       fields:
-            nombre: { name: Nombre , params: size=64}
+            nombre: { name: Nombres , params: size=64}
             apellido: { name: Apellido , params: size=64}
+            apellido_materno: { name: Apellido Mat. , params: size=64}
             direccion: { name: Dirección , params: size=64 }
             ciudad: { name: Ciudad , params: size=64}
             codigo_postal: { name: CP , params: size=20}
@@ -23,7 +24,7 @@
         fields:
             apellido: { params: size=20 }
         title: Listado de Responsables
-        display: [ cuenta, =apellido, nombre, nro_documento, telefono_movil, telefono, _rolresponsable, autorizacion_retiro ]
+        display: [ cuenta, =apellido, apellido_materno, nombre, nro_documento, telefono_movil, telefono, _rolresponsable, autorizacion_retiro ]
         object_actions:
           _edit: -
           _delete: -
@@ -36,7 +37,7 @@
             fk_cuenta_id:   { params: include_custom=>>Selecciones un Cuenta<<}
             fk_provincia_id:   { params: include_custom=--Selecciones una Provincia--}
         display:
-                "Informaci&oacute;n general":  [apellido, nombre, _sexo, fk_tipodocumento_id, nro_documento]
+                "Informaci&oacute;n general":  [apellido, apellido_materno,  nombre, _sexo, fk_tipodocumento_id, nro_documento]
                 "Donde vive": [direccion, ciudad, _pais_id, _fk_provincia_id, codigo_postal ]
                 "Otros":  [ telefono, telefono_movil, email, observacion,  autorizacion_retiro]
         actions:
@@ -44,4 +45,4 @@
           _save: -
           _save_and_add: -
           _list: -          
-          irCuenta:  { name: Ir a Cuenta, action: irCuenta, icon: next.png }
\ No newline at end of file
+          irCuenta:  { name: Ir a Cuenta, action: irCuenta, icon: next.png }

Modified: prosistem/alba/trunk/alba/apps/principal/modules/responsable/templates/editSuccess.php
===================================================================
--- prosistem/alba/trunk/alba/apps/principal/modules/responsable/templates/editSuccess.php	2008-04-09 16:24:23 UTC (rev 5514)
+++ prosistem/alba/trunk/alba/apps/principal/modules/responsable/templates/editSuccess.php	2008-04-09 18:25:09 UTC (rev 5515)
@@ -71,6 +71,20 @@
 </div>
 
 <div class="form-row">
+  <?php echo label_for('responsable[apellido_materno]', __('Apellido Materno:'), '') ?>
+  <div class="content<?php if ($sf_request->hasError('responsable{apellido_materno}')): ?> form-error<?php endif; ?>">
+  <?php if ($sf_request->hasError('responsable{apellido_materno}')): ?>
+    <?php echo form_error('responsable{apellido_materno}', array('class' => 'form-error-msg')) ?>
+  <?php endif; ?>
+
+  <?php $value = object_input_tag($responsable, 'getApellidoMaterno', array (
+  'size' => 64,
+  'control_name' => 'responsable[apellido_materno]',
+)); echo $value ? $value : '&nbsp;' ?>
+    </div>
+</div>
+
+<div class="form-row">
   <?php echo label_for('responsable[nombre]', __('Nombre:'), 'class="required" ') ?>
   <div class="content<?php if ($sf_request->hasError('responsable{nombre}')): ?> form-error<?php endif; ?>">
   <?php if ($sf_request->hasError('responsable{nombre}')): ?>
@@ -306,4 +320,4 @@
 <div id="sf_admin_footer">
 <?php include_partial('responsable/edit_footer', array('responsable' => $responsable)) ?>
 </div>
-</div>
\ No newline at end of file
+</div>




Más información sobre la lista de distribución Alba-desarrollo