[Alba-desarrollo] SVN Alba r4367 - in prosistem/alba/trunk/alba/apps/principal/modules/rol: actions templates

commits en pressenter.com.ar commits en pressenter.com.ar
Vie Mar 2 17:46:31 CET 2007


Author: ftoledo
Date: 2007-03-02 13:46:29 -0300 (Fri, 02 Mar 2007)
New Revision: 4367

Modified:
   prosistem/alba/trunk/alba/apps/principal/modules/rol/actions/actions.c=
lass.php
   prosistem/alba/trunk/alba/apps/principal/modules/rol/templates/editPer=
misoSuccess.php
Log:
fix ticket #174
error al guardar por warnigs de php >5.1 con los arrays de propiedades de=
 clases.



Modified: prosistem/alba/trunk/alba/apps/principal/modules/rol/actions/ac=
tions.class.php
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- prosistem/alba/trunk/alba/apps/principal/modules/rol/actions/actions.=
class.php	2007-03-01 21:10:52 UTC (rev 4366)
+++ prosistem/alba/trunk/alba/apps/principal/modules/rol/actions/actions.=
class.php	2007-03-02 16:46:29 UTC (rev 4367)
@@ -23,8 +23,8 @@
  * rol Acciones
  *
  * @package    alba
- * @author     Jos=E9 Luis Di Biase <josx en interorganic.com.ar>
- * @author     H=E9ctor Sanchez <hsanchez en pressenter.com.ar>
+ * @author     Jos=C3=A9 Luis Di Biase <josx en interorganic.com.ar>
+ * @author     H=C3=A9ctor Sanchez <hsanchez en pressenter.com.ar>
  * @author     Fernando Toledo <ftoledo en pressenter.com.ar>
  * @version    SVN: $Id$
  * @filesource
@@ -44,9 +44,9 @@
         $rolPermisos =3D RelRolPermisoPeer::doSelectJoinPermiso($c);
    =20
             // esto puede ser descartado usando en el select_tag, object=
s_for_select                              =20
-        $this->optionsRolPermisos =3D array();
+        $optionsRolPermisos =3D array();
         foreach($rolPermisos as $rolPermiso) {
-            $this->optionsRolPermisos[$rolPermiso->getFkPermisoId()] =3D=
 $rolPermiso->getPermiso()->getNombre();
+            $optionsRolPermisos[$rolPermiso->getFkPermisoId()] =3D $rolP=
ermiso->getPermiso()->getNombre();
         }
=20
         //estos son todos los permisos existentes
@@ -57,7 +57,7 @@
         }
        =20
         // estos son los permisos existentes menos los del usuario
-        $this->optionsPermisos =3D array_diff_key($todosLosPermisos, $th=
is->optionsRolPermisos);
+        $this->optionsPermisos =3D array_diff_key($todosLosPermisos, $op=
tionsRolPermisos);
         =20
         $c =3D new Criteria();
         //$c->clearSelectColumns()->addSelectColumn(RolPeer::NOMBRE);
@@ -66,11 +66,12 @@
         $c->add(RolPeer::ACTIVO, 1);
         $roles  =3D RolPeer::doSelect($c);
=20
-        $this->optionsRol =3D array();
+        $optionsRol =3D array();
         foreach($roles as $rol) {
-            $this->optionsRol[$rol->getId()] =3D $rol->getNombre();=20
+            $optionsRol[$rol->getId()] =3D $rol->getNombre();=20
         }
-       =20
+        $this->optionsRol =3D $optionsRol;
+        $this->optionsRolPermisos =3D $optionsRolPermisos;
     }       =20
    =20
     function executeSavePermiso() {

Modified: prosistem/alba/trunk/alba/apps/principal/modules/rol/templates/=
editPermisoSuccess.php
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- prosistem/alba/trunk/alba/apps/principal/modules/rol/templates/editPe=
rmisoSuccess.php	2007-03-01 21:10:52 UTC (rev 4366)
+++ prosistem/alba/trunk/alba/apps/principal/modules/rol/templates/editPe=
rmisoSuccess.php	2007-03-02 16:46:29 UTC (rev 4367)
@@ -5,23 +5,23 @@
         location.href =3D "<?php echo url_for('rol/editPermiso', false);=
?>/id/"+obj.options[obj.selectedIndex].value;
      }
 	</script>	=09
+<div id=3D"sf_admin_container">
+    <h1>Permisos por Roles</h1>
+    <br>
+    <?php echo form_tag('rol/savePermiso', 'onSubmit=3D"selectItem()"')?=
>
+    Rol: <?php echo select_tag('id', options_for_select($optionsRol, $sf=
_params->get('id')), 'onChange=3DlinkTo()'); ?><br> <br>
+    <?php=20
+        echo select_tag('permisos', options_for_select($optionsPermisos)=
, 'multiple=3Dmultiple id=3D"fromBox"');
+        echo select_tag('rolPermisos[]', options_for_select($optionsRolP=
ermisos), 'multiple=3Dmultiple id=3D"toBox"');
+    //    echo select_tag('rolPermisos[]', objects_for_select($optionsRo=
lPermisos,'getFkPermisoId','getPermiso()->getNombre',''), 'multiple=3Dmul=
tiple id=3D"toBox"');
+    ?>
+    <ul class=3D"sf_admin_actions">
+        <li><? echo submit_tag('submit', 'class=3Dsf_admin_action_save v=
alue=3DGrabar');?></li>
+        <li><? echo button_to('Listado de Roles','rol/list',array('class=
'=3D>'sf_admin_action_list'))?></li>
+    </ul>
+    </form>
=20
-<h1>Permisos por Roles</h1>
-<br>
-<?php echo form_tag('rol/savePermiso', 'onSubmit=3D"selectItem()"')?>
-Rol: <?php echo select_tag('id', options_for_select($optionsRol, $sf_par=
ams->get('id')), 'onChange=3DlinkTo()'); ?><br> <br>
-<?php=20
-    echo select_tag('permisos', options_for_select($optionsPermisos), 'm=
ultiple=3Dmultiple id=3D"fromBox"');
-    echo select_tag('rolPermisos[]', options_for_select($optionsRolPermi=
sos), 'multiple=3Dmultiple id=3D"toBox"');
-//    echo select_tag('rolPermisos[]', objects_for_select($optionsRolPer=
misos,'getFkPermisoId','getPermiso()->getNombre',''), 'multiple=3Dmultipl=
e id=3D"toBox"');
-?>
-<ul class=3D"sf_admin_actions">
-<li><? echo submit_tag('submit', 'class=3Dsf_admin_action_save value=3DG=
rabar"');?></li>
-<li><? echo button_to('Listado de Roles','rol/list',array('class'=3D>'sf=
_admin_action_list'))?></li>
-</ul>
-</form>
-
-<script type=3D"text/javascript">
-createMovableOptions("fromBox","toBox",500,300,'Permisos Disponibles','P=
ermisos Seleccionados');
-</script>
-
+    <script type=3D"text/javascript">
+    createMovableOptions("fromBox","toBox",500,300,'Permisos Disponibles=
','Permisos Seleccionados');
+    </script>
+</div>




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