luci-base: FlagValue fix type of enabled and disabled properties

The form.Flag checkbox allows to specify a value for enabled/disabled e.g. for a dropbear:

    o = s.option(form.Flag, 'PasswordAuth');
    o.enabled  = 'on';

So the property type should be a string but not just a number.

Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
This commit is contained in:
Sergey Ponomarev 2024-01-19 19:47:58 +02:00
parent b18960f600
commit a4fd238ab2

View file

@ -4007,7 +4007,7 @@ var CBIFlagValue = CBIValue.extend(/** @lends LuCI.form.FlagValue.prototype */ {
* Sets the input value to use for the checkbox checked state.
*
* @name LuCI.form.FlagValue.prototype#enabled
* @type number
* @type string
* @default 1
*/
@ -4015,7 +4015,7 @@ var CBIFlagValue = CBIValue.extend(/** @lends LuCI.form.FlagValue.prototype */ {
* Sets the input value to use for the checkbox unchecked state.
*
* @name LuCI.form.FlagValue.prototype#disabled
* @type number
* @type string
* @default 0
*/