Add status if referrer list of a project

This commit is contained in:
Laurent Destailleur 2008-12-27 23:40:25 +00:00
parent ff49c3c833
commit cc7ebc8251
3 changed files with 35 additions and 44 deletions

View File

@ -687,7 +687,7 @@ if ($_POST['action'] == 'updateligne' && $user->rights->propale->creer && $_POST
$vat_rate=$_POST['tva_tx']; $vat_rate=$_POST['tva_tx'];
$vat_rate=eregi_replace('\*','',$vat_rate); $vat_rate=eregi_replace('\*','',$vat_rate);
// On vérifie que le prix minimum est respecté // On v<EFBFBD>rifie que le prix minimum est respect<63>
$productid = $_POST['productid'] ; $productid = $_POST['productid'] ;
if ($productid) if ($productid)
{ {
@ -1093,24 +1093,13 @@ if ($_GET['propalid'] > 0)
} }
print '</td></tr>'; print '</td></tr>';
// Projet // Project
if ($conf->projet->enabled) if ($conf->projet->enabled)
{ {
$langs->load("projects"); $langs->load("projects");
print '<tr><td>'; print '<tr><td>';
print '<table class="nobordernopadding" width="100%"><tr><td>'; print '<table class="nobordernopadding" width="100%"><tr><td>';
print $langs->trans('Project').'</td>'; print $langs->trans('Project').'</td>';
$numprojet = $societe->has_projects();
if (! $numprojet)
{
print '</td></tr></table>';
print '<td colspan="2">';
print $langs->trans("NoProject").'</td><td>';
print '<a href=../projet/fiche.php?socid='.$societe->id.'&action=create>'.$langs->trans('AddProject').'</a>';
print '</td>';
}
else
{
if ($propal->statut == 0 && $user->rights->propale->creer) if ($propal->statut == 0 && $user->rights->propale->creer)
{ {
if ($_GET['action'] != 'classer' && $propal->brouillon) print '<td align="right"><a href="'.$_SERVER['PHP_SELF'].'?action=classer&amp;propalid='.$propal->id.'">'.img_edit($langs->trans('SetProject')).'</a></td>'; if ($_GET['action'] != 'classer' && $propal->brouillon) print '<td align="right"><a href="'.$_SERVER['PHP_SELF'].'?action=classer&amp;propalid='.$propal->id.'">'.img_edit($langs->trans('SetProject')).'</a></td>';
@ -1143,7 +1132,6 @@ if ($_GET['propalid'] > 0)
print '<td colspan="3">&nbsp;</td>'; print '<td colspan="3">&nbsp;</td>';
} }
} }
}
print '</tr>'; print '</tr>';
} }

View File

@ -2458,7 +2458,7 @@ else
print '<tr><td>'.$langs->trans('Status').'</td>'; print '<tr><td>'.$langs->trans('Status').'</td>';
print '<td align="left" colspan="3">'.($fac->getLibStatut(4,$totalpaye)).'</td></tr>'; print '<td align="left" colspan="3">'.($fac->getLibStatut(4,$totalpaye)).'</td></tr>';
// Projet // Project
if ($conf->projet->enabled) if ($conf->projet->enabled)
{ {
$langs->load('projects'); $langs->load('projects');

View File

@ -40,7 +40,7 @@ if ($conf->facture->enabled) $langs->load("bills");
if ($conf->commande->enabled) $langs->load("orders"); if ($conf->commande->enabled) $langs->load("orders");
if ($conf->propal->enabled) $langs->load("propal"); if ($conf->propal->enabled) $langs->load("propal");
// Sécurité accés client // S<EFBFBD>curit<EFBFBD> acc<63>s client
$projetid=''; $projetid='';
if ($_GET["id"]) { $projetid=$_GET["id"]; } if ($_GET["id"]) { $projetid=$_GET["id"]; }
@ -123,6 +123,7 @@ foreach ($listofreferent as $key => $value)
print '<td width="150">'.$langs->trans("Ref").'</td>'; print '<td width="150">'.$langs->trans("Ref").'</td>';
print '<td>'.$langs->trans("Date").'</td>'; print '<td>'.$langs->trans("Date").'</td>';
print '<td align="right">'.$langs->trans("Amount").'</td>'; print '<td align="right">'.$langs->trans("Amount").'</td>';
print '<td align="right" width="200">'.$langs->trans("Status").'</td>';
print '</tr>'; print '</tr>';
$elementarray = $projet->get_element_list($key); $elementarray = $projet->get_element_list($key);
if (sizeof($elementarray)>0 && is_array($elementarray)) if (sizeof($elementarray)>0 && is_array($elementarray))
@ -143,13 +144,15 @@ foreach ($listofreferent as $key => $value)
if (empty($date)) $date=$element->datep; if (empty($date)) $date=$element->datep;
print '<td>'.dolibarr_print_date($date,'day').'</td>'; print '<td>'.dolibarr_print_date($date,'day').'</td>';
print '<td align="right">'.price($element->total_ht).'</td>'; print '<td align="right">'.price($element->total_ht).'</td>';
print '<td align="right">'.$element->getLibStatut(5).'</td>';
print '</tr>'; print '</tr>';
$total = $total + $element->total_ht; $total = $total + $element->total_ht;
} }
print '<tr class="liste_total"><td colspan="2">'.$i.' '.$langs->trans("Bills").'</td>'; print '<tr class="liste_total"><td colspan="2">'.$langs->trans("Number").': '.$i.'</td>';
print '<td align="right" width="100">'.$langs->trans("TotalHT").' : '.price($total).'</td>'; print '<td align="right" width="100">'.$langs->trans("TotalHT").' : '.price($total).'</td>';
print '<td>&nbsp;</td>';
print '</tr>'; print '</tr>';
} }
print "</table>"; print "</table>";
@ -189,7 +192,7 @@ foreach ($listofreferent as $key => $value)
} }
} }
// Juste pour éviter bug IE qui réorganise mal div précédents si celui-ci absent // Juste pour <EFBFBD>viter bug IE qui r<>organise mal div pr<70>c<EFBFBD>dents si celui-ci absent
print '<div class="tabsAction">'; print '<div class="tabsAction">';
print '</div>'; print '</div>';