I'm using a standard select menu nested within a loop. The boolean values come from my hibernate entity. I took a look at the enumSelectModel, I'm just not sure how to get it to work with my entity.
.tml <t:Loop source="fields" value="field" encoder="encoder"> <div class="col-xs-15"> <div> <t:Select value="field.propertyValue" clientId="${field.propertyName}" model="selectModel" blankOption="literal:never" encoder="encoderSelect"/> </div> </div> </t:Loop> .java @Property private FieldEntity field; @Prroperty private List<FieldEntity> fields; @Inject private SelectModelFactory selectModelFactory public SelectModel getSelectModel() { List<Boolean> tardies = new ArrayList<Boolean>(); tardies.add(true); tardies.add(false); return this.selectModelFactory.create(tardies); } public ValueEncoder getEncoderSelect() { return new ValueEncoder<Boolean>() { public String toClient(Boolean value) { return value.toString(); } public Boolean toValue(String clientValue) { return "true".equals(clientValue) ? true : false; } }; } FieldEntity.class @NonVisual private boolean tsTardy01; @NonVisual private boolean tsTardy02; @NonVisual private boolean tsTardy03; @NonVisual private boolean tsTardy04; On Thu, Sep 19, 2013 at 9:03 AM, Eugen <eugens...@gmail.com> wrote: > Hi, > which select model are You using? > if You use an EnumSelectModel the client side caption is build as follow: > Enum.class.getSimpleName()+"."+Enum.name() > > > 2013/9/19 George Christman <gchrist...@cardaddy.com>: > > Hello, I'm wondering if anybody knows how to rename the options in a > select > > menu using .properties or some other method. I currently have true false > in > > the menu and that needs to be changed to Y N. > > > > Thanks, > > George > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > -- George Christman www.CarDaddy.com P.O. Box 735 Johnstown, New York