Dropdown box fetch values from JS.

2010-11-22 Thread Rajesh
Hi All,     Actually I have a requirement, which fetch the drop down values from JS and show it in jsp.     I have to use ajax auto completer  to achieve this.     Here the issue is, i can able to enter any value in the auto completer box and pass that value to datab

Re: JSON plugin suggest : parse String value "" to Number with null / 0

2010-11-22 Thread Maurizio Cucchiara
Hi Knight, I take your point, JSONPopulator.convertPrimitive function maybe uses a wrong approach. Does anyone know why convert method process is driven by value and type instead of target type only? 2010/11/23 Knight Chen > Hi All, > Thanks for reply, and sorry for my poor English. > > In this

Re: JSON plugin suggest : parse String value "" to Number with null / 0

2010-11-22 Thread Knight Chen
Hi All, Thanks for reply, and sorry for my poor English. In this case: I have a POJO: public class UserDTO { private int age; ... public void setAge(int age) { this.age = age; } } And Action has a property with this type: public Class UserAction { priv

Re: JSON plugin suggest : parse String value "" to Number with null / 0

2010-11-22 Thread Maurizio Cucchiara
I'm not sure understand what you mean, it could be ognl conversion related. For further details, could you provide the NPE stack? 2010/11/22 Knight Chen > Hi all, > > I often encounter Number format exception when I use JSON plugin to > parse input String "" from AJAX request to Number, > becaus

Re: JSON plugin suggest : parse String value "" to Number with null / 0

2010-11-22 Thread Mead Lai
Hello Knight, I think you can change the Value-Object(Model obj), modify the get method code: if(this.value.equal("")){ this.value=null; or this.value=0 } You can pass a Value-Object to server side, instead of Json-Text formation. Regards, Mead On Mon, Nov 22, 2010 at 8:12 PM, K

RE: ActionErrors and ActionMessages not included in the result generated by org.apache.struts2.json.JSONResult

2010-11-22 Thread Alfredo Manuel Osorio Martinez
I found out looking at the code that in order that properties of superclass get included in the json output you need to set ignoreHierarchy param to false: false Alfredo Osorio -Mensaje original- De: Alfredo

Re: Struts 2 and Tiles 2.2 problem - Result type is not recognized

2010-11-22 Thread Dave Newton
Cool; glad you worked it out :) Dave On Mon, Nov 22, 2010 at 2:00 PM, John Dondapati wrote: > Dave, you are absolutely right. Once I put the s2tiles plugin, everything > works. Thanks a bunch. I owe you big time. :) > > On Mon, Nov 22, 2010 at 1:39 PM, Dave Newton > wrote: > > > Doesn't look li

ActionErrors and ActionMessages not included in the result generated by org.apache.struts2.json.JSONResult

2010-11-22 Thread Alfredo Manuel Osorio Martinez
Hello, I'm trying to generate a json output with the JSONResult but the problem is that actionMessages and actionErrors properties are not being included. I also tried to pass this parameter to the interceptor but it didn't work: actionErro

Re: Struts 2 and Tiles 2.2 problem - Result type is not recognized

2010-11-22 Thread John Dondapati
Dave, you are absolutely right. Once I put the s2tiles plugin, everything works. Thanks a bunch. I owe you big time. :) On Mon, Nov 22, 2010 at 1:39 PM, Dave Newton wrote: > Doesn't look like you have the S2 Tiles plugin anywhere. > > http://struts.apache.org/2.x/docs/tiles-plugin.html > >

Re: Struts 2 and Tiles 2.2 problem - Result type is not recognized

2010-11-22 Thread Dave Newton
Doesn't look like you have the S2 Tiles plugin anywhere. http://struts.apache.org/2.x/docs/tiles-plugin.html Without it there is no way for S2 to know what a tiles result actually *means*. Once S2 knows what Tiles even is, you still need to set

Struts 2 and Tiles 2.2 problem - Result type is not recognized

2010-11-22 Thread John Dondapati
Hi, I am very new to Struts 2 and really want to use it in a project at work. We have Struts 2, Spring 2.5.6 working peacefully together and I wanted to add Tiles 2.2 on to the stack to experiment with it. I have added all the dependencies in the maven and they are all available. I am following t

JSON plugin suggest : parse String value "" to Number with null / 0

2010-11-22 Thread Knight Chen
Hi all, I often encounter Number format exception when I use JSON plugin to parse input String "" from AJAX request to Number, because in Web front, that will be a zero length String "" transfer to backend if the text input has no enter, so will encounter the Number format exception for input Str

Re: Initial setup

2010-11-22 Thread Peter Nguyen
http://struts.apache.org/2.2.1/index.html On Sun, Nov 21, 2010 at 7:08 PM, Brajesh Patel wrote: > Hi all, > Please provide initial setup guide for struts, it will great help for me. > > -- > Thanks > Brajesh Patel >

Re: Initial setup

2010-11-22 Thread Greg Akins
On Sun, Nov 21, 2010 at 11:12 PM, Brajesh Patel wrote: > Hi Dave, > Thanks for your quick support. > > I am going for 2.2.1 that jar I have downloaded, also please provide doc > where I found it. There is a documentation link on the http://struts.apache.org site. But for your convenience try thi

Re: Initial setup

2010-11-22 Thread M. Rakowski
Docs and sample applications are in the same place: http://struts.apache.org/download.cgi#struts221 I am going for 2.2.1 that jar I have downloaded, also please provide doc where I found it. - To unsubscribe, e-mail: user-un