Project

General

Profile

Actions

Bug #19122

closed

The option "autoSizeMax" is not applied to a record selector.

Added by Jochen Rau over 16 years ago. Updated about 11 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2008-07-17
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.2
PHP Version:
5.2
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

In the $TCA you can set the configuration option "autoSizeMax" to create "self-adapting" selector boxes. The record selector of IRRE does not consider the given value.

This bug is caused by the following line in which the variable $itemArray is not set (=0):

$size = $conf['autoSizeMax'] ? t3lib_div::intInRange(count($itemArray)+1,t3lib_div::intInRange($size,1),$conf['autoSizeMax']) : $size;

IMO it should be

$size = $conf['autoSizeMax'] ? t3lib_div::intInRange(count($selItems) - count($uniqueIds) + 1, t3lib_div::intInRange($size, 1), $conf['autoSizeMax']) : $size;

An example configuration of a field:

'my_field' => Array (
'label' => 'The Label',
'config' => Array (
'type' => 'inline',
'foreign_table' => 'tx_foreign_table',
'foreign_field' => 'component_id',
'foreign_sortby' => 'component_sort',
'foreign_label' => 'subcomponent_id',
'foreign_selector' => 'subcomponent_id',
'foreign_unique' => 'subcomponent_id',
'minitems' => 0,
'maxitems' => 999,
'size' => 4,
'autoSizeMax' => 20,
'default' => '',
)
),
(issue imported from #M8999)


Files

bug_8999.diff (1.11 KB) bug_8999.diff Administrator Admin, 2008-07-17 20:54
Actions #1

Updated by Alexander Opitz over 11 years ago

  • Status changed from New to Needs Feedback
  • Target version deleted (0)

The issue is very old, does this issue exists in newer versions of TYPO3 CMS (4.5 or 6.1)?

Actions #2

Updated by Alexander Opitz about 11 years ago

  • Status changed from Needs Feedback to Closed
  • Is Regression set to No

No feedback for over 90 days.

Actions

Also available in: Atom PDF