With patch, it's better ;)

Le Sat, 13 Aug 2011 15:01:21 +0200
David DURIEUX <d.duri...@siprossii.com> a écrit:

>Hello, 
>
>I have made fix for function Ajax::updateItemOnEventJsCode
>When use $minsize or $forceloadfor parameter and if $toobserve is an
>array, it don't works because use id the array instead each value of
>the array.
>
>++
>
>David
>
>_______________________________________________
>Glpi-dev mailing list
>Glpi-dev@gna.org
>https://mail.gna.org/listinfo/glpi-dev
index inc/ajax.class.php
--- inc/ajax.class.php
+++ inc/ajax.class.php
@@ -173,14 +173,14 @@ class Ajax {
                 function() {";
                   $condition = '';
                   if ($minsize >= 0) {
-                     $condition = " Ext.get('$toobserve').getValue().length >= $minsize ";
+                     $condition = " Ext.get('$zone').getValue().length >= $minsize ";
                   }
                   if (count($forceloadfor)) {
                      foreach ($forceloadfor as $value) {
                         if (!empty($condition)) {
                            $condition .= " || ";
                         }
-                        $condition .= "Ext.get('$toobserve').getValue() == '$value'";
+                        $condition .= "Ext.get('$zone').getValue() == '$value'";
                      }
                   }
                   if (!empty($condition)) {
_______________________________________________
Glpi-dev mailing list
Glpi-dev@gna.org
https://mail.gna.org/listinfo/glpi-dev

Reply via email to