Re: Trouble with tag after upgrading from struts v2.5.31 to v6.3.0.2

2024-01-05 Thread Burton Rhodes
Curious... are the values based off an enum (as opposed to a String)?  
This was an issue for me at one point.



-- Original Message --

From "Pranish Srigiri" 

To user@struts.apache.org
Date 1/5/2024 2:46:36 PM
Subject Trouble with  tag after upgrading from struts v2.5.31 
to v6.3.0.2



Hi All,
I have a situation in my project where the radio buttons are not selected
by default. This has only started happening after I upgraded struts to
v6.3.0.2
Just a heads up, I've upgraded all the dependencies like OGNL, Freemarker,
after I upgraded struts to v6.3.0.2
I have a tag which looks like this.


I set the list 'YesNo' in my Action class that looks like this.
ActionContext.getContext().put("YesNo",
PageData.getInstance().getRadioYesNo(params));
Here PageData.getInstance().getRadioYesNo(params) returns a HashMap.

In my action class sshCompress is set to "N":
sshCompress = "N";
The above variable also has its getter and setter.

When the page loads, the above struts radio tag is rendered like this in
v2.5.31:

Yes
No

but it's rendered like this in v6.3.0.2

Yes

No

If you notice, the radio button with value="N" is not checked by default in
v6.3.0.2 even though sshCompress is being set to "N" in the Action.

I can see this behaviour with all the  tags where the list
attribute is used, I'm not sure what has changed in the new version or if I
have missed adding something.

Like I said, no code has been changed in the project. The dependencies were
upgraded and the necessary compiler issues were resolved.

Please let me know if you need any more information.
Really appreciate all your help.

Thanks and Regards,
Pranish Srigiri


-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Trouble with tag after upgrading from struts v2.5.31 to v6.3.0.2

2024-01-05 Thread Pranish Srigiri
Hi All,
I have a situation in my project where the radio buttons are not selected
by default. This has only started happening after I upgraded struts to
v6.3.0.2
Just a heads up, I've upgraded all the dependencies like OGNL, Freemarker,
after I upgraded struts to v6.3.0.2
I have a tag which looks like this.


I set the list 'YesNo' in my Action class that looks like this.
ActionContext.getContext().put("YesNo",
PageData.getInstance().getRadioYesNo(params));
Here PageData.getInstance().getRadioYesNo(params) returns a HashMap.

In my action class sshCompress is set to "N":
sshCompress = "N";
The above variable also has its getter and setter.

When the page loads, the above struts radio tag is rendered like this in
v2.5.31:

Yes
No

but it's rendered like this in v6.3.0.2

Yes

No

If you notice, the radio button with value="N" is not checked by default in
v6.3.0.2 even though sshCompress is being set to "N" in the Action.

I can see this behaviour with all the  tags where the list
attribute is used, I'm not sure what has changed in the new version or if I
have missed adding something.

Like I said, no code has been changed in the project. The dependencies were
upgraded and the necessary compiler issues were resolved.

Please let me know if you need any more information.
Really appreciate all your help.

Thanks and Regards,
Pranish Srigiri