mirror of https://github.com/layui/layui
修复 dropdown 未设置 `click` 回调函数时无法关闭的问题
parent
f7695d5279
commit
12ef156cbb
|
@ -285,7 +285,10 @@ layui.define(['jquery', 'laytpl', 'lay'], function(exports){
|
|||
|
||||
// 普通菜单项点击后的回调及关闭面板
|
||||
if((!isChild || isClickAllScope) && data.type !== '-'){
|
||||
var ret = typeof options.click === 'function' && options.click(data, othis);
|
||||
var ret = typeof options.click === 'function'
|
||||
? options.click(data, othis)
|
||||
: null;
|
||||
|
||||
ret === false || (isChild || that.remove());
|
||||
layui.stope(e);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue