0

I have this field in my JSP file:

<s:hidden name="testResult.bottle" value="${testResultsActionBean.testResult.bottle.id}" />

and I get this:

<input name="testResult.bottle" value="package.dto.BottleDto@e8" type="hidden" />

But this line of code returns ID, which I need as value in the hidden input:

<c:out value="${testResultsActionBean.testResult.bottle.id}"></c:out>

How can I get ID as value in input?

Thanks for any advice.

user152468
  • 3,202
  • 6
  • 27
  • 57
kmaci
  • 3,094
  • 2
  • 18
  • 28

1 Answers1

1

Stripes always prefers the value from the action bean over anything you put in the value attribute. (Even if the value in the action bean is null)

Use this:

<s:hidden name="testResult.bottle.id"/>
Matt Jennings
  • 1,148
  • 6
  • 11