Code

Some fixes for phone reports
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 17 May 2006 07:24:28 +0000 (07:24 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 17 May 2006 07:24:28 +0000 (07:24 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3379 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/gofon/fonreports/class_fonreport.inc
plugins/gofon/fonreports/contents.tpl

index 9c5ec44645f2fe6a627ab771eacd46815890dc32..4c478938432c15b72df6f2061fd1557a746b8283 100644 (file)
@@ -159,7 +159,7 @@ class fonreport extends plugin
                                  "(|(uid=$s)(l=$s)(homePhone=$s)".
                                  "(telephoneNumber=$s)(facsimileTelephoneNumber=$s)(mobile=$s)".
                                  "(pager=$s)(cn=$s)(givenName=$s)(sn=$s)(personalTitle=$s)".
-                                 "(title=$s)))");
+                                 "(title=$s)))" ,array("uid"));
 
                  $fon_users= array();
                  while ($attrs= $ldap->fetch()){
@@ -167,7 +167,7 @@ class fonreport extends plugin
                          $acl= get_module_permission($acl, "fax", $ldap->getDN());
 
                          if (chkacl ($acl, "faxReport") == ""){
-                                 $fax_users[]= $attrs["uid"][0];
+                                 $fon_users[]= $attrs["uid"][0];
                          }
                  }
 
@@ -213,6 +213,7 @@ class fonreport extends plugin
                return($smarty->fetch(get_template_path('contents.tpl', TRUE)));
        }
        $report_list= array();
+       
        while ($line = mysql_fetch_array($result, MYSQL_ASSOC)) {
                $append_str = "";
                $hour=  substr($line["calldate"], 11, 2);
@@ -278,7 +279,6 @@ class fonreport extends plugin
        $smarty->assign("month_select"  , $this->month);
        $smarty->assign("years"                 , $years);
        $smarty->assign("year_select"   , $this->year);
-       $smarty->assign("search_result" , "");
        return($smarty->fetch(get_template_path('contents.tpl', TRUE)));
   }
 
index f3641085e7eabd595266ea7d5949342ba5fc20cc..a128dcc358333bd9b211e8572c03cbc808a7db02 100644 (file)
@@ -24,7 +24,7 @@
 
 <br>
 
-{if $search_result ne ""}
+{if $search_result }
  <table style="width:100%; vertical-align:top; text-align:left; border:1px solid #B0B0B0;" cellpadding=2 cellspacing=1 border=0 rules="cols" summary="">
   <tr style="background-color: #E8E8E8; height:26px; font-weight:bold">
    <td><a href="main.php{$plug}&amp;sort=0">{t}Date{/t} {$mode0}</a></td>