From 9a1e482a8018fb491e42da566641ea7e5c288712 Mon Sep 17 00:00:00 2001 From: Argo Window10 Date: Sun, 8 Dec 2019 10:17:39 +0800 Subject: [PATCH] =?UTF-8?q?fix(#I1645P):=20=E8=A7=92=E8=89=B2=E5=AF=B9?= =?UTF-8?q?=E7=94=A8=E6=88=B7=E6=8E=88=E6=9D=83=E5=BC=B9=E7=AA=97=E5=86=85?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=BF=87=E6=BB=A4=E6=9D=A1=E4=BB=B6=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #Issue link https://gitee.com/LongbowEnterprise/BootstrapAdmin/issues/I1645P --- .../Bootstrap.Admin/Views/Shared/UserConfig.cshtml | 13 +++++++++++++ src/admin/Bootstrap.Admin/wwwroot/js/roles.js | 9 +++++++++ 2 files changed, 22 insertions(+) diff --git a/src/admin/Bootstrap.Admin/Views/Shared/UserConfig.cshtml b/src/admin/Bootstrap.Admin/Views/Shared/UserConfig.cshtml index ef22b0d0..d1c0fd51 100644 --- a/src/admin/Bootstrap.Admin/Views/Shared/UserConfig.cshtml +++ b/src/admin/Bootstrap.Admin/Views/Shared/UserConfig.cshtml @@ -7,6 +7,19 @@ diff --git a/src/admin/Bootstrap.Admin/wwwroot/js/roles.js b/src/admin/Bootstrap.Admin/wwwroot/js/roles.js index f549aca8..534e980b 100644 --- a/src/admin/Bootstrap.Admin/wwwroot/js/roles.js +++ b/src/admin/Bootstrap.Admin/wwwroot/js/roles.js @@ -172,4 +172,13 @@ $(function () { $nestMenu.find('[data-category="1"]').removeClass('d-none'); } }); + + // 用户列表过滤 + var $userFilter = $('#useFilter').on('input', 'input', function (e) { + var userName = $(this).val(); + $userFilter.next().find('.checkbox-label').each(function (index, element) { + if ($(element).text().toLocaleLowerCase().indexOf(userName.toLocaleLowerCase()) === -1) $(element).parents(".form-group").hide(); + else $(element).parents(".form-group").show(); + }); + }); }); \ No newline at end of file