Author: jaimesuez
Date: 2010-04-13 20:34:06 +0200 (Tue, 13 Apr 2010)
New Revision: 29123

Modified:
   
plugins/sfDoctrineAjaxFormPlugin/lib/widget/sfWidgetFormDinamicEmbeddedForm.class.php
   
plugins/sfDoctrineAjaxFormPlugin/modules/ajax_form/templates/_autocomplete_with_embedded_forms.php
Log:
Arreglado el uso de credenciales


Modified: 
plugins/sfDoctrineAjaxFormPlugin/lib/widget/sfWidgetFormDinamicEmbeddedForm.class.php
===================================================================
--- 
plugins/sfDoctrineAjaxFormPlugin/lib/widget/sfWidgetFormDinamicEmbeddedForm.class.php
       2010-04-13 17:20:41 UTC (rev 29122)
+++ 
plugins/sfDoctrineAjaxFormPlugin/lib/widget/sfWidgetFormDinamicEmbeddedForm.class.php
       2010-04-13 18:34:06 UTC (rev 29123)
@@ -47,7 +47,7 @@
     $this->addOption('is_autocomplete', true);
 
     $this->addOption('partial', false);
-    $this->addOption('permission', false);
+    $this->addOption('credentials', false);
     $this->addOption('unset', array());
     $this->addOption('thumbnail', null);
 
@@ -78,7 +78,7 @@
     $form_module_relation =  $this->getOption('form_module_relation');
     $foreign_type =     $this->getOption('foreign_type');
     $columns =          $this->getOption('columns');
-    $permission =       $this->getOption('permission');
+    $credentials =       $this->getOption('credentials');
     $partial =          $this->getOption('partial');
     $thumbnail =       $this->getOption('thumbnail');
 
@@ -135,7 +135,7 @@
         'form_module_relation' => $form_module_relation,
         'foreign_type' => $foreign_type,
         'columns' => $columns,
-        'permission' => $permission,
+        'credentials' => $credentials,
         "partial" => $partial,
         'thumbnail' => $thumbnail,
     ));

Modified: 
plugins/sfDoctrineAjaxFormPlugin/modules/ajax_form/templates/_autocomplete_with_embedded_forms.php
===================================================================
--- 
plugins/sfDoctrineAjaxFormPlugin/modules/ajax_form/templates/_autocomplete_with_embedded_forms.php
  2010-04-13 17:20:41 UTC (rev 29122)
+++ 
plugins/sfDoctrineAjaxFormPlugin/modules/ajax_form/templates/_autocomplete_with_embedded_forms.php
  2010-04-13 18:34:06 UTC (rev 29123)
@@ -21,7 +21,7 @@
           'form_module_relation' => $form_module_relation,
           'foreign_type' => $foreign_type,
           'columns' => $columns,
-          'permission' => $permission,
+          'credentials' => $credentials,
           'thumbnail' => $thumbnail,
   ))
   ?>
@@ -85,15 +85,14 @@
         <img align="top" src="/themeAdmin/images/icons/down.png"/>Ocultar
       </a>
 
-            <?php #if (!$permission || 
sfContext::getInstance()->getUser()->hasPermission($permission)): ?>
-            <?php #if (!$permission || 
sfContext::getInstance()->getUser()->getUser()->hasPermission($permission)): ?>
+          <?php if (!$credentials || 
sfContext::getInstance()->getUser()->hasCredential($credentials)): ?>
       <a id="<?php echo $module ?>_form_<?php echo $widget_name 
?>_related_object_form_unlink_<?php echo $embedded['id']->getValue()?>" 
style="cursor:pointer; margin-left:15px;">
         <img align="top" src="/themeAdmin/images/icons/unlink.gif"/>Quitar 
asociación
       </a>
       <a id="<?php echo $module ?>_form_<?php echo $widget_name 
?>_related_object_form_delete_<?php echo $embedded['id']->getValue()?>" 
style="cursor:pointer; margin-left:15px;">
         <img align="top" src="/themeAdmin/images/icons/delete.png"/>Borrar
       </a>
-            <?php #endif ?>
+          <?php endif ?>
 
 
           <?php else: ?>

-- 
You received this message because you are subscribed to the Google Groups 
"symfony SVN" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/symfony-svn?hl=en.

Reply via email to