[WIP] doc added for CopyClipboard fields
This commit is contained in:
parent
0d70247612
commit
15cfb3d9ae
@ -124,6 +124,18 @@ Reference List
|
|||||||
- `color_picker`
|
- `color_picker`
|
||||||
- `integer`
|
- `integer`
|
||||||
- description...
|
- description...
|
||||||
|
* - :ref:`CopyClipboardCharField <frontend/fields/copy_clipboard_char_field>`
|
||||||
|
- `CopyClipboardChar`
|
||||||
|
- `char`
|
||||||
|
- button to copy a `char` value to the clipboard
|
||||||
|
* - :ref:`CopyClipboardTextField <frontend/fields/copy_clipboard_text_field>`
|
||||||
|
- `CopyClipboardText`
|
||||||
|
- `char`
|
||||||
|
- button to copy a text to the clipboard
|
||||||
|
* - :ref:`CopyClipboardURLField <frontend/fields/copy_clipboard_url_field>`
|
||||||
|
- `CopyClipboardURL`
|
||||||
|
- `char`
|
||||||
|
- button to copy a url to the clipboard
|
||||||
* - :ref:`DateField <frontend/fields/date_field>`
|
* - :ref:`DateField <frontend/fields/date_field>`
|
||||||
- `date`
|
- `date`
|
||||||
- `date`, `datetime`
|
- `date`, `datetime`
|
||||||
@ -318,6 +330,48 @@ ColorPickerField
|
|||||||
- Supported types: `integer`
|
- Supported types: `integer`
|
||||||
|
|
||||||
|
|
||||||
|
.. _frontend/fields/copy_clipboard_char_field:
|
||||||
|
|
||||||
|
CopyClipboardCharField
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
- Location: `@web/fields/copy_clipboard_char_field`
|
||||||
|
- Technical name: `CopyClipboardText`
|
||||||
|
- Supported types: `char`
|
||||||
|
|
||||||
|
This component represents a field that allows a user to copy a `char` value to its clipboard
|
||||||
|
by clicking on the copy button present in the field. The value is also displayed inline on
|
||||||
|
the left.
|
||||||
|
|
||||||
|
|
||||||
|
.. _frontend/fields/copy_clipboard_text_field:
|
||||||
|
|
||||||
|
CopyClipboardTextField
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
- Location: `@web/fields/copy_clipboard_text_field`
|
||||||
|
- Technical name: `CopyClipboardChar`
|
||||||
|
- Supported types: `char`
|
||||||
|
|
||||||
|
This component represents a field that allows a user to copy a text block to its clipboard
|
||||||
|
by clicking on the copy button present in the field. The text is also displayed on the left
|
||||||
|
and can have multiple lines.
|
||||||
|
|
||||||
|
|
||||||
|
.. _frontend/fields/copy_clipboard_url_field:
|
||||||
|
|
||||||
|
CopyClipboardURLField
|
||||||
|
---------------------
|
||||||
|
|
||||||
|
- Location: `@web/fields/copy_clipboard_url_field`
|
||||||
|
- Technical name: `CopyClipboardURL`
|
||||||
|
- Supported types: `char`
|
||||||
|
|
||||||
|
This component represents a field that allows a user to copy a URL link to its clipboard
|
||||||
|
by clicking on the copy button present in the field. The value is also displayed on the left
|
||||||
|
and the user can click on it to open the link in a new tab.
|
||||||
|
|
||||||
|
|
||||||
.. _frontend/fields/date_field:
|
.. _frontend/fields/date_field:
|
||||||
|
|
||||||
DateField
|
DateField
|
||||||
@ -536,18 +590,13 @@ It supports the following options:
|
|||||||
- optional. set if the maximum value is editable
|
- optional. set if the maximum value is editable
|
||||||
* - `current_value`
|
* - `current_value`
|
||||||
- `integer`, `float`
|
- `integer`, `float`
|
||||||
- required. this is the current value of the progress. It can be the name of another field
|
- optional. this is the current value of the progress. It can be the name of any field
|
||||||
that is present in the view, or any numerical value set directly.
|
that is present in the view, or any numerical value set directly.
|
||||||
* - `max_value`
|
* - `max_value`
|
||||||
- `integer`, `float`
|
- `integer`, `float`
|
||||||
- optional. this value is used to set a maximum value. It can be the name of another field
|
- optional. this value is used to set a maximum value. It can be the name of any field
|
||||||
that is present in the view, or any numerical value set directly.
|
that is present in the view, or any numerical value set directly.
|
||||||
|
|
||||||
.. note::
|
|
||||||
|
|
||||||
To use a more dynamic progress bar, it is recommended to set the current_value and the max_value
|
|
||||||
using the record instead of a static numerical value, which can't be edited.
|
|
||||||
|
|
||||||
.. code-block:: xml
|
.. code-block:: xml
|
||||||
|
|
||||||
<field name="my_field" widget="progressbar" options="{'editable': true, 'current_value': 'quantity', 'max_value': 'available_stock'}" />
|
<field name="my_field" widget="progressbar" options="{'editable': true, 'current_value': 'quantity', 'max_value': 'available_stock'}" />
|
||||||
|
Loading…
Reference in New Issue
Block a user