[TYPO3-irre] enableControls

Steffen Kamper steffen at sk-typo3.de
Mon May 26 21:16:48 CEST 2008


"Oliver Hader" <oliver at typo3.org> schrieb im Newsbeitrag 
news:mailman.1.1211828114.9579.typo3-project-irre at lists.netfielders.de...
> Hi Steffen,
>
> Steffen Kamper schrieb:
>> i discovered the enableControls-Array and the only possibility i saw is 
>> using a hook.
>>
>> Did i miss something, or is it possible to define this with TCA as well?
>>
>> I tried 'inlineNewButtonStyle' => 'display:none;' but doesn't affec, 
>> seems to be used only in a special case.
>>
>> Reason: i want to deactivate "create record"-link and the delete link. Is 
>> there a possibility to do so? Would be the easiest way to do something 
>> like
>>
>> 'type' => 'inline',
>> 'enableControls' => array (
>>   'new' => false,
>>   'delete' => false,
>>  ),
>
> You're right. This currently only works with implementing a hook which 
> sets the enabled control items. But it would be possible to introduce a 
> new appearance property like you mentioned:
>
> 'fieldname' => array(
>   'label' => '...',
>   'config' => array(
>     'type' => 'inline',
>     'foreign_table' => '...',
>     'appearance' => array(
>       'enabledControls' => array(
>         'new' => false,
>         'delete' => false,
>       ),
>     ),
>   ),
> ),
>
> The values in enabledControls would the be the initial value of that field 
> and merged with all items to be true. Thus, if a control item was not 
> explicitly set by the new appearance property, it's shown by default (like 
> it's now).
>

Thx olly for taking care, the bug report is
http://bugs.typo3.org/view.php?id=8523

This would be a nice feature :)

vg Steffen 




More information about the TYPO3-project-irre mailing list