You do not need a custom logic converter, use the Struts2 internationalization function to get βgoodβ Boolean texts. Put true = Yes and false = No in your message properties, and then use the listValue attribute of the <s:select> to call the getText method to receive messages for true and false .
<s:select key="invoice.productSold" list="productSold" listValue="%{getText(top)}"/>
By the way, you do not need to use any "special" notation inside the list attribute to get the value from the value stack.
BTW No. 2: you do not need this productSold method inside your action, instead you can define your yes / no list directly in the JSP using the OGNL notation for lists {...} .
<s:select key="invoice.productSold" list='{"", true, false}' listValue="%{getText(top)}"/>
source share