From a78a9e133377fec6208b79d9c32602a4c8fe6109 Mon Sep 17 00:00:00 2001 From: Ad Schellevis Date: Sun, 15 Oct 2023 14:57:42 +0200 Subject: [PATCH] Development Manual / Frontend / Fieldtypes - explain the new optgroup introduced in https://github.com/opnsense/core/commit/bc195308be01698a3cff3e8c375d2646b8576b37 , https://github.com/opnsense/core/commit/9206823d60f90430f26415082ba8a7b52931c294 --- .../frontend/models_fieldtypes.rst | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/source/development/frontend/models_fieldtypes.rst b/source/development/frontend/models_fieldtypes.rst index 605762ef..9af10c01 100644 --- a/source/development/frontend/models_fieldtypes.rst +++ b/source/development/frontend/models_fieldtypes.rst @@ -439,6 +439,25 @@ Validate against a static list of options. "Multiple", "Y,N", "Allow to select multiple options" "OptionValues", ":code:`xml`", "Xml structure containing keys and values, when keys should be numeric, the value tag is also supported :code:`option1`" + +When the list of available options is relatively large, its also possible to nest the options one level, which +generates :code:`` clauses in our model. As of 24.1 they can be defined using the following structure: + +.. code-block:: xml + + + + + option 1 + + + option 2 + + + + + + PortField ------------------------------------