Trad: Traductions sur le module prospect
This commit is contained in:
parent
78330e8649
commit
b21470b6f0
@ -38,9 +38,9 @@ $user->getrights('fichinter');
|
||||
$user->getrights('commande');
|
||||
$user->getrights('projet');
|
||||
|
||||
|
||||
$langs->load("orders");
|
||||
$langs->load("companies");
|
||||
$langs->load("contracts");
|
||||
|
||||
|
||||
llxHeader();
|
||||
@ -656,7 +656,7 @@ if ($_socid > 0)
|
||||
*/
|
||||
if ($objsoc->note)
|
||||
{
|
||||
print '<table border="1" width="100%" cellspacing="0" bgcolor="#e0e0e0">';
|
||||
print '<table class="border" width="100%" bgcolor="#e0e0e0">';
|
||||
print "<tr><td>".nl2br($objsoc->note)."</td></tr>";
|
||||
print "</table>";
|
||||
}
|
||||
@ -668,7 +668,7 @@ if ($_socid > 0)
|
||||
|
||||
}
|
||||
} else {
|
||||
print $db->error() . "<br>" . $sql;
|
||||
dolibarr_print_error($db);
|
||||
}
|
||||
|
||||
$db->close();
|
||||
|
||||
@ -20,7 +20,21 @@
|
||||
* $Source$
|
||||
*
|
||||
*/
|
||||
|
||||
/*!
|
||||
\file htdocs/comm/index.php
|
||||
\ingroup commercial
|
||||
\brief Page acceuil de la zone commercial
|
||||
\version $Revision$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
if ($conf->contrat->enabled) {
|
||||
require_once("../contrat/contrat.class.php");
|
||||
}
|
||||
|
||||
$langs->load("commercial");
|
||||
$langs->load("orders");
|
||||
|
||||
$user->getrights('propale');
|
||||
$user->getrights('fichinter');
|
||||
@ -76,7 +90,7 @@ if ($_GET["action"] == 'del_bookmark')
|
||||
|
||||
print_titre("Espace commercial");
|
||||
|
||||
print '<table border="0" width="100%" cellspacing="0" cellpadding="3">';
|
||||
print '<table border="0" width="100%">';
|
||||
|
||||
print '<tr><td valign="top" width="30%">';
|
||||
|
||||
@ -87,7 +101,7 @@ print '<tr><td valign="top" width="30%">';
|
||||
*/
|
||||
if ($conf->propal->enabled) {
|
||||
print '<form method="post" action="propal.php">';
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="2">Rechercher une proposition</td></tr>';
|
||||
print "<tr $bc[1]><td>";
|
||||
print $langs->trans("Ref").' : <input type="text" name="sf_ref"> <input type="submit" value="'.$langs->trans("Search").'" class="flat"></td></tr>';
|
||||
@ -103,7 +117,7 @@ if ($conf->propal->enabled) {
|
||||
$i = 0;
|
||||
if ($num > 0 )
|
||||
{
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print "<tr class=\"liste_titre\">";
|
||||
print "<td colspan=\"2\">Propositions commerciales brouillons</td></tr>";
|
||||
|
||||
@ -137,7 +151,7 @@ if ($conf->commande->enabled)
|
||||
$num = $db->num_rows();
|
||||
if ($num)
|
||||
{
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td colspan="2">'.$langs->trans("OrdersToValid").'</td></tr>';
|
||||
$i = 0;
|
||||
@ -177,9 +191,9 @@ if ( $db->query($sql) )
|
||||
|
||||
$i = 0;
|
||||
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print "<tr class=\"liste_titre\">";
|
||||
print "<td colspan=\"2\">Bookmark</td>";
|
||||
print "<td colspan=\"2\">".$langs->trans("Bookmark")."</td>";
|
||||
print "</tr>\n";
|
||||
|
||||
while ($i < $num)
|
||||
@ -197,9 +211,9 @@ if ( $db->query($sql) )
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
print '</td><td valign="top" width="70%">';
|
||||
|
||||
|
||||
/*
|
||||
* Dernières actions commerciales effectuées
|
||||
*
|
||||
@ -218,7 +232,7 @@ if ( $db->query($sql) )
|
||||
{
|
||||
$num = $db->num_rows();
|
||||
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="4">Dernières actions effectuées</td></tr>';
|
||||
$var = true;
|
||||
$i = 0;
|
||||
@ -243,9 +257,10 @@ if ( $db->query($sql) )
|
||||
}
|
||||
else
|
||||
{
|
||||
print $db->error();
|
||||
dolibarr_print_error($db);
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Actions commerciales a faire
|
||||
*
|
||||
@ -265,8 +280,8 @@ if ( $db->query($sql) )
|
||||
$num = $db->num_rows();
|
||||
if ($num > 0)
|
||||
{
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="4">Actions à faire</td></tr>';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="4">'.$langs->trans("ActionsToDo").'</td></tr>';
|
||||
$var = true;
|
||||
$i = 0;
|
||||
|
||||
@ -306,9 +321,7 @@ else
|
||||
*/
|
||||
if ($conf->contrat->enabled)
|
||||
{
|
||||
$labelservice[0]="Hors service";
|
||||
$labelservice[1]="En service";
|
||||
$labelservice[2]="Cloturé";
|
||||
$langs->load("contracts");
|
||||
|
||||
$sql = "SELECT s.nom, s.idp, c.enservice, c.rowid, p.ref, c.mise_en_service as datemes, c.fin_validite as datefin, c.date_cloture as dateclo";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."contrat as c, ".MAIN_DB_PREFIX."product as p WHERE c.fk_soc = s.idp and c.fk_product = p.rowid";
|
||||
@ -325,10 +338,12 @@ if ($conf->contrat->enabled)
|
||||
|
||||
if ($num > 0)
|
||||
{
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="3">Les 5 derniers contrats</td></tr>';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="3">'.$langs->trans("LastContracts",5).'</td></tr>';
|
||||
$i = 0;
|
||||
|
||||
$contrat=new Contrat($db);
|
||||
|
||||
$var=false;
|
||||
while ($i < $num)
|
||||
{
|
||||
@ -336,7 +351,7 @@ if ($conf->contrat->enabled)
|
||||
print "<tr $bc[$var]><td><a href=\"../contrat/fiche.php?id=".$obj->rowid."\">".img_file()."</a> ";
|
||||
print "<a href=\"../contrat/fiche.php?id=".$obj->rowid."\">".$obj->ref."</a></td>";
|
||||
print "<td><a href=\"fiche.php?socid=$obj->idp\">$obj->nom</a></td>\n";
|
||||
print "<td align=\"right\">".$labelservice[$obj->enservice]."</td></tr>\n";
|
||||
print "<td align=\"right\">".$contrat->LibStatut($obj->enservice)."</td></tr>\n";
|
||||
$var=!$var;
|
||||
$i++;
|
||||
}
|
||||
@ -345,7 +360,7 @@ if ($conf->contrat->enabled)
|
||||
}
|
||||
else
|
||||
{
|
||||
print $db->error();
|
||||
dolibarr_print_error($db);
|
||||
}
|
||||
}
|
||||
|
||||
@ -370,7 +385,7 @@ if ($conf->propal->enabled) {
|
||||
$i = 0;
|
||||
if ($num > 0)
|
||||
{
|
||||
print '<table class="noborder" cellspacing="0" cellpadding="3" width="100%">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="4">Les 5 dernières propositions commerciales ouvertes</td></tr>';
|
||||
$var=false;
|
||||
while ($i < $num)
|
||||
@ -412,7 +427,7 @@ if ($conf->propal->enabled) {
|
||||
$num = $db->num_rows();
|
||||
|
||||
$i = 0;
|
||||
print '<table class="noborder" width="100%" cellspacing="0" cellpadding="3">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td colspan="6">Les 5 dernières propositions commerciales fermées</td></tr>';
|
||||
$var=False;
|
||||
while ($i < $num)
|
||||
@ -438,8 +453,8 @@ if ($conf->propal->enabled) {
|
||||
|
||||
print "<td align=\"right\">";
|
||||
print strftime("%e %b %Y",$objp->dp)."</td>\n";
|
||||
print "<td align=\"right\">".price($objp->price)."</TD>\n";
|
||||
print "<td align=\"center\">$objp->statut</TD>\n";
|
||||
print "<td align=\"right\">".price($objp->price)."</td>\n";
|
||||
print "<td align=\"center\">$objp->statut</td>\n";
|
||||
print "</tr>\n";
|
||||
$i++;
|
||||
$var=!$var;
|
||||
|
||||
@ -20,18 +20,28 @@
|
||||
* $Source$
|
||||
*
|
||||
*/
|
||||
|
||||
/*!
|
||||
\file htdocs/comm/prospect/fiche.php
|
||||
\ingroup prospect
|
||||
\brief Page de la fiche prospect
|
||||
\version $Revision$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
require("../../contact.class.php");
|
||||
require("../../cactioncomm.class.php");
|
||||
require("../../actioncomm.class.php");
|
||||
|
||||
$langs->load('companies');
|
||||
|
||||
$user->getrights('propale');
|
||||
$user->getrights('fichinter');
|
||||
$user->getrights('commande');
|
||||
$user->getrights('projet');
|
||||
|
||||
$langs->load('companies');
|
||||
|
||||
$socid = isset($_GET["id"])?$_GET["id"]:$_GET["socid"]; // Fonctionne si on passe id ou socid
|
||||
|
||||
if ($_GET["action"] == 'cstc')
|
||||
{
|
||||
@ -42,10 +52,7 @@ if ($_GET["action"] == 'cstc')
|
||||
|
||||
llxHeader();
|
||||
|
||||
/*
|
||||
*
|
||||
*/
|
||||
$socid = isset($_GET["id"])?$_GET["id"]:$_GET["socid"]; // Fonctionne si on passe id ou socid
|
||||
|
||||
/*
|
||||
* Sécurité si un client essaye d'accéder à une autre fiche que la sienne
|
||||
*/
|
||||
@ -53,6 +60,8 @@ if ($user->societe_id > 0)
|
||||
{
|
||||
$socid = $user->societe_id;
|
||||
}
|
||||
|
||||
|
||||
/*********************************************************************************
|
||||
*
|
||||
* Mode fiche
|
||||
@ -81,6 +90,7 @@ if ($socid > 0)
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT.'/comm/prospect/fiche.php?id='.$societe->id;
|
||||
$head[$h][1] = 'Prospect';
|
||||
$hselected=$h;
|
||||
$h++;
|
||||
|
||||
if (file_exists(DOL_DOCUMENT_ROOT.'/sl/'))
|
||||
@ -97,19 +107,20 @@ if ($socid > 0)
|
||||
$h++;
|
||||
}
|
||||
$head[$h][0] = DOL_URL_ROOT.'/socnote.php?socid='.$societe->id;
|
||||
$head[$h][1] = 'Note';
|
||||
$head[$h][1] = $langs->trans("Note");
|
||||
$h++;
|
||||
if ($user->societe_id == 0)
|
||||
{
|
||||
$head[$h][0] = DOL_URL_ROOT.'/docsoc.php?socid='.$societe->id;
|
||||
$head[$h][1] = 'Documents';
|
||||
$head[$h][1] = $langs->trans("Documents");
|
||||
$h++;
|
||||
}
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT.'/societe/notify/fiche.php?socid='.$societe->id;
|
||||
$head[$h][1] = 'Notifications';
|
||||
$head[$h][1] = $langs->trans("Notifications");
|
||||
|
||||
dolibarr_fiche_head($head, 1, $societe->nom);
|
||||
|
||||
dolibarr_fiche_head($head, $hselected, $societe->nom);
|
||||
|
||||
/*
|
||||
*
|
||||
@ -117,10 +128,10 @@ if ($socid > 0)
|
||||
*/
|
||||
print '<table width="100%" border="0">';
|
||||
print '<tr><td valign="top">';
|
||||
print '<table class="border" cellspacing="0" cellpadding="3" border="1" width="100%">';
|
||||
print '<table class="border" width="100%">';
|
||||
|
||||
print "<tr><td>Téléphone</td><td align=\"center\">".dolibarr_print_phone($societe->tel)." </td><td>fax</td><td align=\"center\">".dolibarr_print_phone($societe->fax)." </td></tr>";
|
||||
print '<tr><td valign="top">Adresse</td><td colspan="3">'.nl2br($societe->address)."<br>$societe->cp $societe->ville</td></tr>";
|
||||
print "<tr><td>".$langs->trans("Phone")."</td><td align=\"center\">".dolibarr_print_phone($societe->tel)." </td><td>fax</td><td align=\"center\">".dolibarr_print_phone($societe->fax)." </td></tr>";
|
||||
print '<tr><td valign="top">'.$langs->trans("Address").'</td><td colspan="3">'.nl2br($societe->address)."<br>$societe->cp $societe->ville</td></tr>";
|
||||
|
||||
print '<tr><td>Siret</td><td>'.$societe->siret.'</td>';
|
||||
print '<td>Capital</td><td>'.$societe->capital.'</td></tr>';
|
||||
@ -153,7 +164,7 @@ if ($socid > 0)
|
||||
|
||||
print '</a>';
|
||||
print '</td></tr>';
|
||||
print "</table></div>";
|
||||
print "</table><br></div>";
|
||||
|
||||
/*
|
||||
*
|
||||
@ -167,7 +178,7 @@ if ($socid > 0)
|
||||
*
|
||||
*/
|
||||
$var = true;
|
||||
print '<table border="0" width="100%" cellspacing="0" cellpadding="1">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
$sql = "SELECT s.nom, s.idp, p.rowid as propalid, p.price, p.ref, p.remise, ".$db->pdate("p.datep")." as dp, c.label as statut, c.id as statutid";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."propal as p, ".MAIN_DB_PREFIX."c_propalst as c WHERE p.fk_soc = s.idp AND p.fk_statut = c.id";
|
||||
$sql .= " AND s.idp = $societe->id ORDER BY p.datep DESC";
|
||||
@ -202,12 +213,11 @@ if ($socid > 0)
|
||||
}
|
||||
|
||||
print "</table>";
|
||||
/*
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
print "</td></tr>";
|
||||
print "</table>\n</div>\n";
|
||||
|
||||
|
||||
/*
|
||||
* Barre d'action
|
||||
*
|
||||
@ -233,7 +243,7 @@ if ($socid > 0)
|
||||
* Liste des contacts
|
||||
*
|
||||
*/
|
||||
print '<table width="100%" cellspacing="1" border="0" cellpadding="2">';
|
||||
print '<table width="100%" class="noborder">';
|
||||
|
||||
print '<tr class="liste_titre"><td>'.$langs->trans("Firstname").' '.$langs->trans("Name").'</td>';
|
||||
print '<td>Poste</td><td colspan="2">'.$langs->trans("Tel").'</td>';
|
||||
@ -287,8 +297,8 @@ if ($socid > 0)
|
||||
* Listes des actions a faire
|
||||
*
|
||||
*/
|
||||
print '<table width="100%" cellspacing=0 border=0 cellpadding=2>';
|
||||
print '<tr class="liste_titre"><td>Actions à faire</td><td align="right"> [<a href="../action/fiche.php?action=create&socid='.$socid.'&afaire=1">Nouvelle action</a>]</td></tr>';
|
||||
print '<table width="100%" class="noborder">';
|
||||
print '<tr class="liste_titre"><td>'.$langs->trans("ActionsToDo").'</td><td align="right"> [<a href="../action/fiche.php?action=create&socid='.$socid.'&afaire=1">'.$langs->trans("AddAction").'</a>]</td></tr>';
|
||||
print '<tr>';
|
||||
print '<td colspan="2" valign="top">';
|
||||
|
||||
@ -300,7 +310,7 @@ if ($socid > 0)
|
||||
$sql .= " ORDER BY a.datea DESC, a.id DESC";
|
||||
|
||||
if ( $db->query($sql) ) {
|
||||
print "<table width=\"100%\" cellspacing=0 border=0 cellpadding=2>\n";
|
||||
print "<table width=\"100%\" class=\"noborder\">\n";
|
||||
|
||||
$i = 0 ; $num = $db->num_rows();
|
||||
while ($i < $num) {
|
||||
@ -313,27 +323,27 @@ if ($socid > 0)
|
||||
if ($oldyear == strftime("%Y",$obj->da) )
|
||||
{
|
||||
//print '<td align="center">|</td>';
|
||||
print '<td align="center">' .strftime("%Y",$obj->da)."</TD>\n";
|
||||
print '<td align="center">' .strftime("%Y",$obj->da)."</td>\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td align="center">' .strftime("%Y",$obj->da)."</TD>\n";
|
||||
print '<td align="center">' .strftime("%Y",$obj->da)."</td>\n";
|
||||
$oldyear = strftime("%Y",$obj->da);
|
||||
}
|
||||
|
||||
if ($oldmonth == strftime("%Y%b",$obj->da) )
|
||||
{
|
||||
// print '<td align="center">|</td>';
|
||||
print "<TD align=\"center\">" .strftime("%b",$obj->da)."</TD>\n";
|
||||
print "<TD align=\"center\">" .strftime("%b",$obj->da)."</td>\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
print "<TD align=\"center\">" .strftime("%b",$obj->da)."</TD>\n";
|
||||
print "<TD align=\"center\">" .strftime("%b",$obj->da)."</td>\n";
|
||||
$oldmonth = strftime("%Y%b",$obj->da);
|
||||
}
|
||||
|
||||
print "<TD>" .strftime("%d",$obj->da)."</TD>\n";
|
||||
print "<TD>" .strftime("%H:%M",$obj->da)."</TD>\n";
|
||||
print "<TD>" .strftime("%d",$obj->da)."</td>\n";
|
||||
print "<TD>" .strftime("%H:%M",$obj->da)."</td>\n";
|
||||
|
||||
print '<td width="10%"> </td>';
|
||||
|
||||
@ -349,6 +359,7 @@ if ($socid > 0)
|
||||
print '<a href="'.DOL_URL_ROOT.'/comm/action/fiche.php?id='.$obj->id.'">'.$obj->libelle.'</a>';
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
/*
|
||||
* Contact pour cette action
|
||||
*
|
||||
@ -374,7 +385,7 @@ if ($socid > 0)
|
||||
|
||||
$db->free();
|
||||
} else {
|
||||
print $db->error();
|
||||
dolibarr_print_error($db);
|
||||
}
|
||||
print "</td></tr></table>";
|
||||
|
||||
@ -399,7 +410,7 @@ if ($socid > 0)
|
||||
{
|
||||
|
||||
print '<table width="100%" class="noborder">';
|
||||
print '<tr class="liste_titre"><td><a href="action/index.php?socid='.$socid.'">Actions effectuées</a></td></tr>';
|
||||
print '<tr class="liste_titre"><td><a href="action/index.php?socid='.$socid.'">'.$langs->trans("ActionsDone").'</a></td></tr>';
|
||||
print '<tr>';
|
||||
print '<td valign="top">';
|
||||
|
||||
@ -420,7 +431,7 @@ if ($socid > 0)
|
||||
}
|
||||
else
|
||||
{
|
||||
print "<TD align=\"center\">" .strftime("%Y",$obj->da)."</TD>\n";
|
||||
print "<td align=\"center\">" .strftime("%Y",$obj->da)."</td>\n";
|
||||
$oldyear = strftime("%Y",$obj->da);
|
||||
}
|
||||
|
||||
@ -430,7 +441,7 @@ if ($socid > 0)
|
||||
}
|
||||
else
|
||||
{
|
||||
print "<td align=\"center\">" .strftime("%b",$obj->da)."</TD>\n";
|
||||
print "<td align=\"center\">" .strftime("%b",$obj->da)."</td>\n";
|
||||
$oldmonth = strftime("%Y%b",$obj->da);
|
||||
}
|
||||
|
||||
@ -486,7 +497,7 @@ if ($socid > 0)
|
||||
}
|
||||
else
|
||||
{
|
||||
print $db->error();
|
||||
dolibarr_print_error($db);
|
||||
}
|
||||
|
||||
/*
|
||||
@ -496,7 +507,7 @@ if ($socid > 0)
|
||||
*/
|
||||
if (strlen(trim($societe->note)))
|
||||
{
|
||||
print '<table border="1" width="100%" cellspacing="0" bgcolor="#e0e0e0">';
|
||||
print '<table class="border" width="100%" bgcolor="#e0e0e0">';
|
||||
print "<tr><td>".nl2br($societe->note)."</td></tr>";
|
||||
print "</table>";
|
||||
}
|
||||
@ -510,7 +521,7 @@ if ($socid > 0)
|
||||
}
|
||||
else
|
||||
{
|
||||
print $db->error() . "<br>" . $sql;
|
||||
dolibarr_print_error($db);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Loading…
Reference in New Issue
Block a user