Look: Modifications esthétiques mineures

This commit is contained in:
Laurent Destailleur 2006-04-29 00:35:00 +00:00
parent 28e3e859e4
commit 269139259e
9 changed files with 122 additions and 102 deletions

View File

@ -35,6 +35,10 @@ require_once(DOL_DOCUMENT_ROOT."/actioncomm.class.php");
$langs->load("companies"); $langs->load("companies");
$socidp = isset($_GET["socid"])?$_GET["socid"]:$_POST["socid"];
$sortfield = isset($_GET["sortfield"])?$_GET["sortfield"]:$_POST["sortfield"];
$sortorder = isset($_GET["sortorder"])?$_GET["sortorder"]:$_POST["sortorder"];
$page = isset($_GET["page"])?$_GET["page"]:$_POST["page"];
// Sécurité accés client // Sécurité accés client
if ($user->societe_id > 0) if ($user->societe_id > 0)
@ -43,11 +47,6 @@ if ($user->societe_id > 0)
$socidp = $user->societe_id; $socidp = $user->societe_id;
} }
$sortfield = isset($_GET["sortfield"])?$_GET["sortfield"]:$_POST["sortfield"];
$sortorder = isset($_GET["sortorder"])?$_GET["sortorder"]:$_POST["sortorder"];
$page = isset($_GET["page"])?$_GET["page"]:$_POST["page"];
if ($page == -1) { $page = 0 ; } if ($page == -1) { $page = 0 ; }
$limit = $conf->liste_limit; $limit = $conf->liste_limit;
$offset = $limit * $page ; $offset = $limit * $page ;

View File

@ -401,7 +401,7 @@ if ($socidp > 0)
if ($num > 0) if ($num > 0)
{ {
print '<tr class="liste_titre">'; print '<tr class="liste_titre">';
print '<td colspan="4"><table width="100%" class="noborder"><tr><td>'.$langs->trans("LastPropals",($num<=$MAXLIST?"":$MAXLIST)).'</td><td align="right"><a href="'.DOL_URL_ROOT.'/comm/propal.php?socidp='.$objsoc->id.'">'.$langs->trans("AllPropals").' ('.$num.')</td></tr></table></td>'; print '<td colspan="4"><table width="100%" class="noborder"><tr><td>'.$langs->trans("LastPropals",($num<=$MAXLIST?"":$MAXLIST)).'</td><td align="right"><a href="'.DOL_URL_ROOT.'/comm/propal.php?socidp='.$objsoc->id.'">'.$langs->trans("AllPropals").' ('.$num.')</a></td></tr></table></td>';
print '</tr>'; print '</tr>';
$var=!$var; $var=!$var;
} }
@ -499,7 +499,7 @@ if ($socidp > 0)
{ {
print '<tr class="liste_titre">'; print '<tr class="liste_titre">';
print '<td colspan="4"><table width="100%" class="noborder"><tr><td>'.$langs->trans("LastContracts",($num<=$MAXLIST?"":$MAXLIST)).'</td>'; print '<td colspan="4"><table width="100%" class="noborder"><tr><td>'.$langs->trans("LastContracts",($num<=$MAXLIST?"":$MAXLIST)).'</td>';
print '<td align="right"><a href="'.DOL_URL_ROOT.'/contrat/liste.php?socid='.$objsoc->id.'">'.$langs->trans("AllContracts").' ('.$num.')</td></tr></table></td>'; print '<td align="right"><a href="'.DOL_URL_ROOT.'/contrat/liste.php?socid='.$objsoc->id.'">'.$langs->trans("AllContracts").' ('.$num.')</a></td></tr></table></td>';
print '</tr>'; print '</tr>';
} }
$i = 0; $i = 0;
@ -678,9 +678,10 @@ if ($socidp > 0)
$user->fetch_clicktodial(); // lecture des infos de clicktodial $user->fetch_clicktodial(); // lecture des infos de clicktodial
} }
print_titre($langs->trans("ContactsForCompany"));
print '<table class="noborder" width="100%">'; print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td>'.$langs->trans("Firstname").' '.$langs->trans("Lastname").'</td>'; print '<tr class="liste_titre"><td>'.$langs->trans("Name").'</td>';
print '<td>'.$langs->trans("Poste").'</td><td colspan="2">'.$langs->trans("Tel").'</td>'; print '<td>'.$langs->trans("Poste").'</td><td colspan="2">'.$langs->trans("Tel").'</td>';
print '<td>'.$langs->trans("Fax").'</td><td>'.$langs->trans("EMail").'</td>'; print '<td>'.$langs->trans("Fax").'</td><td>'.$langs->trans("EMail").'</td>';
print "<td>&nbsp;</td>"; print "<td>&nbsp;</td>";
@ -689,7 +690,7 @@ if ($socidp > 0)
$sql = "SELECT p.idp, p.name, p.firstname, p.poste, p.phone, p.fax, p.email, p.note "; $sql = "SELECT p.idp, p.name, p.firstname, p.poste, p.phone, p.fax, p.email, p.note ";
$sql .= " FROM ".MAIN_DB_PREFIX."socpeople as p"; $sql .= " FROM ".MAIN_DB_PREFIX."socpeople as p";
$sql .= " WHERE p.fk_soc = $objsoc->id"; $sql .= " WHERE p.fk_soc = ".$objsoc->id;
$sql .= " ORDER by p.datec"; $sql .= " ORDER by p.datec";
$result = $db->query($sql); $result = $db->query($sql);
@ -747,8 +748,10 @@ if ($socidp > 0)
* Listes des actions a faire * Listes des actions a faire
* *
*/ */
print_titre($langs->trans("ActionsOnCompany"));
print '<table width="100%" class="noborder">'; print '<table width="100%" class="noborder">';
print '<tr class="liste_titre"><td colspan="10"><a href="action/index.php?socid='.$objsoc->id.'">'.$langs->trans("ActionsToDo").'</a></td><td align="right">&nbsp;</td></tr>'; print '<tr class="liste_titre"><td colspan="10"><a href="'.DOL_URL_ROOT.'/comm/action/index.php?socid='.$objsoc->id.'&amp;status=todo">'.$langs->trans("ActionsToDoShort").'</a></td><td align="right">&nbsp;</td></tr>';
$sql = "SELECT a.id, a.label, ".$db->pdate("a.datep")." as dp, c.code as acode, c.libelle, u.code, a.propalrowid, a.fk_user_author, fk_contact, u.rowid "; $sql = "SELECT a.id, a.label, ".$db->pdate("a.datep")." as dp, c.code as acode, c.libelle, u.code, a.propalrowid, a.fk_user_author, fk_contact, u.rowid ";
$sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u "; $sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u ";
@ -764,90 +767,98 @@ if ($socidp > 0)
$num = $db->num_rows($result); $num = $db->num_rows($result);
$var=true; $var=true;
while ($i < $num) if ($num)
{ {
$var = !$var; while ($i < $num)
{
$var = !$var;
$obj = $db->fetch_object($result); $obj = $db->fetch_object($result);
print "<tr $bc[$var]>"; print "<tr $bc[$var]>";
if ($oldyear == strftime("%Y",$obj->dp) ) if ($oldyear == strftime("%Y",$obj->dp) )
{ {
print '<td width="30" align="center">|</td>'; print '<td width="30" align="center">|</td>';
} }
else else
{ {
print '<td width="30" align="center">'.strftime("%Y",$obj->dp)."</td>\n"; print '<td width="30" align="center">'.strftime("%Y",$obj->dp)."</td>\n";
$oldyear = strftime("%Y",$obj->dp); $oldyear = strftime("%Y",$obj->dp);
} }
if ($oldmonth == strftime("%Y%b",$obj->dp) ) if ($oldmonth == strftime("%Y%b",$obj->dp) )
{ {
print '<td width="30" align="center">|</td>'; print '<td width="30" align="center">|</td>';
} }
else else
{ {
print '<td width="30" align="center">' .strftime("%b",$obj->dp)."</td>\n"; print '<td width="30" align="center">' .strftime("%b",$obj->dp)."</td>\n";
$oldmonth = strftime("%Y%b",$obj->dp); $oldmonth = strftime("%Y%b",$obj->dp);
} }
print '<td width="20">'.strftime("%d",$obj->dp)."</td>\n"; print '<td width="20">'.strftime("%d",$obj->dp)."</td>\n";
print '<td width="30" nowrap="nowrap">'.strftime("%H:%M",$obj->dp).'</td>'; print '<td width="30" nowrap="nowrap">'.strftime("%H:%M",$obj->dp).'</td>';
// Picto warning // Picto warning
print '<td width="16">'; print '<td width="16">';
if (date("U",$obj->dp) < time()) print ' '.img_warning("Late"); if (date("U",$obj->dp) < time()) print ' '.img_warning("Late");
else print '&nbsp;'; else print '&nbsp;';
print '</td>'; print '</td>';
// Status/Percent // Status/Percent
print '<td width="30">&nbsp;</td>'; print '<td width="30">&nbsp;</td>';
if ($obj->propalrowid) if ($obj->propalrowid)
{ {
print '<td><a href="propal.php?propalid='.$obj->propalrowid.'">'.img_object($langs->trans("ShowAction"),"task"); print '<td><a href="propal.php?propalid='.$obj->propalrowid.'">'.img_object($langs->trans("ShowAction"),"task");
$transcode=$langs->trans("Action".$obj->acode); $transcode=$langs->trans("Action".$obj->acode);
$libelle=($transcode!="Action".$obj->acode?$transcode:$obj->libelle); $libelle=($transcode!="Action".$obj->acode?$transcode:$obj->libelle);
print $libelle; print $libelle;
print '</a></td>'; print '</a></td>';
} }
else else
{ {
print '<td><a href="action/fiche.php?id='.$obj->id.'">'.img_object($langs->trans("ShowAction"),"task"); print '<td><a href="action/fiche.php?id='.$obj->id.'">'.img_object($langs->trans("ShowAction"),"task");
$transcode=$langs->trans("Action".$obj->acode); $transcode=$langs->trans("Action".$obj->acode);
$libelle=($transcode!="Action".$obj->acode?$transcode:$obj->libelle); $libelle=($transcode!="Action".$obj->acode?$transcode:$obj->libelle);
print $libelle; print $libelle;
print '</a></td>'; print '</a></td>';
} }
print '<td colspan="2">'.$obj->label.'</td>'; print '<td colspan="2">'.$obj->label.'</td>';
// Contact pour cette action // Contact pour cette action
if ($obj->fk_contact) { if ($obj->fk_contact) {
$contact = new Contact($db); $contact = new Contact($db);
$contact->fetch($obj->fk_contact); $contact->fetch($obj->fk_contact);
print '<td><a href="'.DOL_URL_ROOT.'/contact/fiche.php?id='.$contact->id.'">'.img_object($langs->trans("ShowContact"),"contact").' '.$contact->fullname.'</a></td>'; print '<td><a href="'.DOL_URL_ROOT.'/contact/fiche.php?id='.$contact->id.'">'.img_object($langs->trans("ShowContact"),"contact").' '.$contact->fullname.'</a></td>';
} else { } else {
print '<td>&nbsp;</td>'; print '<td>&nbsp;</td>';
} }
print '<td width="50"><a href="'.DOL_URL_ROOT.'/user/fiche.php?id='.$obj->fk_user_author.'">'.img_object($langs->trans("ShowUser"),"user").' '.$obj->code.'</a></td>'; print '<td width="50"><a href="'.DOL_URL_ROOT.'/user/fiche.php?id='.$obj->fk_user_author.'">'.img_object($langs->trans("ShowUser"),"user").' '.$obj->code.'</a></td>';
print "</tr>\n"; print "</tr>\n";
$i++; $i++;
} }
print "</table>"; }
else
{
// Aucun action à faire
}
$db->free($result); $db->free($result);
} else { } else {
dolibarr_print_error($db); dolibarr_print_error($db);
} }
print "</table><br>"; print "</table>";
print "<br>";
/* /*
* Listes des actions effectuees * Listes des actions effectuees
*/ */
print '<table class="noborder" width="100%">'; print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td colspan="11"><a href="action/index.php?socid='.$objsoc->id.'">'.$langs->trans("ActionsDone").'</a></td></tr>'; print '<tr class="liste_titre"><td colspan="11"><a href="'.DOL_URL_ROOT.'/comm/action/index.php?socid='.$objsoc->id.'&amp;status=done">'.$langs->trans("ActionsDoneShort").'</a></td></tr>';
$sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da,"; $sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da,";
$sql.= " a.propalrowid, a.fk_facture, a.fk_user_author, a.fk_contact,"; $sql.= " a.propalrowid, a.fk_facture, a.fk_user_author, a.fk_contact,";

View File

@ -382,9 +382,10 @@ if ($socid > 0)
* Liste des contacts * Liste des contacts
* *
*/ */
print_titre($langs->trans("ContactsForCompany"));
print '<table class="noborder" width="100%">'; print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td>'.$langs->trans("Firstname").' '.$langs->trans("Lastname").'</td>'; print '<tr class="liste_titre"><td>'.$langs->trans("Name").'</td>';
print '<td>'.$langs->trans("Poste").'</td><td>'.$langs->trans("Tel").'</td>'; print '<td>'.$langs->trans("Poste").'</td><td>'.$langs->trans("Tel").'</td>';
print '<td>'.$langs->trans("Fax").'</td><td>'.$langs->trans("EMail").'</td>'; print '<td>'.$langs->trans("Fax").'</td><td>'.$langs->trans("EMail").'</td>';
print "<td align=\"center\">&nbsp;</td>"; print "<td align=\"center\">&nbsp;</td>";
@ -447,8 +448,9 @@ if ($socid > 0)
* Listes des actions a faire * Listes des actions a faire
* *
*/ */
print_titre($langs->trans("ActionsOnCompany"));
print '<table width="100%" class="noborder">'; print '<table width="100%" class="noborder">';
print '<tr class="liste_titre"><td colspan="10"><a href="action/index.php?socid='.$societe->id.'">'.$langs->trans("ActionsToDo").'</a></td><td align="right">&nbsp;</td></tr>'; print '<tr class="liste_titre"><td colspan="10"><a href="'.DOL_URL_ROOT.'/comm/action/index.php?socid='.$societe->id.'&amp;status=todo">'.$langs->trans("ActionsToDoShort").'</a></td><td align="right">&nbsp;</td></tr>';
$sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da, c.code as acode, c.libelle, u.code, a.propalrowid, a.fk_user_author, fk_contact, u.rowid "; $sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da, c.code as acode, c.libelle, u.code, a.propalrowid, a.fk_user_author, fk_contact, u.rowid ";
$sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u "; $sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u ";
@ -547,7 +549,7 @@ if ($socid > 0)
* Listes des actions effectuées * Listes des actions effectuées
*/ */
print '<table width="100%" class="noborder">'; print '<table width="100%" class="noborder">';
print '<tr class="liste_titre"><td colspan="11"><a href="action/index.php?socid='.$societe->id.'">'.$langs->trans("ActionsDone").'</a></td></tr>'; print '<tr class="liste_titre"><td colspan="11"><a href="'.DOL_URL_ROOT.'/comm/action/index.php?socid='.$societe->id.'&amp;status=done">'.$langs->trans("ActionsDoneShort").'</a></td></tr>';
$sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da,"; $sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da,";
$sql.= " a.propalrowid, a.fk_facture, a.fk_user_author, a.fk_contact,"; $sql.= " a.propalrowid, a.fk_facture, a.fk_user_author, a.fk_contact,";

View File

@ -298,9 +298,12 @@ if ( $societe->fetch($socid) )
*/ */
$langs->load("companies"); $langs->load("companies");
print '<br><table class="noborder" width="100%">'; print '<br>';
print '<tr class="liste_titre"><td>'.$langs->trans("Firstname").' '.$langs->trans("Lastname").'</td>'; print_titre($langs->trans("ContactsForCompany"));
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td>'.$langs->trans("Name").'</td>';
print '<td>'.$langs->trans("Poste").'</td><td>'.$langs->trans("Tel").'</td>'; print '<td>'.$langs->trans("Poste").'</td><td>'.$langs->trans("Tel").'</td>';
print "<td>".$langs->trans("Fax")."</td><td>".$langs->trans("EMail")."</td>"; print "<td>".$langs->trans("Fax")."</td><td>".$langs->trans("EMail")."</td>";
print "<td align=\"center\">&nbsp;</td>"; print "<td align=\"center\">&nbsp;</td>";
@ -359,8 +362,9 @@ if ( $societe->fetch($socid) )
* Listes des actions a faire * Listes des actions a faire
* *
*/ */
print_titre($langs->trans("ActionsOnCompany"));
print '<table width="100%" class="noborder">'; print '<table width="100%" class="noborder">';
print '<tr class="liste_titre"><td colspan="10"><a href="action/index.php?socid='.$societe->id.'">'.$langs->trans("ActionsToDo").'</a></td><td align="right">&nbsp;</td></tr>'; print '<tr class="liste_titre"><td colspan="10"><a href="'.DOL_URL_ROOT.'/comm/action/index.php?socid='.$societe->id.'&amp;status=todo">'.$langs->trans("ActionsToDoShort").'</a></td><td align="right">&nbsp;</td></tr>';
$sql = "SELECT a.id, a.label, ".$db->pdate("a.datep")." as dp, c.code as acode, c.libelle, u.code, a.propalrowid, a.fk_user_author, fk_contact, u.rowid "; $sql = "SELECT a.id, a.label, ".$db->pdate("a.datep")." as dp, c.code as acode, c.libelle, u.code, a.propalrowid, a.fk_user_author, fk_contact, u.rowid ";
$sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u "; $sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u ";
@ -460,7 +464,7 @@ if ( $societe->fetch($socid) )
* Listes des actions effectuées * Listes des actions effectuées
*/ */
print '<table width="100%" class="noborder">'; print '<table width="100%" class="noborder">';
print '<tr class="liste_titre"><td colspan="11"><a href="action/index.php?socid='.$societe->id.'">'.$langs->trans("ActionsDone").'</a></td></tr>'; print '<tr class="liste_titre"><td colspan="11"><a href="'.DOL_URL_ROOT.'/comm/action/index.php?socid='.$societe->id.'&amp;status=done">'.$langs->trans("ActionsDoneShort").'</a></td></tr>';
$sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da,"; $sql = "SELECT a.id, a.label, ".$db->pdate("a.datea")." as da,";
$sql.= " a.propalrowid, a.fk_facture, a.fk_user_author, a.fk_contact,"; $sql.= " a.propalrowid, a.fk_facture, a.fk_user_author, a.fk_contact,";

View File

@ -33,13 +33,13 @@ ListOfProspects=List of prospects
ListOfCustomers=List of customers ListOfCustomers=List of customers
LastDoneTasks=Last %s done tasks LastDoneTasks=Last %s done tasks
LastRecordedTasks=Last recorded tasks LastRecordedTasks=Last recorded tasks
DoneAndToDoActionsFor=Done and To do tasks for DoneAndToDoActionsFor=Done and To do tasks for %s
DoneAndToDoActions=Done and To do tasks DoneAndToDoActions=Done and To do tasks
DoneActions=Done actions DoneActions=Done actions
DoneActionsFor=Done actions for DoneActionsFor=Done actions for %s
MenuToDoActions=Uncomplete actions MenuToDoActions=Uncomplete actions
ToDoActions=Uncomplete actions ToDoActions=Uncomplete actions
ToDoActionsFor=Uncomplete actions for ToDoActionsFor=Uncomplete actions for %s
SendPropalRef=Send commercial proposal %s SendPropalRef=Send commercial proposal %s
NoRecordedProspects=No prospect recorded NoRecordedProspects=No prospect recorded
StatusActionToDo=To do StatusActionToDo=To do

View File

@ -45,8 +45,8 @@ Customer=Client
CustomerDiscount=Remise client CustomerDiscount=Remise client
Supplier=Fournisseur Supplier=Fournisseur
CompanyList=Liste des sociétés CompanyList=Liste des sociétés
AddContact=Ajouter contact AddContact=Créer contact
AddCompany=Ajouter société AddCompany=Créer société
DeleteACompany=Supprimer une société DeleteACompany=Supprimer une société
PersonalInformations=Informations personnelles PersonalInformations=Informations personnelles
AccountancyCode=Code comptable AccountancyCode=Code comptable

View File

@ -34,11 +34,11 @@ ListOfCustomers=Liste des clients
LastDoneTasks=Les %s dernières actions effectuées LastDoneTasks=Les %s dernières actions effectuées
LastRecordedTasks=Dernières actions enregistrées LastRecordedTasks=Dernières actions enregistrées
DoneActions=Liste des actions réalisées DoneActions=Liste des actions réalisées
DoneActionsFor=Liste des actions réalisées pour DoneActionsFor=Liste des actions réalisées pour %s
MenuToDoActions=Actions incomplètes MenuToDoActions=Actions incomplètes
ToDoActions=Liste des actions incomplètes ToDoActions=Liste des actions incomplètes
ToDoActionsFor=Liste des actions incomplètes pour ToDoActionsFor=Liste des actions incomplètes pour %s
DoneAndToDoActionsFor=Liste des actions réalisées ou à faire pour DoneAndToDoActionsFor=Liste des actions réalisées ou à faire pour %s
DoneAndToDoActions=Liste des actions réalisées ou à faire DoneAndToDoActions=Liste des actions réalisées ou à faire
SendPropalRef=Envoi proposition commerciale %s SendPropalRef=Envoi proposition commerciale %s
NoRecordedProspects=Aucun prospect enregistré NoRecordedProspects=Aucun prospect enregistré

View File

@ -77,8 +77,8 @@ CustomerAbsoluteDiscountMy=Avoirs en cours (accord
DiscountNone=Aucune DiscountNone=Aucune
Supplier=Fournisseur Supplier=Fournisseur
CompanyList=Liste des sociétés CompanyList=Liste des sociétés
AddContact=Ajouter contact AddContact=Créer contact
AddCompany=Ajouter société AddCompany=Créer société
DeleteACompany=Supprimer une société DeleteACompany=Supprimer une société
PersonalInformations=Informations personnelles PersonalInformations=Informations personnelles
AccountancyCode=Code compta AccountancyCode=Code compta

View File

@ -185,6 +185,10 @@ Comment=Commentaire
Comments=Commentaires Comments=Commentaires
ActionsDone=Actions effectuées ActionsDone=Actions effectuées
ActionsToDo=Actions à faire ActionsToDo=Actions à faire
ActionsDoneShort=Effectuées
ActionsToDoShort=A faire
ContactsForCompany=Contacts de cette société
ActionsOnCompany=Actions vis à vis de cette société
NActions=%s actions NActions=%s actions
NActionsLate=%s en retard NActionsLate=%s en retard
Filter=Filtre Filter=Filtre