So formbuilder has an annoying glitch, that setting the value of a
checkbox, even without force, will override the value currently on the
form. Thus the guards against changing checkbox values when a form has been
submitted.
But those guards also prevented the checkboxes for advanced items getting
the right value when going into advanced mode.
Note that if the user makes changes to advanced mode stuff and leaves
advanced mode, those changes are lost. That seems reasonable so I didn't
change it -- and it made this fix simple.
options => [ [ 1 => $description ] ],
fieldset => $section,
);
- if (! $form->submitted) {
+ if (! $form->submitted ||
+ ($info{advanced} && $form->submitted eq 'Advanced Mode')) {
$form->field(name => $name, value => $value);
}
}
feature.
* actiontabs: More consistent styling of Hn tags.
* websetup: Fix saving of advanced mode changes.
+ * websetup: Fix defaults of checkboxes in advanced mode.
-- Joey Hess <joeyh@debian.org> Wed, 29 Sep 2010 11:58:23 -0400