mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 10:38:45 +02:00
UIContentBlock: Add PrependSubBlock() to add a block in first position
This commit is contained in:
@@ -71,6 +71,19 @@ class UIContentBlock extends UIBlock implements iUIContentBlock
|
|||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Add $oSubBlock as the first of the sub blocks, while preserving the array indexes
|
||||||
|
*
|
||||||
|
* @param \Combodo\iTop\Application\UI\Base\iUIBlock $oSubBlock
|
||||||
|
*
|
||||||
|
* @return $this
|
||||||
|
*/
|
||||||
|
public function PrependSubBlock(iUIBlock $oSubBlock)
|
||||||
|
{
|
||||||
|
$this->aSubBlocks = [$oSubBlock->GetId() => $oSubBlock] + $this->aSubBlocks;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @inheritDoc
|
* @inheritDoc
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user