giant: mise a jour affichage rapport html

This commit is contained in:
Sebastien BEAUGRAND 2010-12-03 10:20:01 +00:00
parent dd3b37540b
commit 9ceb02679a

View File

@ -298,9 +298,6 @@ function printLiensFinanciers(&$company, $type)
}
}
// -------------------------------------------------------------------------- //
// Type de rapport
// -------------------------------------------------------------------------- //
require_once 'dbbootstrap.php';
setDbConn('giantclient');
@ -314,6 +311,9 @@ if ($r == false) {
exit;
}
// -------------------------------------------------------------------------- //
// Type de rapport
// -------------------------------------------------------------------------- //
print '<div id="center">';
switch ($r->DataSetType) {
case 'Full':
@ -483,14 +483,14 @@ if (isset($c->Operations->IndustryCode) == true ||
if (isset($t->Period->StartDate->_) == true &&
$t->Period->StartDate->_ > $annee) {
$annee = $t->Period->StartDate->_;
$total = $t->TotalStaffEmployed + 0;
$total = intval($t->TotalStaffEmployed);
} else if (isset($t->Period->EndDate->_) == true &&
$t->Period->EndDate->_ > $annee) {
$annee = $t->Period->EndDate->_;
$total = $t->TotalStaffEmployed + 0;
$total = intval($t->TotalStaffEmployed);
}
} else {
$total = $t->TotalStaffEmployed + 0;
$total = intval($t->TotalStaffEmployed);
}
}
if ($total > 0) {
@ -565,12 +565,14 @@ if (isset($c->Employees) == true) {
foreach (getArray($c->Employees) as $t) {
if (isset($t->Period) == true) {
if (isset($t->Period->StartDate) == true) {
dRow(pdate($t->Period->StartDate), $t->TotalStaffEmployed + 0);
dRow(pdate($t->Period->StartDate),
intval($t->TotalStaffEmployed));
} else if (isset($t->Period->EndDate) == true) {
dRow(pdate($t->Period->EndDate), $t->TotalStaffEmployed + 0);
dRow(pdate($t->Period->EndDate),
intval($t->TotalStaffEmployed));
}
} else {
dRow('', $t->TotalStaffEmployed + 0);
dRow('', intval($t->TotalStaffEmployed));
}
}
print '</table>';
@ -720,6 +722,7 @@ if (isset($c->PaymentBehaviour) == true) {
pdate($cat->Period->StartDate).' - '.
pdate($cat->Period->EndDate);
$total = 0;
if (isset($cat->DueDateExceeds) == true) {
foreach (getArray($cat->DueDateExceeds) as $e) {
if ($e->NrOfDaysExceeds->LowerLimit->_ >= 90) {
$total += $e->Percentage;
@ -732,6 +735,7 @@ if (isset($c->PaymentBehaviour) == true) {
}
$tab['90-'][$trim] = $total;
}
}
ksort($tab);
print '<h2>'.$ap->Description->_.'</h2>';
print '<table cellpadding="10">';
@ -773,6 +777,7 @@ if (isset($c->PaymentBehaviour) == true) {
$amount .= $cat->AmountCategory->HigherLimit->_;
}
$total = 0;
if (isset($cat->DueDateExceeds) == true) {
foreach (getArray($cat->DueDateExceeds) as $e) {
if ($e->NrOfDaysExceeds->LowerLimit->_ >= 90) {
$total += $e->Percentage;
@ -785,6 +790,7 @@ if (isset($c->PaymentBehaviour) == true) {
}
$tab['90-'][$amount] = $total;
}
}
ksort($tab);
print '<h2>'.$ap->Description->_.'</h2>';
print '<table cellpadding="10">';
@ -885,10 +891,14 @@ if (isset($c->PeerGroup->FlexibleComparisonItems
foreach ($c->PeerGroup->FlexibleComparisonItems->ComparisonItemsGroup as
$group) {
print '<td align="right">';
if (isset($group->FlexibleComparisonItem[$i]->SubjectValue)) {
print $group->FlexibleComparisonItem[$i]->SubjectValue;
}
print '</td>';
print '<td align="right">';
if (isset($group->FlexibleComparisonItem[$i]->AverageValue)) {
print $group->FlexibleComparisonItem[$i]->AverageValue;
}
print '</td>';
}
print '</tr>';