diff --git a/htdocs/telephonie/contrat/fiche.php b/htdocs/telephonie/contrat/fiche.php index 291fe920257..b99378a54a0 100644 --- a/htdocs/telephonie/contrat/fiche.php +++ b/htdocs/telephonie/contrat/fiche.php @@ -577,7 +577,7 @@ else print ''; - $sql = "SELECT l.ligne, l.statut, l.rowid, l.remise, f.nom as fournisseur"; + $sql = "SELECT l.ligne, l.statut, l.rowid, l.remise, l.techno, f.nom as fournisseur"; $sql .= ", ss.code_client, ss.nom as agence"; $sql .= " FROM ".MAIN_DB_PREFIX."telephonie_societe_ligne as l"; $sql .= " , ".MAIN_DB_PREFIX."societe as ss"; @@ -622,7 +622,8 @@ else print '\n"; print '\n"; - print "\n"; + print "\n"; print "\n"; $i++; } diff --git a/htdocs/telephonie/ligne/fiche.php b/htdocs/telephonie/ligne/fiche.php index 30f2e828660..938e1d189db 100644 --- a/htdocs/telephonie/ligne/fiche.php +++ b/htdocs/telephonie/ligne/fiche.php @@ -46,6 +46,7 @@ if ($_POST["action"] == 'add' && $user->rights->telephonie->ligne->creer) $ligne->concurrent = $_POST["concurrent"]; $ligne->remise = $_POST["remise"]; $ligne->note = $_POST["note"]; + $ligne->techno = $_POST["techno"]; if ( $ligne->create($user) == 0) { @@ -375,7 +376,7 @@ elseif ($_GET["action"] == 'create' && $_GET["contratid"] > 0) print ''; - print ''; + print ''; $client = new Societe($db, $contrat->client_id); $client->fetch($contrat->client_id); @@ -417,6 +418,13 @@ elseif ($_GET["action"] == 'create' && $_GET["contratid"] > 0) } $form->select_array("fournisseur",$ff,$ligne->fournisseur); + + $tech = array(); + $tech["presel"] = "Présélection"; + $tech["voip"] = "VoIP"; + print " Technologie : "; + $form->select_array("techno",$tech,"presel"); + print ''; /* diff --git a/htdocs/telephonie/lignetel.class.php b/htdocs/telephonie/lignetel.class.php index 6b116977447..c841ae71b0b 100644 --- a/htdocs/telephonie/lignetel.class.php +++ b/htdocs/telephonie/lignetel.class.php @@ -236,6 +236,15 @@ class LigneTel { $this->DefineClientOption(); + if ($this->techno == 'voip' && $this->id) + { + $sql = "UPDATE ".MAIN_DB_PREFIX."telephonie_societe_ligne"; + $sql .= " SET statut = 3, techno='voip'"; + $sql .= " WHERE rowid=".$this->id; + $this->db->query($sql); + } + + return 0; } else
'.$ligne->statuts[$obj->statut]."'.$obj->remise." %".$obj->fournisseur."".$obj->fournisseur." - \n"; + print $obj->techno."
Numéro
Numéro