mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-24 02:58:43 +02:00
221 lines
9.6 KiB
ReStructuredText
221 lines
9.6 KiB
ReStructuredText
.. Copyright (C) 2010-2022 Combodo SARL
|
|
.. http://opensource.org/licenses/AGPL-3.0
|
|
|
|
.. _Field:
|
|
|
|
Field
|
|
=====
|
|
|
|
Class Field
|
|
|
|
----
|
|
|
|
.. include:: /manual/Component/Field/FieldAdditionalDescription.rst
|
|
|
|
----
|
|
|
|
Twig Tag
|
|
--------
|
|
|
|
:Tag: **UIField**
|
|
|
|
:Syntax:
|
|
|
|
.. code-block:: twig
|
|
|
|
{% UIField Type {Parameters} %}
|
|
Content Goes Here
|
|
{% EndUIField %}
|
|
|
|
:Type:
|
|
|
|
+-------------------------------------+------------+
|
|
| :ref:`FromParams <FieldFromParams>` | No comment |
|
|
+-------------------------------------+------------+
|
|
| :ref:`FromObject <FieldFromObject>` | No comment |
|
|
+-------------------------------------+------------+
|
|
| :ref:`Large <FieldLarge>` | No comment |
|
|
+-------------------------------------+------------+
|
|
| :ref:`Small <FieldSmall>` | No comment |
|
|
+-------------------------------------+------------+
|
|
| :ref:`Standard <FieldStandard>` | No comment |
|
|
+-------------------------------------+------------+
|
|
|
|
.. _FieldFromParams:
|
|
|
|
Field FromParams
|
|
^^^^^^^^^^^^^^^^
|
|
|
|
:syntax:
|
|
|
|
.. code-block:: twig
|
|
|
|
{% UIField FromParams {aParams:value} %}
|
|
Content Goes Here
|
|
{% EndUIField %}
|
|
|
|
:parameters:
|
|
|
|
+---------+--+-----------+--+--+
|
|
| aParams | | mandatory | | |
|
|
+---------+--+-----------+--+--+
|
|
|
|
.. _FieldFromObject:
|
|
|
|
Field FromObject
|
|
^^^^^^^^^^^^^^^^
|
|
|
|
:syntax:
|
|
|
|
.. code-block:: twig
|
|
|
|
{% UIField FromObject {sLabel:'value', oInput:value, sLayout:'value'} %}
|
|
Content Goes Here
|
|
{% EndUIField %}
|
|
|
|
:parameters:
|
|
|
|
+---------+---------+-----------+------+--+
|
|
| sLabel | string | mandatory | | |
|
|
+---------+---------+-----------+------+--+
|
|
| oInput | UIBlock | mandatory | | |
|
|
+---------+---------+-----------+------+--+
|
|
| sLayout | string | optional | NULL | |
|
|
+---------+---------+-----------+------+--+
|
|
|
|
.. _FieldLarge:
|
|
|
|
Field Large
|
|
^^^^^^^^^^^
|
|
|
|
:syntax:
|
|
|
|
.. code-block:: twig
|
|
|
|
{% UIField Large {sLabel:'value', sValueHtml:'value'} %}
|
|
Content Goes Here
|
|
{% EndUIField %}
|
|
|
|
:parameters:
|
|
|
|
+------------+--------+-----------+----+--+
|
|
| sLabel | string | mandatory | | |
|
|
+------------+--------+-----------+----+--+
|
|
| sValueHtml | string | optional | '' | |
|
|
+------------+--------+-----------+----+--+
|
|
|
|
.. _FieldSmall:
|
|
|
|
Field Small
|
|
^^^^^^^^^^^
|
|
|
|
:syntax:
|
|
|
|
.. code-block:: twig
|
|
|
|
{% UIField Small {sLabel:'value', sValueHtml:'value'} %}
|
|
Content Goes Here
|
|
{% EndUIField %}
|
|
|
|
:parameters:
|
|
|
|
+------------+--------+-----------+----+--+
|
|
| sLabel | string | mandatory | | |
|
|
+------------+--------+-----------+----+--+
|
|
| sValueHtml | string | optional | '' | |
|
|
+------------+--------+-----------+----+--+
|
|
|
|
.. _FieldStandard:
|
|
|
|
Field Standard
|
|
^^^^^^^^^^^^^^
|
|
|
|
:syntax:
|
|
|
|
.. code-block:: twig
|
|
|
|
{% UIField Standard {sLabel:'value', sLayout:'value', sId:'value'} %}
|
|
Content Goes Here
|
|
{% EndUIField %}
|
|
|
|
:parameters:
|
|
|
|
+---------+--------+----------+---------+--+
|
|
| sLabel | string | optional | '' | |
|
|
+---------+--------+----------+---------+--+
|
|
| sLayout | string | optional | 'small' | |
|
|
+---------+--------+----------+---------+--+
|
|
| sId | string | optional | NULL | |
|
|
+---------+--------+----------+---------+--+
|
|
|
|
Field common parameters
|
|
^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddCSSClass | string | CSS class to add to the generated html block |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddCSSClasses | array | like <code>['ibo-is-hidden', 'ibo-alert--body']</code> |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddCssFileRelPath | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddDeferredBlock | iUIBlock | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddHtml | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddJsFileRelPath | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddMultipleCssFilesRelPaths | array | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddMultipleJsFilesRelPaths | array | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AddSubBlock | iUIBlock | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AttCode | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AttLabel | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| AttType | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| CSSClasses | array | like <code>['ibo-is-hidden', 'ibo-alert--body']</code> |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| Comments | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| DataAttributes | array | Array of data attributes in the format ['name' => 'value'] |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| DeferredBlocks | array | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| HasForcedDiv | bool | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| InputId | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| InputType | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| IsHidden | bool | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| IsMandatory | bool | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| IsReadOnly | bool | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| IsSlave | bool | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| Label | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| Layout | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| MustChange | bool | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| MustPrompt | bool | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| SubBlocks | array | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| Value | UIBlock | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| ValueId | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
| ValueRaw | string | |
|
|
+-----------------------------+----------+------------------------------------------------------------+
|
|
|
|
----
|
|
|
|
.. include:: /manual/Component/Field/FieldFooter.rst
|