NEW #20650 completing checkcolumn on left for propal list

This commit is contained in:
Faustin 2022-06-24 16:43:28 +02:00
parent 6118cb69e6
commit 1cc9eda9a6

View File

@ -675,7 +675,7 @@ if (!empty($moreforfilter)) {
}
$varpage = empty($contextpage) ? $_SERVER["PHP_SELF"] : $contextpage;
$selectedfields = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage); // This also change content of $arrayfields
$selectedfields = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage, getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN', '')); // This also change content of $arrayfields
if ($massactionbutton) {
$selectedfields .= $form->showCheckAddButtons('checkforselect', 1);
}
@ -685,7 +685,13 @@ print '<table class="tagtable liste'.($moreforfilter ? " listwithfilterbefore" :
// Line for filters fields
print '<tr class="liste_titre_filter">';
// Action column
if (!empty($conf->global->MAIN_CHECKBOX_LEFT_COLUMN)) {
print '<td class="liste_titre middle">';
$searchpicto = $form->showFilterButtons('left');
print $searchpicto;
print '</td>';
}
// Line numbering
if (!empty($conf->global->MAIN_SHOW_TECHNICAL_ID)) {
print '<td class="liste_titre">&nbsp;</td>';
@ -962,6 +968,19 @@ while ($i < min($num, $limit)) {
print '<tr class="oddeven">';
// Action column
if (!empty($conf->global->MAIN_CHECKBOX_LEFT_COLUMN)) {
print '<td class="center">';
if ($massactionbutton || $massaction) { // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined
$selected = 0;
if (in_array($obj->rowid, $arrayofselected)) {
$selected = 1;
}
print '<input id="cb'.$obj->rowid.'" class="flat checkforselect" type="checkbox" name="toselect[]" value="'.$obj->rowid.'"'.($selected ? ' checked="checked"' : '').'>';
}
print '</td>';
}
if (!empty($conf->global->MAIN_SHOW_TECHNICAL_ID)) {
print '<td class="center" data-key="id">'.$obj->rowid.'</td>';
if (!$i) {