Re: [Announcement] New feature for Tapestry 5.4.2 and 5.5: easily call event handler methods from JavaScript

abangkis <[email protected]>
Newsgroups gmane.comp.java.tapestry.user
Message-ID <CAGqeSzVa=YpSAnkgw-QsZ2LCUtxqf830EvE2Cpt2pLdx71WHLQ@mail.gmail.com>
Yes. I've seen it. Pretty clean and good example.

Thank you.

On Thu, Apr 27, 2017 at 7:15 PM, Svein-Erik Løken <[email protected]> wrote:

> See my working demo above in this thread:
> (https://github.com/sveine/tapestry-multi-module-demo/
> blob/master/module1-root/module1/src/main/resources/META-INF/modules/
> publisheventdemo.js)
>
> From: Thiago H de Paula Figueiredo [via Apache Tapestry Mailing List
> Archives] [mailto:[email protected]]
> Sent: 27. april 2017 14:11
> To: Svein-Erik Løken <[email protected]>
> Subject: Re: [Announcement] New feature for Tapestry 5.4.2 and 5.5: easily
> call event handler methods from JavaScript
>
> On Thu, Apr 27, 2017 at 6:43 AM, abangkis <[hidden
> email]</user/SendEmail.jtp?type=node&node=5733456&i=0>> wrote:
>
> > Hi. Thanks for the awesome improvement. I want to adopt it immediately.
>
>
> Hi! Nice! :)
>
>
> > But I've stumbled to one problem. How do I pass a parameter to the event?
> >
>
> You don't pass it to the event, but to the t5/core/ajax() function. Check
> the data property of the options parameter in
> https://tapestry.apache.org/current/coffeescript/ajax.html. Basically, you
> pass an object with the key/value pairs you want passed as parameters:
>
> ajax('answer', {
>     element: $('#result'),
> /* Here it goes */
> data: {
> queryParameter1: valueParameter1,
> queryParameter2: valueParameter2
> }
> /* Here it ends */
>     success: function(response) {
>         $('#result').text(response.json.origin);
>     }
> });
>
>
> --
> Thiago
>
> ________________________________
> If you reply to this email, your message will be added to the discussion
> below:
> http://apache-tapestry-mailing-list-archives.1045711.
> n5.nabble.com/Announcement-New-feature-for-Tapestry-5-4-
> 2-and-5-5-easily-call-event-handler-methods-from-
> JavaScript-tp5733295p5733456.html
> To unsubscribe from [email protected]<mailto:
> [email protected]> Mailing List Archives, click here<
> http://apache-tapestry-mailing-list-archives.1045711.
> n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=
> 2375125&code=c3ZlaW5AamFjaWxsYS5ub3wyMzc1MTI1fC0xNTM4NzY2ODg4>.
> NAML<http://apache-tapestry-mailing-list-archives.1045711.
> n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%
> 21nabble%3Aemail.naml&base=nabble.naml.namespaces.
> BasicNamespace-nabble.view.web.template.NabbleNamespace-
> nabble.view.web.template.NodeNamespace&breadcrumbs=
> notify_subscribers%21nabble%3Aemail.naml-instant_emails%
> 21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
>



-- 
http://www.mreunionlabs.net/ <http://www.mreunion-labs.net/>
twitter : @mreunionlabs @abangkis
page : https://plus.google.com/104168782385184990771
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.