Debug v14
This commit is contained in:
parent
aceeb9558f
commit
f8f951977c
@ -189,8 +189,8 @@ foreach ($data as $val) {
|
||||
//print '</a>';
|
||||
print '</td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right amount nowraponall">0</td>';
|
||||
print '<td class="right amount nowraponall">0</td>';
|
||||
print '</tr>';
|
||||
}
|
||||
print '<tr class="oddeven" height="24">';
|
||||
@ -200,8 +200,8 @@ foreach ($data as $val) {
|
||||
//print '</a>';
|
||||
print '</td>';
|
||||
print '<td class="right">'.$val['nb'].'</td>';
|
||||
print '<td class="right"><span class="amount">'.price(price2num($val['total'], 'MT'), 1).'</span></td>';
|
||||
print '<td class="right"><span class="amount">'.price(price2num($val['avg'], 'MT'), 1).'</span></td>';
|
||||
print '<td class="right amount nowraponall"><span class="amount">'.price(price2num($val['total'], 'MT'), 1).'</span></td>';
|
||||
print '<td class="right amount nowraponall"><span class="amount">'.price(price2num($val['avg'], 'MT'), 1).'</span></td>';
|
||||
print '</tr>';
|
||||
$oldyear = $year;
|
||||
}
|
||||
|
||||
@ -316,14 +316,14 @@ if ($mode == 'supplier') {
|
||||
}
|
||||
print '<tr><td>'.$cat_label.'</td><td>';
|
||||
print img_picto('', 'category', 'class="pictofixedwidth"');
|
||||
print $formother->select_categories($cat_type, $categ_id, 'categ_id', true);
|
||||
print $formother->select_categories($cat_type, $categ_id, 'categ_id', 0, 1, 'widthcentpercentminusx maxwidth300');
|
||||
print '</td></tr>';
|
||||
// User
|
||||
print '<tr><td class="left">'.$langs->trans("CreatedBy").'</td><td class="left">';
|
||||
print '<tr><td>'.$langs->trans("CreatedBy").'</td><td>';
|
||||
print img_picto('', 'user', 'class="pictofixedwidth"');
|
||||
print $form->select_dolusers($userid, 'userid', 1, '', 0, '', '', 0, 0, 0, '', 0, '', 'widthcentpercentminusx maxwidth300');
|
||||
// Status
|
||||
print '<tr><td class="left">'.$langs->trans("Status").'</td><td class="left">';
|
||||
print '<tr><td>'.$langs->trans("Status").'</td><td>';
|
||||
if ($mode == 'customer') {
|
||||
$liststatus = array(
|
||||
Commande::STATUS_DRAFT=>$langs->trans("StatusOrderDraft"),
|
||||
@ -388,11 +388,11 @@ foreach ($data as $val) {
|
||||
print '<tr class="oddeven" height="24">';
|
||||
print '<td align="center"><a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&mode='.$mode.($socid > 0 ? '&socid='.$socid : '').($userid > 0 ? '&userid='.$userid : '').'">'.$year.'</a></td>';
|
||||
print '<td class="right">'.$val['nb'].'</td>';
|
||||
print '<td class="right" style="'.(($val['nb_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.round($val['nb_diff']).'</td>';
|
||||
print '<td class="right opacitylow" style="'.(($val['nb_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.round($val['nb_diff']).'%</td>';
|
||||
print '<td class="right">'.price(price2num($val['total'], 'MT'), 1).'</td>';
|
||||
print '<td class="right" style="'.(($val['total_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.round($val['total_diff']).'</td>';
|
||||
print '<td class="right opacitylow" style="'.(($val['total_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.round($val['total_diff']).'%</td>';
|
||||
print '<td class="right">'.price(price2num($val['avg'], 'MT'), 1).'</td>';
|
||||
print '<td class="right" style="'.(($val['avg_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.round($val['avg_diff']).'</td>';
|
||||
print '<td class="right opacitylow" style="'.(($val['avg_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.round($val['avg_diff']).'%</td>';
|
||||
print '</tr>';
|
||||
$oldyear = $year;
|
||||
}
|
||||
|
||||
@ -6971,7 +6971,7 @@ abstract class CommonObject
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.form.class.php';
|
||||
$form = new Form($this->db);
|
||||
}
|
||||
|
||||
var_dump($val);
|
||||
$objectid = $this->id;
|
||||
$label = $val['label'];
|
||||
$type = $val['type'];
|
||||
@ -7018,7 +7018,7 @@ abstract class CommonObject
|
||||
|
||||
$langfile = $val['langfile'];
|
||||
$list = $val['list'];
|
||||
$help = $val['help'];
|
||||
$help = (empty($val['help']) ? '' : $val['help']);
|
||||
$hidden = (($val['visible'] == 0) ? 1 : 0); // If zero, we are sure it is hidden, otherwise we show. If it depends on mode (view/create/edit form or list, this must be filtered by caller)
|
||||
|
||||
if ($hidden) {
|
||||
@ -7044,9 +7044,9 @@ abstract class CommonObject
|
||||
} elseif ($type == 'boolean') {
|
||||
$morecss = '';
|
||||
} else {
|
||||
if (round($size) < 12) {
|
||||
if (is_numeric($size) && round($size) < 12) {
|
||||
$morecss = 'minwidth100';
|
||||
} elseif (round($size) <= 48) {
|
||||
} elseif (is_numeric($size) && round($size) <= 48) {
|
||||
$morecss = 'minwidth200';
|
||||
} else {
|
||||
$morecss = 'minwidth400';
|
||||
|
||||
@ -274,8 +274,8 @@ foreach ($data as $val) {
|
||||
print '<tr class="oddeven" height="24">';
|
||||
print '<td class="center"><a href="'.$_SERVER["PHP_SELF"].'?year='.$oldyear.'&mode='.$mode.'">'.$oldyear.'</a></td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right amount nowraponall">0</td>';
|
||||
print '<td class="right amount nowraponall">0</td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
@ -283,8 +283,8 @@ foreach ($data as $val) {
|
||||
print '<tr class="oddeven" height="24">';
|
||||
print '<td class="center"><a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&mode='.$mode.'">'.$year.'</a></td>';
|
||||
print '<td class="right">'.$val['nb'].'</td>';
|
||||
print '<td class="right">'.price(price2num($val['total'], 'MT'), 1).'</td>';
|
||||
print '<td class="right">'.price(price2num($val['avg'], 'MT'), 1).'</td>';
|
||||
print '<td class="right amount nowraponall">'.price(price2num($val['total'], 'MT'), 1).'</td>';
|
||||
print '<td class="right amount nowraponall">'.price(price2num($val['avg'], 'MT'), 1).'</td>';
|
||||
print '</tr>';
|
||||
$oldyear = $year;
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2014-2015 Florian HENRY <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2015 Laurent Destailleur <ldestailleur@users.sourceforge.net>
|
||||
* Copyright (C) 2015-2021 Laurent Destailleur <ldestailleur@users.sourceforge.net>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -325,12 +325,12 @@ foreach ($data_all_year as $val) {
|
||||
|
||||
print '<tr class="oddeven" height="24">';
|
||||
print '<td class="center"><a href="'.$_SERVER["PHP_SELF"].'?year='.$oldyear.($socid > 0 ? '&socid='.$socid : '').($userid > 0 ? '&userid='.$userid : '').'">'.$oldyear.'</a></td>';
|
||||
if (!empty($conf->global->PROJECT_USE_OPPORTUNITIES)) {
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right">0</td>';
|
||||
}
|
||||
print '<td class="right">0</td>';
|
||||
if (!empty($conf->global->PROJECT_USE_OPPORTUNITIES)) {
|
||||
print '<td class="right amount nowraponall">0</td>';
|
||||
print '<td class="right amount nowraponall">0</td>';
|
||||
print '<td class="right amount nowraponall">0</td>';
|
||||
}
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
@ -338,9 +338,9 @@ foreach ($data_all_year as $val) {
|
||||
print '<td class="center"><a href="'.$_SERVER["PHP_SELF"].'?year='.$year.($socid > 0 ? '&socid='.$socid : '').($userid > 0 ? '&userid='.$userid : '').'">'.$year.'</a></td>';
|
||||
print '<td class="right">'.$val['nb'].'</td>';
|
||||
if (!empty($conf->global->PROJECT_USE_OPPORTUNITIES)) {
|
||||
print '<td class="right">'.($val['total'] ? price(price2num($val['total'], 'MT'), 1) : '0').'</td>';
|
||||
print '<td class="right">'.($val['avg'] ? price(price2num($val['avg'], 'MT'), 1) : '0').'</td>';
|
||||
print '<td class="right">'.(isset($val['weighted']) ? price(price2num($val['weighted'], 'MT'), 1) : '0').'</td>';
|
||||
print '<td class="right amount nowraponall">'.($val['total'] ? price(price2num($val['total'], 'MT'), 1) : '0').'</td>';
|
||||
print '<td class="right amount nowraponall">'.($val['avg'] ? price(price2num($val['avg'], 'MT'), 1) : '0').'</td>';
|
||||
print '<td class="right amount nowraponall">'.(isset($val['weighted']) ? price(price2num($val['weighted'], 'MT'), 1) : '0').'</td>';
|
||||
}
|
||||
print '</tr>';
|
||||
$oldyear = $year;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user