How to inject string to javascript in template

2011-04-08 Thread Anton Mezerny
Hi, I need to implement component based on javascript library. To make this component reusable I have to inject some string values inside the

Re: How to render label for dynamically rendered radiogroup?

2010-12-12 Thread Anton Mezerny
requently. I think you only need to change > the way you specify the label. > Here's an example from my code: > > > > > > > > > > > On Sun, Dec 12, 2010 at 8:18 AM, Anton Mezerny >wrote: > &g

Re: How to render label for dynamically rendered radiogroup?

2010-12-12 Thread Anton Mezerny
Maybe I can write another component called for example RadioField and construct it with Radio and Label components as aggregation fields. Is there any other approach? 2010/12/12 Anton Mezerny > Hi all, > I'm trying to render dynamic RadioGroup like here: > >> > >

How to render label for dynamically rendered radiogroup?

2010-12-12 Thread Anton Mezerny
Hi all, I'm trying to render dynamic RadioGroup like here: > value="value" > label="prop:context.availableLabel" > encoder="valueEncoderForFeature" > validate="prop:selectValidator"> > >

Re: How to cast object to some type

2010-12-12 Thread Anton Mezerny
Thank you, Thiago 2010/12/12 Thiago H. de Paula Figueiredo > On Sun, 12 Dec 2010 07:55:04 -0200, Anton Mezerny > wrote: > > Hi all, >> > > Hi! > > > I'am trying to call some methods like here: >> ${element.contents.name} >> >>>

How to cast object to some type

2010-12-12 Thread Anton Mezerny
Hi all, I'am trying to call some methods like here: ${element.contents.name} > Where 'contents' is represented as Object, but in my component I know exact type of this field. When I try to render name field I get exception. One possible solution is to write a public method in my component which ma

Re: Some questions about Tapestry components source code

2010-11-08 Thread Anton Mezerny
responds to my actual fields. Is there any ability to use normal debug in Tapestry, maybe some configuration parameter? 2010/11/7 Thiago H. de Paula Figueiredo > On Sun, 07 Nov 2010 16:29:15 -0200, Anton Mezerny > wrote: > > Hi all, >> > > Hi! > > > I&

Some questions about Tapestry components source code

2010-11-07 Thread Anton Mezerny
Hi all, I've spent some time diving into the tapestry's sources (particulary BeanEditor and all code which is linked to it). I use Tapestry 5.2.2. I found some interesting things, that I can't explain: 1)in PropertyEditor.java there is some code, but it is not used anywhere (I did't find any usage

Re: Objects session persistance and validation

2010-10-28 Thread Anton Mezerny
()) != null) { registerForm.recordError(messages.get("error.user.already.exists")); } if (customerService.getCustomerByBusinessName(customer.getBusinessName()) != null) { registerForm.recordError(messages.get("error.customer.already.exists")); } } An

Re: Objects session persistance and validation

2010-10-25 Thread Anton Mezerny
you > can start fresh when the page is submitted. > > The required,email and email,required things sounds odd. I'm going to see > if > I can reproduce that. What version of tapestry are you using? > > Mark > > On Mon, Oct 25, 2010 at 2:17 PM, Anton Mezerny >wr

Re: tynamo-security (shiro) exception

2010-10-25 Thread Anton Mezerny
Checked out Tynamo 0.3.0-Snapshot and exception is gone. Thank you. 2010/10/25 Katia Aresti > Its normal, you have to checkout Tynamo branch ;) > > > 2010/10/25 Anton Mezerny > > > Checked out new version of Hotel booking application. There is no > > tynamo-securi

Re: Objects session persistance and validation

2010-10-25 Thread Anton Mezerny
ht try switching the order from validation="required,email" to > validation="email,required" just to see what happens. > > Mark > > On Mon, Oct 25, 2010 at 10:24 AM, Anton Mezerny >wrote: > > > Required validation works on client side, so I have not

Re: tynamo-security (shiro) exception

2010-10-25 Thread Anton Mezerny
Checked out new version of Hotel booking application. There is no tynamo-security dependency in pom.xml at all. Am I doing something wrong? Anton 2010/10/25 Christophe Cordenier > Hi > > Yes it's fixed, i have update the pom.xml to use tynamo 0.3.0-SNAPSHOT > > 2010

Re: Objects session persistance and validation

2010-10-25 Thread Anton Mezerny
know that the actual spec for email > addresses is a lot more permissive than you'd think. > > Mark > > On Mon, Oct 25, 2010 at 6:35 AM, Anton Mezerny >wrote: > > > So, I removed initializeNewUser() from Registration.java and added > @Inject > > annotation t

tynamo-security (shiro) exception

2010-10-25 Thread Anton Mezerny
Hi all, I am playing with hotel booking application and trying to use some examples from it in my project. Now I have a problem in login page - when I try to login, I got shiro's cipher exception, like here: https://issues.apache.org/jira/browse/SHIRO-183 Is it fixed now? How can I upgrade to fixed

Re: Objects session persistance and validation

2010-10-25 Thread Anton Mezerny
reate the relevant entity if none if present. Hope this helps. > > > > Regards, > > Jim. > > > > -Original Message- > > From: Anton Mezerny [mailto:anton.meze...@gmail.com] > > Sent: 23 October 2010 17:02 > > To: Tapestry users > > Subject: O

Objects session persistance and validation

2010-10-23 Thread Anton Mezerny
Hi all, I'm trying to write simple registration form using beaneditor component. If I fullfill all reqired fields in the form and submit it - everything works fine, but if server validation occurs (for example passwords don't match), then all data is lost and Registration page renders with validati

Re: Strange beaneditor behaviour

2010-09-28 Thread Anton Mezerny
ty to be type Object, Tapestry built a model for Object, which > as no properties. > > You can, alternatively, use the BeanModelSource to build a model > object from Child.class, and pass that directly to the BeanEditor via > its model parameter. > > > On Tue, Sep 28, 201

Strange beaneditor behaviour

2010-09-28 Thread Anton Mezerny
Hi! I have 2 classes: public static class Parent{ private String name; private String description; private Child child; //getters and setters } public static class Child{ private String childName; private String childDescr; //getters

Re: Dynamic form

2010-09-18 Thread Anton Mezerny
Looking on ComponentSource code I understood, that it gets only components, that are already defined within some page. Is there any way to get component instance by its name even if this component is not used in any other page? 2010/9/18 Anton Mezerny > Igor, I am now trying to write someth

Re: Dynamic form

2010-09-18 Thread Anton Mezerny
Igor, I am now trying to write something like in your book, but first of all I don't want to define blocks in one tml page, and a number or blocks in java-class. I try to get component instance dynamically using method componentSource.getComponent(String) but I have an exception on this method. o