diff --git a/htdocs/comm/fiche.php3 b/htdocs/comm/fiche.php3
index 85c03a512e1..5dde7b57846 100644
--- a/htdocs/comm/fiche.php3
+++ b/htdocs/comm/fiche.php3
@@ -170,11 +170,14 @@ if ($socid > 0) {
print "
| siren | siren\">$objsoc->siren | ";
print "prefix | ";
- if ($objsoc->prefix_comm) {
- print $objsoc->prefix_comm;
- } else {
- print "[idp&action=attribute_prefix\">Attribuer]";
- }
+ if ($objsoc->prefix_comm)
+ {
+ print $objsoc->prefix_comm;
+ }
+ else
+ {
+ print "[idp&action=attribute_prefix\">Attribuer]";
+ }
print " |
";
@@ -303,9 +306,10 @@ if ($socid > 0) {
//print '
';
print ''.$obj->firstname.' '. $obj->name.' ';
- if ($obj->note) {
- print "
".nl2br($obj->note);
- }
+ if ($obj->note)
+ {
+ print "
".nl2br($obj->note);
+ }
print "";
print "$obj->poste | ";
print ''.$obj->phone.' | ';
@@ -413,70 +417,84 @@ if ($socid > 0) {
$sql .= " AND c.id=a.fk_action AND a.percent = 100";
$sql .= " ORDER BY a.datea DESC, a.id DESC";
- if ( $db->query($sql) ) {
- print "\n";
-
- $i = 0 ;
- $num = $db->num_rows();
- $oldyear='';
- $oldmonth='';
- while ($i < $num) {
- $var = !$var;
-
- $obj = $db->fetch_object( $i);
- print "";
-
- if ($oldyear == strftime("%Y",$obj->da) ) {
- print '| | | ';
- } else {
- print "" .strftime("%Y",$obj->da)." | \n";
- $oldyear = strftime("%Y",$obj->da);
- }
-
- if ($oldmonth == strftime("%Y%b",$obj->da) ) {
- print '| | ';
- } else {
- print "" .strftime("%b",$obj->da)." | \n";
- $oldmonth = strftime("%Y%b",$obj->da);
- }
+ if ( $db->query($sql) )
+ {
+ print "\n";
- print "| " .strftime("%d",$obj->da)." | \n";
- print "" .strftime("%H:%M",$obj->da)." | \n";
-
- print ' | ';
-
- if ($obj->propalrowid) {
- print ''.$obj->libelle.' | ';
- } else {
- print ''.$obj->libelle.' | ';
- }
- /*
- * Contact pour cette action
- *
- */
- if ($obj->fk_contact) {
- $contact = new Contact($db);
- $contact->fetch($obj->fk_contact);
- print ''.$contact->fullname.' | ';
- } else {
- print ' | ';
- }
- /*
- */
- print ''.$obj->code.' | ';
- print "\n";
- $i++;
+ $i = 0 ;
+ $num = $db->num_rows();
+ $oldyear='';
+ $oldmonth='';
+ while ($i < $num)
+ {
+ $var = !$var;
+
+ $obj = $db->fetch_object( $i);
+ print "";
+
+ if ($oldyear == strftime("%Y",$obj->da) )
+ {
+ print '| | | ';
+ }
+ else
+ {
+ print "" .strftime("%Y",$obj->da)." | \n";
+ $oldyear = strftime("%Y",$obj->da);
+ }
+
+ if ($oldmonth == strftime("%Y%b",$obj->da) )
+ {
+ print '| | ';
+ }
+ else
+ {
+ print "" .strftime("%b",$obj->da)." | \n";
+ $oldmonth = strftime("%Y%b",$obj->da);
+ }
+
+ print "" .strftime("%d",$obj->da)." | \n";
+ print "" .strftime("%H:%M",$obj->da)." | \n";
+
+ print ' | ';
+
+ if ($obj->propalrowid)
+ {
+ print ''.$obj->libelle.' | ';
+ }
+ else
+ {
+ print ''.$obj->libelle.' | ';
+ }
+ /*
+ * Contact pour cette action
+ *
+ */
+ if ($obj->fk_contact)
+ {
+ $contact = new Contact($db);
+ $contact->fetch($obj->fk_contact);
+ print ''.$contact->fullname.' | ';
+ }
+ else
+ {
+ print ' | ';
+ }
+ /*
+ */
+ print ''.$obj->code.' | ';
+ print "
\n";
+ $i++;
+ }
+ print "
";
+
+ $db->free();
+ }
+ else
+ {
+ print $db->error();
}
- print "
";
-
- $db->free();
- } else {
- print $db->error();
- }
print "";
-
-
-
+
/*