PDA

View Full Version : loadRecord into a radio button



iamcootis
16 Jan 2014, 6:42 AM
I have a form that includes some textfields and a radiogroup with two buttons 'bandwidth' and 'flows. The radio group looks like this.



{
xtype: 'radiogroup',
flex: 1,
width: 400,
fieldLabel: 'Weight According to',
allowBlank: false,
vertical: true,
layout: {
type: 'vbox',
align: 'stretch'
},
items: [
{
xtype: 'radiofield',
boxLabel: 'Bandwidth',
name: 'weightType',
value: 'bandwidth'
},
{
xtype: 'radiofield',
boxLabel: 'Flows',
name: 'weightType',
value: 'flows'
}
]
}


my data object contains a value that looks like this: weightType = 'bandwidth'

When I do a loadRecord, the textFields are populated, but my radiobuttons are not. Am I doing something wrong? I have also tried putting the name field on the radiogroup, but that also did not work.

jay@moduscreate.com
17 Jan 2014, 10:24 AM
what are the values for "weightType" in your model?

iamcootis
17 Jan 2014, 10:40 AM
I figured this out. The correct parameter was inputValue not value in the radiobutton.