Ajoute le champs fournisseur dans le tableau
This commit is contained in:
parent
4598412e18
commit
e20cc8cdb2
@ -25,11 +25,11 @@ require_once DOL_DOCUMENT_ROOT.'/telephonie/fournisseurtel.class.php';
|
|||||||
$dir = $conf->telephonie->dir_output."/cdr/atraiter/" ;
|
$dir = $conf->telephonie->dir_output."/cdr/atraiter/" ;
|
||||||
|
|
||||||
$files = array();
|
$files = array();
|
||||||
|
$fourn_files = array();
|
||||||
|
|
||||||
$obj = new FournisseurTelephonie($db,$user);
|
$obj = new FournisseurTelephonie($db,$user);
|
||||||
$fourns = $obj->GetActives();
|
$fourns = $obj->GetActives();
|
||||||
|
|
||||||
$var=true;
|
|
||||||
foreach ($fourns as $id => $nom)
|
foreach ($fourns as $id => $nom)
|
||||||
{
|
{
|
||||||
$fdir = $dir . $id.'/';
|
$fdir = $dir . $id.'/';
|
||||||
@ -39,18 +39,17 @@ foreach ($fourns as $id => $nom)
|
|||||||
while (($file = readdir($handle))!==false)
|
while (($file = readdir($handle))!==false)
|
||||||
{
|
{
|
||||||
if (is_file($fdir.'/'.$file))
|
if (is_file($fdir.'/'.$file))
|
||||||
array_push($files, $id.'/'.$file);
|
{
|
||||||
|
array_push($files, $id.'/'.$file);
|
||||||
|
$fourn_files[$id.'/'.$file] = $nom;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
closedir($handle);
|
closedir($handle);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (!$user->rights->telephonie->facture->lire) accessforbidden();
|
if (!$user->rights->telephonie->facture->ecrire) accessforbidden();
|
||||||
|
|
||||||
$page = $_GET["page"];
|
|
||||||
$sortorder = $_GET["sortorder"];
|
|
||||||
$sortfield = $_GET["sortfield"];
|
|
||||||
|
|
||||||
llxHeader();
|
llxHeader();
|
||||||
|
|
||||||
@ -63,33 +62,14 @@ if ($user->societe_id > 0)
|
|||||||
$socid = $user->societe_id;
|
$socid = $user->societe_id;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($sortorder == "") {
|
|
||||||
$sortorder="";
|
|
||||||
}
|
|
||||||
if ($sortfield == "") {
|
|
||||||
$sortfield="f.date DESC, f.gain ASC";
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Recherche
|
|
||||||
*
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
|
|
||||||
if ($page == -1) { $page = 0 ; }
|
|
||||||
|
|
||||||
$offset = $conf->liste_limit * $page ;
|
|
||||||
$pageprev = $page - 1;
|
|
||||||
$pagenext = $page + 1;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Mode Liste
|
* Mode Liste
|
||||||
*/
|
*/
|
||||||
|
|
||||||
print_barre_liste("Fichiers CDR a traiter", $page, "files.php", "", $sortfield, $sortorder, '', $num);
|
print_barre_liste("Fichiers CDR a traiter", $page, "files.php", "", $sortfield, $sortorder, '', $num);
|
||||||
|
|
||||||
print '<table class="noborder" width="100%" cellspacing="0" cellpadding="4">';
|
print '<table class="noborder" width="100%" cellspacing="0" cellpadding="4">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre"><td>Fournisseur</td>';
|
||||||
print '<td>Fichier</td><td>Date</td>';
|
print '<td>Fichier</td><td>Date</td>';
|
||||||
print '<td align="right">Taille</td>';
|
print '<td align="right">Taille</td>';
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
@ -98,11 +78,12 @@ $var=True;
|
|||||||
|
|
||||||
foreach ($files as $file)
|
foreach ($files as $file)
|
||||||
{
|
{
|
||||||
$obj = $db->fetch_object($i);
|
|
||||||
$var=!$var;
|
$var=!$var;
|
||||||
|
|
||||||
print "<tr $bc[$var]>";
|
print "<tr $bc[$var]>";
|
||||||
|
|
||||||
|
print '<td>'.$fourn_files[$file].'</td>';
|
||||||
|
|
||||||
print '<td>';
|
print '<td>';
|
||||||
print img_file();
|
print img_file();
|
||||||
print ' ';
|
print ' ';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user