From f84b2dace9b360e2612869e90729f37f960d28d3 Mon Sep 17 00:00:00 2001 From: tipaul Date: Mon, 14 Nov 2005 21:13:08 +0000 Subject: [PATCH] =?UTF-8?q?-=20tri=20des=20actions=20dans=20le=20m=EAme=20?= =?UTF-8?q?ordre=20que=20index.php=20-=20ajout=20du=20libell=E9=20de=20l'a?= =?UTF-8?q?ction=20sur=20la=20liste=20-=20gestion=20des=20dates=20identiqu?= =?UTF-8?q?e=20=E0=20celle=20sur=20index.php=20(la=20date=20en=201er)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/comm/fiche.php | 43 +++++++++++++++++++++++++++++-------------- 1 file changed, 29 insertions(+), 14 deletions(-) diff --git a/htdocs/comm/fiche.php b/htdocs/comm/fiche.php index 13cad8c64a3..adc95454bf5 100644 --- a/htdocs/comm/fiche.php +++ b/htdocs/comm/fiche.php @@ -252,23 +252,28 @@ if ($_socid > 0) print ''.$langs->trans('Zip').''.$objsoc->cp.""; print ''.$langs->trans('Town').''.$objsoc->ville.""; - - print ''.$langs->trans('Country').''.$objsoc->pays.''; + if ($objsoc->pays) { + print ''.$langs->trans('Country').''.$objsoc->pays.''; + } print ''.$langs->trans('Phone').''.dolibarr_print_phone($objsoc->tel,$objsoc->pays_code).''; print ''.$langs->trans('Fax').''.dolibarr_print_phone($objsoc->fax,$objsoc->pays_code).''; print ''.$langs->trans("Web")."url\" target=\"_blank\">".$objsoc->url." "; - - print "".$langs->transcountry("ProfId1",$objsoc->pays_code)."siren."\" target=\"_blank\">".$objsoc->siren." "; + if ($objsoc->siren || $objsoc->siret) { + print "".$langs->transcountry("ProfId1",$objsoc->pays_code)."siren."\" target=\"_blank\">".$objsoc->siren." "; print ''.$langs->transcountry('ProfId2',$objsoc->pays_code).''.$objsoc->siret.''; - - print ''.$langs->transcountry('ProfId3',$objsoc->pays_code).''.$objsoc->ape.' '; + } + if ($objsoc->ape) { + print ''.$langs->transcountry('ProfId3',$objsoc->pays_code).''.$objsoc->ape.' '; + } // Type + Staff $arr = $objsoc->typent_array($objsoc->typent_id); $objsoc->typent= $arr[$objsoc->typent_id]; - print ''.$langs->trans("Type").''.$objsoc->typent.''.$langs->trans("Staff").''.$objsoc->effectif.''; + if ($objsoc->typent || $objsoc->effectif) { + print ''.$langs->trans("Type").''.$objsoc->typent.''.$langs->trans("Staff").''.$objsoc->effectif.''; + } // Remise permanente print ''; @@ -683,9 +688,9 @@ if ($_socid > 0) * */ print ''; - print ''; + print ''; - $sql = "SELECT a.id, ".$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 .= " WHERE a.fk_soc = $objsoc->id "; $sql .= " AND u.rowid = a.fk_user_author"; @@ -708,7 +713,7 @@ if ($_socid > 0) if ($oldyear == strftime("%Y",$obj->da) ) { - print '\n"; + print ''; } else { @@ -718,7 +723,7 @@ if ($_socid > 0) if ($oldmonth == strftime("%Y%b",$obj->da) ) { - print '\n"; + print ''; } else { @@ -728,6 +733,10 @@ if ($_socid > 0) print '\n"; print '\n"; + if (date("U",$obj->da) < time()) + { + print ""; + } // Status/Percent print ''; @@ -748,7 +757,8 @@ if ($_socid > 0) print $libelle; print ''; } - + print ""; + // Contact pour cette action if ($obj->fk_contact) { $contact = new Contact($db); @@ -775,9 +785,9 @@ if ($_socid > 0) * Listes des actions effectuees */ print '
'.$langs->trans("ActionsToDo").' 
'.$langs->trans("ActionsToDo").' 
'.strftime("%Y",$obj->da)."|' .strftime("%b",$obj->da)."|'.strftime("%d",$obj->da)."'.strftime("%H:%M",$obj->da)."".img_warning("Late")." $obj->label
'; - print ''; + print ''; - $sql = "SELECT a.id, ".$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 .= " WHERE a.fk_soc = $objsoc->id "; $sql .= " AND u.rowid = a.fk_user_author"; @@ -822,6 +832,10 @@ if ($_socid > 0) } print '\n"; print '\n"; + if (date("U",$obj->da) < time()) + { + print ""; + } // Statut/Percent print ''; @@ -843,6 +857,7 @@ if ($_socid > 0) print ''; } + print ""; // Contact pour cette action if ($obj->fk_contact) {
'.$langs->trans("ActionsDone").'
'.$langs->trans("ActionsDone").'
'.strftime("%d",$obj->da)."'.strftime("%H:%M",$obj->da)."  $obj->label