需求:扩展行,不同行同一列的内容不能重复选择。
解决方案:
在下拉框控件添加编辑后事件:
if (this.getValue()==null || this.getValue() == '') {
return;
}
var that = this;
$.each($.makeArray(contentPane.getWidgetsByName('name'),[]),function(i,e){
if (e == that)
return true;
if ($(e.element).closest('tr').css('display') != 'none') {
if (that.getValue() == e.getValue()) {
FR.Msg.toast('此销售员已选择, 请重新选择');
that.setValue(null);
return false;
}
}
});