From adffaces-user-return-2427-apmail-incubator-adffaces-user-archive=incubator.apache.org@incubator.apache.org Thu Mar 22 09:53:37 2007 Return-Path: Delivered-To: apmail-incubator-adffaces-user-archive@locus.apache.org Received: (qmail 78889 invoked from network); 22 Mar 2007 09:53:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 22 Mar 2007 09:53:37 -0000 Received: (qmail 73350 invoked by uid 500); 22 Mar 2007 09:53:44 -0000 Delivered-To: apmail-incubator-adffaces-user-archive@incubator.apache.org Received: (qmail 73335 invoked by uid 500); 22 Mar 2007 09:53:44 -0000 Mailing-List: contact adffaces-user-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: adffaces-user@incubator.apache.org Delivered-To: mailing list adffaces-user@incubator.apache.org Received: (qmail 73326 invoked by uid 99); 22 Mar 2007 09:53:44 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Mar 2007 02:53:44 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: local policy) Received: from [209.191.68.192] (HELO web34913.mail.mud.yahoo.com) (209.191.68.192) by apache.org (qpsmtpd/0.29) with SMTP; Thu, 22 Mar 2007 02:53:34 -0700 Received: (qmail 3631 invoked by uid 60001); 22 Mar 2007 09:53:13 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type:Message-ID; b=PspAXY37GGFxDAvW7NsQZrWvdiGHdGKt0rn5yAIKv3xUBFCpp8QIXUZxB74UJ+vypWXHlQTDWX9SFQi5uHD41G0MpgWMMXIs1ZwGdJ2D/4s5AUj0kY4v2lxQ8h4yVhvFHgtFbSwR8wu5jNgaFJPkwNdbK6i7zj0w8mydsAWHffA=; X-YMail-OSG: bYz0OnUVM1lX8MI0TdzJh.4djN9gzZiI40GOwia2pFk8qH05fePTfy7wm9pz6XLxabBclpVLJo5KnZqIyCyD6RE7cJsUdGeEANOsOPcclGwmroK1MpruShaPOTUXwxZeMoKdSVd6uM5DH3Z6X44- Received: from [80.129.64.138] by web34913.mail.mud.yahoo.com via HTTP; Thu, 22 Mar 2007 02:53:13 PDT X-Mailer: YahooMailRC/476 YahooMailWebService/0.7.41.8 Date: Thu, 22 Mar 2007 02:53:13 -0700 (PDT) From: Jochen Traunecker Subject: [TRINIDAD] How to reset a form To: adffaces-user@incubator.apache.org MIME-Version: 1.0 Content-Type: text/plain; charset=ascii Message-ID: <168290.2459.qm@web34913.mail.mud.yahoo.com> X-Virus-Checked: Checked by ClamAV on apache.org Hello everybody, using Trinidad and Shale I ran into this silly simple problem: I want a form containing a bunch of text-input fields, each of them with some validator associated to get reset by clicking a commandButton. To avoid validating the input fields I use immediate="true" for the reset button. My model gets reset (see pseudocode) but the textfields in the browser don't disply the model-values - they keep their values. I'm wondering, how to reset some UIComponents (without any validation). I thougth, that all updates to the datamodel/backingbean before RENDER_RESPONSE will have an impact on the rendered output, regardless of immediate="true". Is this a partialPageRendering issue ? Thanks for your help! Jochen Pseudocode ... ... backingbean.class String name="Foo"; public String save(){ //getName is set to validated name provided by the user someDao.persist(getName()); } public String reset(){ //do nothing, as prerender will reset the model } ... public void prerender(){ name=someDao.retrieve(); //allways reset datamodel to latest persistent state } public String getName(){ return name; } public void setName(String name){ this.name= name; } ___________________________________________________________ Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de