Re: Multiple file upload
If you don't mind introducing the dependency to a flash component, then look at this: http://www.swfupload.org/ I have successfully created a tapestry component using SWFUpload, which supports multiple file upload and degrades to default single file upload if Flash is not present. Quoting Thiago HP <[EMAIL PROTECTED]>: > On Thu, Aug 28, 2008 at 3:27 PM, Chris Lewis > <[EMAIL PROTECTED]> wrote: > > The tricky part unfortunately is dealing with T5. I don't know how > you > > can create new components on the fly. > > You just cannot do that. Tapestry 5' mantra is "Static Structure, > Dynamic Behavior". > One way to do it would be putting your form inside a zone. Then submit > the form to do the first file uploading. The form would show the list > of already uploaded files (if any) and show the file upload component > again. > > Thiago > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T4.1.5 possible ognl cache problem
Jesse, could you comment on this? I haven't tried profiling my apps, but the repeated calls to Ognl.compileExpression are worrisome if Denis got his numbers right. Are there any ognl-related changes in 4.1.6? Denis, maybe you could repeat your profiling with the latest snapshot, so hopefully something could still be done for this before 4.1.6 is released. Kalle On Thu, Aug 28, 2008 at 5:08 AM, denis queffeulou < [EMAIL PROTECTED]> wrote: > Hi all, > > I'm making some profiling on an web app made with Tapestry 4.1.5 which > returns XML. > The result are disappointing as the average access time (got with JMeter) > is around 2000ms. > > In JProfiler, I found that OGNL expressions compilation uses 40% of > processing time. > As the JMeter script is requesting always the same page on the webapp, I'm > wondering why the expressions are always compiled. The cache seems not to be > used: > > 31896 invocations on ExpressionCache.getCompiledExpression > 31140 invocations on Ognl.compileExpression > > Is there someone to give me a clue to have better performances ? > > Thanks > > PS: sorry for double posting in dev list, I had some problems to subscribe > to users. > -- > Denis Queffeulou > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
T5: Contributing to web.xml and web app context from module
In Grails a plugin has the ability to contribute something into the spring context, as well as the web.xml and the web application context. This allows plugins to be very independent in adding needed functionality. For example, when a plugin is installed into Grails, it can add a number of controllers that can handle requests (e.g. in the case of acegi, login & logout links, login & logout pages, etc) and can add content to the application's web.xml (e.g. to add an extra filters, etc). Now, it's pretty clear that T5 modules can contribute services, add stuff to the configuration, etc. I was looking at the tapestry-spring plugin and I noticed that it still requires some manual configuration (e.g. adding a spring filter), which makes me think that contributing content to the web.xml is not possible. I was wondering, is there a reason not to support something like this in T5? If something like this could be supported, which part of T5 should be tweaked to support that ? Any tips and thoughts would be highly appreciated. Cheers, Alex Kotchnev
Re: Page pool hard limit and page instance usage
Tapestry is obtaining page instances to see if there is an activation context for the page. I expect to optimize this in the future, to check to see if the page has an event handler for the passivate event. In the meantime, you could build your own PageLink component that generates the link by invoking ComponentResources.createPageLink("pagename", true) ... that will tell Tapestry to generate a link to the page with no activation context, and the page will NOT be queried for its context, and therefore, won't need to be attached to the current request. On Fri, Aug 29, 2008 at 3:58 AM, 9902468 <[EMAIL PROTECTED]> wrote: > > Hi, > > we are experiencing strange hard pool limit reached exceptions. (For the > user count that we have.) After debugging a little, it seems that our left > menu component, which is full of page links, instantiates not only the page > that we are at, but also the ones that are referenced in page link. > > This can be seen also in that exception page is shown, if one of the pages > that are referenced in page links have an error. > > Is this correct behavior? And should we really use common a href= tags to > avoid this? Further more, is it possible to create infinite loop, when page > a has page link to page b, which has page link to page a? > > - 99 > -- > View this message in context: > http://www.nabble.com/Page-pool-hard-limit-and-page-instance-usage-tp19217773p19217773.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Howard M. Lewis Ship Creator Apache Tapestry and Apache HiveMind - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5 : Spring 2.5 support w/ tapestry-spring ?
That's not to say that I prefer Spring over tapestry IOC but I needed Spring security support. For example lazy initialization of services is more powerful and versatile with Tapestry IOC than with Spring. Martijn On Fri, 2008-08-29 at 09:21 +0200, Martijn Brinkers wrote: > Yes I am using Spring 2.5 with the Tapestry Spring module > > Martijn Brinkers > > On Fri, 2008-08-29 at 03:15 -0400, Alex Kotchnev wrote: > > Is anyone successfully using spring 2.5 w/ the tapestry-spring module ? The > > module main page talks about it being tested against 1.2.8. > > > > Cheers, > > > > Alex K - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5 : Spring 2.5 support w/ tapestry-spring ?
sorry, the spring version is 2.5, On Sat, Aug 30, 2008 at 1:32 AM, Mohammad Shamsi <[EMAIL PROTECTED]>wrote: > Martin, take a look at PHB here : http://code.google.com/p/shams > that is another sample of integrating Tapestry with Spring 2.0.5 > > > > > On Sat, Aug 30, 2008 at 1:26 AM, Timothy Sweetser < > [EMAIL PROTECTED]> wrote: > >> Thirded--my most recent app is pretty heavily integrated with Spring >> 2.5, without much trouble. >> >> Tim >> >> On Fri, Aug 29, 2008 at 12:49 PM, Toby Hobson >> <[EMAIL PROTECTED]> wrote: >> > me too >> > >> > Toby >> > >> > 2008/8/29 Martijn Brinkers <[EMAIL PROTECTED]> >> > >> >> Yes I am using Spring 2.5 with the Tapestry Spring module >> >> >> >> Martijn Brinkers >> >> >> >> On Fri, 2008-08-29 at 03:15 -0400, Alex Kotchnev wrote: >> >> > Is anyone successfully using spring 2.5 w/ the tapestry-spring module >> ? >> >> The >> >> > module main page talks about it being tested against 1.2.8. >> >> > >> >> > Cheers, >> >> > >> >> > Alex K >> >> >> >> >> >> - >> >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> >> > >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > -- > sincerely yours > M. H. Shamsi > -- sincerely yours M. H. Shamsi
Re: T5 : Spring 2.5 support w/ tapestry-spring ?
Martin, take a look at PHB here : http://code.google.com/p/shams that is another sample of integrating Tapestry with Spring 2.0.5 On Sat, Aug 30, 2008 at 1:26 AM, Timothy Sweetser < [EMAIL PROTECTED]> wrote: > Thirded--my most recent app is pretty heavily integrated with Spring > 2.5, without much trouble. > > Tim > > On Fri, Aug 29, 2008 at 12:49 PM, Toby Hobson > <[EMAIL PROTECTED]> wrote: > > me too > > > > Toby > > > > 2008/8/29 Martijn Brinkers <[EMAIL PROTECTED]> > > > >> Yes I am using Spring 2.5 with the Tapestry Spring module > >> > >> Martijn Brinkers > >> > >> On Fri, 2008-08-29 at 03:15 -0400, Alex Kotchnev wrote: > >> > Is anyone successfully using spring 2.5 w/ the tapestry-spring module > ? > >> The > >> > module main page talks about it being tested against 1.2.8. > >> > > >> > Cheers, > >> > > >> > Alex K > >> > >> > >> - > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- sincerely yours M. H. Shamsi
Re: T5 : Spring 2.5 support w/ tapestry-spring ?
Thirded--my most recent app is pretty heavily integrated with Spring 2.5, without much trouble. Tim On Fri, Aug 29, 2008 at 12:49 PM, Toby Hobson <[EMAIL PROTECTED]> wrote: > me too > > Toby > > 2008/8/29 Martijn Brinkers <[EMAIL PROTECTED]> > >> Yes I am using Spring 2.5 with the Tapestry Spring module >> >> Martijn Brinkers >> >> On Fri, 2008-08-29 at 03:15 -0400, Alex Kotchnev wrote: >> > Is anyone successfully using spring 2.5 w/ the tapestry-spring module ? >> The >> > module main page talks about it being tested against 1.2.8. >> > >> > Cheers, >> > >> > Alex K >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5 : Spring 2.5 support w/ tapestry-spring ?
me too Toby 2008/8/29 Martijn Brinkers <[EMAIL PROTECTED]> > Yes I am using Spring 2.5 with the Tapestry Spring module > > Martijn Brinkers > > On Fri, 2008-08-29 at 03:15 -0400, Alex Kotchnev wrote: > > Is anyone successfully using spring 2.5 w/ the tapestry-spring module ? > The > > module main page talks about it being tested against 1.2.8. > > > > Cheers, > > > > Alex K > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: T5: onActivate exception query
i think that solution is a bit "dangerous", if you do some refectorings. eg: move the page Administration in another package or the application context is changed 2008/8/29 <[EMAIL PROTECTED]> > Hi, > > I was just about to reply and say I solved it. Missing slash in the > location.href. The following works: > > onclick="location.href='/Administration';"/> > > thanks for your help. > > > p. > > > Quoting Martijn Brinkers <[EMAIL PROTECTED]>: > > I'm not sure but I thinks it's a similar problem. It looks like >> Administration is interpreted as the context. >> >> If you want to cancel the page it's easier to use the t5Component Button >> component. >> >> Add t5Component jar to you project (see >> http://code.google.com/p/tapestry5-components/) and add this to >> the .tml: >> >> > t:event="cancel">Cancel >> >> >> And add an event handler in your page: >> >> protected Object onCancel() >> { >> return Administration.class; // The Page to redirect to >> } >> >> >> Martijn Brinkers >> >> >> On Fri, 2008-08-29 at 12:09 +0100, [EMAIL PROTECTED] wrote: >> >>> Thanks for the fast reply Martijn; that fixed the GIF asset. >>> >>> However, I am still having problems with the Cancel button. I can >>> reference the Administration page as an asset, but obviously it then >>> does not get processed by Tapestry. >>> >>> Thoughts, anyone? >>> >>> >> onclick="location.href='Administration';"/> >>> >>> >>> p. >>> >>> >>> Quoting Martijn Brinkers <[EMAIL PROTECTED]>: >>> >>> > I think the following happens >>> > >>> > The gif is requested by your page because of the IMG so the GET for the >>> > IMG looks something like >>> > >>> > http://YOUR_DOMAIN/YOUR_PAGE/bl_red_hundred.gif >>> > >>> > Now you page assumes this is your activation context and tries to >>> > convert it to int (which it's not). >>> > >>> > I think you can solve this by adding an image Asset. Another option I >>> > think would be to not request the image relative to your page but from >>> > for example the /images subir (make sure the request if relative with >>> > respect to you app root and not absolute). >>> > >>> > I guess the other problem is related. >>> > >>> > Martijn Brinkers >>> > >>> > On Fri, 2008-08-29 at 11:23 +0100, [EMAIL PROTECTED] wrote: >>> >> I don't quite understand why the following does not work and produces: >>> >> >>> >> TapestryModule.RequestExceptionHandler Processing of request failed >>> >> with uncaught exception: Exception in method >>> >> uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), >>> >> parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer >>> >> (via String --> Long, Long --> Integer) failed: For input string: >>> >> "bl_red_hundred.gif" >>> >> org.apache.tapestry5.runtime.ComponentEventException: Exception in >>> >> method uk.bl.dportal.pages.EditUser.onActivate(int) (at >>> >> EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to >>> >> type java.lang.Integer (via String --> Long, Long --> Integer) failed: >>> >> For input string: "bl_red_hundred.gif" >>> >> at >>> >> >>> >>> org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1054) >>> >> ... >>> >> >>> >> >>> >> I have a template which containes a reference to a gif used in the >>> >> banner (BLTemplate.tml): >>> >> >>> >> http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> >>> >> >>> >> Digital Portal: ${heading} >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> ${title} >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> ... >>> >> >>> >> >>> >> This template is used for all my pages (in this case EditUser.tml): >>> >> >>> >> >> >> t:title="literal:Edit >>> User Details" >>> >> xmlns:t=" >>> http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> >>> >> >>> >> Edit user details. >>> >> ... >>> >> >>> >> >>> >> This page is called from a link produced by the Grid component (in >>> >> ManageUsers.tml): >>> >> >>> >> >> >> t:exclude="id,password" t:row="listItem"> >>> >> >>> >> >> t:context="listItem.id"> >>> >> ${listItem.userName} >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> and EditUser.java has an onActivate with a parameter: >>> >> >>> >> public void onActivate(int id) >>> >> { >>> >> Query query = session.createQuery("from User where id = >>> '"+id+"'"); >>> >> List result = query.list(); >>> >> user = (User)result.get(0); >>> >> } >>> >> >>> >> >>> >> Why is the GIF name being passed in initially? The page still works, >>> >> so the id is being set to that given by the link from
Re: T5: onActivate exception query
Hi, I was just about to reply and say I solved it. Missing slash in the location.href. The following works: onclick="location.href='/Administration';"/> thanks for your help. p. Quoting Martijn Brinkers <[EMAIL PROTECTED]>: I'm not sure but I thinks it's a similar problem. It looks like Administration is interpreted as the context. If you want to cancel the page it's easier to use the t5Component Button component. Add t5Component jar to you project (see http://code.google.com/p/tapestry5-components/) and add this to the .tml: Cancel And add an event handler in your page: protected Object onCancel() { return Administration.class; // The Page to redirect to } Martijn Brinkers On Fri, 2008-08-29 at 12:09 +0100, [EMAIL PROTECTED] wrote: Thanks for the fast reply Martijn; that fixed the GIF asset. However, I am still having problems with the Cancel button. I can reference the Administration page as an asset, but obviously it then does not get processed by Tapestry. Thoughts, anyone? p. Quoting Martijn Brinkers <[EMAIL PROTECTED]>: > I think the following happens > > The gif is requested by your page because of the IMG so the GET for the > IMG looks something like > > http://YOUR_DOMAIN/YOUR_PAGE/bl_red_hundred.gif > > Now you page assumes this is your activation context and tries to > convert it to int (which it's not). > > I think you can solve this by adding an image Asset. Another option I > think would be to not request the image relative to your page but from > for example the /images subir (make sure the request if relative with > respect to you app root and not absolute). > > I guess the other problem is related. > > Martijn Brinkers > > On Fri, 2008-08-29 at 11:23 +0100, [EMAIL PROTECTED] wrote: >> I don't quite understand why the following does not work and produces: >> >> TapestryModule.RequestExceptionHandler Processing of request failed >> with uncaught exception: Exception in method >> uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), >> parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer >> (via String --> Long, Long --> Integer) failed: For input string: >> "bl_red_hundred.gif" >> org.apache.tapestry5.runtime.ComponentEventException: Exception in >> method uk.bl.dportal.pages.EditUser.onActivate(int) (at >> EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to >> type java.lang.Integer (via String --> Long, Long --> Integer) failed: >> For input string: "bl_red_hundred.gif" >>at >> org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1054) >> ... >> >> >> I have a template which containes a reference to a gif used in the >> banner (BLTemplate.tml): >> >> http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> >> >> Digital Portal: ${heading} >> >> >> >> >> >> >>${title} >> >> >> >> >> >> ... >> >> >> This template is used for all my pages (in this case EditUser.tml): >> >> >t:title="literal:Edit User Details" >> xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> >> >> Edit user details. >> ... >> >> >> This page is called from a link produced by the Grid component (in >> ManageUsers.tml): >> >>> t:exclude="id,password" t:row="listItem"> >> >> >>${listItem.userName} >> >> >> >> >> >> and EditUser.java has an onActivate with a parameter: >> >>public void onActivate(int id) >>{ >>Query query = session.createQuery("from User where id = '"+id+"'"); >>List result = query.list(); >>user = (User)result.get(0); >>} >> >> >> Why is the GIF name being passed in initially? The page still works, >> so the id is being set to that given by the link from ManageUsers.tml. >> The exception is generated but it continues on to display the page. >> >> However, I have a Cancel button on the EditUser page, and when I press >> that the whole lot fails with a coercion error, this time trying to >> take the name of the page from the Cancel button and pass it as a >> parameter: >> >> (EditUser.tml): >> >> > onclick="location.href='Administration';"/> >> >> >> producing exception: >> >> Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at >> EditUser.java:36), parameter #1: Coercion of Administration to type >> java.lang.Integer (via String --> Long, Long --> Integer) failed: For >> input string: "Administration" >> >> >> What is going on and why does this happen? It's only happening for >> this page which has an onActivate with a parameter. All my other pa
Re: T5: onActivate exception query
I'm not sure but I thinks it's a similar problem. It looks like Administration is interpreted as the context. If you want to cancel the page it's easier to use the t5Component Button component. Add t5Component jar to you project (see http://code.google.com/p/tapestry5-components/) and add this to the .tml: Cancel And add an event handler in your page: protected Object onCancel() { return Administration.class; // The Page to redirect to } Martijn Brinkers On Fri, 2008-08-29 at 12:09 +0100, [EMAIL PROTECTED] wrote: > Thanks for the fast reply Martijn; that fixed the GIF asset. > > However, I am still having problems with the Cancel button. I can > reference the Administration page as an asset, but obviously it then > does not get processed by Tapestry. > > Thoughts, anyone? > > onclick="location.href='Administration';"/> > > > p. > > > Quoting Martijn Brinkers <[EMAIL PROTECTED]>: > > > I think the following happens > > > > The gif is requested by your page because of the IMG so the GET for the > > IMG looks something like > > > > http://YOUR_DOMAIN/YOUR_PAGE/bl_red_hundred.gif > > > > Now you page assumes this is your activation context and tries to > > convert it to int (which it's not). > > > > I think you can solve this by adding an image Asset. Another option I > > think would be to not request the image relative to your page but from > > for example the /images subir (make sure the request if relative with > > respect to you app root and not absolute). > > > > I guess the other problem is related. > > > > Martijn Brinkers > > > > On Fri, 2008-08-29 at 11:23 +0100, [EMAIL PROTECTED] wrote: > >> I don't quite understand why the following does not work and produces: > >> > >> TapestryModule.RequestExceptionHandler Processing of request failed > >> with uncaught exception: Exception in method > >> uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), > >> parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer > >> (via String --> Long, Long --> Integer) failed: For input string: > >> "bl_red_hundred.gif" > >> org.apache.tapestry5.runtime.ComponentEventException: Exception in > >> method uk.bl.dportal.pages.EditUser.onActivate(int) (at > >> EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to > >> type java.lang.Integer (via String --> Long, Long --> Integer) failed: > >> For input string: "bl_red_hundred.gif" > >>at > >> org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1054) > >> ... > >> > >> > >> I have a template which containes a reference to a gif used in the > >> banner (BLTemplate.tml): > >> > >> http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > >> > >> Digital Portal: ${heading} > >> > >> > >> > >> > >> > >> > >>${title} > >> > >> > >> > >> > >> > >> ... > >> > >> > >> This template is used for all my pages (in this case EditUser.tml): > >> > >> >>t:title="literal:Edit User > >> Details" > >> > >> xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > >> > >> Edit user details. > >> ... > >> > >> > >> This page is called from a link produced by the Grid component (in > >> ManageUsers.tml): > >> > >> >> t:exclude="id,password" t:row="listItem"> > >> > >> >> t:context="listItem.id"> > >>${listItem.userName} > >> > >> > >> > >> > >> > >> and EditUser.java has an onActivate with a parameter: > >> > >>public void onActivate(int id) > >>{ > >>Query query = session.createQuery("from User where id = > >> '"+id+"'"); > >>List result = query.list(); > >>user = (User)result.get(0); > >>} > >> > >> > >> Why is the GIF name being passed in initially? The page still works, > >> so the id is being set to that given by the link from ManageUsers.tml. > >> The exception is generated but it continues on to display the page. > >> > >> However, I have a Cancel button on the EditUser page, and when I press > >> that the whole lot fails with a coercion error, this time trying to > >> take the name of the page from the Cancel button and pass it as a > >> parameter: > >> > >> (EditUser.tml): > >> > >> >> onclick="location.href='Administration';"/> > >> > >> > >> producing exception: > >> > >> Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at > >> EditUser.java:36), parameter #1: Coercion of Administration to type > >> java.lang.Integer (via String --> Long, Long --> Integer) failed: For > >> input string: "Administration" > >> > >> > >> What is going on and why does this happen? It's only happening f
Re: [ANN] Tapestry5-Cayenne Integration Module 0.1
> That's really nice... do you think to merge it with apache svn repo in > a near future? > > -- > Massimo > http://meridio.blogspot.com I think it's something we're open to. We've definitely planned for that possibility. The code is ASLv2, all dependencies are ASL-compatible, there have only been two contributors, one of which already has an ICLA on file, code is in Subversion, etc. If there's enough general interest, we can bring it to the PMC for a vote. The module is a nice bridge between two ASF projects, so it'd likely be a good candidate. I just don't want to bloat things or introduce bureaucracy that slows development down. -- Kevin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
howto change/remove a persistence from AjaxFormLoop
hi there, i have a page to edit an entity. this entity contains a list of childs connected via OneToMany. the page contains a component and that component (named ActionsLoop) contains an AjaxFormLoop component for edit/add/delete the child entities. the ActionsLoop component has a parameter: @Parameter(required = true, defaultPrefix = BindingConstants.PROP) private List actionsList; the actionsList elements wrapped into a map object (CollectionFactory.newConcurrentMap()) with an unique ID as map key. (AtomicLong ID_ALLOCATOR = new AtomicLong();) this is my onAddRow event method: Object onAddRow() { CallOnDutyAction action = new CallOnDutyAction(); action.setMapId(ID_ALLOCATOR.incrementAndGet()); actionsMap.put(action.getMapId(), action); return action; } and this is my onRemoveRow event method: void onRemoveRow(CallOnDutyAction item) { actionsMap.remove(item.getMapId()); } and here is my onAfterSubmit void onAfterSubmit() { for (CallOnDutyAction action : actionsMap.values()) { if (action.getId() == 0) actionsList.add(action); } } if i add a child entity, all is fine: after i submit the form, the new child added to child list and saved into the database table. but if i change or remove a child from the AjaxFormLoop nothing is happen with the modfied childs where is my fault ? -- with regards Sven Homburg http://www.chenillekit.org http://tapestry5-components.googlecode.com
Re: [T5]: using a mixin on a form prevents correct submission
some ,ore testing revealed that BeanEditForm works very well with the FormLayoutMixin, but Form does not. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [T5]: using a mixin on a form prevents correct submission
The same happens if I wrap another component around the form. In this example "t5c/ContentBox" is nothing more than a component wrapping a table around it's body and including some CSS. "somePageProperty" will not be updated with the ContentBox component. ... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tapestry group in LinkedIn
I've created a Tapestry group in LinkedIn and everyone is invited to join. :) http://www.linkedin.com/groups?home=&gid=133965 Thiago - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[T5]: using a mixin on a form prevents correct submission
I have a very simple page which uses a form to update one page property and a zone. Sourcecode and template see below. It works as expected, the page property and the zone is updated as intended. But whenever I use a the FormLayoutMixin on the form, "somePageProperty" won't be updated anymore. The mixin doesn't do very much but render some html before and some after the form, so I don't understand this odd behaviour. I tested this with 5.0.14 and 5.0.15-SNAPSHOT on Windows XP with Jetty 6 and FF3. Andy -- * page class * -- public class FormZoneUpdate { @Inject private Block showResult; @Property private String somePageProperty; /**Tapestry form submit event method. Called if validation is successful.*/ @Log public Object onSuccess() { return showResult; } } -- * page template * -- http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> Nothing yet to show. You searched for: ${somePageProperty} -- * mixin class* -- @IncludeStylesheet("css/FormLayoutMixin.css") public class FormLayoutMixin { /** * Der Titel des Formulars */ @Parameter(required=true, allowNull=false, defaultPrefix=BindingConstants.LITERAL) private String layoutMixinTitle; void beginRender(MarkupWriter writer) { writer.writeRaw("t5c-oneColumnStyle\">"); writer.writeRaw(getLayoutMixinTitle()); writer.writeRaw(""); } void afterRender(MarkupWriter writer) { writer.writeRaw(""); } /** * @return the layoutMixinTitle */ public String getLayoutMixinTitle() { return this.layoutMixinTitle; } } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tapestry working with other Servlets
Yup, I from Indonesia. I think u are miss understanding. What I mean is this servlet is extend ApplicationServlet and this servlet want to get session from tapestry page. :) Thank you... Agus Winarno Mohammad Irfan wrote: > > Hi Agus, are you from Indonesia? me too. > > Btw, if you want to use the servlet object in tapestry 4 you can add > this property in the .page file of the page: > > object="service:tapestry.globals.HttpServletRequest"/> > object="service:tapestry.globals.HttpServletResponse"/> > > And in your java page model you could add this abstract method: > > public abstract HttpServletRequest getRequest(); > > public abstract HttpServletResponse getResponse(); > > Hope it helps. > > On Fri, Aug 29, 2008 at 2:28 PM, agus winarno <[EMAIL PROTECTED]> wrote: >> >> Hi, >> Can the servlet get object in session from tapestry 4? >> I try to get it, but can't. Looks like HttpSession in servlet is >> different >> from HttpSession in tapestry4. >> Thanks... >> >> Agus Winarno >> >> >> Norman Franke wrote: >>> >>> Those links are for Tapestry 5. I use multiple servlets in a single >>> application and haven't had a problem with Tapestry 4. I just map the >>> URLs uniquely in the web.xml. >>> >>> Norman Franke >>> Answering Service for Directors, Inc. >>> www.myasd.com >>> >>> On Apr 2, 2008, at 10:06 AM, Imran Amajd wrote: >>> Hello everybody, I m using Tapestry4 with spring & Hibernate. I am having a problem when i call my own java servlet with-in appcalication. The calling servlet sends response correctly but it causes HttpSession termination. i want tapestry to ignore this servlet request and let the container handle this request. The link http://tapestry.apache.org/tapestry5/tapestry-core/guide/ conf.html http://tapestry.apache.org/tapestry5/tapestry-core/guide/conf.html describes about configurig Tapestry. At the end its mentions how we can tell tapestry to ignore certain URLs but it doesnot explain it in depth. Can any body help on how can IgnoredPathsFilter service be used to make it work. if you need to have application web.xml/hivemodule.xml i am happy to provide these. Thanks In Advance buddies. -Imran Amjad -- View this message in context: http://www.nabble.com/Tapestry- working-with-other-Servlets-tp16447065p16447065.html Sent from the Tapestry - User mailing list archive at Nabble.com. >>> >>> >>> >> >> -- >> View this message in context: >> http://www.nabble.com/Tapestry-working-with-other-Servlets-tp16447065p19215057.html >> Sent from the Tapestry - User mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > > -- > Wassalamu'alaikum wr. wb. > Mohammad Irfan > > --- > www.doktermaya.com > www.L-Ads.com (classifieds ads, iklan baris) > www.komplain.org (complain about product) > www.akarprima.com > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Tapestry-working-with-other-Servlets-tp16447065p19218533.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: onActivate exception query
Em Fri, 29 Aug 2008 07:23:48 -0300, <[EMAIL PROTECTED]> escreveu: Something that works wonderfully with any kind of resource (imagens, CSS, etc) is to use the asset prefix: alt="bl" /> It works regardless of where your template is and what URL it has. Thiago - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: onActivate exception query
Thanks for the fast reply Martijn; that fixed the GIF asset. However, I am still having problems with the Cancel button. I can reference the Administration page as an asset, but obviously it then does not get processed by Tapestry. Thoughts, anyone? p. Quoting Martijn Brinkers <[EMAIL PROTECTED]>: I think the following happens The gif is requested by your page because of the IMG so the GET for the IMG looks something like http://YOUR_DOMAIN/YOUR_PAGE/bl_red_hundred.gif Now you page assumes this is your activation context and tries to convert it to int (which it's not). I think you can solve this by adding an image Asset. Another option I think would be to not request the image relative to your page but from for example the /images subir (make sure the request if relative with respect to you app root and not absolute). I guess the other problem is related. Martijn Brinkers On Fri, 2008-08-29 at 11:23 +0100, [EMAIL PROTECTED] wrote: I don't quite understand why the following does not work and produces: TapestryModule.RequestExceptionHandler Processing of request failed with uncaught exception: Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer (via String --> Long, Long --> Integer) failed: For input string: "bl_red_hundred.gif" org.apache.tapestry5.runtime.ComponentEventException: Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer (via String --> Long, Long --> Integer) failed: For input string: "bl_red_hundred.gif" at org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1054) ... I have a template which containes a reference to a gif used in the banner (BLTemplate.tml): http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> Digital Portal: ${heading} ${title} ... This template is used for all my pages (in this case EditUser.tml): http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> Edit user details. ... This page is called from a link produced by the Grid component (in ManageUsers.tml): ${listItem.userName} and EditUser.java has an onActivate with a parameter: public void onActivate(int id) { Query query = session.createQuery("from User where id = '"+id+"'"); List result = query.list(); user = (User)result.get(0); } Why is the GIF name being passed in initially? The page still works, so the id is being set to that given by the link from ManageUsers.tml. The exception is generated but it continues on to display the page. However, I have a Cancel button on the EditUser page, and when I press that the whole lot fails with a coercion error, this time trying to take the name of the page from the Cancel button and pass it as a parameter: (EditUser.tml): producing exception: Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:36), parameter #1: Coercion of Administration to type java.lang.Integer (via String --> Long, Long --> Integer) failed: For input string: "Administration" What is going on and why does this happen? It's only happening for this page which has an onActivate with a parameter. All my other pages work as expected. thanks, p. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Page pool hard limit and page instance usage
Hi, we are experiencing strange hard pool limit reached exceptions. (For the user count that we have.) After debugging a little, it seems that our left menu component, which is full of page links, instantiates not only the page that we are at, but also the ones that are referenced in page link. This can be seen also in that exception page is shown, if one of the pages that are referenced in page links have an error. Is this correct behavior? And should we really use common a href= tags to avoid this? Further more, is it possible to create infinite loop, when page a has page link to page b, which has page link to page a? - 99 -- View this message in context: http://www.nabble.com/Page-pool-hard-limit-and-page-instance-usage-tp19217773p19217773.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: onActivate exception query
I think the following happens The gif is requested by your page because of the IMG so the GET for the IMG looks something like http://YOUR_DOMAIN/YOUR_PAGE/bl_red_hundred.gif Now you page assumes this is your activation context and tries to convert it to int (which it's not). I think you can solve this by adding an image Asset. Another option I think would be to not request the image relative to your page but from for example the /images subir (make sure the request if relative with respect to you app root and not absolute). I guess the other problem is related. Martijn Brinkers On Fri, 2008-08-29 at 11:23 +0100, [EMAIL PROTECTED] wrote: > I don't quite understand why the following does not work and produces: > > TapestryModule.RequestExceptionHandler Processing of request failed > with uncaught exception: Exception in method > uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), > parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer > (via String --> Long, Long --> Integer) failed: For input string: > "bl_red_hundred.gif" > org.apache.tapestry5.runtime.ComponentEventException: Exception in > method uk.bl.dportal.pages.EditUser.onActivate(int) (at > EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to > type java.lang.Integer (via String --> Long, Long --> Integer) failed: > For input string: "bl_red_hundred.gif" > at > org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1054) > ... > > > I have a template which containes a reference to a gif used in the > banner (BLTemplate.tml): > > http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > > Digital Portal: ${heading} > > > > > > > ${title} > > > > > > ... > > > This template is used for all my pages (in this case EditUser.tml): > >t:title="literal:Edit User > Details" > > xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > > Edit user details. > ... > > > This page is called from a link produced by the Grid component (in > ManageUsers.tml): > >t:exclude="id,password" t:row="listItem"> > >t:context="listItem.id"> > ${listItem.userName} > > > > > > and EditUser.java has an onActivate with a parameter: > > public void onActivate(int id) > { > Query query = session.createQuery("from User where id = > '"+id+"'"); > List result = query.list(); > user = (User)result.get(0); > } > > > Why is the GIF name being passed in initially? The page still works, > so the id is being set to that given by the link from ManageUsers.tml. > The exception is generated but it continues on to display the page. > > However, I have a Cancel button on the EditUser page, and when I press > that the whole lot fails with a coercion error, this time trying to > take the name of the page from the Cancel button and pass it as a > parameter: > > (EditUser.tml): > > onclick="location.href='Administration';"/> > > > producing exception: > > Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at > EditUser.java:36), parameter #1: Coercion of Administration to type > java.lang.Integer (via String --> Long, Long --> Integer) failed: For > input string: "Administration" > > > What is going on and why does this happen? It's only happening for > this page which has an onActivate with a parameter. All my other pages > work as expected. > > thanks, > p. > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
T5: onActivate exception query
I don't quite understand why the following does not work and produces: TapestryModule.RequestExceptionHandler Processing of request failed with uncaught exception: Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer (via String --> Long, Long --> Integer) failed: For input string: "bl_red_hundred.gif" org.apache.tapestry5.runtime.ComponentEventException: Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:40), parameter #1: Coercion of bl_red_hundred.gif to type java.lang.Integer (via String --> Long, Long --> Integer) failed: For input string: "bl_red_hundred.gif" at org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1054) ... I have a template which containes a reference to a gif used in the banner (BLTemplate.tml): http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> Digital Portal: ${heading} ${title} ... This template is used for all my pages (in this case EditUser.tml): http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> Edit user details. ... This page is called from a link produced by the Grid component (in ManageUsers.tml): t:exclude="id,password" t:row="listItem"> ${listItem.userName} and EditUser.java has an onActivate with a parameter: public void onActivate(int id) { Query query = session.createQuery("from User where id = '"+id+"'"); List result = query.list(); user = (User)result.get(0); } Why is the GIF name being passed in initially? The page still works, so the id is being set to that given by the link from ManageUsers.tml. The exception is generated but it continues on to display the page. However, I have a Cancel button on the EditUser page, and when I press that the whole lot fails with a coercion error, this time trying to take the name of the page from the Cancel button and pass it as a parameter: (EditUser.tml): onclick="location.href='Administration';"/> producing exception: Exception in method uk.bl.dportal.pages.EditUser.onActivate(int) (at EditUser.java:36), parameter #1: Coercion of Administration to type java.lang.Integer (via String --> Long, Long --> Integer) failed: For input string: "Administration" What is going on and why does this happen? It's only happening for this page which has an onActivate with a parameter. All my other pages work as expected. thanks, p. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[RESOLVED] Re: T5.0.14 - OnActivate problem and coercion error
I resolve the problem !!! But, in my case, it is not a classic problem ! Because my problem come from javascript code : In an onload fonction, I found this code : // http://slayeroffice.com/code/imageCrossFade/xfade2.css //css = d.createElement("link"); //css.setAttribute("href","xfade2.css"); //css.setAttribute("rel","stylesheet"); //css.setAttribute("type","text/css"); //d.getElementsByTagName("head")[0].appendChild(css); So my java code was OK, my application work but I have some exceptions trace. I remove the javascript code and now it's OK Thanks Szemere Szemere a écrit : This is a classic problem. The path to your assets is shifted by one level because of the parameter you are passing. Not sure of the fix for your specific case, but if you referenced an asset like this in a .tml, you would use href="${asset:context:org/atlog/mjweb/components/xfade2.css}" HTH, Szemere --- Antivirus avast! : message Sortant sain. Base de donnees virale (VPS) : 080828-0, 28/08/2008 Analyse le : 29/08/2008 12:17:04 avast! - copyright (c) 1988-2008 ALWIL Software. http://www.avast.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5.0.14 - OnActivate problem and coercion error
This is a classic problem. The path to your assets is shifted by one level because of the parameter you are passing. Not sure of the fix for your specific case, but if you referenced an asset like this in a .tml, you would use href="${asset:context:org/atlog/mjweb/components/xfade2.css}" HTH, Szemere
Re: [ANN] Tapestry5-Cayenne Integration Module 0.1
On Thu, Aug 28, 2008 at 6:53 PM, Kevin Menard <[EMAIL PROTECTED]> wrote: > Hi all, > > I'd like to announce the first release of a Tapestry5-Cayenne > integration module that Robert Zeigler and I have been working on. > The goal of this module is to provide seemless integration of the > Cayenne ORM with your Tapestry5 web apps. It's very similar in nature > to the Hibernate module. > > The release is alpha, but we've been using it on some production apps > with good success. A short list of current features: > > - ObjectContext creation and binding to Application State Object for > easy context retrieval > - Injectable ObjectContext (with on-demand creation) for sessionless > applications > - ValueEncoder for all Persistent objects > - BeanModelSource implementation to hide Cayenne's "non-editable" fields > - Pluggable ID encoding strategies for URL generation in order to > prevent data tampering > - Editors and viewers for Persistent objects, allowing Persistent > objects to be used in BeanEditor and BeanDisplay with no effort > - Rich components and supporting services for making working with > Persistent objects as simple as possible > > The project is ASLv2 licensed and assemblies are provided as packed > JARs or via maven2. > > Documentation: http://t5cayenne.saiwai-solutions.com/ > Code & downloads: http://code.google.com/p/tapestry5-cayenne/ That's really nice... do you think to merge it with apache svn repo in a near future? -- Massimo http://meridio.blogspot.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Event handlers with multiple parameters
Thanks for the reply Thiago, I missed EventContext in the docs. Looks to me like using EventContext to parse the context params myself is the best solution here. Unless anyone can suggest a better way? Thanks, Andy > -Original Message- > From: Thiago H. de Paula Figueiredo [mailto:[EMAIL PROTECTED] > Sent: 28 August 2008 20:33 > To: Tapestry users > Subject: Re: Event handlers with multiple parameters > > Em Thu, 28 Aug 2008 08:21:50 -0300, Blower, Andy > <[EMAIL PROTECTED]> escreveu: > > > mark(boolean checked, String[] itemIds) > > > > mark(boolean checked, String... itemIds) > > > > mark(boolean checked, List itemIds) > > As far as I know, none of the would work because Tapestry would not > handle > an event handler method with one one String[] or List parameter AND > other > parameters. It handles String[], List and EventContext, each one as the > single parameter, for that matter. > > Thiago > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 5.0.15-SNAPSHOT: something wrong with it?
You are right. The 5.0.14 jars were pulled in by a component library. After fixing this, everything works fine. Thanks for the suggestion. Howard Lewis Ship schrieb: Odd, I can't think of a change that would account for that kind of instability. There's no chance that both 5.0.14 and 5.0.15-SNAPSHOT jars were on the classpath? On Thu, Aug 28, 2008 at 3:18 AM, Andy Pahne <[EMAIL PROTECTED]> wrote: After having upgraded to 5.0.15-SNAPSHOT our existing application crashes with OutOfMemory Exceptions (heap) space occassionally. It happens sometimes when I view a page containing a simple form and submitting it once in a while. I think it happens more often when class reloading is involved. Switching back to 5.0.14 resolves this problem totally. Does anybody else experience this? Andy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tapestry working with other Servlets
Hi Agus, are you from Indonesia? me too. Btw, if you want to use the servlet object in tapestry 4 you can add this property in the .page file of the page: And in your java page model you could add this abstract method: public abstract HttpServletRequest getRequest(); public abstract HttpServletResponse getResponse(); Hope it helps. On Fri, Aug 29, 2008 at 2:28 PM, agus winarno <[EMAIL PROTECTED]> wrote: > > Hi, > Can the servlet get object in session from tapestry 4? > I try to get it, but can't. Looks like HttpSession in servlet is different > from HttpSession in tapestry4. > Thanks... > > Agus Winarno > > > Norman Franke wrote: >> >> Those links are for Tapestry 5. I use multiple servlets in a single >> application and haven't had a problem with Tapestry 4. I just map the >> URLs uniquely in the web.xml. >> >> Norman Franke >> Answering Service for Directors, Inc. >> www.myasd.com >> >> On Apr 2, 2008, at 10:06 AM, Imran Amajd wrote: >> >>> >>> Hello everybody, >>> >>> I m using Tapestry4 with spring & Hibernate. I am having a problem >>> when i >>> call my own java servlet with-in appcalication. The calling servlet >>> sends >>> response correctly but it causes HttpSession termination. i want >>> tapestry to >>> ignore this servlet request and let the container handle this request. >>> >>> The link http://tapestry.apache.org/tapestry5/tapestry-core/guide/ >>> conf.html >>> http://tapestry.apache.org/tapestry5/tapestry-core/guide/conf.html >>> >>> describes about configurig Tapestry. At the end its mentions how we >>> can tell >>> tapestry to ignore certain URLs but it doesnot explain it in depth. >>> >>> Can any body help on how can IgnoredPathsFilter service be used to >>> make it >>> work. if you need to have application web.xml/hivemodule.xml i am >>> happy to >>> provide these. >>> >>> Thanks In Advance buddies. >>> >>> -Imran Amjad >>> >>> >>> >>> >>> -- >>> View this message in context: http://www.nabble.com/Tapestry- >>> working-with-other-Servlets-tp16447065p16447065.html >>> Sent from the Tapestry - User mailing list archive at Nabble.com. >> >> >> > > -- > View this message in context: > http://www.nabble.com/Tapestry-working-with-other-Servlets-tp16447065p19215057.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Wassalamu'alaikum wr. wb. Mohammad Irfan --- www.doktermaya.com www.L-Ads.com (classifieds ads, iklan baris) www.komplain.org (complain about product) www.akarprima.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tapestry working with other Servlets
Hi, Can the servlet get object in session from tapestry 4? I try to get it, but can't. Looks like HttpSession in servlet is different from HttpSession in tapestry4. Thanks... Agus Winarno Norman Franke wrote: > > Those links are for Tapestry 5. I use multiple servlets in a single > application and haven't had a problem with Tapestry 4. I just map the > URLs uniquely in the web.xml. > > Norman Franke > Answering Service for Directors, Inc. > www.myasd.com > > On Apr 2, 2008, at 10:06 AM, Imran Amajd wrote: > >> >> Hello everybody, >> >> I m using Tapestry4 with spring & Hibernate. I am having a problem >> when i >> call my own java servlet with-in appcalication. The calling servlet >> sends >> response correctly but it causes HttpSession termination. i want >> tapestry to >> ignore this servlet request and let the container handle this request. >> >> The link http://tapestry.apache.org/tapestry5/tapestry-core/guide/ >> conf.html >> http://tapestry.apache.org/tapestry5/tapestry-core/guide/conf.html >> >> describes about configurig Tapestry. At the end its mentions how we >> can tell >> tapestry to ignore certain URLs but it doesnot explain it in depth. >> >> Can any body help on how can IgnoredPathsFilter service be used to >> make it >> work. if you need to have application web.xml/hivemodule.xml i am >> happy to >> provide these. >> >> Thanks In Advance buddies. >> >> -Imran Amjad >> >> >> >> >> -- >> View this message in context: http://www.nabble.com/Tapestry- >> working-with-other-Servlets-tp16447065p16447065.html >> Sent from the Tapestry - User mailing list archive at Nabble.com. > > > -- View this message in context: http://www.nabble.com/Tapestry-working-with-other-Servlets-tp16447065p19215057.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
T5: Remove "value" parameter on Select component
Hi! I'm creating a mixin that hooks on to the onchange event of a Select and AJAX-submits the value. Other types of Select-boxes that has an onchange event without having an interesting value to submit is a common pattern in my application. For example a select that opens a popup window. I've seen a couple of relevant Mixin-examples on the Wiki, in the Autocomplete mixin, and other places and they all use the same approach where a GET-parameter is added to the Ajax.Request and read as request.getParameter() in the Mixin class. Obviously there is no need for the value-binding of the Select here because this value is never set and never read. Right now I'm using a "Hijax" approach, where there's a chance the user won't be getting the AJAX-functionality, but rather the original onchange event that refreshes the page. In that case I will need to bind a page property to the value parameter. But if there's no alternative to AJAX that makes sense, I still have to put a dummy property in my form to bind to the value parameter of the Select. Is there any way to avoid that without writing my own copy of the select component? Regards Inge
Re: T4.1 Property Selection component
On my POJO model, the equals method is like this: public boolean equals(Object obj) { if (this == obj) return true; // if (!super.equals(obj)) // return false; if (getClass() != obj.getClass()) return false; ReportType other = (ReportType) obj; if (code == null) { if (other.code != null) return false; } else if (!code.equals(other.code)) return false; if (name == null) { if (other.name != null) return false; } else if (!name.equals(other.name)) return false; if (reportTemplates == null) { if (other.reportTemplates != null) return false; } else if (!reportTemplates.equals(other.reportTemplates)) return false; return true; } It is generated from eclipse. And for the PropertySelectionModel the code is like this: public class ReportTypeSelectionModel implements IPropertySelectionModel, Serializable { private static final long serialVersionUID = 1823541941745724736L; private List rtList; public ReportTypeSelectionModel(List reptypList) { this.rtList = reptypList; } public String getLabel(int index) { return rtList.get(index).getCode(); } public Object getOption(int index) { return rtList.get(index); } public int getOptionCount() { return rtList.size(); } public String getValue(int index) { return Integer.toString(index); } public boolean isDisabled(int index) { // TODO Auto-generated method stub return false; } public Object translateValue(String value) { return getOption(Integer.parseInt(value)); } } Do the PropertySelectionModel will select the value which it set using setMyValue(theValue) on the page class? On Fri, Aug 29, 2008 at 11:32 AM, Andreas Andreou <[EMAIL PROTECTED]> wrote: > is equals() implemented accordingly for your domain object? > > On Fri, Aug 29, 2008 at 7:09 AM, Mohammad Irfan <[EMAIL PROTECTED]> wrote: >> Hi, getting the selected object from the list is not a problem. The >> problem is if I want to edit an object where it has a property >> selection on it's form, I want to set it according to the object's >> value. >> >> The code: >> > model="ognl:myValues" /> >> >> I have a setter and geter for both model and value object: >> >> public abstract Value getMyValue(); >> public abstract void setMyValue(Value val); >> >> public abstract IPropertySelectionModel getMyValues(){ >> ... >> } >> >> and on the page begin render, I have set the default value if I'm >> editting the object: >> >> public void pageBeginRender(PageEvent event) { >> . >> setMyValue( getObject().getValue() ); >> } >> >> But, nothing is happened. The list is always selecting the first >> value, not the object's value that I want. >> >> Thanks. >> >> On Wed, Aug 27, 2008 at 10:06 PM, Norman Franke <[EMAIL PROTECTED]> wrote: >>> This is handled automatically based on the "value" parameter for the >>> tapestry object. >>> >>> >> model="ognl:myValues" /> >>> >>> You can use an existing model, or implement IPropertySelectionModel which >>> Tapestry uses to translate values and the like. >>> >>> Norman Franke >>> Answering Service for Directors, Inc. >>> www.myasd.com >>> >>> On Aug 27, 2008, at 5:54 AM, Mohammad Irfan wrote: >>> Hi, I have success in using Property selection component but I found a problem. I'd like to ask, how can I set a selected value for the Selection list? So I can have this html output: CSV DBF DELIM TXT XLS Thanks. -- Mohammad Irfan --- www.doktermaya.com www.L-Ads.com (classifieds ads, iklan baris) www.komplain.org (complain about product) www.akarprima.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >> >> >> >> -- >> Wassalamu'alaikum wr. wb. >> Mohammad Irfan >> >> --- >> www.doktermaya.com >> www.L-Ads.com (classifieds ads, iklan baris) >> www.komplain.org (complain about product) >> www.akarprima.com >> >> - >> To
Re: T5 : Spring 2.5 support w/ tapestry-spring ?
Yes I am using Spring 2.5 with the Tapestry Spring module Martijn Brinkers On Fri, 2008-08-29 at 03:15 -0400, Alex Kotchnev wrote: > Is anyone successfully using spring 2.5 w/ the tapestry-spring module ? The > module main page talks about it being tested against 1.2.8. > > Cheers, > > Alex K - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
T5 : Spring 2.5 support w/ tapestry-spring ?
Is anyone successfully using spring 2.5 w/ the tapestry-spring module ? The module main page talks about it being tested against 1.2.8. Cheers, Alex K