myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jakob Korherr (JIRA)" <...@myfaces.apache.org>
Subject [jira] Commented: (MYFACES-3012) Allow f:param for <h:inputText> <f:ajax>
Date Fri, 07 Jan 2011 23:13:48 GMT

    [ https://issues.apache.org/jira/browse/MYFACES-3012?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12979018#action_12979018
] 

Jakob Korherr commented on MYFACES-3012:
----------------------------------------

I am not sure if this really »should« work. At least I could not find any documentation
about it in the spec.

IMO it is clear that this should work for UICommand components, because f:param is associated
with the command that this component triggers. But I don't know if this should be true for
input components also, because on a non-ajax JSF request this is also not supported by input
components.

However, looking at the javascript spec of jsf.ajax.request(source, event, options) I found
the following:

options
    The set of available options that can be sent as request parameters to control client
and/or server side request processing. Acceptable name/value pair options are:
    name 	value
    execute 	space seperated list of client identifiers
    render 	space seperated list of client identifiers
    onevent 	function to callback for event
    onerror 	function to callback for error
    params 	object containing parameters to include in the request
    The options argument is optional.

--> you are able to specify custom params here, so why shouldn't it work via the JSF tags
f:param + f:ajax?

Thus IMO we should ask the expert group about the expected behavior before committing the
patch. However, I think the behavior you're describing is NOT expected in JSF 2.0 and 2.1,
but it might be a cool feature for JSF 2.2.

Furthermore it could support something like this:

<f:ajax>
    <f:param name="param1" value="value1" />
</f:ajax>

I'll write a mail to jsr-314-open about this!

> Allow f:param for <h:inputText> <f:ajax>
> ----------------------------------------
>
>                 Key: MYFACES-3012
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3012
>             Project: MyFaces Core
>          Issue Type: Improvement
>          Components: JSR-314
>    Affects Versions: 2.0.4-SNAPSHOT
>         Environment: myfaces trunk, shared svn. rev 1051469
>            Reporter: Martin Kočí
>            Priority: Minor
>         Attachments: MYFACES-3012.patch
>
>
> I don't know what  spec says but following should work:
> <h:inputText>
>   <f:param name="paramName" value="paramValue" />   
>   <f:ajax />
> </h:inputText>
> expected result is paramName = paramValue pair in request.
> For h:command it works already.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message