[5.4] Select Menu Bug (secure?)

2013-12-18 Thread George Christman
While trying to submit a new record with blankOption="always" and t:secure="literal:NEVER" I'm finding when my getModel method is called, the query used to rebuild my select model attempts to commit my object model to the database resulting in a database constraint violation exception rather than t

Re: My form error message, include link to a page from java class

2013-12-18 Thread Chris Mylonas
Beauty, I'll give that a shot - sounds like what I want to do. Thanks Taha On Thu, Dec 19, 2013 at 11:14 AM, Taha Siddiqi wrote: > Oops! Sorry I misunderstood your question. > > If you want a clickable link, I don't think Errors component can do that. > > > http://tapestry.apache.org/5.3/apido

Re: My form error message, include link to a page from java class

2013-12-18 Thread Thiago H de Paula Figueiredo
On Wed, 18 Dec 2013 19:54:51 -0200, Chris Mylonas wrote: Thanks, but no again. form.recordError(commonNameField, "The ip address you entered is public and in use - please try again or search for it ${" + link.toAbsoluteURI() + "}" ); renders this as a string, and without the expansion

Re: My form error message, include link to a page from java class

2013-12-18 Thread Taha Siddiqi
Oops! Sorry I misunderstood your question. If you want a clickable link, I don't think Errors component can do that. http://tapestry.apache.org/5.3/apidocs/src-html/org/apache/tapestry5/corelib/components/Errors.html The text message is written as writer.write() rather than writer.writeRaw() Yo

Re: My form error message, include link to a page from java class

2013-12-18 Thread Chris Mylonas
Thanks, but no again. form.recordError(commonNameField, "The ip address you entered is public and in use - please try again or search for it ${" + link.toAbsoluteURI() + "}" ); renders this as a string, and without the expansion-y ${} it's just plain old text. ${http://hplaptop:8080/MetwideSubne

Re: submit form with context from js

2013-12-18 Thread Taha Siddiqi
If I am using jQuery, I won't be too much worried about it. BTW nice catch !! On Dec 18, 2013, at 9:34 PM, George Christman wrote: > Taha, firing $("#form").trigger('submit'); seems to remember my > original submit action. Should I be wary of this with other browsers? > > example > > define(["

How to detect clientside validation errors have occurred in js

2013-12-18 Thread George Christman
Hello, I've created a modal dialog box mixin that is attached to my submit actions. On form submission, is there a way to detect whether or not clientside validation errors have occurred in js so I can prevent the dialog box from opening up? The dialog box is covering up field errors preventing the

Re: submit form with context from js

2013-12-18 Thread George Christman
Taha, firing $("#form").trigger('submit'); seems to remember my original submit action. Should I be wary of this with other browsers? example define(["jquery", "bootstrap/modal"], function($) { int = function(spec) { var $field = $("#" + spec.id); $field.bind("click", functio

Re: submit form with context from js

2013-12-18 Thread George Christman
No, there is unfortunately 4 submit buttons. :( On Wed, Dec 18, 2013 at 10:30 AM, Taha Siddiqi wrote: > If there is only one submit button, you can also use form's own context > parameter. that way you just have to call form.submit() from the javascript. > > > On Dec 18, 2013, at 8:46 PM, Georg

Re: submit form with context from js

2013-12-18 Thread Taha Siddiqi
If there is only one submit button, you can also use form's own context parameter. that way you just have to call form.submit() from the javascript. On Dec 18, 2013, at 8:46 PM, George Christman wrote: > I guess that would work, I wish there was a way to reconstruct the > original submit button

Re: My form error message, include link to a page from java class

2013-12-18 Thread Taha Siddiqi
Use Link#toAbsoluteURI() or Link#toURI() depending on your need( I think here toAbsoluteURI() is more appropriate) On Dec 18, 2013, at 8:32 PM, Chris Mylonas wrote: > Thanks Taha - I was looking at the Link Component FAQ earlier scratching my > head. It spits out the text for the link, not a h

Re: submit form with context from js

2013-12-18 Thread George Christman
I guess that would work, I wish there was a way to reconstruct the original submit button in js. On Wed, Dec 18, 2013 at 9:56 AM, Lance Java wrote: > You could use 2 buttons (one hidden). > Hide the original form submit button and show a button that fires the > modal. The modal somehow fires a cl

Re: My form error message, include link to a page from java class

2013-12-18 Thread Chris Mylonas
Thanks Taha - I was looking at the Link Component FAQ earlier scratching my head. It spits out the text for the link, not a html link. So I tried this: Link link = linkSource.createPageRenderLink(IPAddress.class); if (ni != null) { form.recordError(commonNa

Re: submit form with context from js

2013-12-18 Thread Lance Java
You could use 2 buttons (one hidden). Hide the original form submit button and show a button that fires the modal. The modal somehow fires a click event on the hidden submit button.

submit form with context from js

2013-12-18 Thread George Christman
Hello, I'm using 5.4 and a custom mixin on my submit actions which is used to trigger the bootstrap modal popup. My popup does nothing other than provide warnings to the user prior to form submission. I'm trying to figure out how to submit the form from my modal popup with the original submit butto

Re: [5.4] hibernate events

2013-12-18 Thread Lance Java
Great! Note, you could reduce the verbosity by getting rid of the interface, NOT registering a service and using @Autobuild Ie: @Startup public static void initHibernateEventListener(@Autobuild HibernateInitializerImpl hi) { hi.initialize(); }

Re: Apache Tapestry 5.4-beta-1 preview release

2013-12-18 Thread Kalle Korhonen
Personally, I really think we should release/should have released the beta as a proper Apache release that has been voted on and that the the bits would have been released through official channels (published on /dist and maven central). Now nothing really changed between alpha and beta preview rel