2
0
forked from Wavyzz/dolibarr

fix warnings in propal list

This commit is contained in:
Frédéric FRANCE
2021-10-24 14:34:47 +02:00
parent 50df842417
commit 677ac4635d
2 changed files with 16 additions and 7 deletions

View File

@@ -1383,10 +1383,24 @@ if ($resql) {
if (!empty($arrayfields['sale_representative']['checked'])) {
print_liste_field_titre($arrayfields['sale_representative']['label'], $_SERVER["PHP_SELF"], "", "", "$param", '', $sortfield, $sortorder);
}
$totalarray = array(
'nbfield' => 0,
'val' => array(
'p.total_ht' => 0,
'p.total_tva' => 0,
'p.total_ttc' => 0,
),
);
// Extra fields
include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_title.tpl.php';
// Hook fields
$parameters = array('arrayfields'=>$arrayfields, 'param'=>$param, 'sortfield'=>$sortfield, 'sortorder'=>$sortorder);
$parameters = array(
'arrayfields' => $arrayfields,
'param' => $param,
'sortfield' => $sortfield,
'sortorder' => $sortorder,
'totalarray' => &$totalarray,
);
$reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters); // Note that $action and $object may have been modified by hook
print $hookmanager->resPrint;
if (!empty($arrayfields['p.datec']['checked'])) {
@@ -1412,12 +1426,6 @@ if ($resql) {
$now = dol_now();
$i = 0;
$totalarray = array();
$totalarray['nbfield'] = 0;
$totalarray['val'] = array();
$totalarray['val']['p.total_ht'] = 0;
$totalarray['val']['p.total_tva'] = 0;
$totalarray['val']['p.total_ttc'] = 0;
$typenArray = null;
while ($i < min($num, $limit)) {

View File

@@ -104,6 +104,7 @@ class FormPropal
print '<option value="-1">&nbsp;</option>';
}
$i = 0;
foreach ($listofstatus as $key => $obj) {
if ($excludedraft) {
if ($obj['code'] == 'Draft' || $obj['code'] == 'PR_DRAFT') {