luci-base: Enforce maximal firewall zone length in the Create / Assign scenario as...
authorJan Pazdziora <jan.pazdziora@code.adelton.com>
Thu, 9 Jan 2025 20:00:55 +0000 (21:00 +0100)
committerPaul Donald <newtwen+github@gmail.com>
Fri, 10 Jan 2025 14:41:58 +0000 (15:41 +0100)
Signed-off-by: Jan Pazdziora <jan.pazdziora@code.adelton.com>
modules/luci-base/htdocs/luci-static/resources/tools/widgets.js

index 0ba07afcde8acd848d60b0b5b6df91d5d8da3602..4c9cd6924e06ce80505c755011b8f412d1ea44c3 100644 (file)
@@ -148,6 +148,7 @@ var CBIZoneSelect = form.ListValue.extend({
                        display_items: this.display_size || this.size || 3,
                        dropdown_items: this.dropdown_size || this.size || 5,
                        validate: L.bind(this.validate, this, section_id),
+                       datatype: 'and(uciname,maxlength(11))',
                        create: !this.nocreate,
                        create_markup: '' +
                                '<li data-value="{{value}}">' +