Would it be easier for you to override the following method in
UISelect in your own component subclass?
protected void validateValue(FacesContext context, Object convertedValue)
I'm actually kind of confused why you'd even need to do this.
Your source select many component has a list of items,
Here is why I believe I need to do this...correct me if Im wrong.
I have two lists (A and B). List A has values 1,2,3,4,5 . List B has
nothing. I move the values 1,2,3 over to list B and submit. Because the
values 1,2,3 are not a subset of the original used to
populate list B, the submitte
Are you physically moving with javascript the values 1,2,3 over to the
other html element form data?
Or when you submit the form, are you submitting values 1,2,3 for List
A, submitting no values for List B, and executing a move action (or
action listener)? This is what would normally happen if
Mike Kienenberger wrote:
>
> Are you physically moving with javascript the values 1,2,3 over to the
> other html element form data?
>
I'm physically moving the values using JavaScript.
Mike Kienenberger wrote:
>
> Or when you submit the form, are you submitting values 1,2,3 for List
> A, sub
: [EMAIL PROTECTED]
Subject: Re: Programatically updating the model
Mike Kienenberger wrote:
>
> Are you physically moving with javascript the values 1,2,3 over to the
> other html element form data?
>
I'm physically moving the values using JavaScript.
Mike Kienenberger wrote:
andbox/selectManyPicklist.html
> It does the trick for me perfectly!
>
> With regards,
> Marco
>
> -Original Message-
> From: monkeyden [mailto:[EMAIL PROTECTED]
> Sent: donderdag 12 april 2007 4:45
> To: [EMAIL PROTECTED]
> Subject: Re: Programatically updat
Ah, I didn't really think you were using client-side javascript.
Yes, if you're using javascript to move the stuff around, then it's a
different story.
Yes, overriding a renderer (or component if that works) would change
the behavior for the entire application. What you'd probably want to
do i
-
> From: monkeyden [mailto:[EMAIL PROTECTED]
> Sent: donderdag 12 april 2007 4:45
> To: [EMAIL PROTECTED]
> Subject: Re: Programatically updating the model
>
>
>
> Mike Kienenberger wrote:
>>
>> Are you physically moving with javascript the values 1,2,3 ove
I guess another possibility would be to add a
before-validation-phase-listener that temporarily adds the List A
values to the List B component's allowed choices, then removes them in
the after phase.
I think trying to handle this after validation is going to cause too
many other problems.
On 4/1
ml
>> > It does the trick for me perfectly!
>> >
>> > With regards,
>> > Marco
>> >
>> > -Original Message-
>> > From: monkeyden [mailto:[EMAIL PROTECTED]
>> > Sent: donderdag 12 april 2007 4:45
>> > To: [EMAI
Isn't there a simple way to tell JSF to ask the backing bean for the
SelectList again, after I've matched it with the submitted values in the
VCL? I tried setLocalValueSet(false), in hopes that it would tell JSF that
the local value needs to be updated. Not sure if this is the right method
as th
Use the following to put a component into a state where it should
fetch values from the backing bean model:
component.setSubmittedValue(null);
component.setLocalValueSet(false);
On 4/12/07, monkeyden <[EMAIL PROTECTED]> wrote:
Isn't there a simple way to tell JSF to ask the backing be
I tired this. The component still fails validation, so JSF still has the old
version of the list.
Mike Kienenberger wrote:
>
> Use the following to put a component into a state where it should
> fetch values from the backing bean model:
>
> component.setSubmittedValue(null);
> compo
Anyone else have any ideas on how to get around this? In a
valueChangeListener method, I update the list bound to a UISelectMany and I
want to tell JSF to update the UISelectMany from the backing bean before
validating.
monkeyden wrote:
>
> I tried this. The component still fails validation,
Wouldn't it be simpler to just create SelectItems from the submitted values,
in the VCL, and set the backing bean property so they match? Who needs a
phase listener and why add ALL the values from the picklist, when I have
everything I need in UIInput.getSubmittedValues(). This seems so logical
The problems you are having are because you are trying to write a JSF
component but are trying to do it through the "user api" rather than the
"component api" of JSF.
If you want to write a picklist component you should really subclass
UIComponent (or other convenient base). In this case you d
16 matches
Mail list logo