Browse Source

chore(dropdown): 将 dropdown id 添加到触发元素 (#1761)

pull/1784/head
morning-star 8 months ago committed by GitHub
parent
commit
394c7e7ee7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 4
      src/modules/dropdown.js

4
src/modules/dropdown.js

@ -150,6 +150,10 @@ layui.define(['jquery', 'laytpl', 'lay', 'util'], function(exports){
elem.attr('id') || that.index
);
if(!lay.isTopElem(elem[0])){
elem.attr('lay-id', options.id);
}
// 初始化自定义字段名
options.customName = $.extend({}, dropdown.config.customName, options.customName);

Loading…
Cancel
Save