[Bugfix] 修复只显示当前节点下资产不生效的问题

pull/4021/head
Bai 5 years ago
parent 4ec4869896
commit 7c44f74068

@ -58,7 +58,9 @@ class AssetByNodeFilterBackend(filters.BaseFilterBackend):
if query_all:
pattern = node.get_all_children_pattern(with_self=True)
else:
pattern = node.get_children_key_pattern(with_self=True)
# pattern = node.get_children_key_pattern(with_self=True)
# 只显示当前节点下资产
pattern = r"^{}$".format(node.key)
return self.perform_query(pattern, queryset)

Loading…
Cancel
Save