Merge branch '14.0' of git@github.com:Dolibarr/dolibarr.git into 14.0

This commit is contained in:
Laurent Destailleur 2022-06-13 13:27:50 +02:00
commit d44df3a440
2 changed files with 12 additions and 3 deletions

View File

@ -288,8 +288,16 @@ if ($result) {
// get_url may return -1 which is not traversable
if (is_array($links) && count($links) > 0) {
$is_sc = false;
foreach ($links as $v) {
if ($v['type'] == 'sc') {
$is_sc = true;
break;
}
}
// Now loop on each link of record in bank (code similar to bankentries_list.php)
foreach ($links as $key => $val) {
if ($links[$key]['type'] == 'user' && !$is_sc) continue;
if (in_array($links[$key]['type'], array('sc', 'payment_sc', 'payment', 'payment_supplier', 'payment_vat', 'payment_expensereport', 'banktransfert', 'payment_donation', 'member', 'payment_loan', 'payment_salary', 'payment_various'))) {
// So we excluded 'company' and 'user' here. We want only payment lines

View File

@ -7410,7 +7410,7 @@ abstract class CommonObject
$langs->load($extrafields->attributes[$this->table_element]['langfile'][$key]);
}
$colspan = '';
$colspan = 0;
if (is_array($params) && count($params) > 0 && $display_type=='card') {
if (array_key_exists('cols', $params)) {
$colspan = $params['cols'];
@ -7423,6 +7423,7 @@ abstract class CommonObject
}
}
}
$colspan = intval($colspan);
switch ($mode) {
case "view":
@ -7468,7 +7469,7 @@ abstract class CommonObject
}
}
$out .= $extrafields->showSeparator($key, $this, ($colspan + 1), $display_type);
$out .= $extrafields->showSeparator($key, $this, ($colspan ? $colspan + 1 : 2), $display_type);
} else {
$class = (!empty($extrafields->attributes[$this->table_element]['hidden'][$key]) ? 'hideobject ' : '');
$csstyle = '';
@ -7489,7 +7490,7 @@ abstract class CommonObject
$html_id = (empty($this->id) ? '' : 'extrarow-'.$this->element.'_'.$key.'_'.$this->id);
if ($display_type=='card') {
if (!empty($conf->global->MAIN_EXTRAFIELDS_USE_TWO_COLUMS) && ($e % 2) == 0) {
$colspan = '0';
$colspan = 0;
}
if ($action == 'selectlines') {