mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-24 11:08:45 +02:00
N°3750 Add data-input-id to field container
This will allow easiest DOM manipulation in BeHat tests
This commit is contained in:
@@ -337,7 +337,12 @@ class Field extends UIContentBlock
|
||||
public function SetValueId(?string $sValueId)
|
||||
{
|
||||
$this->sValueId = $sValueId;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function SetInputId(string $sInputId)
|
||||
{
|
||||
$this->AddDataAttribute('input-id', $sInputId);
|
||||
}
|
||||
}
|
||||
@@ -31,6 +31,7 @@ class FieldUIBlockFactory extends AbstractUIBlockFactory
|
||||
'attlabel' => 'SetAttLabel',
|
||||
'value_raw' => 'SetValueRaw',
|
||||
'comments' => 'SetComments',
|
||||
'inputId' => 'SetInputId',
|
||||
];
|
||||
foreach ($aParamsMapping as $sParamKey => $sFieldMethod) {
|
||||
self::UpdateFieldFromParams($oField, $sFieldMethod, $aParams, $sParamKey);
|
||||
|
||||
Reference in New Issue
Block a user