diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index a79cdbf02..3aa19597c 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -1,4 +1,5 @@ 7.6.7 + - fixed #9263: Thingy possibleValues processing, and List type autodetection. 7.6.6 - fixed #8792: Image Preview gives ERROR in Collateral Manager diff --git a/lib/WebGUI/Asset/Wobject/Thingy.pm b/lib/WebGUI/Asset/Wobject/Thingy.pm index d68660b8e..3b5f6ee5d 100644 --- a/lib/WebGUI/Asset/Wobject/Thingy.pm +++ b/lib/WebGUI/Asset/Wobject/Thingy.pm @@ -862,7 +862,7 @@ sub getFormElement { } } - if (WebGUI::Utility::isIn($data->{fieldType},qw(SelectList CheckList SelectBox Attachments Combo))) { + if (WebGUI::Utility::isIn($data->{fieldType},qw(SelectList CheckList SelectBox Attachments))) { my @defaultValues; if ($self->session->form->param($name)) { @defaultValues = $self->session->form->selectList($name); @@ -876,7 +876,9 @@ sub getFormElement { $param{value} = \@defaultValues; } - if (WebGUI::Utility::isIn($data->{fieldType},qw(SelectList SelectBox CheckList RadioList SelectSlider Combo))) { + my $class = 'WebGUI::Form::'. ucfirst $data->{fieldType}; + eval { WebGUI::Pluggable::load($class) }; + if ($class->isa('WebGUI::Form::List')) { delete $param{size}; my $values = WebGUI::Operation::Shared::secureEval($self->session,$data->{possibleValues}); @@ -930,7 +932,7 @@ sub getFormElement { $param{value} = $data->{value} || $data->{defaultValue}; } - my $formElement = eval { WebGUI::Pluggable::instanciate("WebGUI::Form::". ucfirst $param{fieldType}, "new", [$self->session, \%param ])}; + my $formElement = eval { WebGUI::Pluggable::instanciate($class, "new", [$self->session, \%param ])}; return $formElement->toHtml(); }