首页 新闻 会员 周边

easyUI单元格编辑问题,急求高人指点

0
悬赏园豆:20 [已解决问题] 解决于 2014-05-23 09:19

代码如下,绑定数据没有问题,下拉列表也可以显示,但是编辑该单元格时,因绑定的字段名与下拉列表字段名不一致,无法显示新选中内容,急求高人指点

<th data-options="field:'userName',width:80,formatter:function(value,row,index){
if (row.recipient){
return row.recipient.userName;
} else {
return row.userName
}
}, editor:{
type:'combobox',
options:{
valueField:'userName',
textField:'userName',
url:'../MstInquiry/show_recipientlist.do',
required:true
}
}">Name</th>

so...的主页 so... | 初学一级 | 园豆:59
提问于:2014-05-23 09:02
< >
分享
最佳答案
0

<th data-options="field:'userName',width:80,formatter:function(value,row,index){
if(value==null||value==''){
if (row.recipient){
return row.recipient.userName;
} else {
return value;
}
}else{
return row.userName;
}}, editor:{
type:'combobox',
options:{
valueField:'userName',
textField:'userName',
url:'../MstInquiry/show_recipientlist.do',
required:true
}
}">Name</th>

so... | 初学一级 |园豆:59 | 2014-05-23 09:18
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册