From d05e9d0b45ac135729e2b2f433c3eccc96320189 Mon Sep 17 00:00:00 2001 From: ibuler Date: Mon, 9 May 2016 18:53:04 +0800 Subject: [PATCH] =?UTF-8?q?modify(jperm)=20=E6=8E=88=E6=9D=83=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E6=A8=A1=E7=B3=8A=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修改授权规则搜索为模糊搜索 --- jperm/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jperm/views.py b/jperm/views.py index 6e7036098..f546079c2 100644 --- a/jperm/views.py +++ b/jperm/views.py @@ -38,7 +38,7 @@ def perm_rule_list(request): rules_list = rules_list.filter(id=rule_id) if keyword: - rules_list = rules_list.filter(Q(name=keyword)) + rules_list = rules_list.filter(Q(name__icontains=keyword)) rules_list, p, rules, page_range, current_page, show_first, show_end = pages(rules_list, request)