fix(#I10GSQ): 角色管理分配菜单复选框状态未刷新

#Comment
comment #I10GSQ
jQuery 操作 checkbox 使用 prop 代替 attr

#Issue
close https://gitee.com/LongbowEnterprise/dashboard/issues?id=I10GSQ
This commit is contained in:
Argo Zhang 2019-08-10 15:38:34 +08:00
parent 8308e95a20
commit 6b3600b603
No known key found for this signature in database
GPG Key ID: 152E398953DDF19F
1 changed files with 2 additions and 2 deletions

View File

@ -64,10 +64,10 @@ $(function () {
$btnSubmitMenu.data('type', 'menu');
// set checkbox status
var menus = $nestMenu.find('input:checkbox');
menus.attr('checked', false);
menus.prop('checked', false);
$.each(result, function (index, item) {
var selector = $.format('[value={0}]', item.Id);
menus.filter(selector).attr('checked', true);
menus.filter(selector).prop('checked', true);
});
$dialogSubMenu.show();
$dialogMenu.modal('show');