Re: BeanEditForm onValidate()

2018-01-18 Thread Christopher Dodunski
Mystery solved! My original suspicion was correct in that somewhere the app was attemting to update the database before or while onValidate() was doing it's thing. It wasn't BeanEditForm however, it was Hibernate jumping in the way. Part of the stack trace: org.hibernate.event.internal.DefaultA

Re: BeanEditForm onValidate()

2018-01-17 Thread Christopher Dodunski
And when using the literal "Abel", as below... User userVerif = crudServiceDAO.findUniqueWithNamedQuery(User.BY_USERNAME, QueryParameters.with("userName", "Abel").parameters()); LOG.debug("Verify user: [" + userVerif.getUserName() + "|" + userVerif.getFirstName() + "|" + userVerif.

Re: BeanEditForm onValidate()

2018-01-17 Thread Christopher Dodunski
Hi Geoff, I'm not sure whether this is what you meant, but I added the below code to my onActivate() method: User userVerif = crudServiceDAO.findUniqueWithNamedQuery(User.BY_USERNAME, QueryParameters.with("userName", user.getUserName()).parameters()); LOG.debug("Verify user: [" +

Re: BeanEditForm onValidate()

2018-01-16 Thread Chris Poulsen
You could try setting a break point in the database update code and some in the event handlers and the examine the call stack to see where the call originates from and in which order things happen -- Chris On Tue, Jan 16, 2018 at 10:51 AM, JumpStart < geoff.callender.jumpst...@gmail.com> wrote:

Re: BeanEditForm onValidate()

2018-01-16 Thread JumpStart
If Hibernate is creating/updating the database definition then you could be right. I’m not sure because I use this kind of thing for alternate key: @Entity @Table(name = "Users", uniqueConstraints = { @UniqueConstraint(columnNames = { “username" }) }) public class User ... > On 16 Jan 2018, at

Re: BeanEditForm onValidate()

2018-01-16 Thread Christopher Dodunski
Hi Geoff, Sorry, I'll try that when back at my PC tomorrow. I could be mistaken, but does the 'column' annotation below not set the USER_NAME column in the database as unique? I assumed this is the reason for the ConstraintViolationException, i.e. the unique field. Irrespective, I'll do as you

Re: BeanEditForm onValidate()

2018-01-16 Thread JumpStart
Did you miss my suggestion? Try putting it in onActivate and pass it 'Abel'. I’m hoping it will have the same problem, because, as you know, it makes no sense that a transaction has taken place before onValidate(). Longer term, however, you should scrap the validation because it can be

Re: BeanEditForm onValidate()

2018-01-15 Thread Christopher Dodunski
To summarise... the exceptions: org.hibernate.exception.ConstraintViolationException could not execute statement SQL n/a SQLState 23000 errorCode 1062 and: java.sql.SQLIntegrityConstraintViolationException Duplicate entry 'Abel' for key 'UK

Re: BeanEditForm onValidate()

2018-01-13 Thread Christopher Dodunski
Below is a snippet of my User entity class, where the NamedQueries are also located. Based on your responses, it seems that I'm correct that UpdateUser.java oughtn't be persisting anything for NamedQuery to discover until the line "crudServiceDAO.update(user)" is reached in onSuccessFromUpdateForm

Re: BeanEditForm onValidate()

2018-01-13 Thread JumpStart
I’m guessing that if you run that query earlier, for that user, then it would return the same exception. Try putting it in onActivate and pass it 'Abel'. Is the query joining entities? Possibly it’s returning a cartesian product of the user with another entity, ie. more than one entity returned.

Re: BeanEditForm onValidate()

2018-01-13 Thread Christopher Dodunski
Hi Bob, Evidently, equals is not being reached as there is no output in the logs from the line containing "LOG.debug("Verify user...)". The log file does contain the output from "LOG.debug("Form user...)", two lines above. So my focus has turned to the line containing "User userVerif = crudServi

Re: BeanEditForm onValidate()

2018-01-13 Thread Bob Harner
I don't think k you actually answered my question about the equals method (or perhaps I misunderstood you). I'll try again: 1. Is the line with the recortError() method call actually being reached? Use a debug breakpoint or log statement to prove it. 2. If not, have you overridden the equals metho

Re: BeanEditForm onValidate()

2018-01-13 Thread Christopher Dodunski
The database contains these two users: User name: Abel First name: Abel Last name: Tasman etc. User name: James First name: James Last name: Cook etc. As a test I load user 'James' into the BeanEditForm of UpdateUser.java, and attempt to change his user name to 'Abel' (an illegal change). This

Re: BeanEditForm onValidate()

2018-01-12 Thread Bob Harner
Does the userVerif.equals(user) clause actually result in true? If not, then recordError wouldn't run, and validation would be considered to have passed. Check User.java's equals method, or better yet, maybe just compare the username strings directly. On Jan 12, 2018 7:04 AM, "Christopher Dodunski

Re: beaneditform with option lists of objects

2016-09-22 Thread Barry Books
You will need to build a select model for your list http://tapestry.apache.org/using-select-with-a-list.html I would create an Interface and have the child implement it so you can create a generic one Then create an edit block out of that code. This will allow the BeanEditor to edit this kind of

Re: beaneditform not hiding id

2015-10-29 Thread Geoff Callender
You can see in the example that it’s true - the id field isn’t rendered. If you’re seeing something different then I guess I’m about to learn something new! I haven’t looked behind the scenes of this since, perhaps, T5.0, so things may have changed. On submit, this example is getting the id fr

Re: beaneditform not hiding id

2015-10-29 Thread Paul Stanton
Thiago, Jumpstart says it is automatically excluded and it's published source code suggests this, however I couldn't get it to work like that. That part of it is a question for jumpstart (is it Geoff?) I agree, beanEditor is satisfactory, however for me, beanEditForm would be better if it su

Re: beaneditform not hiding id

2015-10-29 Thread Thiago H de Paula Figueiredo
BeanEditForm is just a thin layer over BeanEditor (basically, a Form with a BeanEditor and a submit button and almost nothing else), so I almost never use BeanEditForm myself, just BeanEditor. Also, I cannot see where in the BeanEditForm documentation it says @Id is automatically excluded.

Re: beaneditform not hiding id

2015-10-28 Thread Paul Stanton
Just further to this, I've decided not to use BeanEditForm because: a) I can't set the context - I'd like to use the Id as context so that I can load the edited bean during 'prepare' b) The 'async' parameter is not exposed meaning I have to specify a zone which is not suitable I suggest these

Re: BeanEditForm in jquery.dialog - problem with validation

2015-07-15 Thread Chris Poulsen
Try bindnig the BeanEditForm to the zone to prevent full page reload on submit (zone="^") On Wed, Jul 15, 2015 at 4:34 PM, Matthias Bieber wrote: > Hello, > > I have a BeanEditForm inside a jquery.dialog. The dialog will be opened if > you click on a link. > I want to validate the input by using

Re: BeanEditForm autofocus issue with JSR 303 validaiton mixed with tapestry validation (Tapestry 5.4-alpha-29)

2013-12-07 Thread Thiago H de Paula Figueiredo
On Sat, 07 Dec 2013 14:13:10 -0200, Balázs Palcsó wrote: I have raised a bug in JIRA for this: https://issues.apache.org/jira/browse/TAP5-2254 Thanks! -- Thiago H. de Paula Figueiredo Tapestry, Java and Hibernate consultant and developer http://machina.com.br Help me spend a whole month wo

Re: BeanEditForm autofocus issue with JSR 303 validaiton mixed with tapestry validation (Tapestry 5.4-alpha-29)

2013-12-07 Thread Balázs Palcsó
I have raised a bug in JIRA for this: https://issues.apache.org/jira/browse/TAP5-2254 On 5 December 2013 22:22, Balázs Palcsó wrote: > I forgot to post the definition of @Validate("password") which makes the > password field the first required field in the form (and making it to owner > of the

Re: BeanEditForm autofocus issue with JSR 303 validaiton mixed with tapestry validation (Tapestry 5.4-alpha-29)

2013-12-05 Thread Balázs Palcsó
I forgot to post the definition of @Validate("password") which makes the password field the first required field in the form (and making it to owner of the focus on the form) @Contribute(ValidatorMacro.*class*) *public* *static* *void* combinePasswordValidators(*final*MappedConfiguration configur

Re: beaneditform and kapcha

2013-08-05 Thread D.R.
Hi, but it also works with a beaneditform: ... What you see? ... @Component(id = "beanEditForm", parameters = {"object=beanToEdit", "add=kaptcha"}) private BeanEditForm _editFormComponent; Kind regards David Am 05.08.2013 18:45, schri

Re: beaneditform and kapcha

2013-08-05 Thread Thiago H de Paula Figueiredo
On Mon, 05 Aug 2013 12:53:48 -0300, Nikola Vulovic wrote: How to add kapcha to beaneditform? Use BeanEditor instead. -- Thiago H. de Paula Figueiredo - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For add

Re: BeanEditForm and hibernate

2012-11-19 Thread Ivan Khalopik
Sorry, I have made mistake, you will need EventConstants.VALIDATE event instead of EventConstants.VALIDATE_FORM, and also you need component id. But to specify this component id you have to override property editor as I've mentioned before. On Mon, Nov 19, 2012 at 6:01 PM, Nicolas Barrera wrote:

Re: BeanEditForm and hibernate

2012-11-19 Thread Nicolas Barrera
Thank you so much Ivan, I 'd rather use option number 1 as I like to leave transaction management as I 've already got it. Related to the first option you mentioned and the code you posted... it's not necessary to override the name property with ain't it? cheers, Nicolás.- On Mon, Nov 19, 20

Re: BeanEditForm and hibernate

2012-11-19 Thread Ivan Khalopik
You can try 2 options: 1. Use validation by name to prevent name changes before request to DB. It will be executed before name property will be assigned to new value: @OnEvent(value=EventConstants.VALIDATE_FORM, component="nameField") public void validateName() { //... } 2.

Re: beaneditform guide out of date

2012-11-01 Thread Kalle Korhonen
Fixed, thanks. If you file a CLA, it'll be faster to edit and fix small issues in docs like these yourself than write an email about it. Kalle On Thu, Nov 1, 2012 at 12:47 PM, Paul Stanton wrote: > http://tapestry.apache.org/beaneditform-guide.html > > > > > > > > >

Re: Beaneditform Troubles

2012-07-17 Thread loshmeey
Thnx Alex! im gonna give it a go in the mornning! Best Regards, Milos D. -- View this message in context: http://tapestry.1045711.n5.nabble.com/Beaneditform-Troubles-tp5714511p5714529.html Sent from the Tapestry - User mailing list archive at Nabble.com.

Re: Beaneditform Troubles

2012-07-17 Thread Alex Kotchnev
I haven't tested it but I'd guess that it's doing this because it doesn't have an editor registered for the Autor and Jezik entities. You have two options : 1. Create property editors for the entities as described in http://jumpstart.doublenegative.com.au/jumpstart/examples/lang/propertyeditors .

Re: Beaneditform Troubles

2012-07-17 Thread loshmeey
hm thank you for the quick reply Alex, i have the same line of code, and for some reason it is not working! Here is the code so if anyone has any clue what the problem might be... @Basic(optional = false) @Validate("required") @Column(name = "KNJIGA_NAPOMENA") private String knjigaNapo

Re: Beaneditform Troubles

2012-07-17 Thread Alex Kotchnev
Milos, I don't seem to have a problem w/ this functionality: [ display the user related information here ], e.g. My "foo" entity already has a "getUsers" method. Cheers, Alex K On Tue, Jul 17, 2012 at 11:44 AM, loshmeey wrote: > Hello, i have problems with

Re: Beaneditform looses data of non visual fields.

2012-05-21 Thread Thiago H. de Paula Figueiredo
On Mon, 21 May 2012 06:07:55 -0300, Michael Schmidt wrote: Hi all, Hi! I'm trying to use the BeanEditForm for editing the data of a object and persist it using hibernate. You either @Persist the object or use BeanEditor (which is the base of BeanEditForm) and use the Hidden component

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Lance Java
Hmm... that's a tricky one... I assumed that RenderInformals always added informals to the currently rendering element but I can see that this won't happen if an element has not been added to the MarkupWriter at beginRender() which happens with the bean edit form. In fact, RenderInformals won't wor

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Chris Mylonas
Cool, good to know for future - My n00bness is still cool too! I've added it to the rosetta stone jira (https://issues.apache.org/jira/browse/TAP5-1894) for the more-than-one-way-to-skin-a-cat approach of getting stuff done in Tapestry. On 26/04/2012, at 12:28 AM, Felix Scheffer wrote: > Gr

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Felix Scheffer
Grid works fine. It's using inheritInformalParameters @Component(parameters = "class=tableClass", inheritInformalParameters = true) private Any table; 2012/4/25 Chris Mylonas > GridColoum suffers from the same thing having a look at the code. There > is no sign of resources.renderInformalPara

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Chris Mylonas
GridColoum suffers from the same thing having a look at the code. There is no sign of resources.renderInformalParameters() Same for Grid. hehe what I've learned this week from the list, you'll have to contribute the NoFUD service to the registry with @EagerLoad to get in before the rest of

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Felix Scheffer
Thanks guys for the quick response. Much appreciated! 2012/4/25 Chris Mylonas > https://issues.apache.org/jira/browse/TAP5-1917 > > Done. > > > re: sarcasm earlier - there seems to be an increase in "is this a bug?" > tacked onto each problem. I thought you were just having a little fun on > t

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Felix Scheffer
Thanks! That was fast :-) I tried using RenderInformals and the result is: now the class attribute is present, but on the wrong tag (should be on the form tag). Looks like the form tag has not been rendered when RenderInformals.beginRender() method is called. I would expected th

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Lance Java
I'm happy to call a bug a bug but I shall valiantly defend my baby (tapestry) from FUD

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Chris Mylonas
https://issues.apache.org/jira/browse/TAP5-1917 Done. re: sarcasm earlier - there seems to be an increase in "is this a bug?" tacked onto each problem. I thought you were just having a little fun on the list :) So far today, The List 1 : Tapestry-5.3.x 0 Nice one Felix. Cheers Chris On 25/0

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Lance Java
It seems that BeanEditor has the same bug. Pls put that in the Jira too Might be an idea to search all components with @SupportsInformalParameters that don't call renderInformalParameters to find any others

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Thiago H. de Paula Figueiredo
On Wed, 25 Apr 2012 10:37:49 -0300, Chris Mylonas wrote: was the sarcasm meter on that Lance? :) - hard to tell at nearly midnight I'd say that I can't think of any reason BeanEditForm shouldn't render attributes which aren't parameters. JIRA please? :) -- Thiago H. de Paula Figueiredo

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Lance Java
No sarcasm intended It seems that the beanEditForm needs a one-liner added to it ComponentResources.renderInformals(writer) On Wednesday, 25 April 2012, Chris Mylonas wrote: > was the sarcasm meter on that Lance? > :) - hard to tell at nearly midnight > > On 25/04/2012, at 11:22 PM, Lance Java

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Chris Mylonas
was the sarcasm meter on that Lance? :) - hard to tell at nearly midnight On 25/04/2012, at 11:22 PM, Lance Java wrote: > Try adding the following attribute: > t:mixins="renderInformals" > > If it works, there's a bug ;) > > On Wednesday, 25 April 2012, Felix Scheffer wrote: >> Hi, >> >> i a

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Chris Mylonas
fyi, it doesn't add the class normally. It works when adding t:mixins="renderInformals" I'm on 5.3.2 On 25/04/2012, at 11:22 PM, Lance Java wrote: > Try adding the following attribute: > t:mixins="renderInformals" > > If it works, there's a bug ;) > > On Wednesday, 25 April 2012, Felix Scheffe

Re: BeanEditForm does NOT support informal parameters?

2012-04-25 Thread Lance Java
Try adding the following attribute: t:mixins="renderInformals" If it works, there's a bug ;) On Wednesday, 25 April 2012, Felix Scheffer wrote: > Hi, > > i am using a BeanEditForm and added a class attribute to it, i.e.: > > > ... > > > but the class attribute does not appear in the actual h

Re: beaneditform submit at the top instead of at the bottom

2012-01-09 Thread Kalle Korhonen
On Mon, Jan 9, 2012 at 4:45 PM, TG wrote: > Hi guys, would anyone advise on what is the best/easiest way to make the > submit button appear at the top? Don't use beaneditform but create your own: Kalle - To u

RE: Beaneditform with two submit buttons?

2011-11-09 Thread TG
When you said Done, do you mean you have provided the source somewhere else? Would you mind sharing the URL? Wiki or otherwise? Thanks! -- View this message in context: http://tapestry.1045711.n5.nabble.com/Beaneditform-with-two-submit-buttons-tp4967644p4978709.html Sent from the Tapestry - User

RE: Beaneditform with two submit buttons?

2011-11-07 Thread Wechsung, Wulf
o:tapestry...@hotmail.com] Sent: Montag, 7. November 2011 22:40 To: users@tapestry.apache.org Subject: RE: Beaneditform with two submit buttons? Wulf, would you mind share the codes? Thanks ! :) -- View this message in context: http://tapestry.1045711.n5.nabble.com/Beaneditform-with-two-subm

RE: Beaneditform with two submit buttons?

2011-11-07 Thread TG
Wulf, would you mind share the codes? Thanks ! :) -- View this message in context: http://tapestry.1045711.n5.nabble.com/Beaneditform-with-two-submit-buttons-tp4967644p4972522.html Sent from the Tapestry - User mailing list archive at Nabble.com. -

RE: Beaneditform with two submit buttons?

2011-11-07 Thread Wechsung, Wulf
't spare the time to annotate it and clean up calls to my own libs which would be necessary in order to add it to the tapestry wiki. Best Regards, Wulf -Original Message- From: TG [mailto:tapestry...@hotmail.com] Sent: Montag, 7. November 2011 20:23 To: users@tapestry.apache.org

Re: Beaneditform with two submit buttons?

2011-11-07 Thread Thiago H. de Paula Figueiredo
On Mon, 07 Nov 2011 17:23:27 -0200, TG wrote: Any kind souls out here that can send me samples codes with beaneditor with two submit buttons that work? Not tested: Cheers! -- Thiago H. de Paula Figueiredo Independent Java, Apache Tapestry 5 and Hibernate consu

Re: Beaneditform with two submit buttons?

2011-11-07 Thread TG
Any kind souls out here that can send me samples codes with beaneditor with two submit buttons that work? Thanks. -- View this message in context: http://tapestry.1045711.n5.nabble.com/Beaneditform-with-two-submit-buttons-tp4967644p4972166.html Sent from the Tapestry - User mailing list archive

Re: Beaneditform with two submit buttons?

2011-11-06 Thread TG
I changed it and also changed but I got Parameter(s) 'object' are required for org.apache.tapestry5.corelib.components.BeanEditForm, but have not been bound. What do I missed? Can you look at my codes again? Thanks. -- View this message in context: http://tapestry.1045711.n5.nabble.com/Beane

Re: Beaneditform with two submit buttons?

2011-11-06 Thread Dusko Jovanovski
You should add this: xmlns:p="tapestry:parameter" to the root element in your .tml file, and use p:id instead of t:parameter name="id" On Sun, Nov 6, 2011 at 6:12 PM, TG wrote: > I changed my codes to something like this - > > > > > > > > > >

Re: Beaneditform with two submit buttons?

2011-11-06 Thread TG
I changed my codes to something like this - ${service.id} and I got the following error - The

Re: Beaneditform with two submit buttons?

2011-11-06 Thread Taha Hafeez Siddiqi
Hi Have you looked at https://github.com/apache/tapestry5/blob/trunk/tapestry-core/src/main/java/org/apache/tapestry5/corelib/components/BeanEditForm.java https://github.com/apache/tapestry5/blob/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/corelib/components/BeanEditForm.tml reg

Re: Beaneditform with two submit buttons?

2011-11-06 Thread TG
Could you provide sample codes for that? Thanks. -- View this message in context: http://tapestry.1045711.n5.nabble.com/Beaneditform-with-two-submit-buttons-tp4967644p4968843.html Sent from the Tapestry - User mailing list archive at Nabble.com. --

Re: Beaneditform with two submit buttons?

2011-11-05 Thread Thiago H. de Paula Figueiredo
On Sat, 05 Nov 2011 21:27:56 -0200, TG wrote: Is it possible to have two submit buttons for this component? I would like to implement "save" (the page stays) and "submit" (done, and go to the welcome page). I don' think so, but you can use a Form with a BeanEditor and your submit buttons

Re: BeanEditForm for hibernate entity with version field

2011-06-14 Thread Geoff Callender
The link http://jumpstart.doublenegative.com.au/jumpstart/examples/easycrud has been replaced by: http://jumpstart.doublenegative.com.au/jumpstart/previews/easycrud/persons On 30/05/2011, at 12:34 AM, Donny Nadolny wrote: > I've got a BeanEditForm for my User entity which has a version

Re: BeanEditForm - small problem

2011-06-09 Thread Howard Lewis Ship
Please refer to the FAQ for a description of this problem, and some solutions. On Fri, May 20, 2011 at 9:23 AM, toejoe wrote: > Thank You for the reply. > > However, suggested solution did not work, but your proposal gave me the > idea. I deleted all constructors from entity class. Bean edit form

Re: BeanEditForm for hibernate entity with version field

2011-05-30 Thread Geoff Callender
I've just re-tested the JumpStart page and it does what you want. Just be sure to use two different browsers applications for the two users so you're absolutely sure they're not sharing one user session. Are you retrieving the user from the DB in onPrepare()? In debug you would expect to see i

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Taha Tapestry
I am guessing the version field updates are ignored by hibernate so the solution that I suggested is more suitable. Regards Taha Sent from my iPhone On May 29, 2011, at 10:51 PM, Donny Nadolny wrote: > Hi Taha, > > Nice find, that's exactly the problem I have. Unfortunately it didn't seem >

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Donny Nadolny
Hi Taha, Nice find, that's exactly the problem I have. Unfortunately it didn't seem to work. I've tried: tml: java: public void setupRender() { versionWhenLoaded = user.getVersion(); } public void onPrepareEditUserForm() { sessio

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Taha Tapestry
Check this out https://forum.hibernate.org/viewtopic.php?f=1&t=957807 Sent from my iPhone On May 29, 2011, at 10:06 PM, Donny Nadolny wrote: > Hi Taha, > > That would be a reasonable place to hook it in. However, I'd like to make > sure that it would work first, and it seems like in principle

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Donny Nadolny
Hi Taha, That would be a reasonable place to hook it in. However, I'd like to make sure that it would work first, and it seems like in principle it's the same as the 4th way I tried (which didn't work): store the current version when the form is rendered, then when you save you grab the latest fro

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Taha Hafeez
Hi Donny One way I can think of is extend AbstractSessionPersistentFieldStrategy as is done by EntityPersistentFieldStrategy(tapestry-hibernate) and store version in addition to id and type in PersistedEntity and later while retrieving the value, check the version too Take a lot at https://svn.a

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Donny Nadolny
Hi Josh, Yup, it must be. The question is, how do I stop that? I tried following the example from the jumpstart demo but it didn't work, and I tried setting the version field manually, and it still didn't work (the exact code I used is in the initial email). On Sun, May 29, 2011 at 12:11 PM, Josh

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Josh Canfield
I would guess that you are pulling the object from the database when you post the form, and thus editing the current version. I believe is the default behaviour with the tapestry persistent object translator, it stores the type and id in the form. Josh On May 29, 2011 7:34 AM, "Donny Nadolny" wr

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Donny Nadolny
Hi Taha, I've tried it having the application update it instead: I opened my "Edit user" page, I hit a page that updated that user, and then I hit save in the "Edit user" page and it overwrote the changes. When I tried just hitting two pages that update the user (grab user, sleep for a bit to make

Re: BeanEditForm for hibernate entity with version field

2011-05-29 Thread Taha Hafeez
Updating the database directly is not advisable when working with hibernate and might be the culprit here. Can you test it by updating the instance using hibernate instead. regards Taha On Sun, May 29, 2011 at 8:04 PM, Donny Nadolny wrote: > I've got a BeanEditForm for my User entity which has

Re: BeanEditForm - small problem

2011-05-20 Thread toejoe
Thank You for the reply. However, suggested solution did not work, but your proposal gave me the idea. I deleted all constructors from entity class. Bean edit form is now working! This is the first time I created entity classes with the wizard. :( Cheers -- View this message in context: http://

Re: BeanEditForm - small problem

2011-05-20 Thread Thiago H. de Paula Figueiredo
On Fri, 20 May 2011 11:15:42 -0300, toejoe wrote: Hello Hi! Try this: void onPrepare() { if (guma == null) { guma = new Guma(...); } } I can not get over thisprobably basic problem. Render queue error in SetupRender[Gume:guma.editor]: Exception instanti

Re: BeanEditForm: What's happening to my object parameter?

2011-05-18 Thread Geoff Callender
Added to JIRA: https://issues.apache.org/jira/browse/TAP5-1527 On 10/05/2011, at 9:39 PM, Geoff Callender wrote: > Nope, it's like Rich said: onPrepare() is being called twice during the > render phase, and then the object disappears! > > Yet, when you replace BeanEditForm with a Form around a

Re: BeanEditForm: What's happening to my object parameter?

2011-05-10 Thread Geoff Callender
Nope, it's like Rich said: onPrepare() is being called twice during the render phase, and then the object disappears! Yet, when you replace BeanEditForm with a Form around a BeanEditor it works correctly: onPrepare() is called once during the render phase and the object doesn't disappear:

Re: BeanEditForm: What's happening to my object parameter?

2011-05-10 Thread Geoff Callender
It looks like a bug - onPrepare() is not being called during render of BeanEditForm. For example, this page should have rendered Person 1: http://jumpstart.doublenegative.com.au/jumpstart/examples/input/edit1/1 I'm sure it worked in 5.1.0.5 but doesn't in 5.2.5. Anyone else seeing this?

Re: BeanEditForm: What's happening to my object parameter?

2011-03-22 Thread Thiago H. de Paula Figueiredo
On Tue, 22 Mar 2011 18:33:16 -0300, Rich M wrote: Why don't you use onPrepare() instead of onPrepareForRender()? Same result, unfortunately. I switched to onPrepareForRender eventually because onPrepare gets called 2-3 times during the page lifecycle while onPrepareForRender only once. On

Re: BeanEditForm: What's happening to my object parameter?

2011-03-22 Thread Rich M
On 03/22/2011 05:10 PM, Thiago H. de Paula Figueiredo wrote: On Tue, 22 Mar 2011 17:53:12 -0300, Rich M wrote: Okay, maybe I'm not interpreting the page lifecycle properly here, or it has changed it some way that is causing me problems? The entity is referenced and loaded properly in onPrepar

Re: BeanEditForm: What's happening to my object parameter?

2011-03-22 Thread Thiago H. de Paula Figueiredo
On Tue, 22 Mar 2011 17:53:12 -0300, Rich M wrote: Okay, maybe I'm not interpreting the page lifecycle properly here, or it has changed it some way that is causing me problems? The entity is referenced and loaded properly in onPrepareForRender. Considering that BeanEditor only changes the v

Re: BeanEditForm: What's happening to my object parameter?

2011-03-22 Thread Rich M
On 03/22/2011 02:50 PM, Thiago H. de Paula Figueiredo wrote: Hi! BeanEditor, which is used inside BeanEditForm, only changes the value of the edited property if it's null, so the problem should be elsewhere. By the way, why are you using the Environment instead of component parameters? And wh

Re: BeanEditForm: What's happening to my object parameter?

2011-03-22 Thread Thiago H. de Paula Figueiredo
Hi! BeanEditor, which is used inside BeanEditForm, only changes the value of the edited property if it's null, so the problem should be elsewhere. By the way, why are you using the Environment instead of component parameters? And what do you call a subpage? -- Thiago H. de Paula Figueired

Re: BeanEditForm and Polymorphism

2011-01-17 Thread Elin
Of course. I started with tapestry some months ago so im not an expert but i will share everything im learning with others through tutorials (hopefully i will end some by the end of this week). The hardest part of tapestry is starting with it. If we all share our knoledge with newbies, it will be

Re: BeanEditForm and Polymorphism

2011-01-17 Thread Werner Keil
Although I am not using T5 beyond that project last year, the resolution sounds useful to many users, and maybe you could even get in touch with Howard & Co. to bake this into the official tutorials for future versions?[?] -- Werner Keil | UOMo Lead | Eclipse Foundation | Agile Coach, Principal

Re: BeanEditForm and Polymorphism

2011-01-17 Thread Elin
Thanks Werner. The problem here was that i wanted a generic method. At first, i dont know what kind of subclasses are avaliable because they are managed by a service so i can add more subclasses just annotating them and i will have more subproducts avaliable without any code changes. Because of th

Re: BeanEditForm and Polymorphism

2011-01-16 Thread Werner Keil
Hi Elin, If your method getMyProduct() returns product I guess that is part of the reason. Whether you change that signature or use a different form, you may need to get your SubProduct into the BeanEditForm. Regarding possibly unwanted fields of the base class, the @Visible annotation or similar

Re: BeanEditForm and Polymorphism

2011-01-16 Thread Elin
Thanks a lot, i managed to solve my problem thanks to your advice. -- View this message in context: http://tapestry.1045711.n5.nabble.com/BeanEditForm-and-Polymorphism-tp3343510p3343792.html Sent from the Tapestry - User mailing list archive at Nabble.com. --

Re: BeanEditForm and Polymorphism

2011-01-16 Thread Josh Canfield
I'm not in front of a computer now, but I would guess that the right thing to do is provide your own bean model... tapestry is probably using the type from your getter to create the model. On Jan 16, 2011 9:32 AM, "Elin" wrote: > > Hi all. > > Im developing a new project and im having some problem

Re: BeanEditForm support for embedded types

2010-11-09 Thread Thiago H. de Paula Figueiredo
On Tue, 09 Nov 2010 09:20:12 -0200, Josh Kamau wrote: Hi there; Hi! Does the beanEditForm have support for Embedded Types and images out of the box? BeanEditor (which is used internally by BeanEditForm) supports any type of object as long there's an edition block for it. See the Addi

Re: BeanEditForm support for embedded types

2010-11-09 Thread Josh Kamau
Thanks. For editing an image i think i would create a file uproad edition block. I thought it would automatically create an upload field for properties of type Byte[]. -- the way grails does it. I will read more of customizing the bean editor form. regards. On Tue, Nov 9, 2010 at 6:46 AM, Th

Re: BeanEditForm - multi col?

2009-12-07 Thread Thiago H. de Paula Figueiredo
Em Mon, 07 Dec 2009 13:37:22 -0200, Jim O'Callaghan escreveu: Thanks Thiago You're welcome! - the CSS idea you mention sounds promising, though rather than using something IE doesn't support, I'll just float-left and clear-left the fields divs using CSS, That's a nice solution. :) Don'

RE: BeanEditForm - multi col?

2009-12-07 Thread Jim O'Callaghan
t of cases that I require - thanks for the pointers. Regards, Jim. -Original Message- From: Thiago H. de Paula Figueiredo [mailto:thiag...@gmail.com] Sent: 07 December 2009 11:45 To: Tapestry users Subject: Re: BeanEditForm - multi col? Em Mon, 07 Dec 2009 08:01:26 -0200, Jim O'Call

Re: BeanEditForm - multi col?

2009-12-07 Thread Thiago H. de Paula Figueiredo
Em Mon, 07 Dec 2009 08:01:26 -0200, Jim O'Callaghan escreveu: Hi, Hi! I'm trying to maximise screen real estate in some pages and was wondering if there is an easy way to make the BEF multi-col - even two col would do the trick - any getter annotations etc. to get it to close one div a

Re: beaneditform question

2009-11-10 Thread Jonhy Pear
http://www.gaonline.com.cn > - Original Message - > From: "Jonhy Pear" > To: "Tapestry users" > Sent: Tuesday, November 10, 2009 3:27 AM > Subject: Re: beaneditform question > > > I'm experimenting your code but I'm blocked :( > > I ha

Re: beaneditform question

2009-11-09 Thread DH
I never had this issue before. I just test and everything works right, can you share the whole stack trace? DH http://www.gaonline.com.cn - Original Message - From: "Jonhy Pear" To: "Tapestry users" Sent: Tuesday, November 10, 2009 3:27 AM Subject: Re: beanedi

Re: beaneditform question

2009-11-09 Thread Jonhy Pear
sage - > From: "João Pereira" > To: "Tapestry users" > Sent: Monday, November 09, 2009 11:53 PM > Subject: Re: beaneditform question > > > Thank you. > > > On Mon, Nov 9, 2009 at 1:50 AM, DH wrote: > > > Hi

Re: beaneditform question

2009-11-09 Thread ningdh
I am sorry that "Object onValidate" should be "Object onValidateForm". DH - Original Message - From: "João Pereira" To: "Tapestry users" Sent: Monday, November 09, 2009 11:53 PM Subject: Re: beaneditform question Thank you. On Mon,

Re: beaneditform question

2009-11-09 Thread João Pereira
codeutil.encode(password)); >service.save(user); >return successpage or other; > } > > DH > http://www.gaonline.com.cn > > - Original Message - > From: "Jonhy Pear" > To: > Sent: Monday, November 09, 2009 9:21 AM > Subject: Re: beaneditform

Re: beaneditform question

2009-11-08 Thread DH
e(password)); service.save(user); return successpage or other; } DH http://www.gaonline.com.cn - Original Message - From: "Jonhy Pear" To: Sent: Monday, November 09, 2009 9:21 AM Subject: Re: beaneditform question Sorry, I mean beaneditform, not beaneditform On Mon, Nov 9, 20

  1   2   >