Re: Validation causing me problems

2008-11-13 Thread Dirk Forchel
lathjer wrote: > > So as I am trying to figure this out, and it has brought up some > questions. > > > lathjer wrote: >> >> >> > method="list"> >> user.list >> >> > > That mapping causes the error. When the UserAction.list() method is called > it is looking for

[s2] OGNL expression for referring to one key-value Map pair

2008-11-13 Thread Pierre Thibaudeau
Say, I have a Map of the kind: Map pet = new HashMap(); public Map getPet() { return pet; } public void setPet(Map pet) { this.pet = pet; } Typically, pet might contain something like: pet.put("fr", "chat"); pet.put("en", "cat"); How do I refer to one of the map entries in a texfield? What is

Re: login problem

2008-11-13 Thread Diny
hi... I had to put role-names into my web.xml file to solve login problem. you mentioned in ur post.. i would like to know how it is possible and how come you are saying tat it will reduce the login problem.. if u dont mind reply me as soon as possible. Anet-2 wrote: > > H

Re: welcome.do ignored in my web.xml

2008-11-13 Thread Wes Wannemacher
JSPs, HTML files and Servlets will work, but pointing to an action will not. This is not a struts limitation, it was part of the spec. [quote servlet-2_4-fr-spec.pdf] The Web server must append each welcome file in the order specified in the deployment descriptor to the partial request and check

Re: Using validation with Hibernate...

2008-11-13 Thread Burton Rhodes
In case anyone is interested, I found this plug-in for the exact problem that look promising: http://code.google.com/p/hibernatesession-plugin-for-struts2/ On Thu, Nov 13, 2008 at 3:46 PM, Adam Ruggles <[EMAIL PROTECTED]> wrote: > > Use a struts interceptor instead of a servlet filter. That way

RE: Advanced Struts 2 Validation Question...

2008-11-13 Thread Shannon, Andrew
I'd have to second that. Writing validation in java code that is. We've been creating a few different patterns to try and do this in an intelligent manner, especially where we might need to go to the database and get some data or rules or something. I think one of the biggest benefits about this

Re: Struts 2.1.2/2.1.3?

2008-11-13 Thread Wendy Smoak
On Thu, Nov 13, 2008 at 3:42 PM, Kurt Dominik <[EMAIL PROTECTED]> wrote: > I was wondering if anyone knows if the source code for 2.1.3 is publicly > available for review yet? 2.1.3 has not been released yet, but you can always check out the source code from Subversion. The trunk which is versio

Re: Struts 2.1.2/2.1.3?

2008-11-13 Thread Dave Newton
--- On Thu, 11/13/08, Kurt Dominik wrote: > I was wondering if anyone knows if the source code for > 2.1.3 is publicly available for review yet? All revisions, including the trunk, are always available. Dave - To unsubscribe, e

Re: Using validation with Hibernate...

2008-11-13 Thread Burton Rhodes
Many thanks. I will give that a try. On 11/13/08, Adam Ruggles <[EMAIL PROTECTED]> wrote: > > Use a struts interceptor instead of a servlet filter. That way you can > check > the return type of the action that gets executed and respond appropriately. > > > > Burton Rhodes wrote: >> >> I am havin

Struts 2.1.2/2.1.3?

2008-11-13 Thread Kurt Dominik
Hey, I noticed on this page: http://struts.apache.org/2.0.12/docs/url.html The mention of a 2.1.3 release, but I have not found it on the struts.apache.org site. I did find the JIRA ( https://issues.apache.org/struts/secure/Dashboard.jspa). I was wondering if anyone knows if the source code for

Re: Using validation with Hibernate...

2008-11-13 Thread Adam Ruggles
Use a struts interceptor instead of a servlet filter. That way you can check the return type of the action that gets executed and respond appropriately. Burton Rhodes wrote: > > I am having trouble getting Struts 2.x to implement validation and > hibernate using the HibernateSessionRequestFil

Re: Struts 2.1.2 type conversion failing for Integer method.

2008-11-13 Thread Carlos Luis Zúñiga Sibaja
Adam, For what I know the only solution to this problem is upgrading the version of OGNL included in struts, but there are problems by doing that (check out the JIRA issue). So the workaround for me was to stop using generic properties in my Model objects. Please, if somebody has come across a si

Problems with s:datetimepicker

2008-11-13 Thread Nick Maunder | Oathouse
Hi I'm trying to use s:datetimepicker in my application (Struts2) I have a basic version running correctly on a jsp The problem comes when I try to integrate with tiles The page then loads correctly before wiping and "loading" constantly. Im using firefox and my firebug gives up at 350

Re: Struts 2.1.2 type conversion failing for Integer method.

2008-11-13 Thread Adam Ruggles
Are there any workarounds for this? I've tried using a conversion properties file for my action and adding the following: id=example.MyTypeConverter but it didn't get called from struts. I wonder if it's because it should be model.id or myobject.id. Carlos Luis Zúñiga Sibaja wrote: > > Actua

Using validation with Hibernate...

2008-11-13 Thread Burton Rhodes
I am having trouble getting Struts 2.x to implement validation and hibernate using the HibernateSessionRequestFilter (the pattern suggested on Hibernate.org). When the validation fails, Hibernate will still update the object in the database when the HibernateFilter closes the transaction. I get w

Re: [S2] Problems including dojo

2008-11-13 Thread Musachy Barroso
Look at the output of the s:head tag which links to the dojo files, and fix the urls to include /ext in it. musachy On Thu, Nov 13, 2008 at 5:36 AM, Jan Froehlich <[EMAIL PROTECTED]>wrote: > Hi there... > > I have an existing web application based on a servlet. As I need to > extend it and dont

Re: Portlet, DirectRenderFromEventAction - how to change the interceptor stack?

2008-11-13 Thread Torsten Krah
On Friday 24 October 2008 09:57:18 Nils-Helge Garli Hegvik wrote: > If you can, I would suggest that > you re-organize your application so that every event (usually a post) > is followed by a redirect (using the redirect action result type). > That way, the "RenderDirect" action is never used. Did

RE: Multi org support with i18n

2008-11-13 Thread Manish Kumar Wadhwa
Hi, I found a solution for my problem. I can create a custom ResourceBundle.Control class where i can define the rules to fulfill my requirements. For this, i need to set my own ResourceBundle object into the stack. ResourceBundle.getBundle(baseName, locale, myRBControl) Can anyone please sug

Re: Validation causing me problems

2008-11-13 Thread lathjer
So as I am trying to figure this out, and it has brought up some questions. lathjer wrote: > > > method="list"> > user.list > > That mapping causes the error. When the UserAction.list() method is called it is looking for the input result type. So my question (o

Re: Advanced Struts 2 Validation Question...

2008-11-13 Thread Burton Rhodes
Thanks to all! Implementing Validatable was simple and works great. I am thinking of moving all my action objects that need it to Validatable. per Bill's suggestion... one less file to worry about. :) On Thu, Nov 13, 2008 at 9:58 AM, Dave Newton <[EMAIL PROTECTED]> wrote: > --- On Thu, 11/13/08,

Re: Advanced Struts 2 Validation Question...

2008-11-13 Thread Dave Newton
--- On Thu, 11/13/08, Burton Rhodes wrote: > How do I use validation in an [Action]-validation.xml file > to validate several fields? > > I need to implement the following logic for 3 fields on a > form: Company, FirstName, LastName. > > Psedo Code: > > If Company empty, then FirstName and LastN

Re: Struts 2.1.2 type conversion failing for Integer method.

2008-11-13 Thread Carlos Luis Zúñiga Sibaja
Actually, this is a problem in OGNL, because the version bundled with Struts 2.1.2 cannot handle objects with generifyed properties. This definitively sucks since it prevents a lot of code reuse, in my specific experience I had a similar implementation for a base ModelObject and an AbstractCrudActi

Re: Migrating to 2.0.12 General Availability Release

2008-11-13 Thread esemba
seems like bug: http://www.nabble.com/-s2.0.12-Client-validation-not-working-to20372886.html https://issues.apache.org/struts/browse/WW-2849 http://www.nabble.com/s%3Adatetimepicker-doesn%27-t-work-after-upgraded-to-struts2.0.12-td20245780.html Tomi21 wrote: > > Hi everyone, > > I've migrated

RE: Advanced Struts 2 Validation Question...

2008-11-13 Thread Jishnu Viswanath
You can write java validation Try like this in xml FirstName Regards, Jishnu Viswanath Software Engineer *(+9180)41190300 - 222(Ext) ll * ( + 91 ) 9731209330ll Tavant Technologies Inc., www.tavant.com PEOPLE :: PASSION :: EXCEL

Re: Advanced Struts 2 Validation Question...

2008-11-13 Thread Bill Harper
Implement Valiadateable in your action and the Workflow interceptor will call validate() before and action method If your validate() method adds ActionErrors then the messages go back to the input form. You will also need to configure / annotate an "input" result. I can't remember off the top of

Re: Advanced Struts 2 Validation Question...

2008-11-13 Thread Néstor Boscán
if you want javascript validation you will have to create your own theme and own validation. You will have to create your own validator class and modify the form-close-validation.ftl. This is what I've done in the past. Once you figure out the details you start creating and reusing validators. On

Advanced Struts 2 Validation Question...

2008-11-13 Thread Burton Rhodes
How do I use validation in an [Action]-validation.xml file to validate several fields? I need to implement the following logic for 3 fields on a form: Company, FirstName, LastName. Psedo Code: If Company empty, then FirstName and LastName must be filled If FirstName and LastName empty, then Comp

RE: [S2] JSON plugin parser error

2008-11-13 Thread Relph,Brian
Thanks for the pointer, you are right, json does not like objects as keys. I re-worked my data structure, and the serialized response was valid. Brian Relph -Original Message- From: Musachy Barroso [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 11, 2008 8:45 PM To: Struts Users M

Re: Problem with debug mode

2008-11-13 Thread Dave Newton
--- On Thu, 11/13/08, Tomi21 wrote: > I wanted to know how to turn on the debug mode in > struts2(2.10.12 GA). > I use and it seems > not working because no messages are shown. That's only for JavaScript/Dojo debugging. What debugging are you trying to turn on? Dave --

Re: welcome.do ignored in my web.xml

2008-11-13 Thread diogo pontual
Try creating a empty text file welcome.do in your WebContent dir. Best regards, Diogo On Thu, Nov 13, 2008 at 10:07 AM, Nils-Helge Garli Hegvik <[EMAIL PROTECTED]>wrote: > Your container probably only supports file resources as welcome files. > Try creating a jsp that forwards to your struts ac

Re: welcome.do ignored in my web.xml

2008-11-13 Thread Nils-Helge Garli Hegvik
Your container probably only supports file resources as welcome files. Try creating a jsp that forwards to your struts action instead. Nils-H On Thu, Nov 13, 2008 at 11:42 AM, Cappelletti Marc <[EMAIL PROTECTED]> wrote: > Hi all, > > I've mapped my struts action *.do in the web.xml file and it wo

Re: Highlighting a field with a validation error in struts 2

2008-11-13 Thread Arpan Debroy
If we use "simple" theme, then also can we make that? On Thu, Nov 13, 2008 at 12:18 PM, Andras Balogh <[EMAIL PROTECTED]> wrote: > Hi, > > I think the easiest way would be to copy from struts2-core-xx.jar the > validation.js based on the theme and put it in your source package folder . > So examp

Problem with debug mode

2008-11-13 Thread Tomi21
Hello everyone, I wanted to know how to turn on the debug mode in struts2(2.10.12 GA). I use and it seems not working because no messages are shown. Thanks in advance. -- View this message in context: http://www.nabble.com/Problem-with-debug-mode-tp20478652p20478652.html Sent from the Struts

welcome.do ignored in my web.xml

2008-11-13 Thread Cappelletti Marc
Hi all, I've mapped my struts action *.do in the web.xml file and it works when I access a struts action directly with the URL (eg: http://localhost:8080/mcbc/welcome.do ) But, when I go to the root of my webapp (http://localhost:8080/mcbc/ ), my welcome-

[S2] Problems including dojo

2008-11-13 Thread Jan Froehlich
Hi there... I have an existing web application based on a servlet. As I need to extend it and dont want to mess around with the old code, I want to add struts2 capabilites and do some reengineering for the extension. My problem is, that I have registered the struts2 filter with the /ext/* When I

Struts2, REST, JSON content encoding, UTF8

2008-11-13 Thread Alex Milanovic
Hi All, I am using the REST plugin for Struts 2.1.3-SNAPSHOT. I want to make sure that the content encoding for the JSON output from the server is always in UTF8. How can I do this? Thanks, Alex - To unsubscribe, e-mail: [EMAIL