|
发表于 2013-9-11 15:27:44
|
显示全部楼层
这是显示单选按钮的方法
mainActivity.grid1_fOwnerIDRender = function(event){
var fid = event.rowId;
var html = "<input type='radio' value='0' name='"+fid+"' "+ifChecked("0",event.value)+" onclick=\"saveRadio('"+fid+"',0)\">芒果</input>"
+"<input type='radio' value='1' name='"+fid+"' "+ifChecked("1",event.value)+" onclick=\"saveRadio('"+fid+"',1)\">苹果</input>";
return html;
}
function ifChecked(value,colValue){
if(value==colValue)
return "checked"
else
return "";
}
function saveRadio(rowID,value){
justep.xbl("bizData1").setValue("fOwnerID", value, rowID);
} |
|