mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-28 22:54:12 +01:00
Merge branch 'support/3.0' into develop
# Conflicts: # application/applicationextension.inc.php
This commit is contained in:
@@ -15,9 +15,9 @@ use Combodo\iTop\Application\UI\Base\Component\Field\Field;
|
||||
* Class InputUIBlockFactory
|
||||
*
|
||||
* @author Eric Espie <eric.espie@combodo.com>
|
||||
* @package Combodo\iTop\Application\UI\Base\Component\Input
|
||||
* @package UIBlockExtensibilityAPI
|
||||
* @api
|
||||
* @since 3.0.0
|
||||
* @internal
|
||||
*/
|
||||
class InputUIBlockFactory extends AbstractUIBlockFactory
|
||||
{
|
||||
@@ -26,6 +26,14 @@ class InputUIBlockFactory extends AbstractUIBlockFactory
|
||||
/** @inheritDoc */
|
||||
public const UI_BLOCK_CLASS_NAME = Input::class;
|
||||
|
||||
/**
|
||||
* @api
|
||||
* @param string $sName
|
||||
* @param string $sValue
|
||||
* @param string|null $sId
|
||||
*
|
||||
* @return \Combodo\iTop\Application\UI\Base\Component\Input\Input
|
||||
*/
|
||||
public static function MakeForHidden(string $sName, string $sValue, ?string $sId = null)
|
||||
{
|
||||
$oInput = new Input($sId);
|
||||
@@ -37,6 +45,15 @@ class InputUIBlockFactory extends AbstractUIBlockFactory
|
||||
return $oInput;
|
||||
}
|
||||
|
||||
/**
|
||||
* @api
|
||||
* @param string $sType
|
||||
* @param string $sName
|
||||
* @param string $sValue
|
||||
* @param string|null $sId
|
||||
*
|
||||
* @return \Combodo\iTop\Application\UI\Base\Component\Input\Input
|
||||
*/
|
||||
public static function MakeStandard(string $sType, string $sName, string $sValue, ?string $sId = null)
|
||||
{
|
||||
$oInput = new Input($sId);
|
||||
@@ -49,6 +66,7 @@ class InputUIBlockFactory extends AbstractUIBlockFactory
|
||||
}
|
||||
|
||||
/**
|
||||
* @api
|
||||
* @see Field component that is better adapter when dealing with a standard iTop form
|
||||
*
|
||||
* @param string $sLabel
|
||||
@@ -71,6 +89,15 @@ class InputUIBlockFactory extends AbstractUIBlockFactory
|
||||
return static::MakeInputWithLabel($sInputName, $sLabel, $oInput, $sInputId);
|
||||
}
|
||||
|
||||
/**
|
||||
* @api
|
||||
* @param string $sName
|
||||
* @param string $sLabel
|
||||
* @param \Combodo\iTop\Application\UI\Base\Component\Input\Input $oInput
|
||||
* @param string|null $sId
|
||||
*
|
||||
* @return \Combodo\iTop\Application\UI\Base\Component\Input\InputWithLabel
|
||||
*/
|
||||
private static function MakeInputWithLabel(string $sName, string $sLabel, Input $oInput, ?string $sId = null)
|
||||
{
|
||||
$oInput->SetName($sName);
|
||||
|
||||
Reference in New Issue
Block a user