Jeff Storey
Jeff Storey

Reputation: 57212

grails set bean value from radio button

I'm somewhat new to grails (not groovy though) and I'm working on a sample CRUD application. The issue I'm trying to solve is how to set a property on a bean based on a radio button before I update it in the database. Is the Form Helper http://www.grails.org/plugin/form-helper plugin the way to go? Will the bean have its value set regardless of if the button is actually clicked by the user or if it is left at its default value?

thanks, Jeff

Upvotes: 2

Views: 1136

Answers (1)

JeffSea
JeffSea

Reputation: 385

Have you tried setting the name of the radio buttons to the bean property name and include the radio buttons in your form or remoteForm submission?

Upvotes: 1

Related Questions