I am using JQGrid with two radio button columns
{ name: 'Primary', index: 'Primary', width: 60, align: 'left', formatter: RadioPrimary },
{ name: 'Secondary', index: 'Secondary', width: 60, align: 'left', formatter: RadioSecondary }
and the Radio buttons are defined as below:
function RadioSecondary() {
return "<input type=radio name=rbtn id=rbtnSecondary />";
}
function RadioPrimary() {
return "<input type=radio name=rbtn id=rbtnPrimary />";
}
My requirement is : In each row, i have to select either Primary or Secondary Radio button.
My Problem is:
1. If i dont specify the name attribute, i am not able to select Radiobutton.
2. If i specify the same name to both Radiobuttons, then it is allowing to select only 1 Radiobutton (out of many rows)
3. If i give different names to Primary and Secondary radiobuttons, the GroupName concept is applying columnwise. I.e i can select only one Primary radiobutton and 1 Secondary Radiobutton
Please let me know how to solve this issue..