/[dolibarr]/dolibarr/htdocs/telephonie/script/presel_active_view.php
ViewVC logotype

Diff of /dolibarr/htdocs/telephonie/script/presel_active_view.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by rodolphe, Thu Nov 24 11:20:47 2005 UTC revision 1.3 by rodolphe, Thu Nov 24 13:10:45 2005 UTC
# Line 18  Line 18 
18   * $Id$   * $Id$
19   * $Source$   * $Source$
20   *   *
  *  
21   * Visualisation de l'etat des lignes preselectionnées   * Visualisation de l'etat des lignes preselectionnées
22   *   *
23   */   */
24  require ("../../master.inc.php");  require ("../../master.inc.php");
25  require_once DOL_DOCUMENT_ROOT."/telephonie/lignetel.class.php";  require_once DOL_DOCUMENT_ROOT."/telephonie/lignetel.class.php";
26    
 set_time_limit(0);  
   
27  $host          = CMD_PRESEL_WEB_HOST;  $host          = CMD_PRESEL_WEB_HOST;
28  $user_login    = CMD_PRESEL_WEB_USER;  $user_login    = CMD_PRESEL_WEB_USER;
29  $user_passwd   = CMD_PRESEL_WEB_PASS;  $user_passwd   = CMD_PRESEL_WEB_PASS;
# Line 35  $ids = array(); Line 32  $ids = array();
32    
33  if ($argv[1])  if ($argv[1])
34  {  {
35    $debug = 1;    $debug = 0;
36    array_push($ids, $argv[1]);    array_push($ids, $argv[1]);
37  }  }
38  else  else
# Line 64  else Line 61  else
61      }      }
62  }  }
63    
   
64  GetPreselection_byRef($db, $host, $user_login, $user_passwd, $ids, $debug);  GetPreselection_byRef($db, $host, $user_login, $user_passwd, $ids, $debug);
65    
66  /*  /*
# Line 76  function GetPreselection_byRef($db, $hos Line 72  function GetPreselection_byRef($db, $hos
72  {    {  
73    $numcli = sizeof($ids);    $numcli = sizeof($ids);
74    $i = 0;    $i = 0;
75    print "$numcli";    print "Nombre de lignes $numcli\n";
76    foreach($ids as $cli)    foreach($ids as $cli)
77      {      {
78        $i++;        $i++;
# Line 121  function GetPreselection_byRef($db, $hos Line 117  function GetPreselection_byRef($db, $hos
117                    $ligne_numero = $array[1];                    $ligne_numero = $array[1];
118                                        
119                    $array = array();                    $array = array();
120                      preg_match('/ServiceActive="([\S]*)"/i', $line, $array);
121                      $service_active = $array[1];
122    
123                      $array = array();
124                      preg_match('/PreSelectionActive="([\S]*)"/i', $line, $array);
125                      $presel_active = $array[1];
126    
127                      $array = array();
128                    preg_match('/Service_Statut="([\S]*)"/i', $line, $array);                    preg_match('/Service_Statut="([\S]*)"/i', $line, $array);
129                    $ligne_service = $array[1];                    $ligne_service = $array[1];
130                                        
# Line 130  function GetPreselection_byRef($db, $hos Line 134  function GetPreselection_byRef($db, $hos
134                                        
135                    print "$i/$numcli ";                    print "$i/$numcli ";
136                    print $ligne_numero." ";                    print $ligne_numero." ";
137                      print "$service_active/$presel_active ";
138                    print substr($ligne_service.str_repeat(" ",20),0,20);                    print substr($ligne_service.str_repeat(" ",20),0,20);
139                    print substr($ligne_presel.str_repeat(" ",20),0,20);                    print substr($ligne_presel.str_repeat(" ",20),0,20);
140                    print "\n";                    print "\n";

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26