Re: Redirect List Parameter

2010-01-29 Thread Timothy Orme
lso need to be aware that there are length limits to url's so if orderNumbers is too big you can have problems. It may be a a better idea to just save the orderNumbers in the session (or some other cache) instead of passing it as a parameter. On Fri, Jan 29, 2010 at 1:25 PM, Timothy Orme wrote:

Re: Redirect List Parameter

2010-01-29 Thread Timothy Orme
270-809-5359 On 01/29/2010 11:12 AM, Timothy Orme wrote: Hello All, I have a typical scenario: 1. User is presented a list of orders, and can select some of them to complete. A list of order numbers is sent to the next action. (ViewOrders.action) 2. Struts action comple

Redirect List Parameter

2010-01-29 Thread Timothy Orme
Hello All, I have a typical scenario: 1. User is presented a list of orders, and can select some of them to complete. A list of order numbers is sent to the next action. (ViewOrders.action) 2. Struts action completes the order by iterating through the list of passed order numbers.

Re: Struts 2/JSON/Hibernate/c3p0/Oracle issue

2009-12-14 Thread Timothy Orme
UCCESS; } public String getStatusName() { return statusName; } } Works fine. Maybe I'm wrong, but shouldn't the status be the full object and not a proxy when I do findById? Thanks, -Tim Timothy Orme wrote: Ill give this a whirl, and you're probably right, bu

Re: Struts 2/JSON/Hibernate/c3p0/Oracle issue

2009-12-14 Thread Timothy Orme
with JSON. Greg On Mon, Dec 14, 2009 at 3:45 PM, Timothy Orme wrote: Hello, I just recently switched to c3p0 and it fixed some other issues I was having with dbcp, but another has arisen. It seems to be a combination of using the c3p0 data source along with the JSON plugin. Here'

Struts 2/JSON/Hibernate/c3p0/Oracle issue

2009-12-14 Thread Timothy Orme
Hello, I just recently switched to c3p0 and it fixed some other issues I was having with dbcp, but another has arisen. It seems to be a combination of using the c3p0 data source along with the JSON plugin. Here's my (slightly shortened) stacktrace: Caused by: org.apache.struts2.json.JSO

Passing List with Redirect

2009-10-13 Thread Timothy Orme
Hi All I'm wondering if theres a way to pass a list of values as a parameter in a redirectAction. For instance: ViewAction ${myList} ${myProperty} In this case, myList is an array list that is populated in

Re: Downloading a Streamed File

2009-07-24 Thread Timothy Orme
, Tim Orme Timothy Orme wrote: Right, I figured that it wasn't a struts specific issue, but thought that I might have been using the wrong content disposition or something along those lines. However, upon further prodding, it seems that this is more an issue of response time with the browser.

Re: Downloading a Streamed File

2009-07-24 Thread Timothy Orme
attachment; filename="${fileName}.zip" ViewDownloadForm.action Thanks, Tim Dale Newfield wrote: Timothy Orme wrote: I still have the same issue though. Right clicking the link doesn't work and the filename is still listed as the action. As far as struts is conce

Re: Downloading a Streamed File

2009-07-24 Thread Timothy Orme
Hey, Not sure where I got this from, but I've corrected it so that all the properties are in the struts.xml instead of modifying it in the code. I still have the same issue though. Right clicking the link doesn't work and the filename is still listed as the action. Thanks, Tim Dale Newfield

Downloading a Streamed File

2009-07-24 Thread Timothy Orme
Hello, I did some digging on this but couldn't find anything. I have an action which is returning a streamed result. I create a zip file in memory and stream it out to the user. This works fine when the user simply clicks the link. I get the correct file, with the right name. However, as of rig

Re: Need help writing an interceptor to force a user to change their password

2009-06-29 Thread Timothy Orme
You should be able to just create a global result with the jsp you want. Ala: /passwordChange.jsp Then have the interceptor return that string when needed. Any time it's true, the result will get hit and the user will get fowarded. Unless I'm missing something. -Tim Russell Neufel

Re: Disabling JSP's

2009-05-15 Thread Timothy Orme
Ah perfect, I was not aware this was the case. Thanks! Jim Kiley wrote: Put the JSP under /WEB-INF -- it is accessible to Struts routing but not directly viewable by end clients. jk On Fri, May 15, 2009 at 2:36 PM, Timothy Orme wrote: Hello All, I'm in the process of migrating

Disabling JSP's

2009-05-15 Thread Timothy Orme
Hello All, I'm in the process of migrating pages from JSP's using snippets to struts actions. I'm wondering how people have disabled access to JSP's so that they cannot be accessed outside of the action anymore. Right now if I have an action like: /priv

Re: Struts 2 Namespaces

2009-05-07 Thread Timothy Orme
Right, but I'm wondering what happens if 2 packages have the SAME namespace and each have an action with the same name like: etc. etc. Which one gets selected? -Tim Martin Gainty wrote: extends attribute: The extends attribute is optional and allows one package to inheri

Re: Please help! Struts 2/Eclipse - List Object is not displaying in JSP

2009-05-07 Thread Timothy Orme
Ah good catch, this is whats causing it. Although as I said, you dont need to rename the method if you've setup your struts.xml as it is. Jim Kiley wrote: Even then it won't be OK. The OP is declaring myList as a local variable in getAllEmployees(), so getMyList won't return it. Change the li

Re: Please help! Struts 2/Eclipse - List Object is not displaying in JSP

2009-05-07 Thread Timothy Orme
This is actually not correct, he defined the method as "getAllEmployees" in his struts.xml That said, I'm not sure of the default behavior of the s:property tag. Have you tried something like s:property value="top"? I'm not huge on the struts tag libs, but this would be the first place I'd lo

Struts 2 Namespaces

2009-05-07 Thread Timothy Orme
Hello All, I just have a quick question concerning struts 2 namespaces. Mainly, are they unique? I have a book "Practical Apache Struts 2 Web 2.0 Projects" which states that: "The name attribute as well as the namespace attribute must be unique. If not Struts 2 will n

Re: Struts 2/Spring and @Required

2009-04-06 Thread Timothy Orme
probably missing. musachy On Mon, Apr 6, 2009 at 2:34 PM, Timothy Orme wrote: Hello All, One of the nice annotation features of spring is the ability to annotate injected fields with @Required so that you don't get null pointer exceptions. However, I can only seem to get this to wo

Re: Struts 2/Spring and @Required

2009-04-06 Thread Timothy Orme
rt of configuration would be needed to get this to work? Thanks, Tim Musachy Barroso wrote: You should post your spring xml config file, it looks like some AOP config is probably missing. musachy On Mon, Apr 6, 2009 at 2:34 PM, Timothy Orme wrote: Hello All, One of the nice annot

Struts 2/Spring and @Required

2009-04-06 Thread Timothy Orme
Hello All, One of the nice annotation features of spring is the ability to annotate injected fields with @Required so that you don't get null pointer exceptions. However, I can only seem to get this to work with my test cases (spring throws an error when a required field isn't set), but I can't

Re: Best Practices for Forms

2009-03-17 Thread Timothy Orme
Awesome, thank you! Greg Lindholm wrote: Well that's about the most common question one sees on this list. Check this out: http://struts.apache.org/2.1.6/docs/how-do-we-repopulate-controls-when-validation-fails.html Timothy Orme wrote: Hi Greg, Thanks, I actually just stu

Re: Best Practices for Forms

2009-03-17 Thread Timothy Orme
/2008/07/02/preserving-messages-across-a-redirect-in-struts-2/ Timothy Orme wrote: Sorry to revive an old thread here, but I've run into another issue with this. I decided to go with the second of Hernan's recommendations here, so I now have the following "flow". 1. User vi

Re: Best Practices for Forms

2009-03-17 Thread Timothy Orme
So this actually doesn't seem to work. Seems that I can't have the dispatcher result have an action as a parameter. Seems like it can only find a jsp even if I write out the full path to the action. Does anyone have any other suggestions on this? Thanks, Tim Orme Timothy Orme wro

Re: Best Practices for Forms

2009-03-17 Thread Timothy Orme
rs) and finally submited back again That kind of scheme works for me well, but i don't claim it's best. Best greetings, Paweł Wielgus. 2009/3/17 Timothy Orme : Sorry to revive an old thread here, but I've run into another issue with this. I decided to go with the second of Herna

Re: Best Practices for Forms

2009-03-17 Thread Timothy Orme
ay to do it. Does anyone have any suggestions? Thanks, Tim Timothy Orme wrote: Ok, this helps a lot. Simply from a usability standpoint though, the latter example seems more in line with what I'd want. It seems silly to have to bring the user to a page where, in my case, they would invariabl

Re: Best Practices for Forms

2009-03-02 Thread Timothy Orme
Ok, this helps a lot. Simply from a usability standpoint though, the latter example seems more in line with what I'd want. It seems silly to have to bring the user to a page where, in my case, they would invariably click a link. I was aware of the TokenSession interceptor, and as you stated, it do

Re: Best Practices for Forms

2009-03-02 Thread Timothy Orme
I'm not really sure what you're suggesting here. Are you saying that I should put the dataId attribute in the session instead of passing it to the page? I'm not really sure what that helps, and in fact it only seems to complicate the issue. Maybe I'm misunderstanding? Thanks, -Tim Martin Gainty

Best Practices for Forms

2009-03-02 Thread Timothy Orme
Hello All, I'm relatively new to Struts 2 and have a few questions as far as how to lay out a form correctly. I have the following scenario: 1. User is presented a form. (addData.jsp) 2. User submits form, we go off to an action to add form information to the database. (SubmitData.action) 3.

Re: Incorrect Bean Injected

2009-01-22 Thread Timothy Orme
e fix (quick and dirty solution). musachy On Fri, Jan 16, 2009 at 2:50 PM, Timothy Orme wrote: Excellent, thank you! Just out of curiosity, what would the release timeline be on this? Thanks, Tim Musachy Barroso wrote: I looked at the code and it cannot be set to none. I fixed it in struts and

Re: Incorrect Bean Injected

2009-01-16 Thread Timothy Orme
oWire" to "no". The spring value is AutowireCapableBeanFactory.AUTOWIRE_NO, so I followed the pattern and used "no" instead of "none". musachy On Fri, Jan 16, 2009 at 11:41 AM, Timothy Orme wrote: So scratch that, I figured out that Struts is set to autowire b

Re: Incorrect Bean Injected

2009-01-16 Thread Timothy Orme
ied both "none" as well as "no" and neither had any effect. Relph,Brian wrote: Did you try setting the value="none"? Brian Relph -Original Message- From: Timothy Orme [mailto:to...@genome.med.harvard.edu] Sent: Friday, January 16, 2009 10:41 AM To: Struts Us

Re: Incorrect Bean Injected

2009-01-16 Thread Timothy Orme
etting the value="none"? Brian Relph -Original Message- From: Timothy Orme [mailto:to...@genome.med.harvard.edu] Sent: Friday, January 16, 2009 10:41 AM To: Struts Users Mailing List Subject: Re: Incorrect Bean Injected So scratch that, I figured out that Struts is set to auto

Re: Incorrect Bean Injected

2009-01-16 Thread Timothy Orme
Yeah, I tried both "none" as well as "no" and neither had any effect. Relph,Brian wrote: Did you try setting the value="none"? Brian Relph -----Original Message- From: Timothy Orme [mailto:to...@genome.med.harvard.edu] Sent: Friday, January 16, 2009 10:4

Re: Incorrect Bean Injected

2009-01-16 Thread Timothy Orme
Here is the link to the feature request. https://issues.apache.org/struts/browse/WW-2765 Timothy Orme wrote: So scratch that, I figured out that Struts is set to autowire by default with the spring plugin. In my struts.xml I have: value="org.apache.struts2.spring.StrutsSpringObjectFa

Re: Incorrect Bean Injected

2009-01-16 Thread Timothy Orme
x27;t been filled yet. Has anyone devised a workaround? Thanks, Tim Orme Timothy Orme wrote: This seems really strange to me, but I don't know the inner workings of struts enough to know if it's expected behavior. I'm using Struts 2.1.2 and spring 2.5.3 I have a 2 service bean

Incorrect Bean Injected

2009-01-16 Thread Timothy Orme
This seems really strange to me, but I don't know the inner workings of struts enough to know if it's expected behavior. I'm using Struts 2.1.2 and spring 2.5.3 I have a 2 service beans that have the same name, but depending on the action, one might be used instead of the other.

Error Throwing With Struts 2 Tags

2009-01-06 Thread Timothy Orme
Hello All, Maybe a silly question, but I've recently noticed that using struts 2 tags can be very problematic when it comes to debugging. For instance, I recently wrote something like: But no value was displayed. This is because I should have written: As t

Re: Dojo datetimepicker problem

2008-12-04 Thread Timothy Orme
Were you able to get this to pass through as a date? After reading what was posted here it seems like it definitely should be possible, but that you were still having issues. -Tim Dimitar Vlasev wrote: Though it would be even elegant enough solution if I was able to refer to the static patter

Re: Dojo datetimepicker problem

2008-12-02 Thread Timothy Orme
Hello, Someone might have to jump in and correct me on this but I think that it should just be coming in as a string. As I understand it, the form's action doesn't know that you're using a datepicker in the form, it only sees a text field with a value (a string). Struts tag libs just generate H

Exception Fowarding

2008-11-12 Thread Timothy Orme
Hello, I have a somewhat complex form for user registration which has several dropdown lists that pull from a database. I created an action called "RegisterUserFORM" which creates the dao objects necessary for the dropdowns to be made on the JSP page. This form then submits to another actio