Re: T5: Grid component, reorder and empty source

2007-11-16 Thread Arve Klev
hi, as a novice in regards to Tapestry, I first thought it was a bug, but at last I tried to supply a beanmodel, and everything is fine (obvious to others, I think). I found the tip here: http://tapestry.apache.org/tapestry5/tapestry-core/guide/beaneditform.html. table t:type=grid

Re: T5: Grid component, reorder and empty source

2007-11-16 Thread Arve Klev
yes, it works fine. 2007/11/16, Joshua Jackson [EMAIL PROTECTED]: On 11/16/07, Arve Klev [EMAIL PROTECTED] wrote: hi, as a novice in regards to Tapestry, I first thought it was a bug, but at last I tried to supply a beanmodel, and everything is fine (obvious to others, I think). I

Re: T5.0.6 about Tapestry ioc

2007-11-16 Thread Chris Lewis
I'm not sure I understand the constructor parameters. Do you mean they come from some other object (HttpRequest)? If so, why not just take HttpRequest as a constructor argument? If you do that then you can auto bind this service and IoC will know how to create it. If you insist on the

Re: T4.1.3 without ajax

2007-11-16 Thread Andreas Andreou
add ajaxDelegate=ognl:null to the Shell component... I believe that it is still possible that Tapestry adds a dojo import script in some cases (related to the @Form component) but you can't get away from this... unless you can go with 4.1.4.-SNAPSHOT that has some improvements on that area On

Re: T5 Newbie : populate the value of a form in a bean

2007-11-16 Thread Michael Courcy
In my case I think I was running in confusion, the MyObject was already initialized from a previous page and injected in the page that hold the form. Thus initialising it from onPrepareFromForm or setupRender is useless in this particular case. Things are working fine now, I really don't see

Re: Problem with 5.0.7-SNAPSHOT

2007-11-16 Thread Howard Lewis Ship
I know that's code I've changed recently. The change affected both tapestry-ioc and tapestry-core, please check that you have current and only current versions of both of those. On Nov 16, 2007 7:50 AM, Alexander Lamb [EMAIL PROTECTED] wrote: Hello, It looks like since today (yesterday it was

Re: T5.0.6 about Tapestry ioc

2007-11-16 Thread Howard Lewis Ship
It's roughly this: @Scope(perthread) public Transport buildHttpTransport(HttpServletRequest request) { return new HttpTransport(request.getAddress(), request.getPort(), request.isSecure()); } Actually, you can't directly inject HttpServletRequest (you can inject Tapestry's Request, and its

Re: T5.0.6 about Tapestry ioc

2007-11-16 Thread Chris Lewis
You can do what you want, and should do whatever seems sensible for your needs. What I'm getting at is that T5 IoC can transparently handle creating services with constructor arguments, if those arguments are of types known to the container. String won't work, and I honestly don't know what

Re: T5.0.6 about Tapestry ioc

2007-11-16 Thread lasitha
On Nov 16, 2007 6:36 PM, lyifan [EMAIL PROTECTED] wrote: for an instance, if address, port, ssl are saved in a config file, I have to pass a ConfigFile object as the parameter of the HttpTransport constructor. Are you just looking for a way to configure an HttpTransport instance with

Re: [T5.0.6] Is coercion MANDATORY for custom parameter classes? [BUG?]

2007-11-16 Thread Vjeran Marcinko
- Original Message - From: César Lesc [EMAIL PROTECTED] To: Tapestry users users@tapestry.apache.org Sent: Friday, November 16, 2007 5:57 PM Subject: Re: [T5.0.6] Is coercion MANDATORY for custom parameter classes? You don't have to create a coercion for you custom class, how do you

[T4] about cookie and page cycle

2007-11-16 Thread #Cyrille37#
Hello, I've found howto set a cookie. I come to you to know more about why setting the cookie in renderPage() works, but not in beginPageRender() ?? Thanks Cyrille = I put my little code here, to archive it in Internet ;-) public abstract class Home extends BasePage {

T5: why is a coorcion needed from subclass to abstract superclass?

2007-11-16 Thread Britske
just curious: why is it needed to make a cooercion from a page subclass to an abstract superclass? Isn't the cast already implictly defined by the 'super-sub relation'? Geert-Jan -- View this message in context:

Re: T5: Customize Grid

2007-11-16 Thread Joshua Jackson
Thanks. It worked. :) On 11/16/07, Angelo Chen [EMAIL PROTECTED] wrote: not beanmodel but mode=department then in the code: void pageLoaded() { model = beanModelSource.create(Department.class, false, resources); model.remove(id); // remove ones not visible

Re: T4.1.3 Form submission

2007-11-16 Thread Nikolaos Konstantinou
So, the java page is public abstract class RegistrationPage extends BasePage implements IExternalPage, PageBeginRenderListener { public abstract IRoomQuote getRoomQuote(); public abstract void setRoomQuote(IRoomQuote roomQuote); ... public void pageBeginRender(PageEvent event) {

T5: testing T5

2007-11-16 Thread Chris Lewis
I've started working on testing my components using the PageTester, partially based on the site docs and partially on the T5 source. I have a test method as follows, which mirrors how the FormTest in T5 works: @Test public void testEffects() { String appPackage =

Re: [T5.0.6] Is coercion MANDATORY for custom parameter classes?

2007-11-16 Thread César Lesc
You don't have to create a coercion for you custom class, how do you declare the binding in the template?. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

T5.0.6 about Tapestry ioc

2007-11-16 Thread lyifan
I want to implement a service: public interface Transport { public void send(); } public class HttpTransport implement Transport { private String _address; private int _port; private boolean _ssl; public HttpTransport (String address, int port,

Re: [T5.0.6] Is coercion MANDATORY for custom parameter classes? [BUG?]

2007-11-16 Thread César Lesc
That's weird, i do the same but in a component template, and have no problems I have a MenuItem that will render for certains users but not for others. then my layout template define the menuItems as follow ... li t:type=MenuItem user=user ... the MenuItem component define the user

Re: T5: Grid component, reorder and empty source

2007-11-16 Thread Joshua Jackson
On 11/16/07, Arve Klev [EMAIL PROTECTED] wrote: hi, as a novice in regards to Tapestry, I first thought it was a bug, but at last I tried to supply a beanmodel, and everything is fine (obvious to others, I think). I found the tip here:

T4.1.3 Form submission

2007-11-16 Thread nkonstantinou
Hi all, I'm facing this problem with T4.1.3. I have a page with a Form and I want to submit a value of the roomQuote object to the next page. The problem is that the page is reloading itself when the form is submitted having as a result to lose the object's (roomQuote) value. More specifically, I

T5: how to let subclass decide which component to render

2007-11-16 Thread Britske
I've got a page-class hierachy which all use component BaseLayout as their layout. This BaseLayout-component contains a component called QuickForm. Each page-class must render a QuickForm-component but the implementation may differ (so there is more than 1 actual QuickForm-component. I

T5: expression language

2007-11-16 Thread Chris Lewis
There's been a lot of interest in and expanded version of the T5 expression language. I know T4 was equipped with ognl and people seem to have liked that very much. I could very well be off base here, and there may be a good reason for having chosen ognl before - but I'm curious - if what is

T4.1.3 without ajax

2007-11-16 Thread 9902468
Hi, I've used tapestry with ajax and it works well, but the current project is not using ajax, or anything related to javascript. What is the right way to do this? After disabling ajax etc. from shell, I still see that dojo javascripts are included in the head, AND dojo still registers forms

Re: T5.0.6 about Tapestry ioc

2007-11-16 Thread lyifan
Hi Chris, Do you mean that any constructor parameters can be replaced by an object that provides those parameters? for an instance, if address, port, ssl are saved in a config file, I have to pass a ConfigFile object as the parameter of the HttpTransport constructor. Am I right? thank you

Re: [T5.0.6] Is coercion MANDATORY for custom parameter classes?

2007-11-16 Thread Vjeran Marcinko
Yes, I kept my parameter class inside same package as component, since it is only sensible place to keep it. It feels a bit stupid to have ImageMessage and ImageMessageModel in separate packages. So, its classloader issue then because of mandatory type of packaging. Hope this will change

Re: T5: expression language

2007-11-16 Thread Davor Hrg
ognl can be easily added as a binding prefix, however expect some features to not work because tapestry in some occasions needs to know in advance type that the expression will return (and this is statically, when bindings are prepared) I think I saw that ognl has methods that calculate return

Re: T5: testing T5

2007-11-16 Thread Chris Lewis
Ok I retract part of that. I see this output in mvn test now: --- T E S T S --- Running net.godcode.t5c.integration.pagelevel.rendering.pages.TestSlideShow Tests run: 0, Failures: 0, Errors:

Re: T5: Grid component, reorder and empty source

2007-11-16 Thread Marcus
Hi Arve, We're using an if to display grid only when it has data. Like this: test.java: ... On Nov 16, 2007 2:40 PM, adamh [EMAIL PROTECTED] wrote: Hi Arve, Yep, I got it to work as well - I should have been a bit more persistent with my searching, still its little 'should be simple'

Re: T4.1.3 Form submission

2007-11-16 Thread Alejandro Scandroli
Hi Nikolaos At first sight it looks like roomQuote is not persisted. Try @Persist public abstract IRoomQuote getRoomQuote(); or property name=roomQuote persist=session/ Alejandro. On Nov 16, 2007 2:11 PM, Nikolaos Konstantinou [EMAIL PROTECTED] wrote: So, the java page is public abstract

Re: T5: Grid component, reorder and empty source

2007-11-16 Thread adamh
Hi Arve, Yep, I got it to work as well - I should have been a bit more persistent with my searching, still its little 'should be simple' things like this that can trip you up if you are new to the T5 way. Its just a question of the docs getting updated, I thought I saw talk of a grid

Re: Problem with 5.0.7-SNAPSHOT

2007-11-16 Thread Sven Homburg
sometimes, after updating from repository, i must remove the target/classes directory manualy from modules before compiling the library sources best regards homburg Softwaretechnik S.Homburg Seevetal / GERMANY Alexander Lamb schrieb: Hello, It looks like since today (yesterday it was ok

[T5.0.6] Is coercion MANDATORY for custom parameter classes?

2007-11-16 Thread Vjeran Marcinko
Hello. Still getting acquainted with T5, and I created my first component called ImageMessage that accepts my custom ImageMessageModel parameter: public class ImageMessage { @Parameter(required = true) private ImageMessageModel model; } And when I bound my ImageMessageModel

Re: T4.1.3 Form submission

2007-11-16 Thread Andreas Andreou
Well, it's not persisted, but it's supposed to be passed on through the hidden field But i dont see how roomQuote is initially set... So, it looks like it's always null - and of course remains null BTW, replace onchange=javascript:this.form.submit(); with onchange=tapestry.form.submit(this.form)

Re: T5: Grid component, reorder and empty source

2007-11-16 Thread Marcus
Hi Arve, We're using an if, to display grid only when it has data. Like this: Test.java: ... public boolean getHasDataToGrid1() { return (_listGrd1.size() 0); } ... Test.tml ... t:if test=hasDataToGrid1 table t:type=grid ... Marcus

Re: [T5.0.6] Is coercion MANDATORY for custom parameter classes?

2007-11-16 Thread Davor Hrg
you must move any class that is not page or componenta from base, components, pages packages they get enhanced and those exceptions occur http://wiki.apache.org/tapestry/Tapestry5HowToNotMakeCustomComponent Davor Hrg On Nov 16, 2007 5:57 PM, César Lesc [EMAIL PROTECTED] wrote: You don't have

Re: T5: expression language

2007-11-16 Thread Davor Hrg
of course, youll need the dependancy in your pom: dependency groupIdognl/groupId artifactIdognl/artifactId version2.6.9/version /dependency On Nov 16, 2007 8:42 PM, Davor Hrg [EMAIL PROTECTED] wrote: ognl can be easily added as a binding prefix, however expect

Re: T4.1.3 Form submission

2007-11-16 Thread Andreas Andreou
Well, you must be doing something wrong... is it possible to show some code? On Nov 16, 2007 2:38 PM, nkonstantinou [EMAIL PROTECTED] wrote: Hi all, I'm facing this problem with T4.1.3. I have a page with a Form and I want to submit a value of the roomQuote object to the next page. The

Re: T5: expression language

2007-11-16 Thread Davor Hrg
thanks, I've played with it only a bit... It was that time that MVEL was said to be much faster than OGNL and very long flame on serverside. I've just wanted try both, and made a small project that adds both binding prefixes.. (I was not testing speeds .. just integration...) after playing with

[T5] Cannot persist field exception

2007-11-16 Thread Jean-Philippe Steinmetz
Hi All, I'm getting the following error Error persisting field Users/Create:username: java.lang.NullPointerException In my page class I have... @Persist private String username; public String getUsername() { return username; } public void setUsername(String username) { this.username =

Re: T5: expression language

2007-11-16 Thread Jesse Kuhnert
You can know the type in advance by calling OgnlContext.getCurrentType() after evaluating an expression (or getPreviousType() / getFirstType() / the type and accessor types are all pushed on to a stack now).. It also supports generics / enums / varargs / etc now.. On Nov 16, 2007 2:42 PM, Davor

OGNL Expression evaluated 4 times on tap 4.1.2 release

2007-11-16 Thread carlos f
Tap 4.1.2 release tapestry-test 5.0.5 selenium 0.8.1 (with Jetty baked into Jar) win xp pro sp/2 java 1.5.0_05 This occurs when i am executing tests as part of my selenium integration tests. I have not looked into how this behaves in a more typical deployment environment. As far as I can tell

Re: T5: expression language

2007-11-16 Thread Jesse Kuhnert
Oh wellit wouldn't hurt my feelings if anyone used MVEL. I'm only as loyal to the best technology and hope everyone else would be too. On Nov 16, 2007 4:35 PM, Davor Hrg [EMAIL PROTECTED] wrote: thanks, I've played with it only a bit... It was that time that MVEL was said to be much

Re: Problem with 5.0.7-SNAPSHOT

2007-11-16 Thread Kalle Korhonen
mvn clean doesn't work for you? Kalle On 11/16/07, Sven Homburg [EMAIL PROTECTED] wrote: sometimes, after updating from repository, i must remove the target/classes directory manualy from modules before compiling the library sources best regards homburg Softwaretechnik S.Homburg

How to make a basic crud : Feedback wanted

2007-11-16 Thread Michael Courcy
http://wiki.apache.org/tapestry/Tapestry5How_to_make_a_basic_crud -- Michael Courcy http://courcy.blogspot.com

T5: Decorating A Service In a Sub Module

2007-11-16 Thread David Kendall
I am working on a sizable application where I am trying to decorate the PageRenderRequestHandler service. I have two modules - a Main Module and a Sub Module. The Sub Module is loaded using the @SubModule annotation on the Main Module. Both modules are trying to decorate the

Re: How to make a basic crud : Feedback wanted

2007-11-16 Thread Vjeran Marcinko
Hi. Although your example is very simple in code as such, it suffers from some drawbacks, mainly because you don't have activation context for Save page. 1. Your create and edit actions on Start page use ActionLinks which make 2 HTTP requests (action + render Save page), whereas PageLinks

Re: Feedback wanted on IoC documentation

2007-11-16 Thread Patrick Moore
Hi Howard -- I appreciate the work you are doing on T5 and look forward to moving to it when it is further along. I just want to comment on the only-constructor injection policy that you are promoting. And the fact that the two paragraphs are contradictory. In the first you acknowledge that

Re: T5: Grid component, reorder and empty source

2007-11-16 Thread Arve Klev
Hi Marcus, Thanks, thats easier. Arve 2007/11/16, Marcus [EMAIL PROTECTED]: Hi Arve, We're using an if, to display grid only when it has data. Like this: Test.java: ... public boolean getHasDataToGrid1() { return (_listGrd1.size() 0); } ... Test.tml ... t:if test=hasDataToGrid1